Пример #1
0
        public void AddItem(APIFSOrderPromotion postedItem)
        {
            List <APIFSOrderPromotion> list = GetData();

            postedItem.Code = (list.Count + 1);
            list.Add(postedItem);
        }
Пример #2
0
        public void UpdateItem(APIFSOrderPromotion postedItem)
        {
            var editedModel = GetData().First(i => i.Code == postedItem.Code);

            editedModel.NO            = postedItem.NO;
            editedModel.Code          = postedItem.Code;
            editedModel.Name          = postedItem.Name;
            editedModel.Specification = postedItem.Specification;
            editedModel.UoM           = postedItem.UoM;
            editedModel.QuantityInUoM = postedItem.QuantityInUoM;
            editedModel.Quantity      = postedItem.Quantity;
            editedModel.Note          = postedItem.Note;
        }