Model/Model.csproj | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
Model/仓库管理/ClsKf_MoveStockStepOutBillMain.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
Model/仓库管理/ClsKf_MoveStockStepOutBillSub.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
WebAPI/Controllers/MoveStockBillController.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
WebAPI/Controllers/POStockInBillController.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
WebAPI/ListModels.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
WebAPI/WebServer.cs | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
Model/Model.csproj
@@ -214,8 +214,10 @@ <Compile Include="ä»åºç®¡ç\ClsKf_MateOutRequestBillSub.cs" /> <Compile Include="ä»åºç®¡ç\ClsKF_ChangeBoxBillMain.cs" /> <Compile Include="ä»åºç®¡ç\ClsKF_ChangeBoxBillSub.cs" /> <Compile Include="ä»åºç®¡ç\ClsKf_MoveStockStepOutBillMain.cs" /> <Compile Include="ä»åºç®¡ç\ClsKf_MoveStockBillMain.cs" /> <Compile Include="ä»åºç®¡ç\ClsKf_MoveStockBillScheme.cs" /> <Compile Include="ä»åºç®¡ç\ClsKf_MoveStockStepOutBillSub.cs" /> <Compile Include="ä»åºç®¡ç\ClsKf_MoveStockBillSub.cs" /> <Compile Include="ä»åºç®¡ç\ClsKf_OtherInBillMain.cs" /> <Compile Include="ä»åºç®¡ç\ClsKf_OtherInBillScheme.cs" /> Model/²Ö¿â¹ÜÀí/ClsKf_MoveStockStepOutBillMain.cs
New file @@ -0,0 +1,23 @@ using System; using System.Collections.Generic; using System.Text; namespace Model { public class ClsKf_MoveStockStepOutBillMain : DBUtility.ClsXt_BaseBillMain { public Int64 HSupID;// int --ä¾åºå public Int64 HWHID;// int --ä»åº public Int64 HSCWHID;// int --è°åºä»åº public Int64 HEmpID;// int --ä¸å¡å public Int64 HManagerID;// int --è´è´£äºº public Int64 HSecManagerID;// int --éªæ¶ public Int64 HKeeperID;// int --ä¿ç®¡å public Int64 HDeptID;// int --é¨é¨ public string HExplanation;// varchar(200) --ÕªÒª public string HInnerBillNo;// varchar(50) --å é¨åæ®å· public bool HRedBlueFlag;// bit --红èå public int HCurID; } } Model/²Ö¿â¹ÜÀí/ClsKf_MoveStockStepOutBillSub.cs
New file @@ -0,0 +1,37 @@ using System; using System.Collections.Generic; using System.Text; namespace Model { public class ClsKf_MoveStockStepOutBillSub : DBUtility.ClsXt_BaseBillSub { public Int64 HMaterID;// int --ç©æID public string HBatchNo;// varchar(50) --æ¹æ¬¡ public int HAuxPropID; public Int64 HPropertyID;// int --è¾ å©å±æ§ public Int64 HSecUnitID;// int --è¾ å©è®¡éåä½ public Single HSecUnitRate;// money --æ¢ç®ç public Int64 HUnitID;// int --计éåä½ public double HQtyMust;// dec(18,8) --åºæ¶æ°é public double HQty;// dec(18,8) --宿¶æ°é public double HPrice;// dec(18,8) --åä»· public double HMoney;// dec(18,8) --éé¢ public Int64 HWHID;// int --æ¶æä»åº public Int64 HSCWHID;// int --è°åºä»åºID public Int64 HSPID;// int --è°å ¥ä»ä½ public Int64 HSCSPID;// int --è°åºä»ä½ID public Int64 HPOOrderInterID;// int --éè´è®¢å主å ç public Int64 HPOOrderEntryID;// int --éè´è®¢ååå ç public string HPOOrderBillNo;// varchar(50) --éè´è®¢åå· public Int64 HSeOrderInterID;// int --éå®è®¢å主å ç public Int64 HSeOrderEntryID;// int --éå®è®¢ååå ç public string HSeOrderBillNo;// varchar(50) --éå®è®¢åå· public double HOrderPrice; public double HInvoiceQty; public string HContainerNum; public double HGrossQty; public double HNetQty; } } WebAPI/Controllers/MoveStockBillController.cs
@@ -467,6 +467,90 @@ return objJsonResult; } } /// <summary> /// çæåå¸å¼è°åºå /// </summary> /// <returns></returns> [Route("MoveStockStepOutBill/set_SaveMoveStockStepOutBill_Json")] [HttpPost] public object set_SaveMoveStockStepOutBill_Json([FromBody] JObject oMain) { var _value = oMain["oMain"].ToString(); string msg1 = _value.ToString(); //List<Model.ClsKf_MoveStockBillMain> lsmain = new List<Model.ClsKf_MoveStockBillMain>(); //ListModels oListModels = new ListModels(); //lsmain = oListModels.getMoveStockBillMainByJson(msg1); //lsmain[0].HYear = DBUtility.ClsPub.isLong(DateTime.Now.Year); //lsmain[0].HDate = DBUtility.ClsPub.isDate(DateTime.Now.ToString("yyyy-MM-dd")); //string sSourceBillType = lsmain[0].HBillType; //BLL.ClsKf_MoveStockBill bll = new BLL.ClsKf_MoveStockBill(); //return bll.set_SaveMoveStockBill(lsmain[0], sSourceBillType, ref DBUtility.ClsPub.sErrInfo); try { List<Model.ClsKf_MoveStockStepOutBillMain> lsmain = new List<Model.ClsKf_MoveStockStepOutBillMain>(); ListModels oListModels = new ListModels(); lsmain = oListModels.getMoveStockStepOutBillMainByJson(msg1); lsmain[0].HYear = DBUtility.ClsPub.isLong(DateTime.Now.Year); lsmain[0].HDate = DBUtility.ClsPub.isDate(DateTime.Now.ToString("yyyy-MM-dd")); string sSourceBillType = lsmain[0].HBillType; //string sSourceBillType = "-1"; WebAPI.WebS.ClsKf_MoveStockStepOutBillMain websLsmain = new WebS.ClsKf_MoveStockStepOutBillMain(); websLsmain.HInterID = lsmain[0].HInterID; websLsmain.HDate = lsmain[0].HDate; websLsmain.HBillNo = lsmain[0].HBillNo; websLsmain.HDeptID = lsmain[0].HDeptID; websLsmain.HEmpID = lsmain[0].HEmpID; websLsmain.HRemark = lsmain[0].HRemark; websLsmain.HMaker = lsmain[0].HMaker; websLsmain.HWHID = lsmain[0].HWHID; websLsmain.HSCWHID = lsmain[0].HSCWHID; websLsmain.HKeeperID = lsmain[0].HKeeperID; websLsmain.HSecManagerID = lsmain[0].HSecManagerID; websLsmain.HManagerID = 0; websLsmain.HBillerID = 0; websLsmain.HExplanation = ""; websLsmain.HInnerBillNo = ""; websLsmain.HRedBlueFlag = true; websLsmain.HMainSourceBillType = "-1"; websLsmain.HStockStyle = ""; websLsmain.HBillType = "1250"; websLsmain.HSupID = 0; //websLsmain.HGroupID = lsmain[0].HGroupID; if (webserver.set_SaveMoveStockBill(websLsmain, "-1", ref DBUtility.ClsPub.sErrInfo)) { objJsonResult.code = "0"; objJsonResult.count = 1; objJsonResult.Message = "çæè°æ¨åæåï¼åæ®å·ä¸ºï¼"; objJsonResult.data = null; return objJsonResult; } else { objJsonResult.code = "99"; objJsonResult.count = 0; objJsonResult.Message = "ä¸ä¼ 失败ï¼" + DBUtility.ClsPub.sErrInfo; objJsonResult.data = null; return objJsonResult; } } catch (Exception e) { objJsonResult.code = "3"; objJsonResult.count = 0; objJsonResult.Message = "ä¸ä¼ 失败ï¼" + e.ToString(); objJsonResult.data = null; return objJsonResult; } } /// <summary> /// /// </summary> @@ -567,6 +651,106 @@ } } /// <summary> /// åå ¥ä¸´æ¶è¡¨ æ«æºåçæ¹æ³ /// </summary> /// <param name="HSourceBillNo"></param> /// <returns></returns> [Route("MoveStockStepOutBill/set_sourcebill")] [HttpGet] public object set_sourcebill(string HSourceBillType, string HSourceBillNo, Int64 sInterID, string sBillNo) { try { // DataSet ds = new DataSet(); // WebServer webserver = new WebServer(); string sWhere = " Where åæ®å· like '%" + HSourceBillNo.Trim() + "%'"; ds = webserver.GetXs_SeOutStockBillList(sWhere); if (ds == null || ds.Tables[0].Rows.Count <= 0) { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "没æè¿åä»»ä½è®°å½ï¼"; objJsonResult.data = null; return objJsonResult; //DBUtility.ClsPub.MessageBeep((int)DBUtility.ClsPub.BeepType.Warning); } else { //HSupID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HSupID"]); //HSupName = Convert.ToString(ds.Tables[0].Rows[0]["HSupName"]); HDeptID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HDeptID"]); HDeptName = Convert.ToString(ds.Tables[0].Rows[0]["HDeptName"]); if (webserver.set_SavePonderationBillMain_Temp_Source_Fast(sInterID, sBillNo, HBillType, HSourceBillNo, HSourceBillType, "èå", ref DBUtility.ClsPub.sErrInfo)) { objJsonResult.code = "0"; objJsonResult.count = 1; objJsonResult.Message = "è¿åè®°å½æåï¼"; objJsonResult.data = null; return objJsonResult; } else { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "åå ¥ä¸´æ¶è¡¨å¤±è´¥ï¼" + DBUtility.ClsPub.sErrInfo; objJsonResult.data = null; return objJsonResult; } } } catch (Exception ex) { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "没æè¿åä»»ä½è®°å½ï¼" + ex.ToString(); objJsonResult.data = null; return objJsonResult; } } /// <summary> /// åå¸å¼è°åºåæ«ç /æ«æ¡ç /ç´æ¥è°ç¨webservice /// </summary> /// <returns></returns> [Route("MoveStockStepOutBill/get_CheckTypeByBarCode_Json")] [HttpGet] public Object get_CheckTypeByBarCode_Json(string sCode, Int64 sInterID, string sBillNo, string sBillType, string sMaker, Int64 WhID, Int64 SPID, Double sQty, bool sRedBlue, bool SourceFlag, string sSourceBillNo, string sSourceType, Int64 HOWNERID) { //if (sRedBlue == true) //{ // HBillType = "1245"; //} //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); WebSoBar = oWebs.get_CheckTypeByBarCode_All(sCode, sInterID, HBillType, sBillNo, sMaker, WhID, SPID, sQty, sRedBlue, SourceFlag, sSourceBillNo, sSourceType, HOWNERID, sExpressNumber, 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 = DBUtility.ClsPub.sErrInfo; objJsonResult.data = WebSoBar; return objJsonResult; } } //å é¤è®°å½ [Route("MoveStock/Delete_Json")] [HttpGet] WebAPI/Controllers/POStockInBillController.cs
@@ -268,6 +268,80 @@ return objJsonResult; } } /// <summary> /// åå ¥ä¸´æ¶è¡¨ æ«æºåçæ¹æ³ /// </summary> /// <param name="HSourceBillNo"></param> /// <returns></returns> [Route("ICMOReportBill/set_SaveICMOReportBill")] [HttpGet] public object set_SaveICMOReportBill(string HSourceBillType, string HSourceBillNo, Int64 sInterID, string sBillNo) { try { // DataSet ds = new DataSet(); // WebServer webserver = new WebServer(); string sWhere = " Where åæ®å· like '%" + HSourceBillNo.Trim() + "'"; //æ ¹æ®æºåç±»åæ¥è°ç¨ä¸åçWEBSæ¹æ³ new if (HSourceBillType == "3710") { ds = webserver.GetSc_ICMOBillList(sWhere + " "); } else { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "没æè¿åä»»ä½è®°å½,æºåç±»åæé误ï¼"; objJsonResult.data = null; return objJsonResult; ; } // if (ds == null || ds.Tables[0].Rows.Count <= 0) { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "没æè¿åä»»ä½è®°å½ï¼" + HSourceBillType; objJsonResult.data = null; return objJsonResult; //DBUtility.ClsPub.MessageBeep((int)DBUtility.ClsPub.BeepType.Warning); } else { HDeptID = DBUtility.ClsPub.isLong(ds.Tables[0].Rows[0]["HDeptID"]); HDeptName = Convert.ToString(ds.Tables[0].Rows[0]["HDeptName"]); if (webserver.set_SavePonderationBillMain_Temp_Source_Fast(sInterID, sBillNo, HBillType, HSourceBillNo, HSourceBillType, "èå", ref DBUtility.ClsPub.sErrInfo)) { objJsonResult.code = "0"; objJsonResult.count = 1; objJsonResult.Message = "è¿åè®°å½æåï¼"; objJsonResult.data = ds.Tables[0]; return objJsonResult; } else { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "åå ¥ä¸´æ¶è¡¨å¤±è´¥ï¼" + DBUtility.ClsPub.sErrInfo; objJsonResult.data = null; return objJsonResult; } } } catch (Exception ex) { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "没æè¿åä»»ä½è®°å½ï¼" + ex.ToString(); objJsonResult.data = null; return objJsonResult; } } /// <summary> /// è¿ååºå ¥åºæ¡ç 临æ¶è¡¨ /// </summary> @@ -606,6 +680,66 @@ } } /// <summary> /// çäº§æ±æ¥å/æäº¤/ç´æ¥è°webservice /// </summary> /// <returns></returns> [Route("ICMOReportBill/set_SaveICMOReportBill_Json")] [HttpPost] public object set_SaveICMOReportBill_Json([FromBody] JObject oMain) { var _value = oMain["oMain"].ToString(); string msg1 = _value.ToString(); try { List<Model.ClsSc_ICMOReportBillMain> lsmain = new List<Model.ClsSc_ICMOReportBillMain>(); ListModels oListModels = new ListModels(); lsmain = oListModels.getICMOReportBillMainByJson(msg1); lsmain[0].HYear = DBUtility.ClsPub.isLong(DateTime.Now.Year); lsmain[0].HDate = DBUtility.ClsPub.isDate(DateTime.Now.ToString("yyyy-MM-dd")); string sSourceBillType = lsmain[0].HBillType; WebAPI.WebS.ClsSc_ICMOReportBillMain websLsmain = new WebS.ClsSc_ICMOReportBillMain(); websLsmain.HInterID = lsmain[0].HInterID; websLsmain.HBillNo = lsmain[0].HBillNo; websLsmain.HBillType = "1201";//åºå®å¼ websLsmain.HDate = lsmain[0].HDate; websLsmain.HDeptID = lsmain[0].HDeptID; websLsmain.HEmpID = 0; websLsmain.HBillerID = lsmain[0].HBillerID; websLsmain.HRemark = ""; websLsmain.HMainSourceBillType = lsmain[0].HBillType; if (webserver.set_SaveICMOReportBill_Json(websLsmain, sSourceBillType, ref DBUtility.ClsPub.sErrInfo)) { objJsonResult.code = "0"; objJsonResult.count = 1; objJsonResult.Message = "æåï¼åæ®å·ä¸ºï¼"; objJsonResult.data = null; return objJsonResult; } else { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "ä¸ä¼ 失败ï¼" + DBUtility.ClsPub.sErrInfo; objJsonResult.data = null; return objJsonResult; } } catch (Exception e) { objJsonResult.code = "0"; objJsonResult.count = 0; objJsonResult.Message = "ä¸ä¼ 失败ï¼" + e.ToString(); objJsonResult.data = null; return objJsonResult; } } [Route("POStockInBill/GetSpName_Json")] [HttpGet] public object GetSpName_Json(long HSpID, long HWHID, long HStockOrgID, ref string sErrMsg) WebAPI/ListModels.cs
@@ -28,6 +28,18 @@ List<Model.ClsKf_POStockInBillMain> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsKf_POStockInBillMain>>(jsonString); return list; } /// <summary> /// çäº§æ±æ¥åååºåå /// </summary> /// <param name="jsonString"></param> /// <returns></returns> public List<Model.ClsSc_ICMOReportBillMain> getICMOReportBillMainByJson(string jsonString) { jsonString = "[" + jsonString.ToString() + "]"; List<Model.ClsSc_ICMOReportBillMain> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsSc_ICMOReportBillMain>>(jsonString); return list; } /// <summary> /// å¤è´å ¥åº(红å)ååºåå /// </summary> @@ -62,6 +74,18 @@ List<Model.ClsKf_MoveStockBillMain> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsKf_MoveStockBillMain>>(jsonString); return list; } /// <summary> /// åå¸å¼è°åºåååºåå /// </summary> /// <param name="jsonString"></param> /// <returns></returns> public List<Model.ClsKf_MoveStockStepOutBillMain> getMoveStockStepOutBillMainByJson(string jsonString) { jsonString = "[" + jsonString.ToString() + "]"; List<Model.ClsKf_MoveStockStepOutBillMain> list = Newtonsoft.Json.JsonConvert.DeserializeObject<List<Model.ClsKf_MoveStockStepOutBillMain>>(jsonString); return list; } /// <summary> /// 产åå ¥åºååºåå /// </summary> WebAPI/WebServer.cs
@@ -3991,6 +3991,25 @@ //sErrMsg = "ä¿åè°æ¨å失败ï¼" + sErrMsg; //return false; } public bool set_MoveStockStepOutBill(WebAPI.WebS.ClsKf_MoveStockStepOutBillMain oMain, string sHSourceType, ref string sErrMsg) { WebS.WebService1 oWebs = new WebS.WebService1(); if (oWebs.set_SaveMoveStockStepOutBill_New(oMain, sHSourceType, ref sErrMsg)) { sErrMsg = "ä¿åæåï¼" + oMain.HBillNo; return true; } else { sErrMsg = "åæ®å·ï¼" + oMain.HBillNo + ", åæ®IDï¼" + oMain.HInterID + ";" + sErrMsg; return false; } } //å é¤è®°å½ public bool set_DelPonderationBillMain_Temp_InterIDAndSource(long HInterID, long HMaterID, long HAuxPropID, string HMTONo, long HSourceInterID, long HSourceEntryID, string sHBillType, ref string sErrMsg) { @@ -4487,6 +4506,33 @@ } } public bool set_SaveICMOReportBill_Json(WebAPI.WebS.ClsSc_ICMOReportBillMain oMain, string sHSourceType, ref string sErrMsg) { //BLL.ClsKf_POStockInBill bll = new BLL.ClsKf_POStockInBill(); //return bll.set_SavePOStockInBill_New(oMain, sHSourceType, ref DBUtility.ClsPub.sExeReturnInfo); WebS.WebService1 oWebs = new WebS.WebService1(); if (oWebs.set_SaveICMOReportBill_New(oMain, sHSourceType, ref sErrMsg)) { //夿æ¯å¦ååæå //if (set_UpdateHStatus(oMain.HInterID, oMain.HExplanation.ToString())) //{ sErrMsg = "ä¿åæåï¼" + oMain.HBillNo; return true; //} //else //{ // sErrMsg = "ä¿åæåï¼" + oMain.HBillNo + "ç¶æåå失败ï¼"; // return true; //} } else { sErrMsg = "åæ®å·ï¼" + oMain.HBillNo + ", åæ®IDï¼" + oMain.HInterID + ";" + sErrMsg; return false; } } /// <summary> /// çæå¤è´å ¥åºåK3 /// </summary>