Exemple #1
0
 public bool Add(DatCho order)
 {
     if (DatCho.Add(order))
     {
         if (List == null)
         {
             List = DatCho.All();
         }
         List.Add(order);
         return(true);
     }
     return(false);
 }
Exemple #2
0
 public bool Delete(DatCho order)
 {
     if (DatCho.Delete(order))
     {
         if (List == null)
         {
             List = DatCho.All();
         }
         for (int i = 0; i < List.Count; i++)
         {
             if (List[i].MChuyen == order.MChuyen && List[i].MKHang == order.MKHang)
             {
                 List.RemoveAt(i);
             }
         }
         return(true);
     }
     return(false);
 }
Exemple #3
0
 public List <DatCho> All()
 {
     return(List = DatCho.All());
 }
Exemple #4
0
 public OrderList()
 {
     List = new List <DatCho>();
     List = DatCho.All();
 }