Browse Source

代码提交。

tangdi 2 years ago
parent
commit
8ff6768ad8

+ 3 - 2
MicroServices/Business/Business.Application/ResourceExamineManagement/CalcBomViewAppService.cs

@@ -1215,10 +1215,11 @@ namespace Business.ResourceExamineManagement
                 srm_Pr.icitem_id = returnlist.item_id;//物料id
                 srm_Pr.icitem_name = returnlist.item_name;//物料名称
                 srm_Pr.num = returnlist.num;
+                var tomorrow = DateTime.Now.Date.AddDays(1);
                 srm_Pr.pr_order_type = 1;//单据类型
-                srm_Pr.pr_ssend_date = DateTime.Now;//系统建议下单日期
+                srm_Pr.pr_ssend_date = tomorrow;//系统建议下单日期
                 srm_Pr.pr_sarrive_date = DateTime.Now.AddDays((double)plan.order_leadtime).AddDays((double)plan.transportation_leadtime);//系统建议到达日期(建议到货日期)
-                srm_Pr.pr_psend_date = DateTime.Now;//计划下单日期
+                srm_Pr.pr_psend_date = tomorrow;//计划下单日期
                 srm_Pr.pr_parrive_date = DateTime.Now.AddDays((double)plan.order_leadtime).AddDays((double)plan.transportation_leadtime);//计划到达日期
                 srm_Pr.pr_rarrive_date = DateTime.Now.AddDays((double)plan.order_leadtime).AddDays((double)plan.transportation_leadtime);//需求到货日期
                 srm_Pr.pr_sysprice = returnlist.lack_qty * x.netpurchase_price * (1 + x.taxrate);//系统价格(含税)

+ 1 - 3
MicroServices/Business/Business.Application/ResourceExamineManagement/ResourceExamineAppService.cs

@@ -1027,9 +1027,7 @@ namespace Business.ResourceExamineManagement
             DateTime toTime = new DateTime(2023, 7, 6);
             DateTime starttime = toTime.Date.AddDays(8);
             DateTime endtime = toTime.Date.AddDays(14);
-            List<srm_pr_main> prlist = _mysql_srm_pr_main.GetListAsync(s => s.pr_rarrive_date >= starttime && s.pr_rarrive_date <= endtime && (s.state == 1 || s.state == 3)).Result;
-            //List<srm_pr_main> prlist = _mysql_srm_pr_main.GetListAsync(s => s.icitem_id == 1949).Result;
-            //List<srm_purchase> purchaselist = _mysql_srm_purchase.GetListAsync(s => prlist.Select(c => c.icitem_id).Contains(s.icitem_id) && prlist.Select(c => c.pr_purchaseid).Contains(s.supplier_id)).Result;
+            List<srm_pr_main> prlist = _mysql_srm_pr_main.GetListAsync(s => s.pr_ssend_date >= starttime && s.pr_ssend_date <= endtime && (s.state == 1 || s.state == 3)).Result;
             List<ic_item> ic_Items = _mysql_ic_item.GetListAsync(s => prlist.Select(c => c.icitem_id).Contains(s.Id)).Result;
             List<PrWeekDto> prWeekDtos = new List<PrWeekDto>();
 

+ 1 - 1
MicroServices/Business/Business.Domain/StructuredDB/SaleFcst/DomesticTerminalFcst.cs

@@ -13,7 +13,7 @@ namespace Business.Domain
     /// 国内终端预测表
     /// </summary>
     [Comment("国内终端预测表")]
-    [Index(nameof(Year), nameof(Month), nameof(ProdLine), nameof(Model),nameof(TypeEnum),nameof(PlanMonth),nameof(company_id), nameof(company_id),nameof(factory_id), IsUnique = true)]
+    [Index(nameof(Year), nameof(Month), nameof(ProdLine), nameof(Model),nameof(TypeEnum),nameof(PlanMonth),nameof(company_id),nameof(factory_id), IsUnique = true)]
     public class DomesticTerminalFcst:BaseEntity
     {
         /// <summary>

+ 1 - 1
MicroServices/Business/Business.Domain/StructuredDB/SaleFcst/OverseasSaleFcst.cs

@@ -13,7 +13,7 @@ namespace Business.Domain
     /// 海外销售预测表
     /// </summary>
     [Comment("海外销售预测表")]
-    [Index(nameof(Year), nameof(Month), nameof(ProdLine), nameof(Model),nameof(Language),nameof(PlanMonth),nameof(company_id),nameof(company_id), nameof(factory_id), IsUnique = true)]
+    [Index(nameof(Year), nameof(Month), nameof(ProdLine), nameof(Model),nameof(Language),nameof(PlanMonth),nameof(company_id), nameof(factory_id), IsUnique = true)]
     public class OverseasSaleFcst : BaseEntity
     {
         /// <summary>

+ 1 - 1
MicroServices/Business/Business.Domain/StructuredDB/SaleFcst/PlatformFcstCollect.cs

@@ -13,7 +13,7 @@ namespace Business.Domain
     /// 平台预测收集表
     /// </summary>
     [Comment("平台预测收集表")]
-    [Index(nameof(Year), nameof(Month), nameof(Platform), nameof(Model),nameof(ProdType),nameof(PlanMonth),nameof(company_id),nameof(company_id),nameof(factory_id), IsUnique = true)]
+    [Index(nameof(Year), nameof(Month), nameof(Platform), nameof(Model),nameof(ProdType),nameof(PlanMonth),nameof(company_id),nameof(factory_id), IsUnique = true)]
     public class PlatformFcstCollect : BaseEntity
     {
         /// <summary>

+ 1 - 1
MicroServices/Business/Business.Domain/StructuredDB/SaleFcst/StandardItemModelSet.cs

@@ -14,7 +14,7 @@ namespace Business.Domain
     /// 标准物料规格型号设置表
     /// </summary>
     [Comment("标准物料规格型号设置表")]
-    [Index(nameof(Model),nameof(ItemNumber), nameof(company_id),nameof(company_id), nameof(factory_id), IsUnique = true)]
+    [Index(nameof(Model),nameof(ItemNumber), nameof(company_id), nameof(factory_id), IsUnique = true)]
     public class StandardItemModelSet:BaseEntity
     {
         /// <summary>

+ 1 - 1
MicroServices/Business/Business.Domain/StructuredDB/SaleFcst/YearDemandManagement.cs

@@ -13,7 +13,7 @@ namespace Business.Domain
     /// 年度生产需求管理表
     /// </summary>
     [Comment("年度生产需求管理表")]
-    [Index(nameof(Year), nameof(Area), nameof(ProdLine),nameof(ProdRange), nameof(Line),nameof(Model),nameof(PlanMonth),nameof(company_id), nameof(company_id),nameof(factory_id), IsUnique = true)]
+    [Index(nameof(Year), nameof(Area), nameof(ProdLine),nameof(ProdRange), nameof(Line),nameof(Model),nameof(PlanMonth), nameof(company_id),nameof(factory_id), IsUnique = true)]
     public class YearDemandManagement:BaseEntity
     {
         /// <summary>