Browse Source

1

AddValidOverTime
506583276@qq.com 2 years ago
parent
commit
501d80ec49
  1. 2
      BBWY.Client/Helpers/MyPrintHelper.cs
  2. 113
      BBWY.Client/Views/FallWare/SetCloudWareBoxWindow.xaml
  3. 5
      BBWY.Client/Views/FallWare/SetCloudWareBoxWindow.xaml.cs
  4. 6
      BBWY.Client/Views/FallWare/SetJDWareBoxWindow.xaml
  5. 2
      BBWY.Client/Views/FallWare/SetJDWareBoxWindow.xaml.cs

2
BBWY.Client/Helpers/MyPrintHelper.cs

@ -61,7 +61,7 @@ namespace BBWY.Client.Helpers
string barcodeSku = $"POP{barCode.SkuId}"; string barcodeSku = $"POP{barCode.SkuId}";
Barcode barcode = new Barcode(); Barcode barcode = new Barcode();
System.Drawing.Image img = barcode.Encode(TYPE.CODE128, barcodeSku, 500, 40); System.Drawing.Image img = barcode.Encode(TYPE.CODE128, barcodeSku, 500, 40);
SizeF size = args.Graphics.MeasureString(barCode.BrandName, font); SizeF size = args.Graphics.MeasureString("品牌", font);
var sizeHeight = size.Height;//字体高度 var sizeHeight = size.Height;//字体高度
topHeigth += 10; topHeigth += 10;

113
BBWY.Client/Views/FallWare/SetCloudWareBoxWindow.xaml

@ -45,62 +45,63 @@
Background="{StaticResource Border.Background}"> Background="{StaticResource Border.Background}">
<TextBlock Text="{Binding WareType,Converter={StaticResource objConverter},ConverterParameter=云仓:云仓箱唛:聚水潭箱唛}" FontSize="16" HorizontalAlignment="Left" Margin="10 0 0 0" VerticalAlignment="Center"/> <TextBlock Text="{Binding WareType,Converter={StaticResource objConverter},ConverterParameter=云仓:云仓箱唛:聚水潭箱唛}" FontSize="16" HorizontalAlignment="Left" Margin="10 0 0 0" VerticalAlignment="Center"/>
</Border> </Border>
<Grid Grid.Row="1" Margin="2" Name="jd_box"> <Grid Grid.Row="1" Name="jd_box">
<Grid.RowDefinitions> <Grid Margin="50">
<RowDefinition Height="*"/> <Grid.RowDefinitions>
<RowDefinition Height="2*"/> <RowDefinition Height="*"/>
<RowDefinition Height="*"/> <RowDefinition Height="2*"/>
<RowDefinition Height="*"/> <RowDefinition Height="*"/>
<RowDefinition Height="*"/>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition/> <ColumnDefinition/>
<ColumnDefinition/> <ColumnDefinition/>
<ColumnDefinition/> <ColumnDefinition/>
<ColumnDefinition/> <ColumnDefinition/>
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
<Border Height="1" Background="Black" Grid.Row="0" VerticalAlignment="Top" Grid.ColumnSpan="4"/> <Border Height="1" Background="Black" Grid.Row="0" VerticalAlignment="Top" Grid.ColumnSpan="4"/>
<Border Height="1" Background="Black" Grid.Row="0" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/> <Border Height="1" Background="Black" Grid.Row="0" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/>
<Border Height="1" Background="Black" Grid.Row="1" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/> <Border Height="1" Background="Black" Grid.Row="1" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/>
<Border Height="1" Background="Black" Grid.Row="2" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/> <Border Height="1" Background="Black" Grid.Row="2" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/>
<Border Height="1" Background="Black" Grid.Row="3" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/> <Border Height="1" Background="Black" Grid.Row="3" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/>
<Border Height="1" Background="Black" Grid.Row="4" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/> <Border Height="1" Background="Black" Grid.Row="4" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/>
<Border Height="1" Background="Black" Grid.Row="5" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/> <Border Height="1" Background="Black" Grid.Row="5" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/>
<Border Height="1" Background="Black" Grid.Row="6" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/> <Border Height="1" Background="Black" Grid.Row="6" VerticalAlignment="Bottom" Grid.ColumnSpan="4"/>
<Border Width="1" Background="Black" Grid.Column="0" HorizontalAlignment="Left" Grid.RowSpan="7"/> <Border Width="1" Background="Black" Grid.Column="0" HorizontalAlignment="Left" Grid.RowSpan="7"/>
<Border Width="1" Background="Black" Grid.Column="0" HorizontalAlignment="Right" Grid.RowSpan="7"/> <Border Width="1" Background="Black" Grid.Column="0" HorizontalAlignment="Right" Grid.RowSpan="7"/>
<Border Width="1" Background="Black" Grid.Column="3" HorizontalAlignment="Right" Grid.RowSpan="7"/> <Border Width="1" Background="Black" Grid.Column="3" HorizontalAlignment="Right" Grid.RowSpan="7"/>
<Border Width="1" Background="Black" Grid.Column="1" Grid.Row="6" HorizontalAlignment="Right" Grid.RowSpan="1"/> <Border Width="1" Background="Black" Grid.Column="1" Grid.Row="6" HorizontalAlignment="Right" Grid.RowSpan="1"/>
<Border Width="1" Background="Black" Grid.Column="2" Grid.Row="6" HorizontalAlignment="Right" Grid.RowSpan="1"/> <Border Width="1" Background="Black" Grid.Column="2" Grid.Row="6" HorizontalAlignment="Right" Grid.RowSpan="1"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="店铺名称"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="店铺名称"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.ShopName}" Grid.Column="1" Grid.ColumnSpan="3"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.ShopName}" Grid.Column="1" Grid.ColumnSpan="3"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding WareType,Converter={StaticResource taskStateToBoolean},ConverterParameter=云仓:CLPS采购单号:采购单号}" Grid.Row="1"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding WareType,Converter={StaticResource taskStateToBoolean},ConverterParameter=云仓:CLPS采购单号:采购单号}" Grid.Row="1"/>
<StackPanel Orientation="Vertical" HorizontalAlignment="Center" VerticalAlignment="Center" Grid.Row="1" Grid.Column="1" Grid.ColumnSpan="3" Margin="2"> <StackPanel Orientation="Vertical" HorizontalAlignment="Center" VerticalAlignment="Center" Grid.Row="1" Grid.Column="1" Grid.ColumnSpan="3" Margin="2">
<Image Stretch="Fill" Source="{Binding PurchaseOrderImage}"/> <Image Stretch="Fill" Source="{Binding PurchaseOrderImage}"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.PurchaseOrder ,Mode=TwoWay}" /> <TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.PurchaseOrder ,Mode=TwoWay}" />
</StackPanel> </StackPanel>
<TextBlock Style="{StaticResource middleTextBlock}" Text="目的城市-仓库" Grid.Row="2"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="目的城市-仓库" Grid.Row="2"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.WareName}" Grid.Row="2" Grid.Column="1" Grid.ColumnSpan="3"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.WareName}" Grid.Row="2" Grid.Column="1" Grid.ColumnSpan="3"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="箱数" Grid.Row="3"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="箱数" Grid.Row="3"/>
<StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Grid.Row="3" Grid.Column="1" > <StackPanel Orientation="Horizontal" HorizontalAlignment="Center" Grid.Row="3" Grid.Column="1" >
<TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding PrintCount,Mode=TwoWay}"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding PrintCount,Mode=TwoWay}"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="/"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="/"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.BoxCount,Mode=TwoWay}" /> <TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.BoxCount,Mode=TwoWay}" />
</StackPanel> </StackPanel>
<TextBlock Style="{StaticResource middleTextBlock}" Text="商品数量" Grid.Row="3" Grid.Column="2"/> <TextBlock Style="{StaticResource middleTextBlock}" Text="商品数量" Grid.Row="3" Grid.Column="2"/>
<TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.ProductCount}" Grid.Row="3" Grid.Column="3" /> <TextBlock Style="{StaticResource middleTextBlock}" Text="{Binding JDWareBoxModel.ProductCount}" Grid.Row="3" Grid.Column="3" />
</Grid>
</Grid> </Grid>
<!--<c:BButton Grid.Row="2" Content="保存" HorizontalAlignment="Right" Width="105" VerticalAlignment="Center" Height="40" Click="BButton_Click" <!--<c:BButton Grid.Row="2" Content="保存" HorizontalAlignment="Right" Width="105" VerticalAlignment="Center" Height="40" Click="BButton_Click"
Name="btn_save" />--> Name="btn_save" />-->

5
BBWY.Client/Views/FallWare/SetCloudWareBoxWindow.xaml.cs

@ -76,12 +76,7 @@ namespace BBWY.Client.Views.FallWare
this.Width = pageWidth; this.Width = pageWidth;
this.FontSize = 30; this.FontSize = 30;
this.jd_box.Arrange(new Rect(new Point(0, 0), new Size(pageWidth, pageHeight))); this.jd_box.Arrange(new Rect(new Point(0, 0), new Size(pageWidth, pageHeight)));
//794 429 Width="478" Height="440"
//this.jd_box.Arrange(new Rect(new Point((pageWidth - jd_box.DesiredSize.Width) / 2, (pageHeight - jd_box.DesiredSize.Height) / 2), new Size(jd_box.DesiredSize.Width, jd_box.DesiredSize.Height)));
printDialog.PrintVisual(this.jd_box, "打印任务"); printDialog.PrintVisual(this.jd_box, "打印任务");
} }
var applicationPath = System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location); var applicationPath = System.IO.Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
string printNames = System.IO.Path.Combine(applicationPath, "printName.init"); string printNames = System.IO.Path.Combine(applicationPath, "printName.init");

6
BBWY.Client/Views/FallWare/SetJDWareBoxWindow.xaml

@ -38,15 +38,15 @@
<Grid.RowDefinitions> <Grid.RowDefinitions>
<RowDefinition Height="39"/> <RowDefinition Height="39"/>
<RowDefinition/> <RowDefinition Height="*"/>
<RowDefinition Height="0"/> <RowDefinition Height="0"/>
</Grid.RowDefinitions> </Grid.RowDefinitions>
<Border BorderThickness="0,0,0,1" BorderBrush="{StaticResource MainMenu.BorderBrush}" <Border BorderThickness="0,0,0,1" BorderBrush="{StaticResource MainMenu.BorderBrush}"
Background="{StaticResource Border.Background}"> Background="{StaticResource Border.Background}">
<TextBlock Text="京仓箱唛" FontSize="16" HorizontalAlignment="Left" Margin="10 0 0 0" VerticalAlignment="Center"/> <TextBlock Text="京仓箱唛" FontSize="16" HorizontalAlignment="Left" Margin="10 0 0 0" VerticalAlignment="Center"/>
</Border> </Border>
<Grid Grid.Row="1" Name="jd_box" > <Grid Grid.Row="1" Name="jd_box" >
<Grid Margin="10" > <Grid Margin="50,50,50,50" >
<Grid.RowDefinitions> <Grid.RowDefinitions>
<RowDefinition Height="*"/> <RowDefinition Height="*"/>
<RowDefinition Height="2*"/> <RowDefinition Height="2*"/>

2
BBWY.Client/Views/FallWare/SetJDWareBoxWindow.xaml.cs

@ -90,7 +90,7 @@ namespace BBWY.Client.Views.FallWare
this.Height = pageHeight + 39; this.Height = pageHeight + 39;
this.Width = pageWidth; this.Width = pageWidth;
this.FontSize = 30; this.FontSize = 30;
this.jd_box.Arrange(new Rect(new Point(0, 0), new Size(pageWidth, pageHeight))); this.jd_box.Arrange(new Rect(new Point(0, 0), new Size(pageWidth-100, pageHeight-200)));
//794 429 Width="478" Height="440" //794 429 Width="478" Height="440"
//this.jd_box.Arrange(new Rect(new Point((pageWidth - jd_box.DesiredSize.Width) / 2, (pageHeight - jd_box.DesiredSize.Height) / 2), new Size(jd_box.DesiredSize.Width, jd_box.DesiredSize.Height))); //this.jd_box.Arrange(new Rect(new Point((pageWidth - jd_box.DesiredSize.Width) / 2, (pageHeight - jd_box.DesiredSize.Height) / 2), new Size(jd_box.DesiredSize.Width, jd_box.DesiredSize.Height)));

Loading…
Cancel
Save