105040 增加字段,优化数量逻辑,修复检查大小匹配时的错误
This commit is contained in:
parent
ba6c125c95
commit
04b57294ce
|
@ -77,7 +77,7 @@ namespace Sinvo.EplanHpD.Plugin.Test
|
|||
}
|
||||
|
||||
|
||||
[TestMethod]
|
||||
[TestMethod("检查包括D-PE的线")]
|
||||
public void CheckAllWithDPETest()
|
||||
{
|
||||
var vm = new MainViewModel();
|
||||
|
@ -178,7 +178,7 @@ w_00196 BK 黑色RV1.5-CE/定制 42012300001005 C45-1.5-CE/定制 4202010000
|
|||
{
|
||||
WireName = "w_00196",
|
||||
WireColor = "BK",
|
||||
WireModel = "黑色RV1.0-CE/定制",
|
||||
WireModel = "黑色RV2.0-CE/定制",
|
||||
WireCode = "42012300001005",
|
||||
FrontTerminalModel = "C45-1.0-CE/定制",
|
||||
FrontTerminalMaterialCode = "42020100000382",
|
||||
|
|
|
@ -16,5 +16,5 @@ using System.Runtime.InteropServices;
|
|||
[assembly: Guid("aec39474-528b-4da8-b650-99189acb7a2c")]
|
||||
|
||||
// [assembly: AssemblyVersion("1.0.*")]
|
||||
[assembly: AssemblyVersion("1.0.0.0")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.0")]
|
||||
[assembly: AssemblyVersion("1.0.0.5")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.5")]
|
||||
|
|
|
@ -350,8 +350,6 @@
|
|||
</DataGrid.Columns>
|
||||
</DataGrid>
|
||||
</TabItem>
|
||||
|
||||
|
||||
<TabItem Header="导入模板预览">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
|
@ -425,6 +423,27 @@
|
|||
IsChecked="{Binding FlagType, Converter={StaticResource FlagEnumConverter}, ConverterParameter={x:Static util:WireFlagType.Mix}}" />
|
||||
</StackPanel>
|
||||
</GroupBox>
|
||||
<GroupBox Header="检查规则说明">
|
||||
<StackPanel>
|
||||
<StackPanel VerticalAlignment="Center" Orientation="Horizontal">
|
||||
<Rectangle
|
||||
Width="40"
|
||||
Height="20"
|
||||
Fill="#dc4d41" />
|
||||
<TextBlock VerticalAlignment="Center" Text="红色表示该项存在异常" />
|
||||
</StackPanel>
|
||||
<StackPanel VerticalAlignment="Center" Orientation="Horizontal">
|
||||
<Rectangle
|
||||
Width="40"
|
||||
Height="20"
|
||||
Fill="#18a05d" />
|
||||
<TextBlock VerticalAlignment="Center" Text="绿色表示该项正常,检查通过" />
|
||||
</StackPanel>
|
||||
<StackPanel VerticalAlignment="Center" Orientation="Horizontal">
|
||||
<TextBlock VerticalAlignment="Center" Text="检查线时,会根据型号配对表中的数据进行检查,当未与配对表中的信息匹配时,将会提示错误,具体错误请查看每一项的异常信息。" />
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
</GroupBox>
|
||||
</StackPanel>
|
||||
</Grid>
|
||||
</TabItem>
|
||||
|
|
|
@ -135,11 +135,21 @@
|
|||
/// </summary>
|
||||
public string InsulationMaterialNo { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 绝缘软套型号数量
|
||||
/// </summary>
|
||||
public string InsulationQuantity { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 下单日期
|
||||
/// </summary>
|
||||
public string OrderDate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 交货日期
|
||||
/// </summary>
|
||||
public string DeliveryDate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 是否忽略异常
|
||||
/// </summary>
|
||||
|
|
|
@ -46,6 +46,6 @@ using System.Windows;
|
|||
// 生成号
|
||||
// 修订号
|
||||
//
|
||||
[assembly: AssemblyVersion("1.0.0.1")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.1")]
|
||||
[assembly: AssemblyInformationalVersion("1.0.0.2")]
|
||||
[assembly: AssemblyVersion("1.0.0.5")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.5")]
|
||||
[assembly: AssemblyInformationalVersion("1.0.0.5")]
|
|
@ -93,7 +93,7 @@ namespace Sinvo.EplanHpD.Plugin.WPFUI.ViewModel
|
|||
if (item.Insulation != null && item.Insulation.Specification != null)
|
||||
{
|
||||
var match = Consts.regex.Match(item.WireModel);
|
||||
if (!string.IsNullOrEmpty(match.Value))
|
||||
if (!string.IsNullOrEmpty(match?.Value) && match != null)
|
||||
{
|
||||
var itemWireDiameter = double.Parse(match.Value.Replace("RV", ""));
|
||||
var insMatch = Consts.dRegex.Match(item.Insulation.Specification);
|
||||
|
@ -101,7 +101,7 @@ namespace Sinvo.EplanHpD.Plugin.WPFUI.ViewModel
|
|||
{
|
||||
if (itemWireDiameter < 1.5d)
|
||||
{
|
||||
if (insMatch.Value != "V1.5")
|
||||
if (insMatch.Value != "V-1.5")
|
||||
{
|
||||
SetItemError(item, "变色套(绝缘软套)大小与线径不匹配!");
|
||||
}
|
||||
|
|
|
@ -385,6 +385,7 @@ public partial class MainViewModel : INotifyPropertyChanged
|
|||
int seqNo = 1;
|
||||
var dataList = new List<ExportModel>();
|
||||
var nowDateStr = DateTime.Now.ToString("yyyy-MM-dd");
|
||||
var nowDeliveryDateStr = DateTime.Now.AddDays(7).ToString("yyyy-MM-dd");
|
||||
//foreach (var stuffedDataModel in StuffedData)
|
||||
StuffedData.AsParallel().WithDegreeOfParallelism(1).ForAll(stuffedDataModel =>
|
||||
{
|
||||
|
@ -410,7 +411,10 @@ public partial class MainViewModel : INotifyPropertyChanged
|
|||
RearTerminalStripLength = stuffedDataModel.RearStripLength,
|
||||
InsulationModel = stuffedDataModel.Insulation?.Specification,
|
||||
InsulationMaterialNo = stuffedDataModel.Insulation?.MaterialCode,
|
||||
InsulationQuantity = string.IsNullOrEmpty(stuffedDataModel.Insulation?.MaterialCode) ? "" : "2",
|
||||
OrderDate = nowDateStr,
|
||||
DeliveryDate = nowDeliveryDateStr,
|
||||
|
||||
IsIgnoreError = stuffedDataModel.IsIgnore ? "是" : string.Empty
|
||||
};
|
||||
seqNo++;
|
||||
|
|
|
@ -28,6 +28,6 @@ using System.Runtime.InteropServices;
|
|||
// 生成号
|
||||
// 修订号
|
||||
//
|
||||
[assembly: AssemblyVersion("1.0.0.1")]
|
||||
[assembly: AssemblyVersion("1.0.0.5")]
|
||||
[assembly: AssemblyFileVersion("1.0.0.1")]
|
||||
[assembly: AssemblyInformationalVersion("1.0.0.2-preview")]
|
||||
[assembly: AssemblyInformationalVersion("1.0.0.2")]
|
Loading…
Reference in New Issue