diff --git a/Admin.Core.Model/Model_New/MaterialCompletion.cs b/Admin.Core.Model/Model_New/MaterialCompletion.cs
index b599da61..53979b50 100644
--- a/Admin.Core.Model/Model_New/MaterialCompletion.cs
+++ b/Admin.Core.Model/Model_New/MaterialCompletion.cs
@@ -49,7 +49,9 @@ namespace Admin.Core.Model.Model_New
[SugarColumn(ColumnName = "STATION_NAME")]
public string StationName { get; set; }
-
+ ///
+ /// 所属产线
+ ///
[SugarColumn(ColumnName = "PRODUCT_LINE_CODE")]
public string ProductLineCode { get; set; }
@@ -63,5 +65,12 @@ namespace Admin.Core.Model.Model_New
///
[SugarColumn(ColumnName = "PLAN_CODE")]
public string planCode { get; set; }
+
+ ///
+ /// 是否下线
+ ///
+ [SugarColumn(ColumnName = "IS_DOWN_LINE")]
+ public int isDownLine { get; set; }
+
}
}
diff --git a/Aucma.Core.BoxFoam/Business/InStoreBusiness.cs b/Aucma.Core.BoxFoam/Business/InStoreBusiness.cs
index b9eba5b8..05dc876c 100644
--- a/Aucma.Core.BoxFoam/Business/InStoreBusiness.cs
+++ b/Aucma.Core.BoxFoam/Business/InStoreBusiness.cs
@@ -295,8 +295,11 @@ namespace Aucma.Core.BoxFoam.Business
//completion.MaterialBarcode = materialBarCode;
//completion.MaterialCode = print.MaterialCode;
//completion.MaterialName = print.MaterialName;
- //completion.StationName = "1003";
+ //completion.StationName = "1004";
+ //completion.ProductLineCode = "CX_02";
+ //completion.isDownLine = 0;
//completion.CompleteDate = DateTime.Now;
+
//await _iMaterialCompletionServices.AddAsync(completion);
#endregion
RefreshDataGridDelegateEvent?.Invoke();
diff --git a/Aucma.Core.CodeBinding/ViewModels/IndexPageViewModel.cs b/Aucma.Core.CodeBinding/ViewModels/IndexPageViewModel.cs
index 7ce58784..f1ccb025 100644
--- a/Aucma.Core.CodeBinding/ViewModels/IndexPageViewModel.cs
+++ b/Aucma.Core.CodeBinding/ViewModels/IndexPageViewModel.cs
@@ -485,7 +485,7 @@ namespace Aucma.Core.CodeBinding.ViewModels
{
RefreshAndWriteLog("条码【" + record.BoxCode + "】与SN码【" + record.ProductCode + "】绑定成功");
#region 更新过点数据,插入记录到MATERIAL_COMPLETION表
- //PrintBarCode print = await _printBarCodeServices.FirstAsync(x => x.MaterialBarcode == code1);
+ //PrintBarCode print = _printBarCodeServices.FirstAsync(x => x.MaterialBarcode == code1).Result;
//if (print != null) return;
//MaterialCompletion completion = new MaterialCompletion();
//completion.OrderCode = print.OrderCode;
@@ -494,7 +494,10 @@ namespace Aucma.Core.CodeBinding.ViewModels
//completion.MaterialName = print.MaterialName;
//completion.StationName = "1007";
//completion.CompleteDate = DateTime.Now;
- //await _iMaterialCompletionServices.AddAsync(completion);
+ //completion.isDownLine = 0;
+ //completion.ProductLineCode = "CX_02";
+ //_= _iMaterialCompletionServices.AddAsync(completion).Result;
+
#endregion
}
diff --git a/Aucma.Core.ProductOffLine/Business/offLineBusiness.cs b/Aucma.Core.ProductOffLine/Business/offLineBusiness.cs
index 93d7a6ce..6065bd3e 100644
--- a/Aucma.Core.ProductOffLine/Business/offLineBusiness.cs
+++ b/Aucma.Core.ProductOffLine/Business/offLineBusiness.cs
@@ -61,6 +61,7 @@ namespace Aucma.Core.ProductOffLine.Business
#region 接口引用
private static readonly log4net.ILog log = LogManager.GetLogger(typeof(OffLineBusiness));
+
private readonly IBaseOrderInfoServices _baseOrderInfoServices = App.ServiceProvider.GetService();
private readonly IPrintBarCodeServices? _printBarCodeServices = App.ServiceProvider.GetService();
// 成品下线操作条码系统接口
@@ -251,15 +252,22 @@ namespace Aucma.Core.ProductOffLine.Business
#region 暂时不启用,因为还没打箱体码,查不到数据,更新过点数据
- //PrintBarCode print = await _printBarCodeServices.FirstAsync(x => x.MaterialBarcode == bindingRecord1.BoxCode);
- //MaterialCompletion completion = new MaterialCompletion();
- //completion.OrderCode = print.OrderCode;
- //completion.MaterialBarcode = bindingRecord1.BoxCode;
- //completion.MaterialCode = print.MaterialCode;
- //completion.MaterialName = print.MaterialName;
- //completion.StationName = "1008" ;
- //completion.CompleteDate = DateTime.Now;
- //await _iMaterialCompletionServices.AddAsync(completion);
+ //PrintBarCode print = _printBarCodeServices.FirstAsync(x => x.MaterialBarcode == bindingRecord1.BoxCode).Result;
+ //if (print != null)
+ //{
+ // MaterialCompletion completion = new MaterialCompletion();
+ // completion.OrderCode = print.OrderCode;
+ // completion.MaterialBarcode = bindingRecord1.BoxCode;
+ // completion.MaterialCode = print.MaterialCode;
+ // completion.MaterialName = print.MaterialName;
+ // completion.StationName = "1009";
+ // completion.CompleteDate = DateTime.Now;
+ // completion.ProductLineCode = "CX_02";
+ // completion.isDownLine = 1;
+ // _ = _iMaterialCompletionServices.AddAsync(completion).Result;
+
+ //}
+
#endregion
diff --git a/Aucma.Core.ProductOffLine/ViewModels/IndexPageViewModel.cs b/Aucma.Core.ProductOffLine/ViewModels/IndexPageViewModel.cs
index 8b205496..41074213 100644
--- a/Aucma.Core.ProductOffLine/ViewModels/IndexPageViewModel.cs
+++ b/Aucma.Core.ProductOffLine/ViewModels/IndexPageViewModel.cs
@@ -59,7 +59,7 @@ namespace Aucma.Core.ProductOffLine.ViewModels
int a = 0;
public IndexPageViewModel()
{
-
+ OffLineQty = "235";
_offLineInfoServices = App.ServiceProvider.GetService();
_baseBomInfoServices = App.ServiceProvider.GetService();
InitEveryDayMethod();
@@ -72,6 +72,20 @@ namespace Aucma.Core.ProductOffLine.ViewModels
#region 参数定义
#region 扫描信息
+
+
+ #region 下线数量
+ private string _offLineQty;
+ public string OffLineQty
+ {
+ get { return _offLineQty; }
+ set
+ {
+ _offLineQty = value;
+ OnPropertyChanged(nameof(OffLineQty));
+ }
+ }
+ #endregion
#region 产品条码
private string _productSNCode;
@@ -326,8 +340,11 @@ namespace Aucma.Core.ProductOffLine.ViewModels
// List hourAmount = _offLineInfoServices.QueryCharts1("CX_01");
List list = _offLineInfoServices.QueryCharts(listTime[0].startTime, listTime[11].startTime).Result;
+
if (list == null) return;
- List hourList1 = new List();
+ List hourList1 = new List();
+ // 当班下线数量
+ int sum = 0;
foreach(ChartsByTime item in list)
{
DateTime date = DateTime.ParseExact(item.date + ":00:00", "yyyy-MM-dd/HH:mm:ss", CultureInfo.InvariantCulture);
@@ -335,8 +352,11 @@ namespace Aucma.Core.ProductOffLine.ViewModels
hour.ProductCode = item.productLineCode;
hour.ProductDate = date;
hour.ProductAmount = item.Amount;
+ sum += item.Amount;
hourList1.Add(hour);
}
+ // 当班下线数量页面赋值
+ OffLineQty = sum.ToString();
if (hourList1 == null) return;
@@ -346,7 +366,7 @@ namespace Aucma.Core.ProductOffLine.ViewModels
ChartValues achievement2 = new ChartValues();
foreach (var item in hourList)
{
- xList.Add(item.ProductDate.Hour.ToString());
+ xList.Add(item.ProductDate.Hour.ToString()+":00");
achievement2.Add(item.ProductAmount);
}
diff --git a/Aucma.Core.ProductOffLine/Views/IndexPageView.xaml b/Aucma.Core.ProductOffLine/Views/IndexPageView.xaml
index 2a6ea514..6bcf7c73 100644
--- a/Aucma.Core.ProductOffLine/Views/IndexPageView.xaml
+++ b/Aucma.Core.ProductOffLine/Views/IndexPageView.xaml
@@ -212,7 +212,7 @@
-
+