void clientXml_ListModelCompleted(object sender, ListModelCompletedEventArgs e) { if (e.Error == null) { if (e.Result != null) { //appModel = e.Result; //e.Result.Insert(0, new AppModel() { Name = "0", Description = "请选择......" }); //MessageList.cbModelCode.ItemsSource = e.Result;//XML模块代码 //MessageList.cbModelCode.SelectedIndex = 0; //RuleList.cbModelCode.ItemsSource = e.Result; //RuleList.cbModelCode.SelectedIndex = 0; //triggerList.cbModelCode.ItemsSource = e.Result; //triggerList.cbModelCode.SelectedIndex = 0; //MessageList.appModel = e.Result;//龙康才新增 //RuleList.appModel = e.Result;//龙康才新增 //triggerList.appModel = e.Result;//龙康才新增 //#region 开始连动 //MessageList.cbSystemCode.SelectedIndex = 0; //RuleList.cbSystemCode.SelectedIndex = 0; //triggerList.cbSystemCode.SelectedIndex = 0; #endregion } } else { ComfirmWindow.ConfirmationBox("提示信息", "系统模块加载错误!", "确定"); } }
void btnReSubmit_Click(object sender, RoutedEventArgs e) { if (DaGr.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "ReSubmit"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (DaGr.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "ReSubmit"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } V_ContractApplications ent = DaGr.SelectedItems[0] as V_ContractApplications; ApplicationsForContractsPages AddWin = new ApplicationsForContractsPages(FormTypes.Resubmit, ent.contractApp.CONTRACTAPPID); EntityBrowser browser = new EntityBrowser(AddWin); browser.FormType = FormTypes.Resubmit; browser.MinWidth = 610; browser.MinHeight = 480; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); }
void btnDelete_Click(object sender, RoutedEventArgs e) { ApplicationsID = new ObservableCollection <string>(); if (DaGr.SelectedItems.Count > 0) { for (int i = 0; i < DaGr.SelectedItems.Count; i++) { V_ContractApplications ent = DaGr.SelectedItems[i] as V_ContractApplications; if (ent.contractApp.CHECKSTATE == ((int)CheckStates.UnSubmit).ToString()) { ApplicationsID.Add((DaGr.SelectedItems[i] as V_ContractApplications).contractApp.CONTRACTAPPID); string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { caswsc.DeleteContraApprovalAsync(ApplicationsID); LoadData(); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("NOTONLYDIDNOSUBMITANDREVIEWTHEDATACANBEDELETEDBY")); return; } } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); } }
/// <summary> /// 删除指定假期记录(物理删除,待定) /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void btnDelete_Click(object sender, RoutedEventArgs e) { string strID = ""; if (dgDeductDetailList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgDeductDetailList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } foreach (object ovj in dgDeductDetailList.SelectedItems) { T_HR_ATTENDANCEDEDUCTDETAIL ent = ovj as T_HR_ATTENDANCEDEDUCTDETAIL; string Result = ""; if (ent != null) { strID = ent.DEDUCTDETAILID.ToString(); ComfirmWindow delComfirm = new ComfirmWindow(); delComfirm.OnSelectionBoxClosed += (obj, result) => { clientAtt.RemoveAttendanceDeductDetailAsync(strID); }; delComfirm.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } } }
private void Delete_Click(object sender, RoutedEventArgs e) { dg.ItemsSource = null; ObservableCollection <string> o = new ObservableCollection <string>(); T_OA_VEHICLEUSEAPP i = ((Button)sender).DataContext as T_OA_VEHICLEUSEAPP; o.Add(i.VEHICLEUSEAPPID); if (_lstVUseApp_Add.Contains(i)) { _lstVUseApp_Add.Remove(i); _lstVUseApp.Remove(i); } else if (_lstVUseApp.Contains(i)) { ComfirmWindow com = new ComfirmWindow(); if (_lstVUseApp.Count > 1) //不能为空 { string Result = ""; com.OnSelectionBoxClosed += (obj, result) => { _VM.Del_VDDetailsAsync(o); _lstVUseApp.Remove(i); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("ERROR_VDUSEAPP"), Utility.GetResourceStr("CONFIRMBUTTON")); } } dg.ItemsSource = _lstVUseApp; }
private void btnDelect_Click(object sender, RoutedEventArgs e) { if (DoTaskRuleDataGrid.SelectedItems.Count > 1) { ComfirmWindow.ConfirmationBox("提示信息", "只能选择一条需要删除的记录!", "确定"); return; } if (DoTaskRuleDataGrid.SelectedItems.Count == 1) { pBar.Start(); string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { PlatformService.T_WF_DOTASKRULE rule = (DoTaskRuleDataGrid.SelectedItem as PlatformService.T_WF_DOTASKRULE); DoTaskClient.DeleteDoTaskRuleAsync(rule.DOTASKRULEID); }; com.SelectionBox("删除确定", "你确定删除选中的记录吗?", ComfirmWindow.titlename, Result); } else { //MessageBox.Show("请先选择一条需要删除的记录!"); ComfirmWindow.ConfirmationBox("提示信息", "请先选择一条需要删除的记录!", "确定"); } }
private void myDelete_Click(object sender, RoutedEventArgs e) { try { if (DaGrs.SelectedItems.Count > 0) { delteWelfarePaymentDetail.Add((DaGrs.SelectedItem as T_OA_WELFAREDISTRIBUTEDETAIL).WELFAREDISTRIBUTEDETAILID); string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { BenefitsAdministration.DeleteWelfarePaymentDetailAsync(delteWelfarePaymentDetail); BenefitsAdministration.GetByIdWelfarePaymentDetailsAsync(InfoObj.WELFAREDISTRIBUTEMASTERID); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETESUCCESSED"), Utility.GetResourceStr("PAYMENTDETAILS")); } } catch (Exception ex) { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), ex.ToString()); } }
/// <summary> /// 弹出表单子窗口,以便编辑请假记录 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void btnEdit_Click(object sender, RoutedEventArgs e) { string strAttendanceSolutionID = string.Empty; if (dgEmpLeaveRdList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgEmpLeaveRdList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } T_HR_EMPLOYEECANCELLEAVE tmpEnt = dgEmpLeaveRdList.SelectedItems[0] as T_HR_EMPLOYEECANCELLEAVE; TerminateLeaveForm form = new TerminateLeaveForm(FormTypes.Edit, tmpEnt.CANCELLEAVEID); EntityBrowser entBrowser = new EntityBrowser(form); entBrowser.FormType = FormTypes.Edit; entBrowser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); entBrowser.Show <string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { }); }
public static void ShowCustomMessage(MessageTypes messageType, string title, string message) { // ErrorWindow ewin = new ErrorWindow(title, message); // ewin.Show(); ComfirmWindow.ConfirmationBox(title, message, Utility.GetResourceStr("CONFIRMBUTTON")); }
/// <summary> /// 删除指定的带薪假设置(物理删除,待定) /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void btnDelete_Click(object sender, RoutedEventArgs e) { string strID = ""; if (dgFreeLeaveDaySetList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgFreeLeaveDaySetList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } foreach (object ovj in dgFreeLeaveDaySetList.SelectedItems) { T_HR_FREELEAVEDAYSET ent = ovj as T_HR_FREELEAVEDAYSET; string Result = ""; if (ent != null) { strID = ent.FREELEAVEDAYSETID.ToString(); ComfirmWindow delComfirm = new ComfirmWindow(); delComfirm.OnSelectionBoxClosed += (obj, result) => { clientAtt.RemoveFreeLeaveDaySetAsync(strID); }; delComfirm.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } } }
/// <summary> /// 弹出表单子窗口,以便编辑带薪假设置 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void btnEdit_Click(object sender, RoutedEventArgs e) { string strFreeLeaveDaySetID = string.Empty; if (dgFreeLeaveDaySetList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgFreeLeaveDaySetList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } T_HR_FREELEAVEDAYSET ent = dgFreeLeaveDaySetList.SelectedItems[0] as T_HR_FREELEAVEDAYSET; strFreeLeaveDaySetID = ent.FREELEAVEDAYSETID.ToString(); FreeLeaveDaySetForm formFreeLeaveDaySet = new FreeLeaveDaySetForm(FormTypes.Edit, strFreeLeaveDaySetID, null); EntityBrowser entBrowser = new EntityBrowser(formFreeLeaveDaySet); entBrowser.MinWidth = 600; entBrowser.MinHeight = 300; entBrowser.ReloadDataEvent += new EntityBrowser.refreshGridView(entBrowser_ReloadDataEvent); entBrowser.Show <string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { }); }
void BtnView_Click(object sender, RoutedEventArgs e) { string strEvectionID = string.Empty; if (dgEmpLeaveRdList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "APPOVALBUTTON"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgEmpLeaveRdList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "APPOVALBUTTON"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } T_HR_EMPLOYEECANCELLEAVE entEvectionRd = dgEmpLeaveRdList.SelectedItems[0] as T_HR_EMPLOYEECANCELLEAVE; strEvectionID = entEvectionRd.CANCELLEAVEID; TerminateLeaveForm form = new TerminateLeaveForm(FormTypes.Browse, strEvectionID); EntityBrowser browser = new EntityBrowser(form); browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.FormType = FormTypes.Browse; browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); }
void btnAudit_Click(object sender, RoutedEventArgs e) { if (dg.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "AUDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dg.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "AUDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } T_OA_VEHICLEDISPATCHRECORD ent = dg.SelectedItems[0] as T_OA_VEHICLEDISPATCHRECORD; if (ent.CHECKSTATE == ((int)CheckStates.Approving).ToString() || ent.CHECKSTATE == ((int)CheckStates.WaittingApproval).ToString() || ent.CHECKSTATE == ((int)CheckStates.UnSubmit).ToString()) { VehicleDispatchRecord_aud form = new VehicleDispatchRecord_aud(FormTypes.Audit, ent.VEHICLEDISPATCHRECORDID); EntityBrowser browser = new EntityBrowser(form); browser.FormType = FormTypes.Audit; browser.MinWidth = 750; browser.MinHeight = 600; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show<string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }, true); } else { Utility.ShowCustomMessage(MessageTypes.Error, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("SELECTRECORDNOTOPERATEPLEASEAGAIN")); return; } }
private void CustomAuthorizationBtn_Click(object sender, RoutedEventArgs e) { string strRoleID = string.Empty; if (DtGrid.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (DtGrid.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } T_SYS_ROLE_V entRole = DtGrid.SelectedItems[0] as T_SYS_ROLE_V; //SysRoleSetMenu UserInfo = new SysRoleSetMenu(AuthorRole); strRoleID = entRole.ROLEID; //RoleCustomMenuPermission UserInfo = new RoleCustomMenuPermission(FormTypes.Edit, strRoleID);//自定义权限 EntityMenuCustomerPermission2 UserInfo = new EntityMenuCustomerPermission2(FormTypes.Edit, strRoleID);//自定义权限 EntityBrowser browser = new EntityBrowser(UserInfo); browser.MinWidth = 850; browser.MinHeight = 520; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => {}, true); }
private void SysRoleClient_SysRoleBatchDelCompleted(object sender, SysRoleBatchDelCompletedEventArgs e) { if (!e.Cancelled) { if (e.Result == "") { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), "删除数据成功!", Utility.GetResourceStr("CONFIRMBUTTON")); this.LoadData(); } else { if (e.Result == "error") { SMT.SAAS.Application.ExceptionManager.SendException("角色管理", "Views/SysRole.xaml--SysRoleDelete" + e.Error.Message); ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), "系统出现错误,请与管理员联系!", Utility.GetResourceStr("CONFIRMBUTTON")); return; } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), e.Result.ToString(), Utility.GetResourceStr("CONFIRMBUTTON")); this.LoadData(); } } } }
void BtnView_Click(object sender, RoutedEventArgs e) { if (DaGr.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "VIEW"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (DaGr.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "VIEW"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } T_OA_AGENTSET ent = DaGr.SelectedItems[0] as T_OA_AGENTSET; ProxySettingsForm AddWin = new ProxySettingsForm(FormTypes.Browse, ent.AGENTSETID); EntityBrowser browser = new EntityBrowser(AddWin); browser.FormType = FormTypes.Browse; browser.MinWidth = 500; browser.MinHeight = 300; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); }
private void BtnView_Click(object sender, RoutedEventArgs e) { SMT.Saas.Tools.PermissionWS.PermissionServiceClient ps = new PermissionServiceClient(); ps.GetFlowUserInfoByRoleIDAsync("fbce7ce8-7e45-4bd9-93db-69f40d0a4d47"); if (SelectRole != null) { if (!string.IsNullOrEmpty(SelectRole.ROLEID)) { Form.SysRoleForms editForm = new SMT.SaaS.Permission.UI.Form.SysRoleForms(FormTypes.Browse, SelectRole.ROLEID); EntityBrowser browser = new EntityBrowser(editForm); browser.MinHeight = 300; browser.MinWidth = 400; browser.FormType = FormTypes.Browse; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTRECORDER"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTRECORDER"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } }
private void btnDelete_Click(object sender, RoutedEventArgs e) { DelInfosList.Clear(); if (this.DtGrid.SelectedItems != null) { foreach (T_SYS_ROLE_V n in this.DtGrid.SelectedItems) { if (!(DelInfosList.IndexOf(n.ROLEID) > 0)) { DelInfosList.Add(n.ROLEID); } } //if (!(DelInfosList.IndexOf(SelectRole.ROLEID) > 0)) //{ // DelInfosList.Add(SelectRole.ROLEID); //} } if (DelInfosList.Count() > 0) { string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { ServiceClient.SysRoleBatchDelAsync(DelInfosList); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), "请您选择需要删除的数据!", Utility.GetResourceStr("CONFIRMBUTTON")); return; } }
void btnDelete_Click(object sender, RoutedEventArgs e) { agentsetId = new ObservableCollection <string>(); if (DaGr.SelectedItems.Count > 0) { for (int i = 0; i < DaGr.SelectedItems.Count; i++) { T_OA_AGENTSET ent = DaGr.SelectedItems[i] as T_OA_AGENTSET; agentsetId.Add((DaGr.SelectedItems[i] as T_OA_AGENTSET).AGENTSETID); string Result = ""; ComfirmWindow com = new ComfirmWindow(); com.OnSelectionBoxClosed += (obj, result) => { SoaChannel.DeleteAgentSetAsync(agentsetId); LoadData(); }; com.SelectionBox(Utility.GetResourceStr("DELETECONFIRM"), Utility.GetResourceStr("DELETEALTER"), ComfirmWindow.titlename, Result); } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "DELETE"), Utility.GetResourceStr("CONFIRMBUTTON")); } }
private void btnEdit_Click(object sender, RoutedEventArgs e) { if (SelectRole != null) { if (!string.IsNullOrEmpty(SelectRole.ROLEID)) { Form.SysRoleForms editForm = new SMT.SaaS.Permission.UI.Form.SysRoleForms(FormTypes.Edit, SelectRole.ROLEID); EntityBrowser browser = new EntityBrowser(editForm); browser.MinHeight = 300; browser.MinWidth = 400; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTDATAALERT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTDATAALERT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } }
void BtnView_Click(object sender, RoutedEventArgs e) { string strLeaveTypeSetID = string.Empty; if (DaGr.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "VIEW"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (DaGr.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "VIEW"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } V_ContractTemplate ent = DaGr.SelectedItems[0] as V_ContractTemplate; ContractTemplates AddWin = new ContractTemplates(FormTypes.Browse, ent); EntityBrowser browser = new EntityBrowser(AddWin); browser.FormType = FormTypes.Browse; browser.MinWidth = 550; browser.MinHeight = 410; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); }
private void Select() { string strLeaveTypeSetID = string.Empty; if (DaGr.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "PRINT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (DaGr.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "PRINT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } V_ContractPrint contractApplications = new V_ContractPrint(); contractApplications.contractApp = DaGr.SelectedItem as V_ContractApplications; contractApplications.contractPrint = null; ContractPrintUploadControl AddWin = new ContractPrintUploadControl(Action.Print, contractApplications); EntityBrowser browser = new EntityBrowser(AddWin); browser.MinWidth = 550; browser.MinHeight = 430; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); RefreshUI(RefreshedTypes.Close); }
/// <summary> /// 弹出表单子窗口,以便编辑考勤异常扣款定义 /// </summary> /// <param name="sender"></param> /// <param name="e"></param> void btnEdit_Click(object sender, RoutedEventArgs e) { string strDeductDetailID = string.Empty; if (dgDeductDetailList.SelectedItems == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } if (dgDeductDetailList.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } T_HR_ATTENDANCEDEDUCTDETAIL ent = dgDeductDetailList.SelectedItems[0] as T_HR_ATTENDANCEDEDUCTDETAIL; strDeductDetailID = ent.DEDUCTDETAILID.ToString(); AttendanceDeductDetailForm formDetail = new AttendanceDeductDetailForm(FormTypes.Edit, strDeductDetailID, entAttendanceDeductMaster); EntityBrowser entBrowser = new EntityBrowser(formDetail); entBrowser.MinWidth = 700; entBrowser.MinHeight = 300; entBrowser.ReloadDataEvent += new EntityBrowser.refreshGridView(entBrowser_ReloadDataEvent); entBrowser.Show <string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { }); }
private void btnEdit_Click(object sender, RoutedEventArgs e) { if (Househireapp != null) { if (Househireapp.houseAppObj.CHECKSTATE == "0" || Househireapp.houseAppObj.CHECKSTATE == "3") { HouseHireAppForm form = new HouseHireAppForm(Action.Edit, Househireapp.houseAppObj.HIREAPPID, checkState, "0"); EntityBrowser browser = new EntityBrowser(form); browser.FormType = FormTypes.Edit; browser.MinHeight = 500; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }, true); } else { Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("CAUTION"), Utility.GetResourceStr("HOUSEAPPNOTEDIT")); } } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } //ObservableCollection<string> hireAppID = GridHelper.GetSelectItem(dgHireApp, "myChkBox", Action.Edit); //string hireAppID = ""; //V_HouseHireApp HireAppT = new V_HouseHireApp(); //if (dgHireApp.ItemsSource != null) //{ // foreach (object obj in dgHireApp.ItemsSource) // { // if (dgHireApp.Columns[0].GetCellContent(obj) != null) // { // CheckBox cb1 = dgHireApp.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 // if (cb1.IsChecked == true) // { // HireAppT = cb1.Tag as V_HouseHireApp; // hireAppID = HireAppT.houseAppObj.HIREAPPID; // break; // } // } // } //} //if (string.IsNullOrEmpty(hireAppID)) //{ // ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); //} //else //{ // HouseHireAppForm form = new HouseHireAppForm(Action.Edit, hireAppID, checkState, "0"); // EntityBrowser browser = new EntityBrowser(form); // browser.MinHeight = 500; // browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); // browser.Show<string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }, true); //} }
//查看详情+提交审批 private void btnShowDetail_Click(object sender, RoutedEventArgs e) { if (selApporvalInfo == null) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "EDIT"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } }
void BtnView_Click(object sender, RoutedEventArgs e) { if (Meetingtemplate != null) { MeetingTemplateForm form = new MeetingTemplateForm(Action.Read, Meetingtemplate.MEETINGTEMPLATEID, ""); EntityBrowser browser = new EntityBrowser(form); browser.FormType = FormTypes.Browse; browser.MinWidth = 850; browser.MinHeight = 600; browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); browser.Show <string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); } else { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", "VIEW"), Utility.GetResourceStr("CONFIRMBUTTON")); return; } ////会议类型ID //string TypeId = ""; //if (DaGr.ItemsSource != null) //{ // foreach (object obj in DaGr.ItemsSource) // { // if (DaGr.Columns[0].GetCellContent(obj) != null) // { // CheckBox cb1 = DaGr.Columns[0].GetCellContent(obj).FindName("myChkBox") as CheckBox; //cb为 // if (cb1.IsChecked == true) // { // T_OA_MEETINGTEMPLATE ChkTemplate = new T_OA_MEETINGTEMPLATE(); // ChkTemplate = cb1.Tag as T_OA_MEETINGTEMPLATE; // TypeId = ChkTemplate.MEETINGTEMPLATEID.ToString(); // break; // } // } // } //} //if (string.IsNullOrEmpty(TypeId)) //{ // Utility.ShowCustomMessage(MessageTypes.Message, Utility.GetResourceStr("ERROR"), Utility.GetResourceStr("PLEASESELECT", "MEETINGTYPETEMPLATE")); // return; //} //else //{ // MeetingTemplateForm form = new MeetingTemplateForm(Action.Read, TypeId, ""); // EntityBrowser browser = new EntityBrowser(form); // browser.MinWidth = 400; // browser.MinHeight = 500; // browser.ReloadDataEvent += new EntityBrowser.refreshGridView(browser_ReloadDataEvent); // browser.Show<string>(DialogMode.Default, Common.ParentLayoutRoot, "", (result) => { }); //} }
private void btnSave_Click(object sender, RoutedEventArgs e) { if (txtMSGCONTENT.Text.Trim() == "") { ComfirmWindow.ConfirmationBox("提示信息", "消息内容不能为空!", "确定"); return; } FLOW_MODELDEFINE_T system = cobSYSTEMCODE.SelectedItem as FLOW_MODELDEFINE_T; FLOW_MODELDEFINE_T model = cobMODELCODE.SelectedItem as FLOW_MODELDEFINE_T; if (system.SYSTEMCODE == "0" || model.MODELCODE == "0") { ComfirmWindow.ConfirmationBox("提示信息", "请正确选择 [系统]和[模块]!", "确定"); return; } PlatformService.T_WF_MESSAGEBODYDEFINE entity = new PlatformService.T_WF_MESSAGEBODYDEFINE(); entity.MESSAGEBODY = ParamOperate.MessageBodyExchange(ListTableColumn.ToList(), true, txtMSGCONTENT.Text); entity.MESSAGEURL = txtURL.Text.Trim(); entity.SYSTEMCODE = (cobSYSTEMCODE.SelectedItem as FLOW_MODELDEFINE_T).SYSTEMCODE; entity.MODELCODE = (cobMODELCODE.SelectedItem as FLOW_MODELDEFINE_T).MODELCODE; entity.COMPANYID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].CompanyID; entity.RECEIVETYPE = this.rBRole.IsChecked == true ? 0 : 1; if (entity.RECEIVETYPE == 0 && OrgObjPost != null && OrgObjPost.Count > 0) { foreach (var item in OrgObjPost) { entity.RECEIVEPOSTID += item.ObjectID + ","; entity.RECEIVEPOSTNAME += item.ObjectName + ","; } entity.RECEIVEPOSTID = entity.RECEIVEPOSTID.TrimEnd(','); entity.RECEIVEPOSTNAME = entity.RECEIVEPOSTNAME.TrimEnd(','); } else if (entity.RECEIVETYPE == 1 && OrgObj != null && OrgObj.Count > 0) { foreach (var item in OrgObj) { entity.RECEIVERUSERID += item.ObjectID + ","; entity.RECEIVERUSERNAME += item.ObjectName + ","; } entity.RECEIVERUSERID = entity.RECEIVERUSERID.TrimEnd(','); entity.RECEIVERUSERNAME = entity.RECEIVERUSERNAME.TrimEnd(','); } if (ActionType == "0") { entity.DEFINEID = Guid.NewGuid().ToString(); entity.CREATEDATE = DateTime.Now; entity.CREATEUSERNAME = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeName; entity.CREATEUSERID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.EmployeeID; entity.COMPANYID = SMT.SAAS.Main.CurrentContext.Common.CurrentLoginUserInfo.UserPosts[0].CompanyID; messageClient.AddDefaultMessgeAsync(entity); } else { entity.DEFINEID = DEFINEID; messageClient.EditDefaultMessgeAsync(entity); } //this.DialogResult = true; }
private void btnGetDepartment_Click(object sender, RoutedEventArgs e) { //object objs = null; //if (Application.Current.Resources["CurrentUserID"] != null) //{ // objs = Application.Current.Resources["CurrentUserID"]; // Application.Current.Resources.Remove("CurrentUserID"); // Application.Current.Resources.Add("CurrentUserID", ""); //} //if (Application.Current.Resources["CurrentUserID"] == null) //{ // Application.Current.Resources.Add("CurrentUserID", ""); //} SMT.SaaS.FrameworkUI.OrganizationControl.OrganizationLookup lookup = new SMT.SaaS.FrameworkUI.OrganizationControl.OrganizationLookup(Utility.CurrentUser.EMPLOYEEID, "3", ""); lookup.SelectedObjType = SMT.SaaS.FrameworkUI.OrgTreeItemTypes.Department; lookup.MultiSelected = true; lookup.SelectedClick += (obj, ev) => { if (lookup.SelectedObj != null) { #region 判断是否是属于同一个公司,如果不是提示,返回 foreach (var item in lookup.SelectedObj) { var deparement = ((SMT.Saas.Tools.OrganizationWS.T_HR_DEPARTMENT)(item.ObjectInstance)); string companyid = deparement.T_HR_COMPANY.COMPANYID; string departmentname = deparement.T_HR_DEPARTMENTDICTIONARY.DEPARTMENTNAME; if (CurrentFlowView.ModelRelation.COMPANYID.TrimEnd('|') != companyid) { ComfirmWindow.ConfirmationBox("提示信息", departmentname + " 不属于 " + txtCompanyName.Text + "公司,请重新选择!", "确定"); return; } } #endregion txtDepartmentName.Text = ""; CurrentFlowView.ModelRelation.DEPARTMENTID = ""; //部门ID CurrentFlowView.ModelRelation.DEPARTMENTNAME = ""; //部门名称 foreach (var item in lookup.SelectedObj) { var deparement = ((SMT.Saas.Tools.OrganizationWS.T_HR_DEPARTMENT)(item.ObjectInstance)); string departmentcode = deparement.DEPARTMENTID; string departmentname = deparement.T_HR_DEPARTMENTDICTIONARY.DEPARTMENTNAME; txtDepartmentName.Text += departmentname + "\r\n"; CurrentFlowView.ModelRelation.DEPARTMENTID += departmentcode + "|"; //部门ID CurrentFlowView.ModelRelation.DEPARTMENTNAME += departmentname + "|"; //部门名称 //Application.Current.Resources.Remove("CurrentUserID"); //if (objs != null) //{ // Application.Current.Resources.Add("CurrentUserID", objs); //} } } }; lookup.Show <string>(DialogMode.Default, SMT.SAAS.Main.CurrentContext.Common.ParentLayoutRoot, "", (result) => { }); }
/// <summary> /// 验证是否选中数据 /// </summary> private bool IsSelect(string message) { if (dgEmployeeSurvey.SelectedItems == null || dgEmployeeSurvey.SelectedItems.Count == 0) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), Utility.GetResourceStr("SELECTERROR", message), Utility.GetResourceStr("CONFIRMBUTTON")); return(false); } return(true); }
/// <summary> /// 修改系统角色信息 /// </summary> /// <param name="sender"></param> /// <param name="?"></param> void SysRoleClient_SysRoleInfoUpdateCompleted(object sender, System.ComponentModel.AsyncCompletedEventArgs e) { if (!e.Cancelled) { ComfirmWindow.ConfirmationBox(Utility.GetResourceStr("CONFIRMINFO"), "修改角色信息成功", Utility.GetResourceStr("CONFIRMBUTTON")); RefreshUI(RefreshedTypes.CloseAndReloadData); } }