From 46ca4c95375f112a28113049517d27dc2e94384f Mon Sep 17 00:00:00 2001
From: zrg <z18737863051@163.com>
Date: 星期四, 18 七月 2024 17:18:56 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MES-WEB-API
---
Model/生产管理/设备管理/ClsSb_EquipDotCheckPlanBillMain.cs | 6 ++-
WebAPI/Controllers/BaseSet/Gy_DepartmentController.cs | 26 ++++++++++---
WebAPI/Controllers/仓存管理/领料发货/Kf_MateOutRequestBillController.cs | 2
WebAPI/Controllers/品质管理/巡检单/QC_PatrolProcCheckOtherBillController.cs | 2
WebAPI/Controllers/条码管理/WEBSController.cs | 52 +++++++++++++++++++-------
DAL/生产管理/设备管理/ClsSb_EquipDotCheckPlanBill.cs | 8 +++-
WebAPI/Controllers/品质管理/首件检验单/QC_FirstPieceCheckBillController.cs | 4 +-
WebAPI/Controllers/ProductInController.cs | 7 ++-
WebAPI/Controllers/品质管理/工序检验单/QC_ProcessCheckBillController.cs | 2
9 files changed, 78 insertions(+), 31 deletions(-)
diff --git "a/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBill.cs" "b/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBill.cs"
index 4a90c79..cceebe6 100644
--- "a/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBill.cs"
+++ "b/DAL/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBill.cs"
@@ -55,6 +55,9 @@
",HCheckCycle=" + omodel.HCheckCycle.ToString() +
",HExplanation='" + omodel.HExplanation+"'" +
",HInnerBillNo='" + omodel.HInnerBillNo+"'" +
+ ",HUSEORGID=" + omodel.HUSEORGID +
+ //",HCREATEORGID=" + omodel.HCREATEORGID +
+ ",HDeptID=" + omodel.HDeptID +
" where HInterID=" + lngBillKey.ToString());
//鍒犻櫎鍏宠仈
DeleteRelation(ref sReturn, lngBillKey);
@@ -115,10 +118,11 @@
"(HBillType,HBillSubType,HInterID,HBillNo,HDate,HMaker,HMakeDate" +
",HYear,HPeriod,HRemark,HEquipID" +
",HBeginDate,HEndDate,HCheckCycle,HCycleUnit,HExplanation,HInnerBillNo,HMouldDotCheckRuleID" +
- ") "+
+ ",HUSEORGID,HCREATEORGID,HDeptID" +
+ ") " +
" values('" + this.BillType + "','" + this.HBillSubType + "'," +omodel.HInterID.ToString() + ",'" + omodel.HBillNo + "','" + omodel.HDate + "','" + omodel.HMaker + "',getdate()" +
"," + omodel.HYear.ToString() + "," + omodel.HPeriod.ToString() + ",'" + omodel.HRemark + "'," + omodel.HEquipID.ToString() +
- ",'" + omodel.HBeginDate +"','" +omodel.HEndDate + "'," + omodel.HCheckCycle.ToString() +",'"+ omodel.HCycleUnit + "','" + omodel.HExplanation + "','" + omodel.HInnerBillNo +"','" + omodel.HMouldDotCheckRuleID + "'"+
+ ",'" + omodel.HBeginDate +"','" +omodel.HEndDate + "'," + omodel.HCheckCycle.ToString() +",'"+ omodel.HCycleUnit + "','" + omodel.HExplanation + "','" + omodel.HInnerBillNo +"','" + omodel.HMouldDotCheckRuleID + "',"+ omodel.HUSEORGID + "," + omodel.HCREATEORGID + "," + omodel.HDeptID +
") ");
//鎻掑叆瀛愯〃
foreach (Model.ClsSb_EquipDotCheckPlanBillSub oSub in DetailColl)
diff --git "a/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBillMain.cs" "b/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBillMain.cs"
index ced5ce2..fe357b6 100644
--- "a/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBillMain.cs"
+++ "b/Model/\347\224\237\344\272\247\347\256\241\347\220\206/\350\256\276\345\244\207\347\256\241\347\220\206/ClsSb_EquipDotCheckPlanBillMain.cs"
@@ -14,7 +14,9 @@
public string HExplanation;
public string HInnerBillNo;
public int HMouldDotCheckRuleID;//设备点检规程id
-
-
+
+ public int HUSEORGID;
+ public int HCREATEORGID;
+ public int HDeptID;
}
}
diff --git a/WebAPI/Controllers/BaseSet/Gy_DepartmentController.cs b/WebAPI/Controllers/BaseSet/Gy_DepartmentController.cs
index 8dfc115..7abfd45 100644
--- a/WebAPI/Controllers/BaseSet/Gy_DepartmentController.cs
+++ b/WebAPI/Controllers/BaseSet/Gy_DepartmentController.cs
@@ -61,12 +61,26 @@
columnNameList.Add(JsonConvert.DeserializeObject(ColmString));//鑾峰彇鍒癉ataColumn鍒楀璞$殑鍒楀悕
}
- objJsonResult.code = "1";
- objJsonResult.count = 1;
- objJsonResult.Message = "Sucess锛�";
- objJsonResult.data = ds.Tables[0];
- objJsonResult.list = columnNameList;
- return objJsonResult;
+ if (ds.Tables[0].Rows.Count > 0 && ds != null)
+ {
+ objJsonResult.code = "1";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "Sucess锛�";
+ objJsonResult.data = ds.Tables[0];
+ objJsonResult.list = columnNameList;
+ return objJsonResult;
+ }
+ else
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = "娌℃湁鏌ヨ鍒伴儴闂ㄦ暟鎹紝璇疯仈绯荤郴缁熺鐞嗗憳杩涜鏍稿";
+ objJsonResult.data = ds.Tables[0];
+ objJsonResult.list = columnNameList;
+ return objJsonResult;
+ }
+
+
}
catch (Exception e)
{
diff --git a/WebAPI/Controllers/ProductInController.cs b/WebAPI/Controllers/ProductInController.cs
index 81e5847..a9a1b45 100644
--- a/WebAPI/Controllers/ProductInController.cs
+++ b/WebAPI/Controllers/ProductInController.cs
@@ -264,8 +264,11 @@
//oBar = webserver.get_CheckTypeByBarCode(sCode, sInterID, sBillType, sBillNo, sMaker, WhID, SPID, sQty, sRedBlue, SourceFlag, sSourceBillNo, sSourceType, HOWNERID, ref DBUtility.ClsPub.sErrInfo);
WebS.WebService1 oWebs = new WebS.WebService1();
WebS.ClsKf_ICStockBill_WMS WebSoBar = new WebS.ClsKf_ICStockBill_WMS();
- string sExpressNumber = "";
- //WebSoBar = oWebs.get_CheckTypeByBarCode_All(sCode, sInterID, HBillType, sBillNo, sMaker, WhID, SPID, sQty, sRedBlue, SourceFlag, sSourceBillNo, sSourceType, HOWNERID, sExpressNumber, ref DBUtility.ClsPub.sErrInfo);
+
+ Kf_MateOutBillController obill = new Kf_MateOutBillController();
+ //閲嶆柊鍚屾鐢熶骇棰嗘枡鍗�
+ objJsonResult = obill.GetKf_MateOutBill_Sync_Json(HBillNo, HBillType);
+
WebSoBar = oWebs.get_BillBarCode_MateOutCheck(HBillNo, HBillType, HMaker, HOwnerID, ref DBUtility.ClsPub.sErrInfo);
if (WebSoBar == null)
{
diff --git "a/WebAPI/Controllers/\344\273\223\345\255\230\347\256\241\347\220\206/\351\242\206\346\226\231\345\217\221\350\264\247/Kf_MateOutRequestBillController.cs" "b/WebAPI/Controllers/\344\273\223\345\255\230\347\256\241\347\220\206/\351\242\206\346\226\231\345\217\221\350\264\247/Kf_MateOutRequestBillController.cs"
index 5130162..8d56be4 100644
--- "a/WebAPI/Controllers/\344\273\223\345\255\230\347\256\241\347\220\206/\351\242\206\346\226\231\345\217\221\350\264\247/Kf_MateOutRequestBillController.cs"
+++ "b/WebAPI/Controllers/\344\273\223\345\255\230\347\256\241\347\220\206/\351\242\206\346\226\231\345\217\221\350\264\247/Kf_MateOutRequestBillController.cs"
@@ -11,7 +11,7 @@
using WebAPI.Models;
-namespace WebAPI.Controllers.浠撳瓨绠$悊.棰嗘枡鍙戣揣
+namespace WebAPI.Controllers
{
public class Kf_MateOutRequestBillController : ApiController
{
diff --git "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\241\346\243\200\345\215\225/QC_PatrolProcCheckOtherBillController.cs" "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\241\346\243\200\345\215\225/QC_PatrolProcCheckOtherBillController.cs"
index 6263785..52e6cd7 100644
--- "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\241\346\243\200\345\215\225/QC_PatrolProcCheckOtherBillController.cs"
+++ "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\241\346\243\200\345\215\225/QC_PatrolProcCheckOtherBillController.cs"
@@ -34,7 +34,7 @@
List<object> columnNameList = new List<object>();
string sql1 = "select * from h_v_QC_PatrolProcCheckOtherBill where 1 = 1 ";
- string sql = sql1 + sWhere + " order by hmainid ";
+ string sql = sql1 + sWhere + " order by 鍒跺崟鏃ユ湡 desc ";
ds = oCN.RunProcReturn(sql, "h_v_QC_PatrolProcCheckOtherBill");
//娣诲姞鍒楀悕
diff --git "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillController.cs" "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillController.cs"
index 05ae380..924a72a 100644
--- "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillController.cs"
+++ "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillController.cs"
@@ -136,7 +136,7 @@
List<object> columnNameList = new List<object>();
string sql1 = "select * from h_v_QC_ProcessCheckBillMainList where 1 = 1 ";
- string sql = sql1 + sWhere + " order by hmainid desc";
+ string sql = sql1 + sWhere + " order by 鍒跺崟鏃ユ湡 desc";
ds = oCN.RunProcReturn(sql, "h_v_QC_ProcessCheckBillMainList");
//娣诲姞鍒楀悕
diff --git "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\351\246\226\344\273\266\346\243\200\351\252\214\345\215\225/QC_FirstPieceCheckBillController.cs" "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\351\246\226\344\273\266\346\243\200\351\252\214\345\215\225/QC_FirstPieceCheckBillController.cs"
index 1ad168a..e3124e8 100644
--- "a/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\351\246\226\344\273\266\346\243\200\351\252\214\345\215\225/QC_FirstPieceCheckBillController.cs"
+++ "b/WebAPI/Controllers/\345\223\201\350\264\250\347\256\241\347\220\206/\351\246\226\344\273\266\346\243\200\351\252\214\345\215\225/QC_FirstPieceCheckBillController.cs"
@@ -34,7 +34,7 @@
List<object> columnNameList = new List<object>();
string sql1 = "select * from h_v_QC_FirstPieceCheckBill where 1 = 1 ";
- string sql = sql1 + sWhere + " order by hmainid desc";
+ string sql = sql1 + sWhere + " order by 鍒跺崟鏃ユ湡 desc";
ds = oCN.RunProcReturn(sql, "h_v_QC_FirstPieceCheckBill");
//娣诲姞鍒楀悕
@@ -85,7 +85,7 @@
List<object> columnNameList = new List<object>();
string sql1 = "select * from h_v_QC_FirstPieceCheckBillMainList where 1 = 1 ";
- string sql = sql1 + sWhere + " order by 鍒跺崟鏃ユ湡 desc";
+ string sql = sql1 + sWhere + " ";
ds = oCN.RunProcReturn(sql, "h_v_QC_FirstPieceCheckBillMainList");
//娣诲姞鍒楀悕
diff --git "a/WebAPI/Controllers/\346\235\241\347\240\201\347\256\241\347\220\206/WEBSController.cs" "b/WebAPI/Controllers/\346\235\241\347\240\201\347\256\241\347\220\206/WEBSController.cs"
index 32aaaca..6d9b83c 100644
--- "a/WebAPI/Controllers/\346\235\241\347\240\201\347\256\241\347\220\206/WEBSController.cs"
+++ "b/WebAPI/Controllers/\346\235\241\347\240\201\347\256\241\347\220\206/WEBSController.cs"
@@ -3778,31 +3778,55 @@
[HttpGet]
public object get_SourceBarCode_MateOut_Json(Int64 HInterID, string HBillNo, string HBillType, string HSourceBillNo, string HSourceBillType, string HMaker, Double HPTQty, Int64 HPlanMode, Int64 HFIFOWhID, Int64 HStockOrgID)
{
- try
+ //鑾峰彇绯荤粺鍙傛暟
+ string sErrMsg = "";
+ if (oSystemParameter.ShowBill(ref sErrMsg) == true)
{
- WebSoBar = oWebs.get_SourceBarCode_MateOut(HInterID, HBillNo, HBillType, HSourceBillNo, HSourceBillType, HMaker, HPTQty, HPlanMode, HFIFOWhID, HStockOrgID, ref DBUtility.ClsPub.sErrInfo);
- if (WebSoBar == null)
+ if (oSystemParameter.omodel.WMS_CloudMode.ToUpper() == "N") //绯荤粺鍙傛暟鏄惁涓虹鏈変簯妯″紡,N涓哄叕鏈変簯妯″紡锛孻涓虹鏈変簯妯″紡
+ {
+ if(HSourceBillType == "1214")
+ {
+ //閲嶆柊鍚屾鐢熶骇鍙戞枡閫氱煡鍗�
+ Kf_MateOutRequestBillController obill = new Kf_MateOutRequestBillController();
+ objJsonResult = obill.GetKf_MateOutRequestBill_Sync_Json(HSourceBillNo, HSourceBillType);
+ }
+ }
+
+ try
+ {
+ WebSoBar = oWebs.get_SourceBarCode_MateOut(HInterID, HBillNo, HBillType, HSourceBillNo, HSourceBillType, HMaker, HPTQty, HPlanMode, HFIFOWhID, HStockOrgID, ref DBUtility.ClsPub.sErrInfo);
+ if (WebSoBar == null)
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 0;
+ objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
+ objJsonResult.data = null;
+ return objJsonResult;
+ }
+ else
+ {
+ objJsonResult.code = "0";
+ objJsonResult.count = 1;
+ objJsonResult.Message = "鎴愬姛";
+ objJsonResult.data = WebSoBar;
+ return objJsonResult;
+ }
+ }
+ catch (Exception e)
{
objJsonResult.code = "0";
objJsonResult.count = 0;
- objJsonResult.Message = DBUtility.ClsPub.sErrInfo;
+ objJsonResult.Message = "鎵弿婧愬崟鏉$爜澶辫触锛�" + e.ToString();
objJsonResult.data = null;
return objJsonResult;
}
- else
- {
- objJsonResult.code = "0";
- objJsonResult.count = 1;
- objJsonResult.Message = "鎴愬姛";
- objJsonResult.data = WebSoBar;
- return objJsonResult;
- }
+
}
- catch (Exception e)
+ else
{
objJsonResult.code = "0";
objJsonResult.count = 0;
- objJsonResult.Message = "鎵弿婧愬崟鏉$爜澶辫触锛�" + e.ToString();
+ objJsonResult.Message = "鑾峰彇绯荤粺鍙傛暟澶辫触锛� " + sErrMsg;
objJsonResult.data = null;
return objJsonResult;
}
--
Gitblit v1.9.1