Ejemplo n.º 1
0
        public ThongKe(DangNhap dn, string manv)
        {
            InitializeComponent();
            this.dn   = dn;
            this.manv = manv;

            hd = new HoaDonController();
            dv = new DichVuController();

            cbxtknamNam.SelectedIndex     = 0;
            cbxtkquyNam.SelectedIndex     = 0;
            cbxtkquyQuy.SelectedIndex     = 0;
            cbxtkthangNam.SelectedIndex   = 0;
            cbxtkthangThang.SelectedIndex = 0;
            int thang = int.Parse(cbxtkthangThang.SelectedItem.ToString());
            int nam   = int.Parse(cbxtkthangNam.SelectedItem.ToString());

            lblChiThu.Text           = "Tổng chi thu tháng: ";
            lblTongChiThu.Text       = null;
            lblTongTienDichVu.Text   = null;
            lblTongThuTienPhong.Text = null;
            tblThongKe.DataSource    = hd.thongKeThang(thang, nam);
            pnlThang.Show();
            pnlNam.Hide();
            pnlQuy.Hide();
        }
Ejemplo n.º 2
0
 private void chonThongKeThang(object sender, EventArgs e)
 {
     if (rdThang.Checked)
     {
         pnlNam.Hide();
         pnlQuy.Hide();
         pnlThang.Show();
         cbxtknamNam.SelectedIndex     = 0;
         cbxtkquyNam.SelectedIndex     = 0;
         cbxtkquyQuy.SelectedIndex     = 0;
         cbxtkthangNam.SelectedIndex   = 0;
         cbxtkthangThang.SelectedIndex = 0;
         int thang = int.Parse(cbxtkthangThang.SelectedItem.ToString());
         int nam   = int.Parse(cbxtkthangNam.SelectedItem.ToString());
         tblThongKe.DataSource    = hd.thongKeThang(thang, nam);
         lblChiThu.Text           = "Tổng chi thu tháng: ";
         lblTongChiThu.Text       = null;
         lblTongTienDichVu.Text   = null;
         lblTongThuTienPhong.Text = null;
     }
 }