diff --git a/.vs/ICSSoft.FromERP/v16/.suo b/.vs/ICSSoft.FromERP/v16/.suo index 57a431a..a586558 100644 Binary files a/.vs/ICSSoft.FromERP/v16/.suo and b/.vs/ICSSoft.FromERP/v16/.suo differ diff --git a/ICSSoft.FromERP/IcsMo_Rhtyon.cs b/ICSSoft.FromERP/IcsMo_Rhtyon.cs index c5df4f7..d7d5706 100644 --- a/ICSSoft.FromERP/IcsMo_Rhtyon.cs +++ b/ICSSoft.FromERP/IcsMo_Rhtyon.cs @@ -103,6 +103,7 @@ and b1.code not like 'K10%' ,case when a.ActualCompleteDate is null then '' else Convert(varchar(10),a.ActualCompleteDate,120 ) end as ActualCompleteDate ,a.IsFIClose +,e3.Name AlternateTypeName INTO #TempMO from {1}.dbo.MO_MO as A With(NoLock) left join {1}.dbo.[MO_MOMemo] as A1 With(NoLock) on (A.[ID] = A1.[MO]) @@ -116,6 +117,9 @@ else Convert(varchar(10),a.ActualCompleteDate,120 ) end as ActualCompleteDate left join {1}.dbo.[CBO_Department] as A13 With(NoLock) on (A.[Department] = A13.[ID]) left join {1}.dbo.[CBO_Department_Trl] as A14 With(NoLock) on (A14.SysMlFlag = 'zh-CN') and (A13.[ID] = A14.[ID]) LEFT JOIN {1}.dbo.[CBO_Wh] AS A22 With(NoLock) ON A22.ID=A.CompleteWh + left join {1}.dbo.UBF_Sys_ExtEnumType e1 on e1.Code = 'UFIDA.U9.CBO.MFG.Enums.AlternateTypesEnum' + left join {1}.dbo.UBF_Sys_ExtEnumValue e2 on e1.ID=e2.ExtEnumType and e2.evalue=a.BOMAlternate + left join {1}.dbo.UBF_Sys_ExtEnumValue_Trl e3 on e2.id=e3.ID and e3.SysMLFlag='zh-CN' where (A.DocState=2 OR A.DocState=3) and A.[BusinessType] != 50 and (A.[BusinessType] != 52) and (A.[BusinessType] != 2417) and (A.[IsMultiRouting] != 1) and A.[ItemMaster] is not null --and (A.[IsStartMO] != 1) and ISNULL(A.ModifiedOn,A.BusinessCreatedOn)>=@LastTime AND A12.id='{0}' @@ -173,6 +177,7 @@ else Convert(varchar(10),a.ActualCompleteDate,120 ) end as ActualCompleteDate values.Add("Default3", "a.ActualCompleteDate"); values.Add("Default5", "a.DocState"); values.Add("Default6", "a.IsFIClose"); + values.Add("Alternate", "a.AlternateTypeName"); //更新存在数据 sql += ICSHelper.UpdateSQL("b", values) diff --git a/ICSSoft.FromERP/IcsSBom_Rhtyon.cs b/ICSSoft.FromERP/IcsSBom_Rhtyon.cs index 7f923ee..f5e6610 100644 --- a/ICSSoft.FromERP/IcsSBom_Rhtyon.cs +++ b/ICSSoft.FromERP/IcsSBom_Rhtyon.cs @@ -139,7 +139,7 @@ and a.TenantId='{0}' values.Add("LastModifierUserId", "'" + ConstWorkPoint.Muser + "'");//操作人 values.Add("LastModifierUserName", "'" + ConstWorkPoint.Musername + "'");//操作人名称 values.Add("SBItemContype", "c.ItemContype"); - values.Add("SBUseage", "a.AlternateTypeName"); + values.Add("Alternate", "a.AlternateTypeName"); values.Add("FixedScrap", "a.固定损耗"); values.Add("Scrap", "a.变动损耗"); values.Add("ScrapType", "a.损耗类型"); diff --git a/ICSSoft.Test/Program.cs b/ICSSoft.Test/Program.cs index de67061..09b8fbd 100644 --- a/ICSSoft.Test/Program.cs +++ b/ICSSoft.Test/Program.cs @@ -13,7 +13,7 @@ namespace ICSSoft.Test //ICSVendor test = new ICSVendor(); //test.Execute(); - IcsSBom_Rhtyon test = new IcsSBom_Rhtyon(); + IcsMo_Rhtyon test = new IcsMo_Rhtyon(); test.Execute(); // var ss= ICSHelper.ApiSign("sj_w_id", "70FF7F01C5899A5ACAAD4ECB7FA5B3C5", 1724650261);