private void statPlataButton_Click(object sender, EventArgs e) { var form = new SelectarePerioada(); if (form.ShowDialog() == DialogResult.Yes) { var salariati = CalculatorViewModel.GetSalariati(); var directory = AppDomain.CurrentDomain.BaseDirectory; var path = Path.Combine(directory, "Reports\\StatPlata\\StatPlataReport.rdlc"); ReportUtils.RefreshReport(reportViewer, salariati, path, form.An, form.Luna); reportViewer.Visible = true; inchideReportButton.Visible = true; } }
private void tiparireFluturasButton_Click(object sender, EventArgs e) { var form = new SelectarePerioada(); if (form.ShowDialog() == DialogResult.Yes) { var vizualizareForm = new VizualizareRaport(); var salariati = new List <Salariat>() { CalculatorViewModel.SalariatSelectat }; var directory = AppDomain.CurrentDomain.BaseDirectory; var path = Path.Combine(directory, "Reports\\FluturasSalariu\\FluturasSalariuReport.rdlc"); ReportUtils.RefreshReport(vizualizareForm.reportViewer1, salariati, path, form.An, form.Luna); vizualizareForm.reportViewer1.Visible = true; vizualizareForm.ShowDialog(); } }