예제 #1
0
 private void InsertHoaDon()
 {
     hoaDonDTO.maNV  = int.Parse(tbMaNhanVien.Text);
     hoaDonDTO.tenKH = tbTenKH.Text;
     hoaDonDTO.TGBD  = DateTime.Parse(dateTimePicker1.Value.ToString());
     hoaDonBUS.Add(hoaDonDTO);
 }
예제 #2
0
        public static void SaveInvoice(int KhId, int total, double saleoff, List <CTHDDTO> listCTHD, GiaoHangDTO GH)
        {
            CTHDBUS   cthd       = new CTHDBUS();
            int       Mahd       = 0;
            DateTime  DateCreate = DateTime.Now;
            HoaDonBUS hd         = new HoaDonBUS();

            HoaDonDTO entity = new HoaDonDTO(Mahd, KhId, DateCreate, saleoff, total);

            CTHDBUS     cTHDBUS     = new CTHDBUS();
            GiaoHangBUS giaoHangBUS = new GiaoHangBUS();

            hd.Add(entity);
            giaoHangBUS.Add(GH);
            cTHDBUS.Add(listCTHD);
        }