示例#1
0
 public List <ReceiptViewModel> Read(ReceiptBindingModel model)
 {
     if (model == null)
     {
         return(_receiptStorage.GetFullList());
     }
     if (model.Id.HasValue)
     {
         return(new List <ReceiptViewModel> {
             _receiptStorage.GetElement(model)
         });
     }
     return(_receiptStorage.GetFilteredList(model));
 }