Beispiel #1
0
        public void LoadPaymentDetailFromDB()
        {
            List <PaymentDetail> paymentDetail = new List <PaymentDetail>();

            paymentDetail.Clear();
            List <string> rooms = new List <string>();

            rooms.Clear();
            rooms.AddRange(RentInfo.GetRoomNameByCustomerID(((Customer)cbCustomerName.SelectedItem).IdCardNumber));
            foreach (var item in rooms)
            {
                paymentDetail.AddRange(PaymentDetail.GetPaymentDetailByRoomName(item));
            }

            paymentDetails.Clear();
            foreach (var item in paymentDetail)
            {
                paymentDetails.Add(item);
            }
        }