private void ReSetCusCode(object s, LoadedDataEventArgs geted) { this.IsBusy = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); return; } var items2 = geted.Entities; foreach (V_Sale_ContractBill_Sub_CusCode y in items2) { foreach (V_Base_CustomerSmart itenm in DContextMain) { if (itenm.CusCode.ToUpper() == y.CusCode.ToUpper()) { itenm.IsSelected = true; break; } } } }
private void ReSetSpCode(object s, LoadedDataEventArgs geted) { this.IsBusy = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); return; } var items2 = geted.Entities; foreach (V_Pur_PriceContract_SpGroup_SpCode y in items2) { foreach (V_B_Supplier item in DContextList) { if (item.SpCode.ToUpper() == y.SpCode.ToUpper()) { item.IsSelected = true; break; } } } }
private void ReSetLensCode(object s, LoadedDataEventArgs geted) { this.IsBusy = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); return; } var items2 = geted.Entities; foreach (V_B_Supplier_Default_Lens y in items2) { foreach (V_B_Material_Lens item in DContextList) { if (item.LensCode.ToUpper() == y.LensCode.ToUpper()) { item.IsSelected = true; break; } } } }
private void ReSetSelectCodes(object s, LoadedDataEventArgs geted) { this.IsBusy = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); return; } var items2 = geted.Entities; foreach (V_B_Customer itenm in DContextList) { itenm.IsSelected = false; } foreach (V_B_Customer_Browse it2 in items2) { if (string.IsNullOrEmpty(it2.GpCode)) { continue; } foreach (V_B_Customer itenm in DContextList) { if (itenm.CusCode.ToUpper() == it2.CusCode.ToUpper()) { itenm.IsSelected = true; break; } } } }
void ddsAuthorityTree_LoadedData(object sender, LoadedDataEventArgs geted) { this.IsBusy = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); this.SourceTree.Clear(); return; } var items2 = geted.Entities; foreach (V_S_Function y in items2) { foreach (V_S_Function itenm in SourceTree.SelectMany(item => GetItems(item))) { if (itenm.FunCode.ToUpper() == y.FunCode.ToUpper()) { itenm.IsSelected = true; break; } } } }
private void ReSetSelectCodes(object s, LoadedDataEventArgs geted) { this.IsBusyList2 = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); return; } var items2 = geted.Entities; if (DContextList2 == null) { return; } foreach (V_B_Customer itenm in DContextList2) { itenm.IsSelected = false; } foreach (V_B_Customer y in items2) { foreach (V_B_Customer itenm in DContextList2) { if (itenm.CusCode.ToUpper() == y.CusCode.ToUpper()) { itenm.IsSelected = true; break; } } } }
private void ReSetSelectCodes(object s, LoadedDataEventArgs geted) { this.IsBusy = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); return; } var items2 = geted.Entities; foreach (V_S_User_GroupDataBase y in items2) { foreach (V_S_User itenm in DContextList) { if (itenm.UserCode.ToUpper() == y.UserCode.ToUpper()) { itenm.IsSelected = true; break; } } } }
private static void dds_LoadedData(object sender, LoadedDataEventArgs geted) { if (geted.HasError) { USysFlag.IsReadyRight = true; geted.MarkErrorAsHandled(); return; } Rights.Clear(); V_S_Function t = null; foreach (V_S_Function item in geted.Entities) { t = new V_S_Function() { F_Open = item.F_Open, FunCode = item.FunCode, FunID = item.FunID, FunName = item.FunName, FunPID = item.FunPID, ImageURL = item.ImageURL, F_Explan = item.F_Explan, F_ShowInMenu = item.F_ShowInMenu, FunRight = item.FunRight, }; Rights.Add(t); } USysFlag.IsReadyRight = true; }
private void transactionInfoDomainDataSource_LoadedData_1(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void dds_LoadedData(object sender, LoadedDataEventArgs geted) { this.IsBusy = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); return; } var items = geted.Entities; if (items.Count() == 0) { MessageWindowErp u = new MessageWindowErp(USysInfo.UserCode + ErpUIText.Get("ERP_Err_NotDataBase"), MessageWindowErp.MessageType.Error); u.Closed += (s1, e1) => { HtmlPage.Window.Eval("window.location.reload();"); return; }; u.Show(); } if (geted.Entities.Count() == 1) { var item = geted.Entities.First() as V_S_User_GroupDataBase; this.InitUserInfo(item); return; } //////////////////////////////////// if (items.Count() > 1) { List <string> lists = new List <string>(); foreach (V_S_User_GroupDataBase item in items) { lists.Add(item.DBName.UIStr()); } String[] comboOptions = lists.ToArray(); MessageWindowErp cmw = new MessageWindowErp(ErpUIText.Get("ERP_SelectDataBase"), MessageWindowErp.MessageType.ComboInput, comboOptions); cmw.Btn_OK.Click += (obj, args) => { if (cmw.InputComboBox.SelectedIndex != -1) { var name = cmw.InputComboBox.SelectedItem.ToString(); foreach (V_S_User_GroupDataBase item in items) { if (item.DBName.UIStr() == name) { this.InitUserInfo(item); break; } } } }; cmw.Show(); } }
private void productGroupDomainDataSource1_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void студентDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void DomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { MessageBox.Show("Connection could not be established." + Environment.NewLine + e.Error.Message, "Connection Error", MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void satisfacaoFuncionarioSetDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void DDsSub_LoadedData(object s, LoadedDataEventArgs geted) { if (geted.HasError) { geted.MarkErrorAsHandled(); return; } ComSubGridColumnUpdate t = this.GetDContextSubToUpdateSubGrid(geted.Entities); Messenger.Default.Send <ComSubGridColumnUpdate>(t, USysMessages.RefreshSubGrid); }
private static void dds_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); return; } _UHV_B_Material_LensSmart.Clear(); foreach (V_B_Material_LensSmart t in e.Entities) { _UHV_B_Material_LensSmart.Add(t); } }
static void ddsProClass_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); return; } _UHV_B_Material_ProcessClass.Clear(); foreach (V_U_ProcessClass t in e.Entities) { _UHV_B_Material_ProcessClass.Add(t); } }
private static void WH_LoadedData(object s, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); return; } _UV_B_WareHouse.Clear(); foreach (V_B_WareHouse t in e.Entities) { _UV_B_WareHouse.Add(t); } }
private static void SP_LoadedData(object s, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); return; } _UV_B_Supplier.Clear(); foreach (V_B_Supplier t in e.Entities) { _UV_B_Supplier.Add(t); } }
private static void dds_LoadedData1(object sender, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); return; } uHV_B_Supplier.Clear(); foreach (V_B_Supplier t in e.Entities) { uHV_B_Supplier.Add(t); } }
private static void dds_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); return; } if (e.Entities.Count() <= 0) { return; } V_B_Material_Lens it = e.Entities.FirstOrDefault() as V_B_Material_Lens; Messenger.Default.Send(it, "VMB_Material_Lens_Sale_FillFromPCode"); }
private static void ddsSmartBrowseRight_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); return; } UHV_B_SupplierRightBrowse.Clear(); foreach (V_B_Supplier t in e.Entities) { _UHV_B_SupplierRightBrowse.Add(t); } //USysFlag.IsReadyCusCodeSmartBrowseRight = true; }
private void companyDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } else { ctx = (RadiographyContext)companyDomainDataSource.DomainContext; if (ctx.Companies.Count > 0) { companyForm.CurrentItem = this.CompanyModel = ctx.Companies.First(); } } }
private void студентDomainDataSource1_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } // продолжение добавления записи if (студентDomainDataSource1.DataView.Count == 0) { MessageBox.Show("Добавление невозможно: для всех студентов данной группы проставлены оценки по данной дисциплине"); return; } int i = 0; do { int j; for (j = 0; j < оценкаDomainDataSource.DataView.Count; j++) { if ((оценкаDomainDataSource.DataView[j] as Оценка).КодСтудента == (студентDomainDataSource1.DataView[i] as Студент).Код) { break; } } if (j == оценкаDomainDataSource.DataView.Count) { break; } i++; }while (i < студентDomainDataSource1.DataView.Count); if (i == студентDomainDataSource1.DataView.Count) { MessageBox.Show("Добавление невозможно: для всех студентов данной группы проставлены оценки по данной дисциплине"); return; } if (оценкаDomainDataSource.DataView.CanAdd) { оценкаDomainDataSource.DataView.Add(new Оценка() { КодДисциплины = (int)кодComboBox.SelectedValue, КодСтудента = (студентDomainDataSource1.DataView[i] as Студент).Код, Оценка1 = 100 }); } }
private void DDsMain_LoadedData(object sender, LoadedDataEventArgs geted) { if (geted.HasError) { this.IsBusy = false; MessageBox.Show(geted.Error.ToString()); geted.MarkErrorAsHandled(); this.Drop(); return; } var items = geted.Entities; if (items.Count() == 0) { if (!flag_Next && !flag_Previous) { USysInfo.ErrMsg = ErpUIText.Get("ERP_NoRecord") + this.SIDCode; MessageErp.ErrorMessage(USysInfo.ErrMsg); this.Drop(); } else if (flag_Next) { this.IsEnableNext = false; } else { this.IsEnablePrevious = false; } this.IsBusy = false; return; } try { var item = items.FirstOrDefault(); this.OnLoadMainEndRetSetDContextMain(item); this.OnLoadMainEnd(); } catch { } finally { this.IsBusy = false; } }
private void DomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { MessageBox.Show("Connection could not be established." + Environment.NewLine + e.Error.Message, "Connection Error", MessageBoxButton.OK); e.MarkErrorAsHandled(); } if (sender == ddsAppointments && firstLoad) { firstLoad = false; if (schedulerControl1.Storage.AppointmentStorage.Count > 0) { schedulerControl1.Start = schedulerControl1.Storage.AppointmentStorage[0].Start; } } }
////////////////////////////////////////////////////////////////////////////////////////////////////////////// private void DDsList_LoadedData(object sender, LoadedDataEventArgs geted) { this.IsBusyLens_Price = false; if (geted.HasError) { MessageBox.Show(geted.Error.ToString()); geted.MarkErrorAsHandled(); return; } try { ResultInfoTimeB_Lens_Price = ErpUIText.Get("ERP_Search1") + DateTime.Now.Subtract(this._TimeCountB_Lens_Price).TotalSeconds.ToString("N") + ErpUIText.Get("ERP_Search2"); ResultInfoCountB_Lens_Price = ErpUIText.Get("ERP_Search3") + (geted.TotalEntityCount).ToString() + ErpUIText.Get("ERP_Search4"); } catch { } GridListSelectedCodesPrice.Clear(); }
private void группаDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { lGID.Clear(); lGName.Clear(); for (int i = 0; i < группаDomainDataSource.DataView.Count; i++) { int id = (группаDomainDataSource.DataView[i] as Группа).Код; string name = (группаDomainDataSource.DataView[i] as Группа).Наименование; int j = lGID.BinarySearch(id); lGID.Insert(~j, id); lGName.Insert(~j, name); } if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void студентDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { lSID.Clear(); lSName.Clear(); for (int i = 0; i < студентDomainDataSource.DataView.Count; i++) { int id = (студентDomainDataSource.DataView[i] as Студент).Код; string name = (студентDomainDataSource.DataView[i] as Студент).ФИО; int j = lSID.BinarySearch(id); lSID.Insert(~j, id); lSName.Insert(~j, name); } if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void OnDataSourceLoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); this.debugTextBox.Text = string.Format("<-- Server returned the following error: {0}\r\n" , e.Error); } else if (e.Cancelled) { this.debugTextBox.Text = string.Format("<-- Load operation was cancelled\r\n"); } else { TimeSpan elapsedTime = DateTime.Now - this.startTime; this.debugTextBox.Text += string.Format("<-- Server replied in {0} ms\r\n" , elapsedTime.Milliseconds); } }
////////////////////////////////////////////////////////////////////////////////////////////////////////////// private void DDsList_LoadedData2(object sender, LoadedDataEventArgs geted) { this.IsBusyList2 = false; if (geted.HasError) { MessageBox.Show(geted.Error.ToString()); geted.MarkErrorAsHandled(); return; } try { ResultInfoTime2 = ErpUIText.Get("ERP_Search1") + DateTime.Now.Subtract(this._TimeCount2).TotalSeconds.ToString("N") + ErpUIText.Get("ERP_Search2"); ResultInfoCount2 = ErpUIText.Get("ERP_Search3") + (geted.TotalEntityCount).ToString() + ErpUIText.Get("ERP_Search4"); } catch { } this.OnLoadMainEnd2(); }
private void ddsTreeView_LoadedData(object sender, LoadedDataEventArgs geted) { this.IsBusy = false; if (geted.HasError) { MessageErp.ErrorMessage(geted.Error.Message.GetErrMsg()); geted.MarkErrorAsHandled(); return; } var items = geted.Entities; this.SourceTree.Clear(); V_S_Function it; items.ToList().ForEach(item => { if (!string.IsNullOrEmpty(((V_S_Function)item).FunParentID)) { return; } it = new V_S_Function(); ComCopyProperties.Copy(it, item); it.I_Explan = true; it.Children = GetChild(items, ((V_S_Function)item).FunID); this.SourceTree.Add(it); }); //////////////////////////////////////////// var ddsInfo = new ComDDsInfo() { Domaincontext = ComDSFactory.Man, QueryName = UDSMethods.V_S_FunctionAuthorityList, PageSize = 0 }; ddsInfo.Parameters.Add(new ComParameters() { ParameterName = "groupID", Value = this._gID }); var dds = ComDDSFactory.Get(ddsInfo, null, ddsAuthorityTree_LoadedData); this.IsBusy = true; dds.Load(); }
private async void tblUserGroupDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } else { this.cboUserGroup.SelectedIndex = 0; var q = await db.LoadAsync<tblUserGroupMenu>(db.GetTblUserGroupMenuIncludeMenuQuery()); menus = q.ToArray(); //this.tblUserGroupMenuDomainDataSource.AutoLoad = true; //this.tblUserGroupMenuDomainDataSource.Load(); Filter(); } }
/////////////////////////////////////////////////////////////////////////////// void dds_LoadedData(object sender, LoadedDataEventArgs geted) { if (geted.HasError) { TreeDateSource.Clear(); TreeDateSource.Add(new V_S_Function() { FunName = ErpUIText.ErrMsg }); geted.MarkErrorAsHandled(); return; } if (geted.Entities.Count() == 0) { TreeDateSource.Clear(); return; } var items = geted.Entities; this.InitTree(items); }
private static void LoadCusFrameCode_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); return; } Messenger.Default.Send <string>((""), USysMessages.ACBoxFrameCodeTextUpdateBegin); _UHV_B_CusFrameCode.Clear(); if (e.TotalEntityCount == 0) { return; } foreach (V_B_Material_Frame t in e.Entities) { _UHV_B_CusFrameCode.Add(t); } Messenger.Default.Send <string>((""), USysMessages.ACBoxFrameCodeTextUpdateEnd); }
private void storyDomainDataSource_LoadedData_1(object sender, LoadedDataEventArgs e) { //var list = obj.Entities.ToList(); //myItem.ItemsSource = list; //foreach (Story s in list) //{ // MyControlLibrary.TaskCard card = new MyControlLibrary.TaskCard() // { // Name = s.StoryId.ToString(), // Height = 90, // Width = 150, // Text = s.Description // }; // //not bound, just pushed onto the control.... // //look at http://stackoverflow.com/questions/507535/silverlight-itemscontrol-can-you-remove-the-panel-completely-via-templating // myGrid.Children.Add(card); //} if(e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void OnDomainDataSourceLoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { Handle(e.Error); e.MarkErrorAsHandled(); } }
/// <summary> /// This handles the load of the datasource data and shows errors if any /// </summary> /// <param name="sender"></param> /// <param name="e"></param> public virtual void domainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void companyDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } else { ctx = (RadiographyContext)companyDomainDataSource.DomainContext; if (ctx.Companies.Count > 0) { companyForm.CurrentItem = this.CompanyModel = ctx.Companies.First(); } } }
private void locationDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { receiveCar.IsEnabled = false; System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } else receiveCar.IsEnabled = true; }
private void convenioPlanoSaudeSetDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }
private void OnOrderDetailsViewLoadedData(object sender, LoadedDataEventArgs e) { if (e.HasError) { e.MarkErrorAsHandled(); } }
private void tblAlarmDomainDataSource_LoadedData(object sender, LoadedDataEventArgs e) { this.BusyIndicator1.IsBusy = false; if (e.HasError) { System.Windows.MessageBox.Show(e.Error.ToString(), "Load Error", System.Windows.MessageBoxButton.OK); e.MarkErrorAsHandled(); } }