/// <summary> /// 设定执行人 /// </summary> public bool SetArrangement(List <int> autoIdList, int arrangementId) { using (SqlConnection conn = new SqlConnection(BaseSQL.connectionString)) { conn.Open(); using (SqlTransaction trans = conn.BeginTransaction()) { try { SqlCommand cmd = new SqlCommand("", conn, trans); string sqlStr = ""; foreach (int autoId in autoIdList) { sqlStr += string.Format("{0},", autoId); } sqlStr = sqlStr.Substring(0, sqlStr.Length - 1); if (CheckPrIsPO(cmd, sqlStr)) { return(false); } DateTime nowTime = BaseSQL.GetServerDateTime(); cmd.CommandText = string.Format("Update PUR_PrReqList set Arrangement = {1}, Operator = {2}, ArrangementTime = '{3}', ArrangementFlat = 1 where AutoId in ({0})", sqlStr, arrangementId, SystemInfo.user.AutoId, nowTime.ToString("yyyy-MM-dd HH:mm:ss")); cmd.ExecuteNonQuery(); //cmd.CommandText = string.Format("select PrReqNo from PUR_PrReqList where AutoId in ({0}) group by PrReqNo", sql.Substring(0, sql.Length - 1)); cmd.CommandText = string.Format("select PrReqNo from PUR_PrReqList where IsNull(ArrangementFlat, 0) = 1 and PrReqNo in (select PrReqNo from PUR_PrReqList where AutoId in ({0})) group by PrReqNo", sqlStr); DataTable prTable = BaseSQL.GetTableBySql(cmd); Dictionary <string, int> prReqNoDictionary = new Dictionary <string, int>(); foreach (DataRow prRow in prTable.Rows) { prReqNoDictionary.Add(DataTypeConvert.GetString(prRow["PrReqNo"]), (int)CommonHandler.OrderState.已审批); } if (!wfHandleDAO.MultiOrderWorkFlowsHandle(cmd, WorkFlowsHandleDAO.OrderType.请购单, WorkFlowsHandleDAO.LineType.任务分配, ref prReqNoDictionary)) { return(false); } //cmd.CommandText = string.Format("Update BS_WorkFlowsDataCurrentNode set NextHandleEnd = 1 where DataNo in (select PrReqNo from PUR_PrReqList where IsNull(ArrangementFlat, 0) = 1 and PrReqNo in (select PrReqNo from PUR_PrReqList where AutoId in ({0})))", sql.Substring(0, sql.Length - 1)); //cmd.ExecuteNonQuery(); trans.Commit(); return(true); } catch (Exception ex) { trans.Rollback(); throw ex; } finally { conn.Close(); } } } }
/// <summary> /// 窗体激活事件 /// </summary> private void FrmWarehouseWarrantQuery_Activated(object sender, EventArgs e) { try { if (orderListAutoId != 0) { spinorderListAutoId.Value = orderListAutoId; orderListAutoId = 0; checkorderListAutoId.Checked = true; DateTime nowDate = BaseSQL.GetServerDateTime(); dateWWDateBegin.DateTime = nowDate.AddMonths(-6); dateWWDateEnd.DateTime = nowDate.AddMonths(6); searchLookUpBussinessBaseNo.Text = "全部"; lookUpRepertoryNo.ItemIndex = 0; lookUpReqDep.ItemIndex = 0; lookUpWarehouseWarrantTypeNo.ItemIndex = 0; comboBoxWarehouseState.SelectedIndex = 0; lookUpPrepared.ItemIndex = 0; textCommon.Text = ""; btnQuery_Click(null, null); } } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体激活事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + f.tsmiCtjhsjcw.Text, ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmProductionSchedule_Load(object sender, EventArgs e) { try { //ControlHandler.DevExpressStyle_ChangeControlLocation(checkAll.LookAndFeel.ActiveSkinName, new List<Control> { checkAll }); DateTime nowDate = BaseSQL.GetServerDateTime(); dateCurrentDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateCurrentDateEnd.DateTime = nowDate.Date; datePlanDateBegin.DateTime = nowDate.Date; datePlanDateEnd.DateTime = nowDate.Date.AddDays(SystemInfo.OrderQueryDate_DateIntervalDays); checkPlanDate.Checked = false; searchLookUpCodeFileName.Properties.DataSource = commonDAO.QueryPartsCode(true); searchLookUpCodeFileName.Text = "全部"; comboBoxReqState.SelectedIndex = 0; ControlCommonInit ctlInit = new ControlCommonInit(); ctlInit.SearchLookUpEdit_UserInfo_ValueMember_EmpName(searchLookUpPrepared); searchLookUpPrepared.EditValue = SystemInfo.user.EmpName; repSearchCodeFileName.DataSource = commonDAO.QueryPartsCode(false); if (textCommon.Text == "") { psDAO.QueryProductionSchedule(dataSet_PSchedule.Tables[0], "", "", "", "", "", 0, "", -1, "", true); psDAO.QueryProductionScheduleBom(dataSet_PSchedule.Tables[1], "", true); } } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmPrReqList_Overplus_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateReqDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateReqDateEnd.DateTime = nowDate.Date; lookUpReqDep.Properties.DataSource = commonDAO.QueryDepartment(true); lookUpReqDep.ItemIndex = 0; lookUpPurCategory.Properties.DataSource = commonDAO.QueryPurCategory(true); lookUpPurCategory.ItemIndex = 0; searchLookUpProjectNo.Properties.DataSource = commonDAO.QueryProjectList(true); searchLookUpProjectNo.Text = "全部"; searchLookUpCodeFileName.Properties.DataSource = commonDAO.QueryPartsCode(true); searchLookUpCodeFileName.Text = "全部"; comboBoxReqState.SelectedIndex = 0; repLookUpReqDep.DataSource = commonDAO.QueryDepartment(false); repLookUpPurCategory.DataSource = commonDAO.QueryPurCategory(false); repLookUpProjectNo.DataSource = commonDAO.QueryProjectList(false); gridBottomPrReq.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + tsmiCt.Text, ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmSalesOrderQuery_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateSalesOrderDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateSalesOrderDateEnd.DateTime = nowDate.Date; searchLookUpBussinessBaseNo.Properties.DataSource = commonDAO.QueryBussinessBaseInfo(true); searchLookUpBussinessBaseNo.Text = "全部"; searchProjectNo.Properties.DataSource = commonDAO.QueryProjectList(true); searchProjectNo.Text = "全部"; lookUpPrepared.Properties.DataSource = commonDAO.QueryUserInfo(true); lookUpPrepared.EditValue = SystemInfo.user.EmpName; repSearchBussinessBaseNo.DataSource = commonDAO.QueryBussinessBaseInfo(false); repLookUpCollectionTypeNo.DataSource = commonDAO.QueryCollectionType(false); gridBottomOrderHead.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; gridBottomOrderHead.pageRowCount = 5; btnQuery_Click(null, null); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmQuotationInfoQuery_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateRecordDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateRecordDateEnd.DateTime = nowDate.Date; DataTable bussInfoTable_t = commonDAO.QueryBussinessBaseInfo(true); searchLookUpBussinessBaseNo.Properties.DataSource = bussInfoTable_t; searchLookUpBussinessBaseNo.Text = "全部"; lookUpQState.Properties.DataSource = CommonHandler.GetQuotationInfoStateTable(true); lookUpQState.ItemIndex = 0; ControlCommonInit ctlInit = new ControlCommonInit(); ctlInit.SearchLookUpEdit_UserInfo_ValueMember_AutoId(searchLookUpCreator); searchLookUpCreator.EditValue = SystemInfo.user.AutoId; //repSearchBussinessBaseNo.DataSource = commonDAO.QueryBussinessBaseInfo(false); repSearchBussinessBaseNo.DataSource = bussInfoTable_t; repLookUpQState.DataSource = CommonHandler.GetQuotationInfoStateTable(false); repLookUpCreator.DataSource = searchLookUpCreator.Properties.DataSource; gridBottomOrderHead.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmProductionScheduleQuery_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateCurrentDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateCurrentDateEnd.DateTime = nowDate.Date; dateReqDateBegin.DateTime = nowDate.Date; dateReqDateEnd.DateTime = nowDate.Date.AddDays(SystemInfo.OrderQueryDate_DefaultDays); checkReqDate.Checked = false; lookUpPrepared.Properties.DataSource = commonDAO.QueryUserInfo(true); lookUpPrepared.EditValue = SystemInfo.user.EmpName; gridBottomOrderHead.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; if (textCommon.Text == "") { btnQuery_Click(null, null); } } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmSpecialWarehouseReceiptQuery_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateSWRDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateSWRDateEnd.DateTime = nowDate.Date; lookUpReqDep.Properties.DataSource = commonDAO.QueryDepartment(true); lookUpReqDep.ItemIndex = 0; lookUpRepertoryNo.Properties.DataSource = commonDAO.QueryRepertoryInfo(true); lookUpRepertoryNo.ItemIndex = 0; comboBoxWarehouseState.SelectedIndex = 0; lookUpPrepared.Properties.DataSource = commonDAO.QueryUserInfo(true); lookUpPrepared.EditValue = SystemInfo.user.EmpName; repLookUpReqDep.DataSource = commonDAO.QueryDepartment(false); repLookUpRepertoryNo.DataSource = commonDAO.QueryRepertoryInfo(false); repLookUpApprovalType.DataSource = commonDAO.QueryApprovalType(false); gridBottomOrderHead.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmInventoryAdjustmentsQuery_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateIADateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateIADateEnd.DateTime = nowDate.Date; lookUpAdjustmentsRepertoryNo.Properties.DataSource = commonDAO.QueryRepertoryInfo(true); lookUpAdjustmentsRepertoryNo.ItemIndex = 0; lookUpReqDep.Properties.DataSource = commonDAO.QueryDepartment(true); lookUpReqDep.ItemIndex = 0; lookUpPrepared.Properties.DataSource = commonDAO.QueryUserInfo(true); lookUpPrepared.EditValue = SystemInfo.user.EmpName; searchAdjustmentsProjectNo.Properties.DataSource = commonDAO.QueryProjectList(true); searchAdjustmentsProjectNo.Text = "全部"; repLookUpInRepertoryNo.DataSource = commonDAO.QueryRepertoryInfo(false); repSearchAdjustmentsProjectNo.DataSource = commonDAO.QueryProjectList(false); repLookUpReqDep.DataSource = commonDAO.QueryDepartment(false); gridBottomIA.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + f.tsmiCtjzsjcw.Text, ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmPrReqQuery_Load(object sender, EventArgs e) { try { lookUpReqDep.Properties.DataSource = commonDAO.QueryDepartment(true); lookUpReqDep.ItemIndex = 0; lookUpPurCategory.Properties.DataSource = commonDAO.QueryPurCategory(true); lookUpPurCategory.ItemIndex = 0; comboBoxReqState.SelectedIndex = 0; lookUpApplicant.Properties.DataSource = commonDAO.QueryUserInfo(true); lookUpApplicant.EditValue = SystemInfo.user.EmpName; repositoryItemLookUpEdit1.DataSource = commonDAO.QueryDepartment(false); repositoryItemLookUpEdit2.DataSource = commonDAO.QueryPurCategory(false); DateTime nowDate = BaseSQL.GetServerDateTime(); dateReqDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateReqDateEnd.DateTime = nowDate.Date; gridBottomPrReq.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + tsmiCt.Text, ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmStnModuleQuery_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateGetTimeBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateGetTimeEnd.DateTime = nowDate.Date; searchLookUpStnModule.Properties.DataSource = ssDAO.QueryStnModule(true); searchLookUpStnModule.Text = "全部"; ControlCommonInit ctlInit = new ControlCommonInit(); ctlInit.SearchLookUpEdit_UserInfo_ValueMember_AutoId(searchLookUpCreator); searchLookUpCreator.EditValue = SystemInfo.user.AutoId; repLookUpCreator.DataSource = searchLookUpCreator.Properties.DataSource; gridBottomOrderHead.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件错误 /// </summary> private void FrmOrderArrivalQuery_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateOrderDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateOrderDateEnd.DateTime = nowDate.Date; datePlanDateBegin.DateTime = nowDate.Date; datePlanDateEnd.DateTime = nowDate.Date.AddDays(SystemInfo.OrderQueryDate_DateIntervalDays); checkPlanDate.Checked = false; DataTable departmentTable_t = commonDAO.QueryDepartment(true); DataTable bussInfoTable_t = commonDAO.QueryBussinessBaseInfo(true); DataTable purCateTable_t = commonDAO.QueryPurCategory(true); lookUpReqDep.Properties.DataSource = departmentTable_t; lookUpReqDep.ItemIndex = 0; searchLookUpBussinessBaseNo.Properties.DataSource = bussInfoTable_t; searchLookUpBussinessBaseNo.Text = "全部"; lookUpPurCategory.Properties.DataSource = purCateTable_t; lookUpPurCategory.ItemIndex = 0; //searchLookUpProjectNo.Properties.DataSource = projectTable_t; //searchLookUpProjectNo.Text = "全部"; //searchLookUpCodeFileName.Properties.DataSource = commonDAO.QueryPartsCode(true); //searchLookUpCodeFileName.EditValue = 0; ControlCommonInit ctlInit = new ControlCommonInit(); ctlInit.SearchLookUpEdit_PartsCode(searchLookUpCodeFileName, true); searchLookUpCodeFileName.EditValue = 0; ctlInit.SearchLookUpEdit_ProjectList(searchLookUpProjectNo, true); searchLookUpProjectNo.Text = "全部"; ctlInit.ComboBoxEdit_OrderState_Submit(comboBoxReqState); comboBoxReqState.SelectedIndex = 0; //repLookUpReqDep.DataSource = commonDAO.QueryDepartment(false); //repSearchBussinessBaseNo.DataSource = commonDAO.QueryBussinessBaseInfo(false); //repLookUpPurCategory.DataSource = commonDAO.QueryPurCategory(false); //repSearchProjectNo.DataSource = commonDAO.QueryProjectList(false); repLookUpReqDep.DataSource = departmentTable_t; repSearchBussinessBaseNo.DataSource = bussInfoTable_t; repLookUpPurCategory.DataSource = purCateTable_t; repSearchProjectNo.DataSource = searchLookUpProjectNo.Properties.DataSource; if (SystemInfo.DisableProjectNo) { labProjectNo.Visible = false; searchLookUpProjectNo.Visible = false; colProjectNo.Visible = false; colStnNo.Visible = false; } gridBottomOrderHead.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmSalesOrder_History_Load(object sender, EventArgs e) { try { DataTable bussBaseTable = commonDAO.QueryBussinessBaseInfo(false); searchProjectName.Properties.DataSource = commonDAO.QueryProjectList(false); searchBussinessBaseNo.Properties.DataSource = bussBaseTable; lookUpCollectionTypeNo.Properties.DataSource = commonDAO.QueryCollectionType(false); lookUpCurrencyCate.Properties.DataSource = commonDAO.QueryCurrencyCate(false); lookUpProjectLeader.Properties.DataSource = commonDAO.QueryUserInfo(false); DateTime nowDate = BaseSQL.GetServerDateTime(); repSearchBussinessBaseNo.DataSource = bussBaseTable; dateSalesOrderDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateSalesOrderDateEnd.DateTime = nowDate.Date; searchLookUpBussinessBaseNo.Properties.DataSource = commonDAO.QueryBussinessBaseInfo(true); searchLookUpBussinessBaseNo.Text = "全部"; repSearchLookUpBussinessBaseNo.DataSource = bussBaseTable; Set_ButtonEditGrid_State(true); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 设定子表的默认值 /// </summary> private void TableQuotationPriceInfo_TableNewRow(object sender, DataTableNewRowEventArgs e) { try { if (bindingSource_BaseInfo.Current != null) { DataRow headRow = ((DataRowView)bindingSource_BaseInfo.Current).Row; e.Row["AutoQuotationNo"] = DataTypeConvert.GetString(headRow["AutoQuotationNo"]); DataTable tmpTable = ((DataTable)repLookUpCurrencyCate.DataSource); if (tmpTable.Rows.Count > 0) { e.Row["CurrencyCate"] = tmpTable.Rows[0]["AutoId"]; } e.Row["QuotationDate"] = BaseSQL.GetServerDateTime(); e.Row["QuotationState"] = 1; e.Row["Offerer"] = SystemInfo.user.EmpName; e.Row["Tax"] = SystemInfo.Quotation_DefaultTax; e.Row["IsPoUse"] = 0; string currentVersion = ""; if (gridViewQuotationPriceInfo.RowCount > 1) { currentVersion = DataTypeConvert.GetString(gridViewQuotationPriceInfo.GetDataRow(gridViewQuotationPriceInfo.RowCount - 2)["Versions"]); } e.Row["Versions"] = CommonHandler.GetNewVersionNo(currentVersion); } } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--设定子表的默认值错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmQuotationApply_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateRecordDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateRecordDateEnd.DateTime = nowDate.Date; searchLookUpBussinessBaseNo.Properties.DataSource = commonDAO.QueryBussinessBaseInfo(true); searchLookUpBussinessBaseNo.Text = "全部"; ControlCommonInit ctlInit = new ControlCommonInit(); ctlInit.SearchLookUpEdit_UserInfo_ValueMember_AutoId(searchLookUpCreator); searchLookUpCreator.EditValue = 0; repSearchBussinessBaseNo.DataSource = commonDAO.QueryBussinessBaseInfo(false); repLookUpCreator.DataSource = searchLookUpCreator.Properties.DataSource; repLookUpCurrencyCate.DataSource = commonDAO.QueryCurrencyCate(false); btnQuery_Click(null, null); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 设定主表的默认值 /// </summary> private void TableQuotationBaseInfo_TableNewRow(object sender, DataTableNewRowEventArgs e) { try { e.Row["RecordDate"] = BaseSQL.GetServerDateTime(); e.Row["Prepared"] = SystemInfo.user.EmpName; e.Row["QuotationState"] = 0; if (newParentAutoQuotationNoStr != "") { e.Row["ParentAutoQuotationNo"] = newParentAutoQuotationNoStr; e.Row["ParentAutoSalesOrderNo"] = newParentAutoSalesOrderNoStr; e.Row["ParentProjectNo"] = newParentProjectNoStr; newParentAutoQuotationNoStr = ""; newParentAutoSalesOrderNoStr = ""; newParentProjectNoStr = ""; DataTable tempTable = new DataTable(); quoDAO.QueryQuotationBaseInfo(tempTable, DataTypeConvert.GetString(e.Row["ParentAutoQuotationNo"])); if (tempTable.Rows.Count > 0) { e.Row["BussinessBaseNo"] = DataTypeConvert.GetString(tempTable.Rows[0]["BussinessBaseNo"]); e.Row["Requester"] = DataTypeConvert.GetString(tempTable.Rows[0]["Requester"]); } } } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--设定主表的默认值错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmQuotationInfo_History_Load(object sender, EventArgs e) { try { ControlHandler.DevExpressStyle_ChangeControlLocation(btnListAdd.LookAndFeel.ActiveSkinName, new List <Control> { btnListAdd }); DataTable bussBaseTable = commonDAO.QueryBussinessBaseInfo(false); DataTable currencyCateTable = commonDAO.QueryCurrencyCate(false); searchBussinessBaseNo.Properties.DataSource = bussBaseTable; repLookUpCurrencyCate.DataSource = currencyCateTable; repItemCORBussinessBaseNo.DataSource = bussBaseTable; repItemCORCurrencyCate.DataSource = currencyCateTable; DateTime nowDate = BaseSQL.GetServerDateTime(); dateRecordDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateRecordDateEnd.DateTime = nowDate.Date; searchLookUpBussinessBaseNo.Properties.DataSource = commonDAO.QueryBussinessBaseInfo(true); searchLookUpBussinessBaseNo.Text = "全部"; repSearchLookUpBussinessBaseNo.DataSource = bussBaseTable; repLookUpQState.DataSource = CommonHandler.GetQuotationInfoStateTable(false); Set_ButtonEditGrid_State(true); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体激活事件 /// </summary> private void FrmSettlementQuery_Activated(object sender, EventArgs e) { try { if (wwListAutoId != 0) { spinwwListAutoId.Value = wwListAutoId; wwListAutoId = 0; checkwwListAutoId.Checked = true; DateTime nowDate = BaseSQL.GetServerDateTime(); dateSettlementDateBegin.DateTime = nowDate.AddMonths(-6); dateSettlementDateEnd.DateTime = nowDate.AddMonths(6); searchLookUpBussinessBaseNo.Text = "全部"; lookUpReqDep.ItemIndex = 0; comboBoxWarehouseState.SelectedIndex = 0; searchLookUpCreator.Text = "全部"; checkPayDate.Checked = false; textCommon.Text = ""; btnQuery_Click(null, null); } } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体激活事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + tsmiCtjh.Text, ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmOrderApply_Load(object sender, EventArgs e) { try { ControlHandler.DevExpressStyle_ChangeControlLocation(checkAll.LookAndFeel.ActiveSkinName, new List <Control> { checkAll }); DateTime nowDate = BaseSQL.GetServerDateTime(); dateOrderDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DefaultDays); dateOrderDateEnd.DateTime = nowDate.Date; checkOrderDate.Checked = false; lookUpReqDep.Properties.DataSource = commonDAO.QueryDepartment(true); lookUpReqDep.ItemIndex = 0; lookUpPurCategory.Properties.DataSource = commonDAO.QueryPurCategory(true); lookUpPurCategory.ItemIndex = 0; lookUpPrepared.Properties.DataSource = commonDAO.QueryUserInfo(true); lookUpPrepared.ItemIndex = 0; searchLookUpProjectNo.Properties.DataSource = commonDAO.QueryProjectList(true); searchLookUpProjectNo.Text = "全部"; searchLookUpBussinessBaseNo.Properties.DataSource = commonDAO.QueryBussinessBaseInfo(true); searchLookUpBussinessBaseNo.Text = "全部"; repLookUpReqDep.DataSource = commonDAO.QueryDepartment(false); repLookUpPurCategory.DataSource = commonDAO.QueryPurCategory(false); repSearchBussinessBaseNo.DataSource = commonDAO.QueryBussinessBaseInfo(false); } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + f.tsmiCtjzsjcw.Text, ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmStnModule_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateGetTimeBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateGetTimeEnd.DateTime = nowDate.Date; LookUpCreator.Properties.DataSource = commonDAO.QueryUserInfo(false); repItemLookUpCreator.DataSource = LookUpCreator.Properties.DataSource; repLookUpCreator.DataSource = LookUpCreator.Properties.DataSource; if (querySMNoStr == "") { smDAO.QueryStnModule(dataSet_StnModule.Tables[0], "", "", 0, "", "", true); Set_ButtonEditGrid_State(true); } } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmSalesOrder_NoSettle_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateSalesOrderDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateSalesOrderDateEnd.DateTime = nowDate.Date; searchLookUpBussinessBaseNo.Properties.DataSource = commonDAO.QueryBussinessBaseInfo(true); searchLookUpBussinessBaseNo.Text = "全部"; //searchProjectNo.Properties.DataSource = commonDAO.QueryProjectList(true); //searchProjectNo.Text = "全部"; ControlCommonInit ctlInit = new ControlCommonInit(); ctlInit.SearchLookUpEdit_UserInfo_ValueMember_AutoId(searchLookUpCreator); searchLookUpCreator.EditValue = SystemInfo.user.AutoId; ctlInit.SearchLookUpEdit_ProjectList(searchProjectNo, true); searchProjectNo.Text = "全部"; repSearchBussinessBaseNo.DataSource = commonDAO.QueryBussinessBaseInfo(false); repLookUpCollectionTypeNo.DataSource = commonDAO.QueryCollectionType(false); repLookUpCreator.DataSource = searchLookUpCreator.Properties.DataSource; gridBottomOrderHead.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体激活事件 /// </summary> private void FrmOrderQuery_Activated(object sender, EventArgs e) { try { if (prReqListAutoId != 0) { spinprReqListAutoId.Value = prReqListAutoId; prReqListAutoId = 0; checkprReqListAutoId.Checked = true; DateTime nowDate = BaseSQL.GetServerDateTime(); dateOrderDateBegin.DateTime = nowDate.AddMonths(-6); dateOrderDateEnd.DateTime = nowDate.AddMonths(6); lookUpReqDep.ItemIndex = 0; lookUpPurCategory.ItemIndex = 0; searchLookUpBussinessBaseNo.Text = "全部"; comboBoxReqState.SelectedIndex = 0; lookUpPrepared.ItemIndex = 0; checkPlanDate.Checked = false; textCommon.Text = ""; btnQuery_Click(null, null); } } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体激活事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + f.tsmiCtjhsjcw.Text, ex); } }
/// <summary> /// 备份服务器的数据库 /// </summary> private void btnBackup_Click(object sender, EventArgs e) { try { if (textBackupPath.Text.Trim() == "") { MessageHandler.ShowMessageBox("数据库备份路径不能为空,请重新操作。"); return; } DateTime nowTime = BaseSQL.GetServerDateTime(); string fileNameStr = string.Format("{0}-{1}.bak", SystemInfo.ServerDataBaseName, nowTime.ToString("yyyyMMddHHmmss")); string filePathNameStr = string.Format("{0}\\{1}", textBackupPath.Text.Trim(), fileNameStr); //if (BaseSQL.BackupDataBase(SystemInfo.ServerDataBaseName, filePathNameStr))//数据库SQL备份,没有进度条 //{ // MessageHandler.ShowMessageBox(string.Format("备份数据库成功,文件名为[{0}]。", fileNameStr)); //} if (BackupDataBase(SystemInfo.ServerDataBaseName, filePathNameStr, progressBarBackup))//引用SQLDMO类备份,有进度条 { MessageHandler.ShowMessageBox(string.Format("备份数据库成功,文件名为[{0}]。", fileNameStr)); } } catch (Exception ex) { MessageHandler.ShowMessageBox(string.Format("备份数据库失败--{0}。", ex.Message)); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmProductOpenAccount_Load(object sender, EventArgs e) { try { DateTime nowDate = BaseSQL.GetServerDateTime(); dateOpBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateOpEnd.DateTime = nowDate.Date; DataTable repertoryTable_t = commonDAO.QueryRepertoryInfo(true); lookUpRepertoryId.Properties.DataSource = repertoryTable_t; lookUpRepertoryId.ItemIndex = 0; //SearchLocationId.Properties.DataSource = locationTable_t; //SearchLocationId.EditValue = 0; //searchLookUpProjectNo.Properties.DataSource = commonDAO.QueryProjectList(true); //searchLookUpProjectNo.Text = "全部"; //searchLookUpShelfId.Properties.DataSource = shelfTable_t; //searchLookUpShelfId.EditValue = 0; //searchLookUpCodeFileName.Properties.DataSource = commonDAO.QueryPartsCode(true); //searchLookUpCodeFileName.EditValue = 0; ControlCommonInit ctlInit = new ControlCommonInit(); ctlInit.SearchLookUpEdit_PartsCode(searchLookUpCodeFileName, true); searchLookUpCodeFileName.EditValue = 0; ctlInit.SearchLookUpEdit_ProjectList(searchLookUpProjectNo, true); searchLookUpProjectNo.Text = "全部"; ctlInit.SearchLookUpEdit_ShelfInfo(searchLookUpShelfId, true); searchLookUpShelfId.EditValue = 0; ctlInit.SearchLookUpEdit_RepertoryLocationInfo(SearchLocationId, true); SearchLocationId.EditValue = 0; //repLookUpRepertoryId.DataSource = commonDAO.QueryRepertoryInfo(false); //repLookUpLocationId.DataSource = commonDAO.QueryRepertoryLocationInfo(false); repLookUpRepertoryId.DataSource = repertoryTable_t; repLookUpLocationId.DataSource = SearchLocationId.Properties.DataSource; repLookUpShelfId.DataSource = searchLookUpShelfId.Properties.DataSource; if (SystemInfo.DisableProjectNo) { labProjectNo.Visible = false; searchLookUpProjectNo.Visible = false; colProjectNo.Visible = false; colProjectName.Visible = false; } if (SystemInfo.DisableShelfInfo) { labShelfId.Visible = false; searchLookUpShelfId.Visible = false; colShelfId.Visible = false; } gridBottomWNowInfo.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); } }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmInventoryAdjustmentsQuery_Load(object sender, EventArgs e) { try { ControlCommonInit ctlInit = new ControlCommonInit(); DateTime nowDate = BaseSQL.GetServerDateTime(); dateIADateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateIADateEnd.DateTime = nowDate.Date; DataTable departmentTable_t = commonDAO.QueryDepartment(true); DataTable repertoryTable_t = commonDAO.QueryRepertoryInfo(true); lookUpReqDep.Properties.DataSource = departmentTable_t; lookUpReqDep.ItemIndex = 0; lookUpRepertoryId.Properties.DataSource = repertoryTable_t; lookUpRepertoryId.ItemIndex = 0; //SearchLocationId.Properties.DataSource = locationTable_t; //SearchLocationId.EditValue = 0; ctlInit.SearchLookUpEdit_RepertoryLocationInfo(SearchLocationId, true); SearchLocationId.EditValue = 0; //searchProjectNo.Properties.DataSource = projectTable_t; //searchProjectNo.Text = "全部"; ctlInit.SearchLookUpEdit_ProjectList(searchProjectNo, true); searchProjectNo.Text = "全部"; ctlInit.ComboBoxEdit_WarehouseState(comboBoxWarehouseState); comboBoxWarehouseState.SelectedIndex = 0; ctlInit.SearchLookUpEdit_UserInfo_ValueMember_AutoId(searchLookUpCreator); searchLookUpCreator.EditValue = SystemInfo.user.AutoId; //repLookUpReqDep.DataSource = commonDAO.QueryDepartment(false); //repLookUpRepertoryId.DataSource = commonDAO.QueryRepertoryInfo(false); //repLookUpLocationId.DataSource = commonDAO.QueryRepertoryLocationInfo(false); //repSearchProjectNo.DataSource = commonDAO.QueryProjectList(false); repLookUpReqDep.DataSource = departmentTable_t; repLookUpRepertoryId.DataSource = repertoryTable_t; repLookUpLocationId.DataSource = SearchLocationId.Properties.DataSource; repSearchProjectNo.DataSource = searchProjectNo.Properties.DataSource; repLookUpCreator.DataSource = searchLookUpCreator.Properties.DataSource; repLookUpApprovalType.DataSource = commonDAO.QueryApprovalType(false); if (SystemInfo.DisableProjectNo) { labProjectNo.Visible = false; searchProjectNo.Visible = false; colProjectNo.Visible = false; } gridBottomIA.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + f.tsmiCtjzsjcw.Text, ex); } }
/// <summary> /// 新增操作员或权限角色 /// </summary> private void btnHandleNew_Click(object sender, EventArgs e) { try { DataRow focusedRow = gridViewLineCondition.GetFocusedDataRow(); if (focusedRow == null) { MessageHandler.ShowMessageBox("请先新增条件信息后,再进行新增处理人员或通知人员的操作。"); btnNew.Focus(); return; } string handleOwnerStr = DataTypeConvert.GetString(searchLookUpHandleOwner.EditValue); if (handleOwnerStr == "") { MessageHandler.ShowMessageBox("请选择要登记的操作员或者权限角色。"); searchLookUpHandleOwner.Focus(); return; } int conditionAutoIdInt = DataTypeConvert.GetInt(focusedRow["AutoId"]); if (TabControlConditionOtherInfo.SelectedTabPage == PageLineHandle)//处理人员 { //setDAO.InsertWorkFlowsLineHandle(lineIdInt, conditionAutoIdInt, radioHandleCate.SelectedIndex, DataTypeConvert.GetString(searchLookUpHandleOwner.EditValue), DataTypeConvert.GetInt(spinMultiLevelApprover.EditValue)); //RefreshHandleInfo(conditionAutoIdInt); DataRow dr = TableLineHandle.NewRow(); dr["LineId"] = lineIdInt > 0 ? lineIdInt : (object)DBNull.Value; dr["ConditionId"] = conditionAutoIdInt; dr["MultiLevelApprover"] = DataTypeConvert.GetInt(spinMultiLevelApprover.EditValue); dr["LineHandleCate"] = radioHandleCate.SelectedIndex; dr["HandleOwner"] = DataTypeConvert.GetString(searchLookUpHandleOwner.EditValue); dr["HandleName"] = searchLookUpHandleOwner.Text; dr["Creator"] = SystemInfo.user.AutoId; dr["GetTime"] = BaseSQL.GetServerDateTime(); TableLineHandle.Rows.Add(dr); BSLineHandle.MoveLast(); } else if (TabControlConditionOtherInfo.SelectedTabPage == PageLineNotice)//通知人员 { //setDAO.InsertWorkFlowsLineNotice(lineIdInt, conditionAutoIdInt, radioHandleCate.SelectedIndex, DataTypeConvert.GetString(searchLookUpHandleOwner.EditValue), DataTypeConvert.GetInt(spinMultiLevelApprover.EditValue)); //RefreshNoticeInfo(conditionAutoIdInt); DataRow dr = TableLineNotice.NewRow(); dr["LineId"] = lineIdInt > 0 ? lineIdInt : (object)DBNull.Value; dr["ConditionId"] = conditionAutoIdInt; dr["MultiLevelApprover"] = DataTypeConvert.GetInt(spinMultiLevelApprover.EditValue); dr["LineHandleCate"] = radioHandleCate.SelectedIndex; dr["HandleOwner"] = DataTypeConvert.GetString(searchLookUpHandleOwner.EditValue); dr["HandleName"] = searchLookUpHandleOwner.Text; dr["Creator"] = SystemInfo.user.AutoId; dr["GetTime"] = BaseSQL.GetServerDateTime(); TableLineNotice.Rows.Add(dr); BSLineNotice.MoveLast(); } } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--新增操作员或权限角色错误。", ex); } }
/// <summary> /// 得到包含系统信息的参数列表 /// </summary> public List <Parameter> GetSystemInfo_ParamList() { List <Parameter> paramList = new List <Parameter>(); Parameter p1 = new Parameter(); //p1.Name = "公司名称"; p1.Name = f.tsmiGsmc.Text; p1.Value = SystemInfo.CompanyName; paramList.Add(p1); Parameter p2 = new Parameter(); //p2.Name = "公司地址"; p2.Name = f.tsmiGsdz.Text; p2.Value = SystemInfo.CompAddress; paramList.Add(p2); Parameter p3 = new Parameter(); //p3.Name = "公司邮编"; p3.Name = f.tsmiGsyb.Text; p3.Value = SystemInfo.CompZipCode; paramList.Add(p3); Parameter p4 = new Parameter(); //p4.Name = "公司电话"; p4.Name = f.tsmiGsdh.Text; p4.Value = SystemInfo.CompTel; paramList.Add(p4); Parameter p5 = new Parameter(); //p5.Name = "公司传真"; p5.Name = f.tsmiGscz.Text; p5.Value = SystemInfo.CompFax; paramList.Add(p5); Parameter p6 = new Parameter(); //p6.Name = "公司网址"; p6.Name = f.tsmiGswz.Text; p6.Value = SystemInfo.CompWebSite; paramList.Add(p6); Parameter p7 = new Parameter(); //p7.Name = "公司商标"; p7.Name = f.tsmiGssb.Text; p7.Value = SystemInfo.CompImage; paramList.Add(p7); Parameter p8 = new Parameter(); //p8.Name = "打印时间"; p8.Name = f.tsmiDysj.Text; p8.Value = BaseSQL.GetServerDateTime(); paramList.Add(p8); Parameter p9 = new Parameter(); //p9.Name = "打印人"; p9.Name = f.tsmiDyr.Text; p9.Value = SystemInfo.user.EmpName; paramList.Add(p9); return(paramList); }
/// <summary> /// 设定默认值 /// </summary> private void TableUserInfo_TableNewRow(object sender, DataTableNewRowEventArgs e) { if (((DataTable)lookUpDept.Properties.DataSource).Rows.Count > 0) { e.Row["DepartmentNo"] = DataTypeConvert.GetString(((DataTable)lookUpDept.Properties.DataSource).Rows[0]["DepartmentNo"]); } e.Row["Founder"] = SystemInfo.user.EmpName; e.Row["CreateDate"] = BaseSQL.GetServerDateTime(); }
/// <summary> /// 窗体加载事件 /// </summary> private void FrmWarehouseWarrantQuery_Load(object sender, EventArgs e) { try { ControlCommonInit ctlInit = new ControlCommonInit(); DateTime nowDate = BaseSQL.GetServerDateTime(); dateWWDateBegin.DateTime = nowDate.Date.AddDays(-SystemInfo.OrderQueryDate_DateIntervalDays); dateWWDateEnd.DateTime = nowDate.Date; DataTable departmentTable_t = commonDAO.QueryDepartment(true); DataTable bussInfoTable_t = commonDAO.QueryBussinessBaseInfo(true); DataTable repertoryTable_t = commonDAO.QueryRepertoryInfo(true); DataTable wwTypeTable_t = wwDAO.QueryWarehouseWarrantType(true); lookUpReqDep.Properties.DataSource = departmentTable_t; lookUpReqDep.ItemIndex = 0; searchLookUpBussinessBaseNo.Properties.DataSource = bussInfoTable_t; searchLookUpBussinessBaseNo.Text = "全部"; lookUpRepertoryId.Properties.DataSource = repertoryTable_t; lookUpRepertoryId.ItemIndex = 0; //SearchLocationId.Properties.DataSource = locationTable_t; //SearchLocationId.EditValue = 0; ctlInit.SearchLookUpEdit_RepertoryLocationInfo(SearchLocationId, true); SearchLocationId.EditValue = 0; lookUpWarehouseWarrantTypeNo.Properties.DataSource = wwTypeTable_t; lookUpWarehouseWarrantTypeNo.ItemIndex = 0; ctlInit.ComboBoxEdit_WarehouseState(comboBoxWarehouseState, true); comboBoxWarehouseState.SelectedIndex = 0; ctlInit.SearchLookUpEdit_UserInfo_ValueMember_AutoId(searchLookUpCreator); searchLookUpCreator.EditValue = SystemInfo.user.AutoId; //repLookUpReqDep.DataSource = commonDAO.QueryDepartment(false); //repSearchBussinessBaseNo.DataSource = commonDAO.QueryBussinessBaseInfo(false); //repLookUpRepertoryId.DataSource = commonDAO.QueryRepertoryInfo(false); //repLookUpRepertoryLocationId.DataSource = commonDAO.QueryRepertoryLocationInfo(false); //repLookUpWWTypeNo.DataSource = wwDAO.QueryWarehouseWarrantType(false); repLookUpReqDep.DataSource = departmentTable_t; repSearchBussinessBaseNo.DataSource = bussInfoTable_t; repLookUpRepertoryId.DataSource = repertoryTable_t; repLookUpRepertoryLocationId.DataSource = SearchLocationId.Properties.DataSource; repLookUpWWTypeNo.DataSource = wwTypeTable_t; repLookUpApprovalType.DataSource = commonDAO.QueryApprovalType(false); repLookUpCreator.DataSource = searchLookUpCreator.Properties.DataSource; gridBottomOrderHead.pageRowCount = SystemInfo.OrderQueryGrid_PageRowCount; btnQuery_Click(null, null); } catch (Exception ex) { //ExceptionHandler.HandleException(this.Text + "--窗体加载事件错误。", ex); ExceptionHandler.HandleException(this.Text + "--" + f.tsmiCtjzsjcw.Text, ex); } }
/// <summary> /// 复制处理人员信息到通知人员事件 /// </summary> private void BtnCopy_Click(object sender, EventArgs e) { try { DataRow focusedConditionRow = gridViewLineCondition.GetFocusedDataRow(); if (focusedConditionRow == null) { MessageHandler.ShowMessageBox("请先新增条件信息后,再进行处理人员或通知人员的操作。"); btnNew.Focus(); return; } int conditionAutoIdInt = DataTypeConvert.GetInt(focusedConditionRow["AutoId"]); if (gridViewLineHandle.DataRowCount == 0) { MessageHandler.ShowMessageBox("没有处理人员可以进行复制,请添加处理人员后再进行操作。"); return; } if (gridViewLineNotice.DataRowCount > 0) { if (MessageHandler.ShowMessageBox_YesNo("通知人员已经有记录,确认是否删除之前的通知人员,复制处理人员信息吗?") != DialogResult.Yes) { return; } } for (int i = gridViewLineNotice.DataRowCount - 1; i >= 0; i--) { gridViewLineNotice.GetDataRow(i).Delete(); } for (int i = 0; i < gridViewLineHandle.DataRowCount; i++) { DataRow dr = gridViewLineHandle.GetDataRow(i); DataRow newRow = TableLineNotice.NewRow(); newRow["LineId"] = dr["LineId"]; newRow["ConditionId"] = dr["ConditionId"]; newRow["MultiLevelApprover"] = dr["MultiLevelApprover"]; newRow["LineHandleCate"] = dr["LineHandleCate"]; newRow["HandleOwner"] = dr["HandleOwner"]; newRow["HandleName"] = dr["HandleName"]; newRow["Creator"] = SystemInfo.user.AutoId; newRow["GetTime"] = BaseSQL.GetServerDateTime(); TableLineNotice.Rows.Add(newRow); } MessageHandler.ShowMessageBox("通知人员复制成功。"); } catch (Exception ex) { ExceptionHandler.HandleException(this.Text + "--复制处理人员信息到通知人员事件错误。", ex); } }