chenhaozhe
1 天以前 14ae0e21c8660dbb3ac20a5b0d9db9b6dde3cfb9
WebAPI/Controllers/CJGL/Cj_StationEntrustInBillController.cs
@@ -219,6 +219,15 @@
                    sBillBarCode = NewBarCode[0];
                }
                string sBillNo = sBillBarCode;
                //截取条码类型 前两位
                string BillNoType1 = sBillNo.Substring(0, Math.Min(2, sBillNo.Length));
                switch (BillNoType1)
                {
                    case "OP"://流转卡
                        //同步工序流转卡
                        oCN.RunProc("exec h_p_IFCLD_ERPSourceBillToLocal_ProcExchAndRouting '" + sBillNo + "'");
                        break;
                }
                //得到信息
                ds = oCN.RunProcReturn("select top 1 * from h_v_Sc_ProcessExchangeBillList  where 单据号= '" + sBillNo + "'", "h_v_Sc_ProcessExchangeBillList");
                //写入信息
@@ -3389,7 +3398,7 @@
                sRemark = sRemark + " ;保存后控制" + DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss:ffff");
                //返回API递入所需数据
                DataSet Ds = oCn.RunProcReturn("exec h_p_MES_StationEntrustInBill_ProdMateRequest_CLD " + oMain.HProcExchInterID.ToString() + "," + oMain.HProcExchEntryID.ToString() + "," + oMain.HProcNo.ToString() + "," + oMain.HQty.ToString(), "h_p_MES_StationEntrustInBill_ProdMateRequest_CLD");
                DataSet Ds = oCn.RunProcReturn("exec h_p_MES_StationEntrustInBill_ProdMateRequest_CLD '" + oMain.HBillNo + "'," + oMain.HProcExchInterID.ToString() + "," + oMain.HProcExchEntryID.ToString() + "," + oMain.HProcNo.ToString() + "," + oMain.HQty.ToString(), "h_p_MES_StationEntrustInBill_ProdMateRequest_CLD");
                if (Ds == null || Ds.Tables[0].Rows.Count == 0)
                {
                    sErrMsg = "未获取到API所需递入数据!";
@@ -3476,10 +3485,10 @@
                "\"FOutProcessId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutProcessId"]) + "\" }," +
                //"FOutEmpId": {"FSTAFFNUMBER": ""},
                "\"FOutOperDescr\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutOperDescr"]) + "\"," +
                //"FOutPurOrgId": {"FNumber": ""},
                "\"FOutPurOrgId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutPurOrgId"]) + "\" }," +
                "\"FInProOrgId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FInProOrgId"]) + "\" }," +
                "\"FInOPBillNo\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FInOPBillNo"]) + "\"," +
                //"FOutSupplier": {"FNUMBER": ""},
                "\"FOutSupplier\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutSupplier"]) + "\" }," +
                "\"FOutOperId\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutOperId"]) + "\"," +
                "\"FInProcessId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FInProcessId"]) + "\" }," +
                "\"FInDeptId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FInDeptId"]) + "\" }," +
@@ -3517,12 +3526,12 @@
                "\"FIsInspect\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FIsInspect"]) + "\"," +
                "\"FQCSchemeId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FQCSchemeId"]) + "\" }," +
                "\"FSendProFailPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendProFailPrice"]) + "\"," +
                //"FReceiveCurrency": {"FNUMBER": ""},
                //"FReceiveQualifiedPrice": 0,
                //"FReceiveProFailPrice": 0,
                //"FReceiveMatFailPrice": 0,
                "\"FReceiveCurrency\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveCurrency"]) + "\" }," +
                "\"FReceiveQualifiedPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveQualifiedPrice"]) + "\"," +
                "\"FReceiveProFailPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveProFailPrice"]) + "\"," +
                "\"FReceiveMatFailPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveMatFailPrice"]) + "\"," +
                "\"FReceiveValuationUnitId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveValuationUnitId"]) + "\" }," +
                //"FReceiveTaxRate": 0,
                "\"FReceiveTaxRate\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveTaxRate"]) + "\"," +
                "\"FSendMatFailPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendMatFailPrice"]) + "\"," +
                //"FOperInspectSelectQty": 0,
                "\"FSendValuationUnitId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendValuationUnitId"]) + "\" }," +
@@ -3580,9 +3589,9 @@
                "\"FDemandBillEntryId\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDemandBillEntryId"]) + "\"," +
                //"FInspectEntryId": 0,
                "\"FConvertType\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FConvertType"]) + "\"," +
                //"FReceiveQualifiedTaxPrice": 0,
                //"FReceiveProFailTaxPrice": 0,
                //"FReceiveMatFailTaxPrice": 0,
                "\"FReceiveQualifiedTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveQualifiedTaxPrice"]) + "\"," +
                "\"FReceiveProFailTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveProFailTaxPrice"]) + "\"," +
                "\"FReceiveMatFailTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveMatFailTaxPrice"]) + "\"," +
                "\"FSendQualifiedTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendQualifiedTaxPrice"]) + "\"," +
                "\"FSendProFailTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendProFailTaxPrice"]) + "\"," +
                "\"FSendMatFailTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendMatFailTaxPrice"]) + "\"," +
@@ -3762,7 +3771,7 @@
            try
            {
                //返回API递入所需数据
                DataSet Ds = oCn.RunProcReturn("exec h_p_MES_StationEntrustInBill_ProdMateRequest_CLD " + HProcExchInterID.ToString() + "," + HProcExchEntryID.ToString() + "," + HProcNo.ToString() + "," + HQty.ToString(), "h_p_MES_StationEntrustInBill_ProdMateRequest_CLD");
                DataSet Ds = oCn.RunProcReturn("exec h_p_MES_StationEntrustInBill_ProdMateRequest_CLD '" + HBillNo + "'," + HProcExchInterID.ToString() + "," + HProcExchEntryID.ToString() + "," + HProcNo.ToString() + "," + HQty.ToString(), "h_p_MES_StationEntrustInBill_ProdMateRequest_CLD");
                if (Ds == null || Ds.Tables[0].Rows.Count == 0)
                {
                    sErrMsg = "未获取到API所需递入数据!";
@@ -3849,10 +3858,10 @@
                "\"FOutProcessId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutProcessId"]) + "\" }," +
                //"FOutEmpId": {"FSTAFFNUMBER": ""},
                "\"FOutOperDescr\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutOperDescr"]) + "\"," +
                //"FOutPurOrgId": {"FNumber": ""},
                "\"FOutPurOrgId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutPurOrgId"]) + "\" }," +
                "\"FInProOrgId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FInProOrgId"]) + "\" }," +
                "\"FInOPBillNo\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FInOPBillNo"]) + "\"," +
                //"FOutSupplier": {"FNUMBER": ""},
                "\"FOutSupplier\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutSupplier"]) + "\" }," +
                "\"FOutOperId\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FOutOperId"]) + "\"," +
                "\"FInProcessId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FInProcessId"]) + "\" }," +
                "\"FInDeptId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FInDeptId"]) + "\" }," +
@@ -3890,12 +3899,12 @@
                "\"FIsInspect\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FIsInspect"]) + "\"," +
                "\"FQCSchemeId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FQCSchemeId"]) + "\" }," +
                "\"FSendProFailPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendProFailPrice"]) + "\"," +
                //"FReceiveCurrency": {"FNUMBER": ""},
                //"FReceiveQualifiedPrice": 0,
                //"FReceiveProFailPrice": 0,
                //"FReceiveMatFailPrice": 0,
                "\"FReceiveCurrency\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveCurrency"]) + "\" }," +
                "\"FReceiveQualifiedPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveQualifiedPrice"]) + "\"," +
                "\"FReceiveProFailPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveProFailPrice"]) + "\"," +
                "\"FReceiveMatFailPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveMatFailPrice"]) + "\"," +
                "\"FReceiveValuationUnitId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveValuationUnitId"]) + "\" }," +
                //"FReceiveTaxRate": 0,
                "\"FReceiveTaxRate\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveTaxRate"]) + "\"," +
                "\"FSendMatFailPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendMatFailPrice"]) + "\"," +
                //"FOperInspectSelectQty": 0,
                "\"FSendValuationUnitId\":{ \"FNumber\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendValuationUnitId"]) + "\" }," +
@@ -3953,9 +3962,9 @@
                "\"FDemandBillEntryId\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FDemandBillEntryId"]) + "\"," +
                //"FInspectEntryId": 0,
                "\"FConvertType\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FConvertType"]) + "\"," +
                //"FReceiveQualifiedTaxPrice": 0,
                //"FReceiveProFailTaxPrice": 0,
                //"FReceiveMatFailTaxPrice": 0,
                "\"FReceiveQualifiedTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveQualifiedTaxPrice"]) + "\"," +
                "\"FReceiveProFailTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveProFailTaxPrice"]) + "\"," +
                "\"FReceiveMatFailTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FReceiveMatFailTaxPrice"]) + "\"," +
                "\"FSendQualifiedTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendQualifiedTaxPrice"]) + "\"," +
                "\"FSendProFailTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendProFailTaxPrice"]) + "\"," +
                "\"FSendMatFailTaxPrice\":\"" + Pub_Class.ClsPub.isStrNull(Ds.Tables[0].Rows[0]["FSendMatFailTaxPrice"]) + "\"," +