| | |
| | | ds = oCN.RunProcReturn(sql + sWhere+ " order by hmainid desc ", "h_v_Sb_EquipRepairSendWorkBill_Edit"); |
| | | } |
| | | |
| | | //if (ds.Tables[0].Rows.Count != 0 || ds != null) |
| | | //{ |
| | | objJsonResult.code = "1"; |
| | | objJsonResult.count = ds.Tables[0].Rows.Count; |
| | | objJsonResult.Message = "Sucess!"; |
| | | objJsonResult.data = ds.Tables[0]; |
| | | return objJsonResult; |
| | | //} |
| | | //else |
| | | //{ |
| | | //objJsonResult.code = "0"; |
| | | //objJsonResult.count = 0; |
| | | //objJsonResult.Message = "无数据"; |
| | | //objJsonResult.data = null; |
| | | //return objJsonResult; |
| | | //} |
| | | } |
| | | catch (Exception e) |
| | | { |
| | |
| | | oCN.RunProc("delete from Sb_EquipRepairSendWorkBillSub where HInterID='" + omodel.HInterID + "' and HEntryID='" + hentryid + "'"); |
| | | } |
| | | //保存子表 |
| | | objJsonResult = AddBillSub(msg3, hentryid); |
| | | objJsonResult = AddBillSub(msg3, hentryid, OperationType); |
| | | if (objJsonResult.code == "0") |
| | | { |
| | | objJsonResult.code = "0"; |
| | |
| | | } |
| | | } |
| | | |
| | | public json AddBillSub(string msg3, int hentryid) |
| | | public json AddBillSub(string msg3, int hentryid,int OperationType) |
| | | { |
| | | DetailColl = Newtonsoft.Json.JsonConvert.DeserializeObject<List<ClsSb_EquipRepairSendWorkBillSub>>(msg3); |
| | | int i = 1; |
| | |
| | | } |
| | | |
| | | //保存后控制========================================= |
| | | DataSet ds = oCN.RunProcReturn("Exec h_p_Sb_EquipRepairSendWorkBill_AfterSaveCtrl " + omodel.HInterID + ",'" + omodel.HBillNo + "','',1", "h_p_Sb_EquipRepairSendWorkBill_AfterSaveCtrl"); |
| | | DataSet ds = oCN.RunProcReturn("Exec h_p_Sb_EquipRepairSendWorkBill_AfterSaveCtrl " + omodel.HInterID + ",'" + omodel.HBillNo + "','','"+ OperationType + "'", "h_p_Sb_EquipRepairSendWorkBill_AfterSaveCtrl"); |
| | | if (ds == null) |
| | | { |
| | | objJsonResult.code = "0"; |