其他入库、其他出库上传生成CLOUD单据调用方法修改,根据系统参数判断生成单据日期是否取界面上日期
1个文件已修改
83 ■■■■ 已修改文件
CLOUDWEB/WebService1.asmx.cs 83 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
CLOUDWEB/WebService1.asmx.cs
@@ -21599,6 +21599,12 @@
                string s = "";
                int sYear = 0;
                int sPeriod = 0;
                if (oSystemParameterMain.WMS_BillDateMode == "N") //系统参数  单据日期是否取界面递入日期
                {
                    oMain.HDate = DateTime.Today;
                }
                if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(oMain.HDate, ref sYear, ref sPeriod, ref s) == false)
                {
                    sErrMsg = s;
@@ -21620,7 +21626,7 @@
                ",HStockStyle" +
                ",HSTOCKORGID,HOWNERID" +
                ") " +
                " values('1206','1206'," + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "',convert(varchar(10),getdate(),120),'" + oMain.HMainSourceBillType + "'" +
                " values('1206','1206'," + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HDate.ToShortDateString() + "','" + oMain.HMainSourceBillType + "'" +
                ", " + oMain.HYear.ToString() + "," + oMain.HPeriod.ToString() + ",'" + oMain.HRemark + "','" + oMain.HMaker + "',convert(varchar(10),getdate(),120)" +
                ", " + oMain.HSupID.ToString() + "," + oMain.HWHID.ToString() + "," + oMain.HSCWHID.ToString() + "," + oMain.HEmpID.ToString() + "," + oMain.HManagerID.ToString() + "," + oMain.HSecManagerID.ToString() +
                ", " + oMain.HKeeperID.ToString() + "," + oMain.HDeptID.ToString() + ",'" + oMain.HExplanation + "','" + oMain.HInnerBillNo + "'," + DBUtility.ClsPub.BoolToString(oMain.HRedBlueFlag) +
@@ -21653,7 +21659,17 @@
                else
                {
                    string sJson_MainCustom = "";    //主表自定义字段
                    string sJson_Date = "";         //单据日期
                    sJson_MainCustom = Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["MainCustom"]);
                    if (oSystemParameterMain.WMS_BillDateMode == "Y") //系统参数  单据日期是否取界面递入日期
                    {
                        sJson_Date = "\"FDATE\":\"" + oMain.HDate.ToShortDateString() + "\",";
                    }
                    else
                    {
                        sJson_Date = "\"FDATE\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDATE"]) + "\",";
                    }
                    string sJson_Main = "{\"Creator\":\"\",\"NeedUpDateFields\":[],\"NeedReturnFields\":[],\"IsDeleteEntry\":\"True\",\"SubSystemId\":\"\",\"IsVerifyBaseDataField\":\"false\",\"IsEntryBatchFill\":\"True\",\"ValidateFlag\":\"True\",\"NumberSearch\":\"True\",\"InterationFlags\":\"\"," +
                        "\"Model\":{ " +
@@ -21663,7 +21679,7 @@
                        "\"FStockOrgId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FStockOrgId"]) + "\"}," +
                        "\"FPickOrgId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FPickOrgId"]) + "\"}," +
                        "\"FStockDirect\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FStockDirect"]) + "\"," +
                        "\"FDate\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDate"]) + "\"," +
                        sJson_Date +
                        "\"FCustId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FCustId"]) + "\"}," +
                        "\"FDeptId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDeptId"]) + "\"}," +
                        "\"FPickerId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FPickerId"]) + "\"}," +
@@ -21919,6 +21935,12 @@
                string s = "";
                int sYear = 0;
                int sPeriod = 0;
                if (oSystemParameterMain.WMS_BillDateMode == "N") //系统参数  单据日期是否取界面递入日期
                {
                    oMain.HDate = DateTime.Today;
                }
                if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(oMain.HDate, ref sYear, ref sPeriod, ref s) == false)
                {
                    sErrMsg = s;
@@ -21940,7 +21962,7 @@
                ",HStockStyle" +
                ",HSTOCKORGID,HOWNERID" +
                ") " +
                " values('1206','1206'," + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "',convert(varchar(10),getdate(),120),'" + oMain.HMainSourceBillType + "'" +
                " values('1206','1206'," + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HDate.ToShortDateString() + "','" + oMain.HMainSourceBillType + "'" +
                ", " + oMain.HYear.ToString() + "," + oMain.HPeriod.ToString() + ",'" + oMain.HRemark + "','" + oMain.HMaker + "',convert(varchar(10),getdate(),120)" +
                ", " + oMain.HSupID.ToString() + "," + oMain.HWHID.ToString() + "," + oMain.HSCWHID.ToString() + "," + oMain.HEmpID.ToString() + "," + oMain.HManagerID.ToString() + "," + oMain.HSecManagerID.ToString() +
                ", " + oMain.HKeeperID.ToString() + "," + oMain.HDeptID.ToString() + ",'" + oMain.HExplanation + "','" + oMain.HInnerBillNo + "'," + DBUtility.ClsPub.BoolToString(oMain.HRedBlueFlag) +
@@ -21975,6 +21997,7 @@
                    string sJson_StockStyle = "";
                    string sJson_MainCustom = "";   //主表自定义字段
                    string sJson_BillTypeID = "";    //单据类型
                    string sJson_Date = "";         //单据日期
                    sJson_MainCustom = Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["MainCustom"]);
                    if (oMain.HBillSubType == "" || oMain.HBillSubType == null)
@@ -21984,6 +22007,15 @@
                    else
                    {
                        sJson_BillTypeID = "\"FBillTypeID\":{ \"FNumber\":\"" + oMain.HBillSubType + "\" },";
                    }
                    if (oSystemParameterMain.WMS_BillDateMode == "Y") //系统参数  单据日期是否取界面递入日期
                    {
                        sJson_Date = "\"FDATE\":\"" + oMain.HDate.ToShortDateString() + "\",";
                    }
                    else
                    {
                        sJson_Date = "\"FDATE\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDATE"]) + "\",";
                    }
                    if (oSystemParameterMain.WMS_CampanyName == "韩电") //系统参数  客户定制化名称     空白为通用
@@ -22004,7 +22036,7 @@
                        "\"FStockOrgId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FStockOrgId"]) + "\"}," +
                        "\"FPickOrgId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FPickOrgId"]) + "\"}," +
                        "\"FStockDirect\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FStockDirect"]) + "\"," +
                        "\"FDate\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDate"]) + "\"," +
                        sJson_Date +
                        //"\"FCustId\":{\"FNumber\":\"" + oMain.HSupplyID.ToString() + "\"}," +
                        "\"FDeptId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDeptId"]) + "\"}," +
                        "\"FPickerId\":{\"FSTAFFNUMBER\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FPickerId"]) + "\"}," +
@@ -31331,6 +31363,12 @@
                string s = "";
                int sYear = 0;
                int sPeriod = 0;
                if (oSystemParameterMain.WMS_BillDateMode == "N") //系统参数  单据日期是否取界面递入日期
                {
                    oMain.HDate = DateTime.Today;
                }
                if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(oMain.HDate, ref sYear, ref sPeriod, ref s) == false)
                {
                    sErrMsg = s;
@@ -31352,7 +31390,7 @@
                ",HStockStyle" +
                ",HSTOCKORGID,HOWNERID" +
                ") " +
                " values('1203','1203'," + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "',convert(varchar(10),getdate(),120),'" + oMain.HMainSourceBillType + "'" +
                " values('1203','1203'," + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HDate.ToShortDateString() + "','" + oMain.HMainSourceBillType + "'" +
                ", " + oMain.HYear.ToString() + "," + oMain.HPeriod.ToString() + ",'" + oMain.HRemark + "','" + oMain.HMaker + "',convert(varchar(10),getdate(),120)" +
                ", " + oMain.HSupID.ToString() + "," + oMain.HWHID.ToString() + "," + oMain.HSCWHID.ToString() + "," + oMain.HEmpID.ToString() + "," + oMain.HManagerID.ToString() + "," + oMain.HSecManagerID.ToString() +
                ", " + oMain.HKeeperID.ToString() + "," + oMain.HDeptID.ToString() + ",'" + oMain.HExplanation + "','" + oMain.HInnerBillNo + "'," + DBUtility.ClsPub.BoolToString(oMain.HRedBlueFlag) +
@@ -31386,7 +31424,8 @@
                {
                    string sJson_StockStyle = "";
                    string sJson_MainCustom = "";   //主表自定义字段
                    string sJson_BillTypeID = "";    //单据类型
                    string sJson_BillTypeID = "";   //单据类型
                    string sJson_Date = "";         //单据日期
                    sJson_MainCustom = Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["MainCustom"]);
                    if (oMain.HBillSubType == "" || oMain.HBillSubType == null)
@@ -31396,6 +31435,15 @@
                    else
                    {
                        sJson_BillTypeID = "\"FBillTypeID\":{ \"FNumber\":\"" + oMain.HBillSubType + "\" },";
                    }
                    if (oSystemParameterMain.WMS_BillDateMode == "Y") //系统参数  单据日期是否取界面递入日期
                    {
                        sJson_Date = "\"FDATE\":\"" + oMain.HDate.ToShortDateString() + "\",";
                    }
                    else
                    {
                        sJson_Date = "\"FDATE\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDATE"]) + "\",";
                    }
                    if (oSystemParameterMain.WMS_CampanyName == "韩电") //系统参数  客户定制化名称     空白为通用
@@ -31417,7 +31465,7 @@
                        sJson_BillTypeID +
                        "\"FStockOrgId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FStockOrgId"]) + "\"}," +
                        "\"FStockDirect\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FStockDirect"]) + "\"," +
                        "\"FDate\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDate"]) + "\"," +
                        sJson_Date +
                        //"\"FSUPPLIERID\":{\"FNumber\":\"" + oMain.HSupplyID.ToString() + "\"}," +
                        "\"FDEPTID\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDEPTID"]) + "\"}," +
                        //"\"FSTOCKERID\":{\"FName\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSTOCKERID"]) + "\"}," +
@@ -31672,6 +31720,12 @@
                string s = "";
                int sYear = 0;
                int sPeriod = 0;
                if (oSystemParameterMain.WMS_BillDateMode == "N") //系统参数  单据日期是否取界面递入日期
                {
                    oMain.HDate = DateTime.Today;
                }
                if (DBUtility.Xt_BaseBillFun.Fun_AllowYearPeriod(oMain.HDate, ref sYear, ref sPeriod, ref s) == false)
                {
                    sErrMsg = s;
@@ -31693,7 +31747,7 @@
                ",HStockStyle" +
                ",HSTOCKORGID,HOWNERID" +
                ") " +
                " values('1203','1203'," + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "',convert(varchar(10),getdate(),120),'" + oMain.HMainSourceBillType + "'" +
                " values('1203','1203'," + oMain.HInterID.ToString() + ",'" + oMain.HBillNo + "','" + oMain.HDate.ToShortDateString() + "','" + oMain.HMainSourceBillType + "'" +
                ", " + oMain.HYear.ToString() + "," + oMain.HPeriod.ToString() + ",'" + oMain.HRemark + "','" + oMain.HMaker + "',convert(varchar(10),getdate(),120)" +
                ", " + oMain.HSupID.ToString() + "," + oMain.HWHID.ToString() + "," + oMain.HSCWHID.ToString() + "," + oMain.HEmpID.ToString() + "," + oMain.HManagerID.ToString() + "," + oMain.HSecManagerID.ToString() +
                ", " + oMain.HKeeperID.ToString() + "," + oMain.HDeptID.ToString() + ",'" + oMain.HExplanation + "','" + oMain.HInnerBillNo + "'," + DBUtility.ClsPub.BoolToString(oMain.HRedBlueFlag) +
@@ -31717,7 +31771,18 @@
                else
                {
                    string sJson_MainCustom = "";    //主表自定义字段
                    string sJson_Date = "";         //单据日期
                    sJson_MainCustom = Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["MainCustom"]);
                    if (oSystemParameterMain.WMS_BillDateMode == "Y") //系统参数  单据日期是否取界面递入日期
                    {
                        sJson_Date = "\"FDATE\":\"" + oMain.HDate.ToShortDateString() + "\",";
                    }
                    else
                    {
                        sJson_Date = "\"FDATE\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDATE"]) + "\",";
                    }
                    string sJson_Main = "{\"Creator\":\"\",\"NeedUpDateFields\":[],\"NeedReturnFields\":[],\"IsDeleteEntry\":\"True\",\"SubSystemId\":\"\",\"IsVerifyBaseDataField\":\"false\",\"IsEntryBatchFill\":\"True\",\"ValidateFlag\":\"True\",\"NumberSearch\":\"True\",\"InterationFlags\":\"\"," +
                        "\"Model\":{ " +
                        //"FID": 0,
@@ -31725,7 +31790,7 @@
                        "\"FBillTypeID\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FBillTypeID"]) + "\"}," +
                        "\"FStockOrgId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FStockOrgId"]) + "\"}," +
                        "\"FStockDirect\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FStockDirect"]) + "\"," +
                        "\"FDate\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDate"]) + "\"," +
                        sJson_Date +
                        "\"FSUPPLIERID\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSUPPLIERID"]) + "\"}," +
                        "\"FDeptId\":{\"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDeptId"]) + "\"}," +
                        "\"FACCEPTANCE\":{\"FStaffNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FACCEPTANCE"]) + "\"}," +