change - 实时库存货道信息加载

foamRearStore
wenjy 1 year ago
parent 9fc8924d53
commit c959c1f9db

Binary file not shown.

@ -36,6 +36,24 @@ namespace Aucma.Scada.Business
}
/// <summary>
/// 获取货道信息
/// </summary>
/// <param name="storeCode"></param>
/// <returns></returns>
public List<BaseSpaceInfo> GetSpaceInfos(string storeCode)
{
List<BaseSpaceInfo> spaceInfos = null;
try
{
spaceInfos =_spaceInfoService.GetSpaceInfosByStoreCode(storeCode);
}catch(Exception ex)
{
logHelper.Error("获取货道信息异常", ex);
}
return spaceInfos;
}
/// <summary>
/// 修改货道入库标识
/// </summary>
@ -114,5 +132,32 @@ namespace Aucma.Scada.Business
}
return result;
}
/// <summary>
/// 修改货道状态
/// </summary>
/// <param name="storeCode"></param>
/// <param name="spaceCode"></param>
/// <returns></returns>
public bool UpdateSpaceStatus(string storeCode,string spaceCode)
{
bool result = false;
try
{
BaseSpaceInfo spaceInfo = _spaceInfoService.GetSpaceInfoBySpaceCode(storeCode, spaceCode);
if (spaceInfo != null)
{
spaceInfo.spaceStatus = spaceInfo.spaceStatus == 1 ? 2 : 1;
result = _spaceInfoService.UpdateSpaceInfo(spaceInfo);
logHelper.Info($"修改仓库:{storeCode};货道:{spaceCode};货道状态:{spaceInfo.unusualFlag};修改{(result == true ? "" : "")}");
}
}
catch (Exception ex)
{
logHelper.Error("修改异常货道标识", ex);
}
return result;
}
}
}

@ -67,7 +67,7 @@
<TextBlock Text="在途" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
<Border Grid.Column="4" BorderBrush="White" BorderThickness="1">
<TextBlock Text="{Binding onTheWay}" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
<TextBlock Text="{Binding onRouteAmount}" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
<Border Grid.Column="5" BorderBrush="White" BorderThickness="1">
<TextBlock Text="合计" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
@ -87,7 +87,7 @@
<TextBlock Text="型号" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
<Border Grid.Column="1" BorderBrush="White" BorderThickness="1">
<TextBlock Text="8307501015SC-349雪王爱喝水" FontSize="16" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
<TextBlock Text="{Binding materialType}" FontSize="16" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
</Grid>
</Border>
@ -124,7 +124,7 @@
</Button>
</Border>
<Border Grid.Column="4" BorderBrush="White" BorderThickness="1">
<Button Command="{Binding DataContext.UpdateCommand, RelativeSource={RelativeSource AncestorType=ItemsControl}}" CommandParameter="{Binding spaceCode}" Style="{StaticResource BUTTON_AGREE}" BorderBrush="Transparent" BorderThickness="0" Background="Transparent">
<Button Command="{Binding DataContext.UpdateSpaceStatusCommand, RelativeSource={RelativeSource AncestorType=ItemsControl}}" CommandParameter="{Binding spaceCode}" Style="{StaticResource BUTTON_AGREE}" BorderBrush="Transparent" BorderThickness="0" Background="Transparent">
<TextBlock Text="禁用" Foreground="{Binding isFlag,Converter={StaticResource StatusLabelConverter}}" FontSize="18" FontWeight="Bold" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Button>

@ -68,7 +68,7 @@
<TextBlock Text="在途" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
<Border Grid.Column="4" BorderBrush="White" BorderThickness="1">
<TextBlock Text="{Binding onTheWay}" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
<TextBlock Text="{Binding onRouteAmount}" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
<Border Grid.Column="5" BorderBrush="White" BorderThickness="1">
<TextBlock Text="合计" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
@ -88,7 +88,7 @@
<TextBlock Text="型号" FontSize="18" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
<Border Grid.Column="1" BorderBrush="White" BorderThickness="1">
<TextBlock Text="8307501015SC-349雪王爱喝水" FontSize="16" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
<TextBlock Text="{Binding materialType}" FontSize="16" Foreground="White" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Border>
</Grid>
</Border>
@ -125,7 +125,7 @@
</Button>
</Border>
<Border Grid.Column="4" BorderBrush="White" BorderThickness="1">
<Button Command="{Binding DataContext.UpdateCommand, RelativeSource={RelativeSource AncestorType=ItemsControl}}" CommandParameter="{Binding spaceCode}" Style="{StaticResource BUTTON_AGREE}" BorderBrush="Transparent" BorderThickness="0" Background="Transparent">
<Button Command="{Binding DataContext.UpdateSpaceStatusCommand, RelativeSource={RelativeSource AncestorType=ItemsControl}}" CommandParameter="{Binding spaceCode}" Style="{StaticResource BUTTON_AGREE}" BorderBrush="Transparent" BorderThickness="0" Background="Transparent">
<TextBlock Text="禁用" Foreground="{Binding isFlag,Converter={StaticResource StatusLabelConverter}}" FontSize="18" FontWeight="Bold" VerticalAlignment="Center" HorizontalAlignment="Center"/>
</Button>

@ -0,0 +1,201 @@
<-------------->
日志时间2023-10-12 17:02:38,326 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:03:00,257 [1]
日志级别INFO
日志内容修改仓库XKJCK-001货道XK_001入库标识2;修改成功
<-------------->
日志时间2023-10-12 17:03:02,594 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:08:43,762 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:09:16,498 [1]
日志级别INFO
日志内容修改仓库XKJCK-001货道XK_001出库标识1;修改成功
<-------------->
日志时间2023-10-12 17:09:19,653 [1]
日志级别INFO
日志内容修改仓库XKJCK-001货道XK_001入库标识1;修改成功
<-------------->
日志时间2023-10-12 17:09:22,115 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:28:01,769 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:28:10,472 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识1;修改成功
<-------------->
日志时间2023-10-12 17:28:12,976 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:29:22,954 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:29:29,357 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识2;修改成功
<-------------->
日志时间2023-10-12 17:29:34,312 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识1;修改成功
<-------------->
日志时间2023-10-12 17:29:36,066 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识2;修改成功
<-------------->
日志时间2023-10-12 17:29:39,525 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:30:22,277 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:30:43,718 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识1;修改成功
<-------------->
日志时间2023-10-12 17:30:46,121 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识1;修改成功
<-------------->
日志时间2023-10-12 17:30:47,990 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001异常标识1;修改成功
<-------------->
日志时间2023-10-12 17:30:49,837 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001异常标识2;修改成功
<-------------->
日志时间2023-10-12 17:30:52,384 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识2;修改成功
<-------------->
日志时间2023-10-12 17:30:54,852 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:31:20,268 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:31:28,038 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识1;修改成功
<-------------->
日志时间2023-10-12 17:31:39,469 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:32:38,096 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:32:53,649 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识2;修改成功
<-------------->
日志时间2023-10-12 17:33:05,878 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识1;修改成功
<-------------->
日志时间2023-10-12 17:33:39,527 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识2;修改成功
<-------------->
日志时间2023-10-12 17:33:46,426 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:34:42,179 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:34:54,781 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识1;修改成功
<-------------->
日志时间2023-10-12 17:34:57,117 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001异常标识1;修改成功
<-------------->
日志时间2023-10-12 17:34:58,889 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识2;修改成功
<-------------->
日志时间2023-10-12 17:35:01,338 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识2;修改成功
<-------------->
日志时间2023-10-12 17:35:03,752 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:35:47,520 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:35:55,379 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识1;修改成功
<-------------->
日志时间2023-10-12 17:35:56,890 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识1;修改成功
<-------------->
日志时间2023-10-12 17:35:58,570 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识2;修改成功
<-------------->
日志时间2023-10-12 17:35:59,980 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001出库标识1;修改成功
<-------------->
日志时间2023-10-12 17:36:01,482 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:37:09,365 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:37:17,143 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 17:39:51,979 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:40:00,451 [1]
日志级别INFO
日志内容修改仓库NDJCK-001货道ND_001入库标识2;修改成功
<-------------->
日志时间2023-10-12 17:59:30,597 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 17:59:43,795 [1]
日志级别INFO
日志内容:程序退出
<-------------->
日志时间2023-10-12 18:00:13,674 [1]
日志级别INFO
日志内容根据产线工位编号ZZ-01获取到的执行计划信息[{"objId":83,"executePlanCode":"a8a9188d085042729cc0992fa2590e7f","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":2,"completeAmount":0,"beginTime":"\/Date(1697012914000)\/","endTime":null,"isFlag":0,"executeOrder":2,"executeStatus":2,"createdTime":"\/Date(1697012871000)\/"},{"objId":82,"executePlanCode":"a1e0d29c2b774f25bd0df0f059e24976","productPlanCode":"202310081458","orderCode":"11215483","materialCode":"9002006859","materialName":"SC-439,YZXGWBC元气森林,C","productLineCode":"ZZ-01","planAmount":1,"completeAmount":0,"beginTime":null,"endTime":null,"isFlag":0,"executeOrder":1,"executeStatus":1,"createdTime":"\/Date(1697003840000)\/"}]
<-------------->
日志时间2023-10-12 18:00:24,034 [1]
日志级别INFO
日志内容:程序退出

File diff suppressed because one or more lines are too long

@ -1,4 +1,4 @@
#pragma checksum "..\..\..\..\Page\InventoryInfo\LinerInventory.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "C1F8B47D4D895615B393CD840BE5F82DC2637E20FB6E6C9724108EBEB9FA548E"
#pragma checksum "..\..\..\..\Page\InventoryInfo\LinerInventory.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "FD500ADE499B80926E0CEF74A314BDC3E4F9FFA695A94ED920F58241FCA70DE2"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.

@ -1,4 +1,4 @@
#pragma checksum "..\..\..\..\Page\InventoryInfo\LinerInventory.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "C1F8B47D4D895615B393CD840BE5F82DC2637E20FB6E6C9724108EBEB9FA548E"
#pragma checksum "..\..\..\..\Page\InventoryInfo\LinerInventory.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "FD500ADE499B80926E0CEF74A314BDC3E4F9FFA695A94ED920F58241FCA70DE2"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.

@ -1,4 +1,4 @@
#pragma checksum "..\..\..\..\Page\InventoryInfo\ShellInventory.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "EA906062C968DA0D3CD30CC81A4F3560306C0628F81B20D5C6686971A43A0F57"
#pragma checksum "..\..\..\..\Page\InventoryInfo\ShellInventory.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "DC02948EA40CF85249C6573F1D0B4926A6A423D976B9A9A4D924469941DCCE85"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.

@ -1,4 +1,4 @@
#pragma checksum "..\..\..\..\Page\InventoryInfo\ShellInventory.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "EA906062C968DA0D3CD30CC81A4F3560306C0628F81B20D5C6686971A43A0F57"
#pragma checksum "..\..\..\..\Page\InventoryInfo\ShellInventory.xaml" "{8829d00f-11b8-4213-878b-770e8597ac16}" "DC02948EA40CF85249C6573F1D0B4926A6A423D976B9A9A4D924469941DCCE85"
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.

@ -1,9 +1,12 @@
using Aucma.Scada.Business;
using Aucma.Scada.UI.Page.InventoryInfo;
using GalaSoft.MvvmLight;
using GalaSoft.MvvmLight.Command;
using HighWayIot.Config;
using HighWayIot.Repository.domain;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
@ -13,7 +16,7 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
{
public class LinerInventoryViewModel :ViewModelBase
{
public List<SpaceDto> Shapes { get; set; } = new List<SpaceDto>();
public ObservableCollection<BaseSpaceInfo> Shapes { get; set; } = new ObservableCollection<BaseSpaceInfo>();
private InventoryInfoBusiness inventoryInfoBusiness = InventoryInfoBusiness.Instance;
@ -28,23 +31,9 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
UpdateUnusualFlagCommand = new RelayCommand<object>(obj => UpdateUnusualFlag(obj));
for (int i = 1; i <= 6; i++)
{
Shapes.Add(new SpaceDto()
{
spaceCode = "ND_00"+i,
spaceStock = i,
onTheWay = i,
totalAmount = i + i,
materialType = "",
inStoreFlag = 1,
outStoreFlag = 2,
unusualFlag = 2,
isFlag = 1,
onlyOne = 1,
spaceType = 1
});
}
UpdateSpaceStatusCommand = new RelayCommand<object>(obj => UpdateSpaceStatus(obj));
Query();
}
@ -53,6 +42,8 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
public RelayCommand<object> UpdateOutStoreFlagCommand { get; set; }
public RelayCommand<object> UpdateUnusualFlagCommand { get; set; }
public RelayCommand<object> UpdateSpaceStatusCommand { get; set; }
#endregion
private void update(object obj)
@ -61,6 +52,20 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
MessageBox.Show("编号:" + info);
}
private void Query()
{
var info = inventoryInfoBusiness.GetSpaceInfos(appConfig.linerStoreCode);
if (info != null)
{
//new LinerInventory();
Shapes = new ObservableCollection<BaseSpaceInfo>();
info.ForEach(x =>
{
Shapes.Add(x);
});
}
}
/// <summary>
/// 货道入库标识设置
/// </summary>
@ -71,6 +76,7 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
bool result = inventoryInfoBusiness.UpdateInStoreFlag(appConfig.linerStoreCode, info);
if (result)
{
Query();
MessageBox.Show("货道入库状态修改成功");
}
else
@ -89,6 +95,7 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
bool result = inventoryInfoBusiness.UpdateOutStoreFlag(appConfig.linerStoreCode, info);
if (result)
{
Query();
MessageBox.Show("货道出库状态修改成功");
}
else
@ -107,6 +114,7 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
bool result = inventoryInfoBusiness.UpdateUnusualFlag(appConfig.linerStoreCode, info);
if (result)
{
Query();
MessageBox.Show("货道异常标识修改成功");
}
else
@ -114,6 +122,25 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
MessageBox.Show("货道异常标识修改失败");
}
}
/// <summary>
/// 修改货道状态
/// </summary>
/// <param name="obj"></param>
private void UpdateSpaceStatus(object obj)
{
string info = obj as string;
bool result = inventoryInfoBusiness.UpdateUnusualFlag(appConfig.linerStoreCode, info);
if (result)
{
Query();
MessageBox.Show("货道状态修改成功");
}
else
{
MessageBox.Show("货道状态修改失败");
}
}
}
}

@ -2,7 +2,9 @@
using GalaSoft.MvvmLight;
using GalaSoft.MvvmLight.Command;
using HighWayIot.Config;
using HighWayIot.Repository.domain;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Windows;
namespace Aucma.Scada.UI.viewModel.InventoryInfo
@ -10,7 +12,7 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
public class ShellInventoryViewModel : ViewModelBase
{
public List<SpaceDto> Shapes { get; set; } = new List<SpaceDto>();
public ObservableCollection<BaseSpaceInfo> Shapes { get; set; } = new ObservableCollection<BaseSpaceInfo>();
private InventoryInfoBusiness inventoryInfoBusiness = InventoryInfoBusiness.Instance;
@ -25,23 +27,9 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
UpdateUnusualFlagCommand = new RelayCommand<object>(obj => UpdateUnusualFlag(obj));
for (int i = 1; i <= 9; i++)
{
Shapes.Add(new SpaceDto()
{
spaceCode = "XK_00"+i,
spaceStock = i,
onTheWay = i,
totalAmount = i+i,
materialType = "",
inStoreFlag = 1,
outStoreFlag = 2,
unusualFlag = 2,
isFlag = 1,
onlyOne = 1,
spaceType = 1
});
}
UpdateSpaceStatusCommand = new RelayCommand<object>(obj => UpdateSpaceStatus(obj));
Query();
}
@ -51,8 +39,24 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
public RelayCommand<object> UpdateOutStoreFlagCommand { get; set; }
public RelayCommand<object> UpdateUnusualFlagCommand { get; set; }
public RelayCommand<object> UpdateSpaceStatusCommand { get; set; }
#endregion
private void Query()
{
var info = inventoryInfoBusiness.GetSpaceInfos(appConfig.shellStoreCode);
if (info != null)
{
//new LinerInventory();
Shapes = new ObservableCollection<BaseSpaceInfo>();
info.ForEach(x =>
{
Shapes.Add(x);
});
}
}
/// <summary>
/// 货道入库标识设置
/// </summary>
@ -63,6 +67,7 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
bool result = inventoryInfoBusiness.UpdateInStoreFlag(appConfig.shellStoreCode, info);
if (result)
{
Query();
MessageBox.Show("货道入库状态修改成功");
}
else
@ -81,6 +86,7 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
bool result = inventoryInfoBusiness.UpdateOutStoreFlag(appConfig.shellStoreCode, info);
if (result)
{
Query();
MessageBox.Show("货道出库状态修改成功");
}
else
@ -99,6 +105,7 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
bool result = inventoryInfoBusiness.UpdateUnusualFlag(appConfig.shellStoreCode, info);
if (result)
{
Query();
MessageBox.Show("货道异常标识修改成功");
}
else
@ -106,69 +113,26 @@ namespace Aucma.Scada.UI.viewModel.InventoryInfo
MessageBox.Show("货道异常标识修改失败");
}
}
}
/// <summary>
/// 货道信息
/// </summary>
public class SpaceDto
{
/// <summary>
/// 货道编号
/// </summary>
public string spaceCode { get; set; }
/// <summary>
/// 在库数量
/// 修改货道状态
/// </summary>
public int spaceStock { get; set; }
/// <summary>
/// 货道类型
/// </summary>
public int spaceType { get; set; }
/// <summary>
/// 在途数量
/// </summary>
public int onTheWay { get; set; }
/// <summary>
/// 合计数量
/// </summary>
public int totalAmount { get; set; }
/// <summary>
/// 物料型号
/// </summary>
public string materialType { get; set; }
/// <summary>
/// 入库状态
/// </summary>
public int inStoreFlag { get; set; }
/// <summary>
/// 出库状态
/// </summary>
public int outStoreFlag { get; set; }
/// <summary>
/// 异常状态
/// </summary>
public int unusualFlag { get; set; }
/// <summary>
/// 禁用状态
/// </summary>
public int isFlag { get; set; }
/// <summary>
/// 出一个
/// </summary>
public int onlyOne { get; set; }
/// <param name="obj"></param>
private void UpdateSpaceStatus(object obj)
{
string info = obj as string;
bool result = inventoryInfoBusiness.UpdateUnusualFlag(appConfig.shellStoreCode, info);
if (result)
{
Query();
MessageBox.Show("货道状态修改成功");
}
else
{
MessageBox.Show("货道状态修改失败");
}
}
}
}

@ -27,4 +27,3 @@ C:\项目代码\澳柯玛MES项目\Aucma.Scada\HighWayIot.Log4net\obj\Debug\High
C:\项目代码\澳柯玛MES项目\Aucma.Scada\HighWayIot.Log4net\obj\Debug\HighWayIot.Log4net.csproj.CopyComplete
C:\项目代码\澳柯玛MES项目\Aucma.Scada\HighWayIot.Log4net\obj\Debug\HighWayIot.Log4net.dll
C:\项目代码\澳柯玛MES项目\Aucma.Scada\HighWayIot.Log4net\obj\Debug\HighWayIot.Log4net.pdb
C:\项目代码\澳柯玛MES项目\Aucma.Scada\HighWayIot.Log4net\obj\Debug\HighWayIot.Log4net.csproj.AssemblyReference.cache

@ -37,6 +37,13 @@ namespace HighWayIot.Repository.service
/// <returns></returns>
BaseSpaceInfo GetSpaceInfoBySpaceCode(string store,string spaceCode);
/// <summary>
/// 通过仓库编号获取货道信息
/// </summary>
/// <param name="storeCode"></param>
/// <returns></returns>
List<BaseSpaceInfo> GetSpaceInfosByStoreCode(string storeCode);
/// <summary>
/// 更新货道信息
/// </summary>

@ -159,6 +159,25 @@ namespace HighWayIot.Repository.service.Impl
return spaceInfo;
}
/// <summary>
/// 通过仓库编号获取货道信息
/// </summary>
/// <param name="storeCode"></param>
/// <returns></returns>
public List<BaseSpaceInfo> GetSpaceInfosByStoreCode(string storeCode)
{
List<BaseSpaceInfo> spaceInfos = null;
try
{
spaceInfos = _mesRepository.GetList(x => x.storeCode == storeCode).ToList();
}
catch (Exception ex)
{
logHelper.Error("获取货道信息异常", ex);
}
return spaceInfos;
}
/// <summary>
/// 更新货道信息
/// </summary>

Loading…
Cancel
Save