private void incarcaRand(DataGridViewRow pRand, BClientiComenzi pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); DataGridViewPersonalizat.InitCelulaDeschideClasic(pRand, EnumColoaneDGV.colTotalEtape.ToString()); pRand.Cells[EnumColoaneDGV.colLucrare.ToString()].Value = pElem.DenumireLucrare; pRand.Cells[EnumColoaneDGV.colNrElemente.ToString()].Value = pElem.NrElemente.ToString(); if (pElem.IdReprezentantClient != 0) { pRand.Cells[EnumColoaneDGV.colNumeMedic.ToString()].Value = pElem.GetIdentitateMedic(); } pRand.Cells[EnumColoaneDGV.colNumePacient.ToString()].Value = pElem.NumePacient; pRand.Cells[EnumColoaneDGV.colTehnician.ToString()].Value = pElem.GetIdentitateTehnician(); if (CUtil.isNotNull(pElem.DataPrimire)) { pRand.Cells[EnumColoaneDGV.colDataPrimire.ToString()].Value = pElem.DataPrimire; } if (CUtil.isNotNull(pElem.DataLaGata)) { pRand.Cells[EnumColoaneDGV.colDataLaGata.ToString()].Value = pElem.DataLaGata; } if (pElem.IdEtapaSetari != 0) { pRand.Cells[EnumColoaneDGV.colEtapaCurenta.ToString()].Value = BEtape.GetEtapaById(pElem.IdEtapaSetari, EnumStare.Activa, null).Denumire; } pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = pElem.Observatii; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BUtilizatoriVenituri pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, true); pRand.Cells[EnumColoaneDGV.colTipVenit.ToString()].Value = BUtilizatoriVenituri.StructTipVenit.GetStringByEnum((BUtilizatoriVenituri.EnumTipVenit)pElem.TipVenit); if (CUtil.isNotNull(pElem.DataInceput)) { pRand.Cells[EnumColoaneDGV.colDataInceput.ToString()].Value = pElem.DataInceput; } if (CUtil.isNotNull(pElem.DataFinal)) { pRand.Cells[EnumColoaneDGV.colDataSfarsit.ToString()].Value = pElem.DataFinal; } pRand.Cells[EnumColoaneDGV.colSalariuFix.ToString()].Value = pElem.SalariuFix; pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = CUtil.PregatesteStringMultiLineDGV(pElem.Observatii); if (CUtil.isNotNull(pElem.DataCreare)) { pRand.Cells[EnumColoaneDGV.colDataCreare.ToString()].Value = pElem.DataCreare; } DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClientiComenziEtape pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); if (pElem.IdEtapa != 0) { pRand.Cells[EnumColoaneDGV.colEtapa.ToString()].Value = BEtape.GetEtapaById(pElem.IdEtapa, CDefinitiiComune.EnumStare.Activa, null).Denumire; } pRand.Cells[EnumColoaneDGV.colDataInceput.ToString()].Value = pElem.DataInceput; if (pElem.Refacere) { DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGV.colEtapa.ToString()); pRand.Cells[EnumColoaneDGV.colEtapa.ToString()].ToolTipText = BMultiLingv.getElementById(BMultiLingv.EnumDictionar.Refacere); } else { DataGridViewPersonalizat.IndeparteazaAlerta(pRand, EnumColoaneDGV.colEtapa.ToString()); } pRand.Cells[EnumColoaneDGV.colDataFinal.ToString()].Value = pElem.DataFinal; if (pElem.IdTehnician != 0) { pRand.Cells[EnumColoaneDGV.colTehnician.ToString()].Value = BUtilizator.GetById(pElem.IdTehnician, null).GetNumeCompletUtilizator(); } pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = pElem.Observatii; pRand.Cells[EnumColoaneDGV.colStatus.ToString()].Value = BClientiComenziEtape.StructStareEtapa.GetStructById(pElem.Status).Denumire; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BProfesii pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colCodCOR.ToString()].Value = pElem.CodCOR; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BListeParametrabile pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colDataCreare.ToString()].Value = pElem.DataCreare; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BLocalitati pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colLocalitate.ToString()].Value = pElem.Nume; pRand.Cells[EnumColoaneDGV.colTip.ToString()].Value = pElem.Tip; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BEtape pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colDurata.ToString()].Value = pElem.DurataMedieMinute; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BBanci pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colInformatiiComplementare.ToString()].Value = pElem.InformatiiComplementare; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BRegiuni pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colRegiune.ToString()].Value = pElem.Nume; pRand.Cells[EnumColoaneDGV.colAbreviere.ToString()].Value = pElem.Abreviere; pRand.Cells[EnumColoaneDGV.colPrefixTelefonic.ToString()].Value = pElem.PrefixTelefon; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRandDetalii(DataGridViewRow pRand, BPontaj pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGVDetalii.colTip.ToString()].Value = BDefinitiiGenerale.StructCheckInOut.GetDenumireTip(pElem.TipPontaj); pRand.Cells[EnumColoaneDGVDetalii.colData.ToString()].Value = pElem.DataPontaj; pRand.Cells[EnumColoaneDGVDetalii.colObservatii.ToString()].Value = pElem.Observatii; }
private void incarcaRand(DataGridViewRow pRand, BClientiComenzi pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colClient.ToString()].Value = BClienti.getClient(pElem.IdClient, null).Denumire; pRand.Cells[EnumColoaneDGV.colReprezentant.ToString()].Value = BClientiReprezentanti.getNumeCompletReprezentant(BClientiReprezentanti.getReprezentant(pElem.IdReprezentantClient, null)); pRand.Cells[EnumColoaneDGV.colDataPrimire.ToString()].Value = pElem.DataPrimire; pRand.Cells[EnumColoaneDGV.colDataLaGata.ToString()].Value = pElem.DataLaGata; pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = pElem.Observatii; }
private void incarcaRand(DataGridViewRow pRand, BTari pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colTara.ToString()].Value = pElem.NumeScurt; pRand.Cells[EnumColoaneDGV.colNumeOficial.ToString()].Value = pElem.NumeOficial; pRand.Cells[EnumColoaneDGV.colPrefixTelefonic.ToString()].Value = pElem.PrefixTelefonic; pRand.Cells[EnumColoaneDGV.colAbreviere.ToString()].Value = pElem.Abreviere; pRand.Cells[EnumColoaneDGV.colCetatenie.ToString()].Value = pElem.Cetatenie; }
private void incarcaRand(DataGridViewRow pRand, BLocatii pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colInitiala.ToString()].Value = pElem.InitialaLocatie; pRand.Cells[EnumColoaneDGV.colDenumireFiscala.ToString()].Value = pElem.DenumireFiscala; pRand.Cells[EnumColoaneDGV.colInfoContact.ToString()].Value = pElem.InfoContact; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClientiCabinete pElem, BColectieClientiComenzi pListaLucrariCabinet) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGVCabinete.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGVCabinete.colAdresa.ToString()].Value = BAdrese.getAdresa(pElem.IdAdresa, null).ToString(); initColoaneUltimaLucrareSiTotal(pRand, pListaLucrariCabinet); DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClienti pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colDenumireFiscala.ToString()].Value = pElem.DenumireFiscala; pRand.Cells[EnumColoaneDGV.colCUI.ToString()].Value = pElem.CUI; DataGridViewPersonalizat.InitCeluleTelefonEmail(pRand, pElem.TelefonMobil, pElem.AdresaMail); pRand.Cells[EnumColoaneDGV.colTelefonFix.ToString()].Value = pElem.TelefonFix; pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = pElem.Observatii; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRandMedic(DataGridViewRow pRand, BClientiReprezentanti pElem, BColectieClientiComenzi pListaLucrariMedic) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGVMedici.colNumePrenume.ToString()].Value = pElem.GetIdentitateReprezentant(); DataGridViewPersonalizat.InitCeluleTelefonEmail(pRand, pElem.TelefonMobil, pElem.AdresaMail); initColoaneUltimaLucrareSiTotal(pRand, pListaLucrariMedic); pRand.Cells[EnumColoaneDGVMedici.colObservatii.ToString()].Value = pElem.Observatii; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClientiPacienti pElem) { pRand.Tag = pElem; string denumire = String.Concat(pElem.Nume, " ", pElem.Prenume); DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); DataGridViewPersonalizat.InitCelulaSelectieUnica(pRand, true); pRand.Cells[2].Value = denumire; pRand.Cells[3].Value = pElem.DataCreare; pRand.Cells[4].Value = pElem.TelefonMobil; pRand.Cells[5].Value = pElem.AdresaMail; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BListaPreturiStandard pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colPrescurtare.ToString()].Value = pElem.DenumirePrescurtata; pRand.Cells[EnumColoaneDGV.colCod.ToString()].Value = pElem.CodIntern; pRand.Cells[EnumColoaneDGV.colCategorie.ToString()].Value = BListaPreturiStandard.getById(BListaPreturiStandard.getByIdCategorie(pElem.IdCategorie, null), null); pRand.Cells[EnumColoaneDGV.colTermenMediu.ToString()].Value = pElem.TermenMediuZile; pRand.Cells[EnumColoaneDGV.colValoareRon.ToString()].Value = pElem.ValoareRON; pRand.Cells[EnumColoaneDGV.colValoareEuro.ToString()].Value = pElem.ValoareEUR; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRandIncasare(DataGridViewRow pRand, BClientiPlati pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGVIncasari.colData.ToString()].Value = pElem.DataPlata; pRand.Cells[EnumColoaneDGVIncasari.colModalitate.ToString()].Value = BDefinitiiGenerale.StructModalitatePlata.GetStringByEnum((BDefinitiiGenerale.EnumModalitatePlata)pElem.ModalitatePlata); DataGridViewPersonalizat.InitCelulaValoareMonetara(pRand, EnumColoaneDGVIncasari.colValoare.ToString(), pElem.SumaPlatita, CDefinitiiComune.EnumTipMoneda.Lei); pRand.Cells[EnumColoaneDGVFacturi.colObservatii.ToString()].Value = pElem.Observatii; pRand.Cells[EnumColoaneDGVIncasari.colCursBNR.ToString()].Value = pElem.CursBNR; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BListaPreturiStandard pElem, BListaPreturiClienti pPretClient) { pRand.Tag = new Tuple <BListaPreturiStandard, BListaPreturiClienti>(pElem, pPretClient); DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colLucrare.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colMoneda.ToString()].Value = pElem.ValoareRON == 0 ? CUtil.getText(1265) : CUtil.getText(1264); pRand.Cells[EnumColoaneDGV.colPretStandard.ToString()].Value = pElem.ValoareRON == 0 ? pElem.ValoareEUR : pElem.ValoareRON; if (pPretClient != null) { pRand.Cells[EnumColoaneDGV.colPretClient.ToString()].Value = pPretClient.GetValoare(); } else { pRand.Cells[EnumColoaneDGV.colPretClient.ToString()].Value = pElem.ValoareRON == 0 ? pElem.ValoareEUR : pElem.ValoareRON; } }
private void incarcaRand(DataGridViewRow pRand, BUtilizator pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colCuloare.ToString()].Style.BackColor = BDefinitiiGenerale.getCuloareDinARGB(pElem.Culoare); pRand.Cells[EnumColoaneDGV.colNume.ToString()].Value = pElem.Nume; pRand.Cells[EnumColoaneDGV.colPrenume.ToString()].Value = pElem.Prenume; if (CUtil.isNotNull(pElem.DataNastere)) { pRand.Cells[EnumColoaneDGV.colDataNastere.ToString()].Value = pElem.DataNastere; } pRand.Cells[EnumColoaneDGV.colTelefonFix.ToString()].Value = pElem.TelefonFix; pRand.Cells[EnumColoaneDGV.colCnp.ToString()].Value = pElem.CNP; DataGridViewPersonalizat.InitCeluleTelefonEmail(pRand, pElem.TelefonMobil, pElem.AdresaMail); DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClientiCabinete pElem, BAdrese pAdresa) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colAdresa.ToString()].Value = pAdresa.ToString(); var lstComenziCabinet = BClientiComenzi.getById(this.lClient.Id, pElem.Id, null); if (lstComenziCabinet.Count != 0) { pRand.Cells[EnumColoaneDGV.colUltimaComanda.ToString()].Value = lstComenziCabinet[lstComenziCabinet.Count - 1].DataPrimire; } pRand.Cells[EnumColoaneDGV.colTotalComenzi.ToString()].Value = BClientiComenzi.getById(this.lClient.Id, pElem.Id, null).Count; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BLocatii pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; //pRand.Cells[EnumColoaneDGV.colInitiala.ToString()].Value = pElem.InitialaLocatie; pRand.Cells[EnumColoaneDGV.colDenumireFiscala.ToString()].Value = pElem.DenumireFiscala; pRand.Cells[EnumColoaneDGV.colInfoContact.ToString()].Value = pElem.InfoContact; pRand.Cells[EnumColoaneDGV.colSerieFacturi.ToString()].Value = pElem.SerieFacturi; pRand.Cells[EnumColoaneDGV.colNumarulUltimeiFacturi.ToString()].Value = pElem.NumarUltimaFactura; pRand.Cells[EnumColoaneDGV.colSerieChitante.ToString()].Value = pElem.SerieChitante; pRand.Cells[EnumColoaneDGV.colNumarulUltimeiChitante.ToString()].Value = pElem.NumarUltimaChitanta; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClientiReprezentanti pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colNumePrenume.ToString()].Value = pElem.Nume + " " + pElem.Prenume; DataGridViewPersonalizat.InitCeluleTelefonEmail(pRand, pElem.TelefonMobil, pElem.AdresaMail); var lstComenziReprezentanti = BClientiComenzi.getByIdReprezentant(this.lClient.Id, pElem.Id, null); if (lstComenziReprezentanti.Count != 0) { pRand.Cells[EnumColoaneDGV.colUltimaComanda.ToString()].Value = lstComenziReprezentanti[lstComenziReprezentanti.Count - 1].DataPrimire; } pRand.Cells[EnumColoaneDGV.colTotalComenzi.ToString()].Value = BClientiComenzi.GetListByParamIdClientReprezentant(this.lClient.Id, pElem.Id, CDL.iStomaLab.CDefinitiiComune.EnumStare.Activa, null).Count; pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = pElem.Observatii; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClientiComenzi pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colNumeReprezentant.ToString()].Value = BClientiReprezentanti.getReprezentant(pElem.IdReprezentantClient, null).Nume + " " + BClientiReprezentanti.getReprezentant(pElem.IdReprezentantClient, null).Prenume; pRand.Cells[EnumColoaneDGV.colNumePacient.ToString()].Value = pElem.NumePacient; if (CUtil.isNotNull(pElem.DataPrimire)) { pRand.Cells[EnumColoaneDGV.colDataPrimire.ToString()].Value = pElem.DataPrimire; } if (CUtil.isNotNull(pElem.DataLaGata)) { pRand.Cells[EnumColoaneDGV.colDataLaGata.ToString()].Value = pElem.DataLaGata; } pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = pElem.Observatii; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClientiFacturi pElem, BColectieClientiComenzi pListaLucrari, BColectieClientiPlatiComenzi pListaPlatiPeFact) { pRand.Tag = pElem; double valoare = pListaLucrari.GetValoareTotalaFactura(CDefinitiiComune.EnumTipMoneda.Lei, pElem.CursBNR); double achitat = pListaPlatiPeFact.GetValoarePlatita(); DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); if (pElem.EsteFiscalizata()) { pRand.Cells[EnumColoaneDGV.colTipDocument.ToString()].Value = BMultiLingv.getElementById(BMultiLingv.EnumDictionar.Factura); DataGridViewPersonalizat.IndeparteazaAlerta(pRand, EnumColoaneDGV.colTipDocument.ToString()); } else { pRand.Cells[EnumColoaneDGV.colTipDocument.ToString()].Value = BMultiLingv.getElementById(BMultiLingv.EnumDictionar.Proforma); DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGV.colTipDocument.ToString()); } pRand.Cells[EnumColoaneDGV.colDataEmiterii.ToString()].Value = pElem.DataFactura; pRand.Cells[EnumColoaneDGV.colSerieFactura.ToString()].Value = pElem.SerieFactura; pRand.Cells[EnumColoaneDGV.colNumarFactura.ToString()].Value = pElem.NumarFactura; pRand.Cells[EnumColoaneDGV.colClinica.ToString()].Value = pElem.DenumireClient; DataGridViewPersonalizat.InitCelulaValoareMonetara(pRand, EnumColoaneDGV.colValoare.ToString(), valoare, CDefinitiiComune.EnumTipMoneda.Lei); //pRand.Cells[EnumColoaneDGV.colValoare.ToString()].Value = ; if (pElem.MonedaFactura != CDefinitiiComune.EnumTipMoneda.Lei) { DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGV.colValoare.ToString()); } pRand.Cells[EnumColoaneDGV.colValoare.ToString()].ToolTipText = CUtil.GetValoareMonetara(valoare, pElem.MonedaFactura); DataGridViewPersonalizat.InitCelulaValoareMonetara(pRand, EnumColoaneDGV.colAchitat.ToString(), achitat, CDefinitiiComune.EnumTipMoneda.Lei); DataGridViewPersonalizat.InitCelulaValoareMonetara(pRand, EnumColoaneDGV.colRestPlata.ToString(), valoare - achitat, CDefinitiiComune.EnumTipMoneda.Lei); pRand.Cells[EnumColoaneDGV.colCursBNR.ToString()].Value = pElem.CursBNR; pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = pElem.Observatii; DataGridViewPersonalizat.InitCelulaStergere(pRand); DataGridViewPersonalizat.InitCelulaDeschideClasic(pRand, EnumColoaneDGV.colDetaliiClinica.ToString()); }
private void incarcaRandRezumat(DataGridViewRow pRand, BColectiePontaj pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGVRezumat.colConcedii.ToString()].Value = this.lUtilizator.NumarZileCOAgreate; pRand.Cells[EnumColoaneDGVRezumat.colZileNelucratoare.ToString()].Value = "0"; pRand.Cells[EnumColoaneDGVRezumat.colZile.ToString()].Value = CUtil.GetNumarZileLucratoareLuna(this.ctrlPerioada.DataInceput); pRand.Cells[EnumColoaneDGVRezumat.colTotal.ToString()].Value = CUtil.GetTextPrescurtatDurataOreMinute(getDurataTotalaPePerioada()); int ultimaZiDinLuna = Convert.ToInt32(DateAndTime.DateDiff(DateInterval.Day, this.ctrlPerioada.DataInceput, this.ctrlPerioada.DataSfarsit)); DateTime dataInceput = this.ctrlPerioada.DataInceput; DateTime dataSfarsit = dataInceput.AddDays(1); for (int i = this.ctrlPerioada.DataInceput.Day; i <= this.ctrlPerioada.DataSfarsit.Day; i++) { this.dgvListaPontaj.Columns[0].Tag = pElem; long totalPontajZi = 0; var listaElem = BPontaj.GetListByIdUtilizatorTotalPePerioada(this.lUtilizator.Id, dataInceput, dataSfarsit, null); foreach (var elem in listaElem) { if (elem.TipPontaj == 1) { dataInceput = elem.DataPontaj; } if (elem.TipPontaj == 2) { totalPontajZi += getNrMinuteZi(dataInceput, elem.DataPontaj); } } pRand.Cells[(dataInceput.Day).ToString()].Value = CUtil.GetTextPrescurtatDurataOreMinute(totalPontajZi); dataInceput = dataInceput.AddDays(1); dataSfarsit = dataSfarsit.AddDays(1); } }
private void incarcaRand(DataGridViewRow pRand, BClientiFacturi pElem, BColectieClientiComenzi pListaLucrari, BColectieClientiPlatiComenzi pListaPlatiPeFact) { pRand.Tag = pElem; double valoare = pListaLucrari.GetValoareTotalaFactura(CDefinitiiComune.EnumTipMoneda.Lei, pElem.CursBNR); double achitat = pListaPlatiPeFact.GetValoarePlatita(); //pListaPlatiPeFact.GetSumaPlatita(); DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGVFacturi.colDataEmiterii.ToString()].Value = pElem.DataFactura; pRand.Cells[EnumColoaneDGVFacturi.colTipDocument.ToString()].Value = pElem.ToStringTipDocument(); pRand.Cells[EnumColoaneDGVFacturi.colSerieFactura.ToString()].Value = pElem.SerieFactura; pRand.Cells[EnumColoaneDGVFacturi.colNumarFactura.ToString()].Value = pElem.NumarFactura != 0 ? pElem.NumarFactura: pElem.Id; DataGridViewPersonalizat.InitCelulaValoareMonetara(pRand, EnumColoaneDGVFacturi.colValoare.ToString(), valoare, CDefinitiiComune.EnumTipMoneda.Lei); if (pElem.MonedaFactura != CDefinitiiComune.EnumTipMoneda.Lei) { DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGVFacturi.colValoare.ToString()); } pRand.Cells[EnumColoaneDGVFacturi.colValoare.ToString()].ToolTipText = CUtil.GetValoareMonetara(valoare, pElem.MonedaFactura); DataGridViewPersonalizat.InitCelulaValoareMonetara(pRand, EnumColoaneDGVFacturi.colPlatit.ToString(), achitat, CDefinitiiComune.EnumTipMoneda.Lei); DataGridViewPersonalizat.InitCelulaValoareMonetara(pRand, EnumColoaneDGVFacturi.colRest.ToString(), valoare - achitat, CDefinitiiComune.EnumTipMoneda.Lei); if (valoare - achitat != 0) { DataGridViewPersonalizat.SeteazaCuloareTextCelula(pRand, EnumColoaneDGVFacturi.colRest.ToString(), Color.Red); } else { DataGridViewPersonalizat.SeteazaCuloareTextCelula(pRand, EnumColoaneDGVFacturi.colRest.ToString(), Color.Black); } pRand.Cells[EnumColoaneDGVFacturi.colCursBNR.ToString()].Value = pElem.CursBNR; pRand.Cells[EnumColoaneDGVFacturi.colObservatii.ToString()].Value = pElem.Observatii; DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BListaPreturiStandard pElem) { pRand.Tag = pElem; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); pRand.Cells[EnumColoaneDGV.colDenumire.ToString()].Value = pElem.Denumire; pRand.Cells[EnumColoaneDGV.colPrescurtare.ToString()].Value = pElem.DenumirePrescurtata; pRand.Cells[EnumColoaneDGV.colCod.ToString()].Value = pElem.CodIntern; if (pElem.IdCategorie != 0) { BCategorii categorie = BCategorii.getCategorieById(pElem.IdCategorie, null); if (categorie.IdCategorie != 0) { pRand.Cells[EnumColoaneDGV.colCategorie.ToString()].Value = BCategorii.getCategorieById(categorie.IdCategorie, null).Denumire; pRand.Cells[EnumColoaneDGV.colSubcategorie.ToString()].Value = categorie.Denumire; } else { pRand.Cells[EnumColoaneDGV.colCategorie.ToString()].Value = categorie.Denumire; pRand.Cells[EnumColoaneDGV.colSubcategorie.ToString()].Value = string.Empty; } } else { pRand.Cells[EnumColoaneDGV.colCategorie.ToString()].Value = string.Empty; pRand.Cells[EnumColoaneDGV.colSubcategorie.ToString()].Value = string.Empty; } pRand.Cells[EnumColoaneDGV.colTermenMediu.ToString()].Value = pElem.TermenMediuZile; pRand.Cells[EnumColoaneDGV.colValoareRon.ToString()].Value = pElem.GetEtichetaRon(); pRand.Cells[EnumColoaneDGV.colValoareEuro.ToString()].Value = pElem.GetEtichetaEuro(); DataGridViewPersonalizat.InitCelulaStergere(pRand); }
private void incarcaRand(DataGridViewRow pRand, BClientiComenzi pElem) { pRand.Tag = pElem; //asa era initial pRand.Tag = new Tuple<BClientiComenzi, BListaPreturiStandard, BListaPreturiClienti>(pElem, pElem2, pElemClient); idclient = pElem.IdClient; idlucrare = pElem.IdLucrare; DataGridViewPersonalizat.InitCelulaEditare(pRand, this.lEcranInModificare); DataGridViewPersonalizat.SeteazaCuloareFundalCelula(pRand, EnumColoaneDGV.colCuloareTehnician.ToString(), BDefinitiiGenerale.getCuloareDinARGB(pElem.CuloareTehnician)); pRand.Cells[EnumColoaneDGV.colCuloareTehnician.ToString()].ToolTipText = pElem.GetIdentitateTehnician(); pRand.Cells[EnumColoaneDGV.colCodLucrareClient.ToString()].Value = pElem.Id; pRand.Cells[EnumColoaneDGV.colCodComanda.ToString()].Value = pElem.CodLucrare; pRand.Cells[EnumColoaneDGV.colClient.ToString()].Value = pElem.GetDenumireClinicaCabinet(); DataGridViewPersonalizat.InitCelulaDeschideClasic(pRand, EnumColoaneDGV.colFisaClient.ToString()); if (pElem.IdReprezentantClient != 0) { pRand.Cells[EnumColoaneDGV.colMedic.ToString()].Value = pElem.GetIdentitateMedic(); } else { pRand.Cells[EnumColoaneDGV.colMedic.ToString()].Value = string.Empty; } if (pElem.Urgent) { DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGV.colLucrare.ToString()); pRand.Cells[EnumColoaneDGV.colLucrare.ToString()].ToolTipText = string.Format("{0} - {1}", BMultiLingv.getElementById(BMultiLingv.EnumDictionar.Urgent), pElem.DenumireLucrare); } else { DataGridViewPersonalizat.IndeparteazaAlerta(pRand, EnumColoaneDGV.colLucrare.ToString()); pRand.Cells[EnumColoaneDGV.colLucrare.ToString()].ToolTipText = pElem.DenumireLucrare; } pRand.Cells[EnumColoaneDGV.colCuloare.ToString()].Value = pElem.Culoare; pRand.Cells[EnumColoaneDGV.colLucrare.ToString()].Value = pElem.GetDenumirePrescurtata(); pRand.Cells[EnumColoaneDGV.colNrElemente.ToString()].Value = pElem.NrElemente.ToString(); if (pElem.IdEtapaCurenta != 0) { pRand.Cells[EnumColoaneDGV.colEtapaCurenta.ToString()].Value = pElem.DenumireEtapa; } else { pRand.Cells[EnumColoaneDGV.colEtapaCurenta.ToString()].Value = string.Empty; } if (pElem.Refacere) { DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGV.colEtapaCurenta.ToString()); pRand.Cells[EnumColoaneDGV.colEtapaCurenta.ToString()].ToolTipText = BMultiLingv.getElementById(BMultiLingv.EnumDictionar.Refacere); } else { DataGridViewPersonalizat.IndeparteazaAlerta(pRand, EnumColoaneDGV.colEtapaCurenta.ToString()); } if (pElem.IdTehnician != 0) { pRand.Cells[EnumColoaneDGV.colTehnician.ToString()].Value = pElem.GetIdentitateTehnician(); } else { pRand.Cells[EnumColoaneDGV.colTehnician.ToString()].Value = string.Empty; } pRand.Cells[EnumColoaneDGV.colStare.ToString()].Value = pElem.StatusEtapaEticheta; if (pElem.DataSfarsitEtapa != CConstante.DataNula) { pRand.Cells[EnumColoaneDGV.colTermen.ToString()].Value = pElem.DataSfarsitEtapa; pRand.Cells[EnumColoaneDGV.colTermen.ToString()].ToolTipText = CUtil.GetNumeZiSaptamana(pElem.DataSfarsitEtapa.DayOfWeek); if (pElem.DataSfarsitEtapa <= DateTime.Today && !pElem.Acceptata) { DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGV.colTermen.ToString()); } else { DataGridViewPersonalizat.IndeparteazaAlerta(pRand, EnumColoaneDGV.colTermen.ToString()); } } DataGridViewPersonalizat.InitCelulaDeschideClasic(pRand, EnumColoaneDGV.colTotalEtape.ToString()); pRand.Cells[EnumColoaneDGV.colDataPrimire.ToString()].Value = pElem.DataPrimire; if (pElem.DataLaGata != CConstante.DataNula) { pRand.Cells[EnumColoaneDGV.colDataLaGata.ToString()].Value = pElem.DataLaGata; } else { pRand.Cells[EnumColoaneDGV.colDataLaGata.ToString()].Value = string.Empty; } if (pElem.DataLaGata.Date <= DateTime.Today && !pElem.Acceptata) { DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGV.colDataLaGata.ToString()); } else { DataGridViewPersonalizat.IndeparteazaAlerta(pRand, EnumColoaneDGV.colDataLaGata.ToString()); } pRand.Cells[EnumColoaneDGV.colNumePacient.ToString()].Value = pElem.GetNumePrenumePacient(); pRand.Cells[EnumColoaneDGV.colObservatii.ToString()].Value = pElem.Observatii; pRand.Cells[EnumColoaneDGV.colDataCreare.ToString()].Value = pElem.DataCreare; if (pElem.IdFactura > 0) { DataGridViewPersonalizat.SeteazaOK(pRand, EnumColoaneDGV.colNumePacient.ToString()); } BListaPreturiClienti pElemClient = BListaPreturiClienti.GetPretClient(pElem.IdLucrare, pElem.IdClient, CDL.iStomaLab.CDefinitiiComune.EnumStare.Activa, null); pRand.Cells[EnumColoaneDGV.colMoneda.ToString()].Value = pElem.GetEtichetaMoneda(); pRand.Cells[EnumColoaneDGV.colValoareInitiala.ToString()].Value = CUtil.GetValoareMonetara(pElem.ValoareInitiala, pElem.Moneda); double pretLista = pElem.ValoareInitiala; double pretNegociat = pElem.ValoareFinala; double diferenta = pretLista - pretNegociat; double ajustare = CUtil.GetProcentDinTotal(diferenta, pretLista); pRand.Cells[EnumColoaneDGV.colDiscount.ToString()].Value = CUtil.GetValoareMonetara(ajustare); // BListaPreturiClienti.GetEtichetaAjustare(); //daca este reducere, atunci % cu minus si alerta text cu rosu if (pretNegociat < pretLista) { DataGridViewPersonalizat.SeteazaAlerta(pRand, EnumColoaneDGV.colDiscount.ToString()); } else { DataGridViewPersonalizat.IndeparteazaAlerta(pRand, EnumColoaneDGV.colDiscount.ToString()); } pRand.Cells[EnumColoaneDGV.colValoareFinala.ToString()].Value = CUtil.GetValoareMonetara(pElem.ValoareFinala, pElem.Moneda); DataGridViewPersonalizat.InitCelulaStergere(pRand); }