| | |
| | | websLsmain.HDeptID = lsmain[0].HDeptID; |
| | | websLsmain.HWHID = lsmain[0].HWHID; |
| | | websLsmain.HSCWHID = 0; |
| | | //websLsmain.HSPID = lsmain[0].HSPID; |
| | | websLsmain.HSupID = lsmain[0].HSupID; |
| | | websLsmain.HKeeperID = lsmain[0].HKeeperID; |
| | | websLsmain.HSecManagerID = lsmain[0].HSecManagerID; |
| | |
| | | websLsmain.HManagerID = 0; |
| | | websLsmain.HBillerID = lsmain[0].HBillerID; |
| | | websLsmain.HRemark = ""; |
| | | websLsmain.HExplanation = lsmain[0].HExplanation; |
| | | websLsmain.HInnerBillNo = ""; |
| | | websLsmain.HRedBlueFlag = false;//false蓝字 true红字 |
| | | websLsmain.HMainSourceBillType = lsmain[0].HBillType; |
| | | websLsmain.HExplanation = lsmain[0].HExplanation; |
| | | |
| | | websLsmain.HMaker = lsmain[0].HMaker; |
| | | websLsmain.HSTOCKORGID = lsmain[0].HSTOCKORGID; |
| | | websLsmain.HOWNERID = lsmain[0].HSTOCKORGID; |
| | | |
| | | if (webserver.set_SavePOStockInBill_New(websLsmain, sSourceBillType, ref DBUtility.ClsPub.sErrInfo)) |
| | | { |
| | |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | |
| | | |
| | | [Route("POStockInBill/Delete_Json")] |
| | | [HttpGet] |
| | | public object Delete_Json(long HInterID, long HMaterID, long HAuxPropID, string HMTONo, long HSourceInterID, long HSourceEntryID, string sHBillType) |
| | |
| | | } |
| | | catch (Exception) |
| | | { |
| | | |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "删除失败!"; |
| | |
| | | { |
| | | try |
| | | { |
| | | SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); |
| | | string sql = $"select * from H_v_SRM_POInStockBillList where 单据号 ='{HBillno}'"; |
| | | ds = oCn.RunProcReturn(sql, "H_v_SRM_POInStockBillList"); |
| | | if (ds == null || ds.Tables[0].Rows.Count == 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "没有返回任何记录!"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | else |
| | | { |
| | | objJsonResult.code = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "Sucess!"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | return objJsonResult; |
| | | } |
| | | json result = Get_ReciveBillCheckDate(HBillno); |
| | | return result; |
| | | //SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); |
| | | //string sql = $"select * from H_v_SRM_POInStockBillList where 单据号 ='{HBillno}'"; |
| | | //ds = oCn.RunProcReturn(sql, "H_v_SRM_POInStockBillList"); |
| | | //if (ds == null || ds.Tables[0].Rows.Count == 0) |
| | | //{ |
| | | // objJsonResult.code = "0"; |
| | | // objJsonResult.count = 0; |
| | | // objJsonResult.Message = "没有返回任何记录!"; |
| | | // objJsonResult.data = null; |
| | | // return objJsonResult; |
| | | //} |
| | | //else |
| | | //{ |
| | | // objJsonResult.code = "1"; |
| | | // objJsonResult.count = 1; |
| | | // objJsonResult.Message = "Sucess!"; |
| | | // objJsonResult.data = ds.Tables[0]; |
| | | // return objJsonResult; |
| | | //} |
| | | } |
| | | catch (Exception e) |
| | | { |
| | |
| | | }; |
| | | var loginRet = InvokeHelper.Login(); |
| | | var isSuccess = JObject.Parse(loginRet)["LoginResultType"].Value<int>(); |
| | | if (isSuccess == 0) |
| | | if (isSuccess <= 0) |
| | | { |
| | | objjson.code = "0"; |
| | | objjson.count = 0; |
| | |
| | | }; |
| | | var loginRet = InvokeHelper.Login(); |
| | | var isSuccess = JObject.Parse(loginRet)["LoginResultType"].Value<int>(); |
| | | if (isSuccess == 0) |
| | | if (isSuccess < 0) |
| | | { |
| | | objjson.code = "0"; |
| | | objjson.count = 0; |
| | |
| | | objjson.data = null; |
| | | return objjson; |
| | | } |
| | | LogService.Write("jsonRoot:" + jsonRoot.ToString()); |
| | | //LogService.Write("jsonRoot:" + jsonRoot.ToString()); |
| | | var result = InvokeHelper.Save("PUR_ReceiveBill", jsonRoot.ToString()); |
| | | //LogService.Write(result); |
| | | if (JObject.Parse(result)["Result"]["ResponseStatus"]["IsSuccess"].ToString().ToUpper() == "TRUE") |
| | |
| | | return HInterID; |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 到货确认扫收料通知单号 获取表体和表头数据 |
| | | /// </summary> |
| | | /// <param name="HBarCode"></param> |
| | | /// <returns></returns> |
| | | public json Get_ReciveBillCheckDate(string HBarCode) |
| | | { |
| | | json objjson = new json(); |
| | |
| | | } |
| | | } |
| | | |
| | | //[Route("POStockInBillList/AuditPOInStockBillPost")] |
| | | //[HttpGet] |
| | | //public object AuditPOInStockBill([FromBody] JObject msg) { |
| | | // string _msg = msg.ToString(); |
| | | |
| | | // objJsonResult.code = "0"; |
| | | // objJsonResult.count = 0; |
| | | // objJsonResult.Message = s; |
| | | // objJsonResult.data = null; |
| | | // return objJsonResult; |
| | | //} |
| | | |
| | | /// <summary> |
| | | /// 到货确认 扫条码 校验 |
| | | /// </summary> |
| | | /// <param name="HBarcode"></param> |
| | | /// <param name="HInterID"></param> |
| | | /// <returns></returns> |
| | | [Route("POStockInBillList/Get_ReciveBillByBarcode")] |
| | | [HttpGet] |
| | | public object Get_ReciveBillByBarcode(string HBarcode, string HInterID) |
| | | { |
| | | try |
| | | { |
| | | //校验条码是否存在 |
| | | string sql = $"select* from Gy_BarCodeBill where HSourceInterID ={HInterID} and HBarCode = '{HBarcode}'"; |
| | | DataSet ds = oCn.RunProcReturn(sql, "H_v_SRM_POOrderBillList") ; |
| | | if (ds.Tables[0].Rows.Count == 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "条码不存在!"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | objJsonResult.code = "1"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "Sucess!"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | return objJsonResult; |
| | | //SQLHelper.ClsCN oCn = new SQLHelper.ClsCN(); |
| | | //string sql = $"select * from H_v_SRM_POInStockBillList where 单据号 ='{HBillno}'"; |
| | | //ds = oCn.RunProcReturn(sql, "H_v_SRM_POInStockBillList"); |
| | | //if (ds == null || ds.Tables[0].Rows.Count == 0) |
| | | //{ |
| | | // objJsonResult.code = "0"; |
| | | // objJsonResult.count = 0; |
| | | // objJsonResult.Message = "没有返回任何记录!"; |
| | | // objJsonResult.data = null; |
| | | // return objJsonResult; |
| | | //} |
| | | //else |
| | | //{ |
| | | |
| | | //} |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "没有返回任何记录!" + e.ToString(); |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | |
| | | //收料通知单审核 审核提交 |
| | | [Route("POStockInBillList/Exec_ReciveBillCheck")] |
| | | [HttpGet] |