/// <summary> /// Carga los integrantes /// </summary> /// <history> /// [vku] 12/Jul/2016 Created /// </history> public async void LoadIntegrantes(TeamGuestServices team) { try { List <Personnel> lstPersonnel = await BRPersonnel.GetPersonnels(blnLiner : true); List <Personnel> lstPersonnelIni = await BRPersonnel.GetPersonnels(blnLiner : true); List <Personnel> lstliner = new List <Personnel>(); lstliner.AddRange(lstPersonnel); cboIntegrant.ItemsSource = lstPersonnel; cboLiner.ItemsSource = lstliner; _lstPersonnel = lstPersonnel.Where(pe => pe.peTeam == team.tgID && pe.peTeamType == EnumToListHelper.GetEnumDescription(EnumTeamType.TeamPRs) && pe.pePlaceID == team.tglo).ToList(); _lstOldPersonnel = lstPersonnelIni.Where(pe => pe.peTeam == team.tgID && pe.peTeamType == EnumToListHelper.GetEnumDescription(EnumTeamType.TeamPRs) && pe.pePlaceID == team.tglo).ToList(); //Cargamos la lista con los datos iniciales dgrIntegrants.ItemsSource = _lstPersonnel; StatusBarReg.Content = _lstPersonnel.Count + " Integrants."; status.Visibility = Visibility.Collapsed; } catch (Exception ex) { UIHelper.ShowMessage(ex); } }
/// <summary> /// Carga los integrantes a transferir /// </summary> /// <history> /// [vku] 19/Jul/2016 Created /// </history> public async void LoadPersonnel() { List <Personnel> lstPersonnelFrom = await BRPersonnel.GetPersonnels(); List <Personnel> lstPersonnelTo = new List <Personnel>(); lstPersonnelTo.AddRange(lstPersonnelFrom); cboIntegrant.ItemsSource = lstPersonnelFrom; cboIntegrantTo.ItemsSource = lstPersonnelTo; _lstPersonnel.AddRange(_lstOldPersonnel); grdFrom.ItemsSource = _lstPersonnel; skpStatus.Visibility = Visibility.Collapsed; lblIntegrantFrom.Content = "Integrants: " + _lstPersonnel.Count; }
/// <summary> /// Llena los datos de Personnels /// </summary> /// <param name="deptID">Id del depto</param> /// <history> /// [emoguel] created 03/05/2016 /// </history> private async void LoadPersonnels(string deptID) { try { List <Personnel> lstAllPersonnels = await BRPersonnel.GetPersonnels(); cmbPersonnel.ItemsSource = lstAllPersonnels; _lstPersonel = lstAllPersonnels.Where(pe => pe.pede == deptID).ToList(); dgrPersonnel.ItemsSource = _lstPersonel; _lstOldPersonnel = lstAllPersonnels.Where(pe => pe.pede == deptID).ToList();//Cargamos la lista con los datos iniciales } catch (Exception ex) { UIHelper.ShowMessage(ex); } }
/// <summary> /// Carga los integrantes /// </summary> /// <history> /// [vku] 23/Jul/2016 Created /// </history> public async void LoadIntegrantes(TeamSalesmen team) { try { List <Personnel> lstPersonnel = await BRPersonnel.GetPersonnels(blnLiner : true); cboIntegrant.ItemsSource = lstPersonnel; _lstPersonnel = lstPersonnel.Where(pe => pe.peTeam == team.tsID && pe.peTeamType == EnumToListHelper.GetEnumDescription(EnumTeamType.TeamSalesmen) && pe.pePlaceID == team.tssr).OrderBy(pe => pe.pepo).ThenBy(pe => pe.peN).ToList(); dgrIntegrants.ItemsSource = _lstPersonnel; List <Personnel> lstPersonnelIni = await BRPersonnel.GetPersonnels(); _lstOldPersonnel = lstPersonnelIni.Where(pe => pe.peTeam == team.tsID && pe.peTeamType == EnumToListHelper.GetEnumDescription(EnumTeamType.TeamSalesmen) && pe.pePlaceID == team.tssr).OrderBy(pe => pe.pepo).ThenBy(pe => pe.peN).ToList(); //Cargamos la lista con los datos iniciales StatusBarReg.Content = _lstPersonnel.Count + " Integrants."; status.Visibility = Visibility.Collapsed; } catch (Exception ex) { UIHelper.ShowMessage(ex); } }