| | |
| | | public string HMainSourceBillNo; |
| | | public string HMainSourceBillType; |
| | | public int HOrderLevID; |
| | | public int HHasten; |
| | | } |
| | | #endregion |
| | | |
| | |
| | | int HMainSourceEntryID = mainList[0].HMainSourceEntryID; |
| | | string HMainSourceBillNo = mainList[0].HMainSourceBillNo; |
| | | string HMainSourceBillType = mainList[0].HMainSourceBillType; |
| | | int HOrderLevID = mainList[0].HOrderLevID == null ? 0 : mainList[0].HOrderLevID; |
| | | int HHasten = mainList[0].HHasten == null ? 0 : mainList[0].HHasten; |
| | | int HOrderLevID = mainList[0].HOrderLevID; |
| | | |
| | | |
| | | |
| | | if (OperationType == 2) |
| | |
| | | { |
| | | string sql = "insert into PM_WorkTaskBillMain" + |
| | | "(HYear,HPeriod,HBillType,HBillSubType,HInterID,HBillNo,HProjectID,HProNumber,HProjectStageID,HName,HDate,HTaskNote,HPlanTimes" + |
| | | ",HSelfTimes,HLastDate,HSendEmp,HReceiveEmp,HType,HCopyEmp,HRemark,HOrgID,HMaker,HMakeDate,HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HOrderLevID,HHasten)" + |
| | | ",HSelfTimes,HLastDate,HSendEmp,HReceiveEmp,HType,HCopyEmp,HRemark,HOrgID,HMaker,HMakeDate,HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HOrderLevID)" + |
| | | "values(" + |
| | | "" + HYear + |
| | | "," + HPeriod + |
| | |
| | | ",'" + HMainSourceBillNo + |
| | | "','" + HMainSourceBillType + |
| | | "','" + HOrderLevID + |
| | | "','" + HHasten + |
| | | "')"; |
| | | |
| | | //主表 |
| | |
| | | ",HMainSourceBillNo = '" + HMainSourceBillNo + |
| | | "',HMainSourceBillType = '" + HMainSourceBillType + |
| | | "',HOrderLevID = '" + HOrderLevID + |
| | | "',HHasten = '" + HHasten + |
| | | "' where HInterID = " + HInterID; |
| | | |
| | | oCN.RunProc(sql); |
| | |
| | | { |
| | | string sql = "insert into PM_WorkTaskBillMain" + |
| | | "(HYear,HPeriod,HBillType,HBillSubType,HInterID,HBillNo,HProjectID,HProNumber,HProjectStageID,HName,HDate,HTaskNote,HPlanTimes" + |
| | | ",HSelfTimes,HLastDate,HSendEmp,HReceiveEmp,HType,HCopyEmp,HRemark,HOrgID,HMaker,HMakeDate,HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HOrderLevID,HHasten )" + |
| | | ",HSelfTimes,HLastDate,HSendEmp,HReceiveEmp,HType,HCopyEmp,HRemark,HOrgID,HMaker,HMakeDate,HMainSourceInterID,HMainSourceEntryID,HMainSourceBillNo,HMainSourceBillType,HOrderLevID )" + |
| | | "values(" + |
| | | "" + HYear + |
| | | "," + HPeriod + |
| | |
| | | ",'" + HMainSourceBillNo + |
| | | "','" + HMainSourceBillType + |
| | | "','" + HOrderLevID + |
| | | "','" + HHasten + |
| | | "')"; |
| | | //主表 |
| | | oCN.RunProc(sql); |
| | |
| | | } |
| | | #endregion |
| | | |
| | | #region å·¥ä½ä»»å¡ å¬ä¿æ¬¡æ°åè½ |
| | | [Route("PM_WorkTaskBill/UpdateHHasten")] |
| | | [HttpGet] |
| | | public object UpdateHHasten(string HInterID, int HHasten, string user) |
| | | { |
| | | try |
| | | { |
| | | |
| | | if (string.IsNullOrWhiteSpace(HInterID)) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "HInterID为空ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | |
| | | ClsPub.CurUserName = user; |
| | | BillOld.MvarItemKey = "PM_WorkTaskBillMain"; |
| | | oCN.BeginTran();//å¼å§äºå¡ |
| | | |
| | | DataSet ds; |
| | | string sql = "select * from PM_WorkTaskBillMain where HinterID = " + HInterID; |
| | | ds = oCN.RunProcReturn(sql, "PM_WorkTaskBillMain"); |
| | | if (ds == null || ds.Tables[0].Rows.Count == 0) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "åæ®ä¸åå¨ï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | if (ds.Tables[0] != null && ds.Tables[0].Rows.Count > 0) |
| | | { |
| | | string sql1 = "update PM_WorkTaskBillMain set HHasten='"+ HHasten+ "' where HinterID = " + HInterID; |
| | | ds = oCN.RunProcReturn(sql1, "PM_WorkTaskBillMain"); |
| | | } |
| | | |
| | | oCN.Commit();//æäº¤äºå¡ |
| | | |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 1; |
| | | objJsonResult.Message = "æ§è¡æåï¼"; |
| | | objJsonResult.data = null; |
| | | return objJsonResult; ; |
| | | |
| | | } |
| | | catch (Exception e) |
| | | { |
| | | objJsonResult.code = "0"; |
| | | objJsonResult.count = 0; |
| | | objJsonResult.Message = "æ§è¡å¤±è´¥ï¼" + e.ToString(); |
| | | objJsonResult.data = null; |
| | | return objJsonResult; |
| | | } |
| | | } |
| | | #endregion |
| | | |
| | | #region 任塿±æ¥ æ°å¢/ç¼è¾-ä¿å |
| | | #region 任塿±æ¥ è¡¨å¤´æ°æ® |
| | | public class PM_WorkTaskReportBill_Main |