xusc 2 weeks ago
parent
commit
c382a410ca
  1. BIN
      .vs/ICSSoft.FromERP/v16/.suo
  2. 5
      ICSSoft.FromERP/IcsMo_Rhtyon.cs
  3. 2
      ICSSoft.FromERP/IcsSBom_Rhtyon.cs
  4. 2
      ICSSoft.Test/Program.cs

BIN
.vs/ICSSoft.FromERP/v16/.suo

Binary file not shown.

5
ICSSoft.FromERP/IcsMo_Rhtyon.cs

@ -103,6 +103,7 @@ and b1.code not like 'K10%'
,case when a.ActualCompleteDate is null then '' ,case when a.ActualCompleteDate is null then ''
else Convert(varchar(10),a.ActualCompleteDate,120 ) end as ActualCompleteDate else Convert(varchar(10),a.ActualCompleteDate,120 ) end as ActualCompleteDate
,a.IsFIClose ,a.IsFIClose
,e3.Name AlternateTypeName
INTO #TempMO INTO #TempMO
from {1}.dbo.MO_MO as A With(NoLock) from {1}.dbo.MO_MO as A With(NoLock)
left join {1}.dbo.[MO_MOMemo] as A1 With(NoLock) on (A.[ID] = A1.[MO]) 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] 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_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.[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) 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 (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}' 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("Default3", "a.ActualCompleteDate");
values.Add("Default5", "a.DocState"); values.Add("Default5", "a.DocState");
values.Add("Default6", "a.IsFIClose"); values.Add("Default6", "a.IsFIClose");
values.Add("Alternate", "a.AlternateTypeName");
//更新存在数据 //更新存在数据
sql += ICSHelper.UpdateSQL("b", values) sql += ICSHelper.UpdateSQL("b", values)

2
ICSSoft.FromERP/IcsSBom_Rhtyon.cs

@ -139,7 +139,7 @@ and a.TenantId='{0}'
values.Add("LastModifierUserId", "'" + ConstWorkPoint.Muser + "'");//操作人 values.Add("LastModifierUserId", "'" + ConstWorkPoint.Muser + "'");//操作人
values.Add("LastModifierUserName", "'" + ConstWorkPoint.Musername + "'");//操作人名称 values.Add("LastModifierUserName", "'" + ConstWorkPoint.Musername + "'");//操作人名称
values.Add("SBItemContype", "c.ItemContype"); values.Add("SBItemContype", "c.ItemContype");
values.Add("SBUseage", "a.AlternateTypeName");
values.Add("Alternate", "a.AlternateTypeName");
values.Add("FixedScrap", "a.固定损耗"); values.Add("FixedScrap", "a.固定损耗");
values.Add("Scrap", "a.变动损耗"); values.Add("Scrap", "a.变动损耗");
values.Add("ScrapType", "a.损耗类型"); values.Add("ScrapType", "a.损耗类型");

2
ICSSoft.Test/Program.cs

@ -13,7 +13,7 @@ namespace ICSSoft.Test
//ICSVendor test = new ICSVendor(); //ICSVendor test = new ICSVendor();
//test.Execute(); //test.Execute();
IcsSBom_Rhtyon test = new IcsSBom_Rhtyon();
IcsMo_Rhtyon test = new IcsMo_Rhtyon();
test.Execute(); test.Execute();
// var ss= ICSHelper.ApiSign("sj_w_id", "70FF7F01C5899A5ACAAD4ECB7FA5B3C5", 1724650261); // var ss= ICSHelper.ApiSign("sj_w_id", "70FF7F01C5899A5ACAAD4ECB7FA5B3C5", 1724650261);

Loading…
Cancel
Save