Beispiel #1
0
        public ActionResult ModifyDeliverBill(DeliverBillViewModel model)
        {
            List<DeliverBillGoods> listGoods = new List<DeliverBillGoods>();
            foreach (DeliverBillGoodsViewModel m in model.Goods)
            {
                DeliverBillGoods g = new DeliverBillGoods();
                g.Id = m.Id;
                g.DeliverBillId = m.DeliverBillId;
                g.GoodsId = m.GoodsId;
                g.GoodsName = m.GoodsName;
                g.GoodsNo = m.GoodsNo;
                g.Brand = m.Brand;
                g.SpecModel = m.SpecModel;
                g.GWeight = m.GWeight;
                g.Grade = m.Grade;
                g.PieceWeight = m.PieceWeight;
                g.Packing = m.Packing;
                g.BatchNo = m.BatchNo;
                g.Location = m.Location;
                g.Packages = m.Packages;
                g.Tunnages = m.Tunnages;
                g.Piles = m.Piles;
                g.TenThousands = m.TenThousands;
                g.ProductionDate = m.ProductionDate;
                g.EnterWarehouseBillId = m.EnterWarehouseBillId;
                g.EnterWarehouseBillNo = m.EnterWarehouseBillNo;
                listGoods.Add(g);
            }

            string strErrText;
            DeliverSystem deliver = new DeliverSystem();
            if (deliver.UpdateDeliverBill(model.Id, model.TransportCharges, listGoods, LoginAccountId, LoginStaffName, out strErrText))
            {
                return Json(string.Empty);
            }
            else
            {
                return Json(strErrText);
            }
        }