示例#1
0
        public ActionResult LoadGRNItemDetais(Guid PoId, string viewName)
        {
            var model = new GoodsReceivedNote()
            {
                PurchaseOrderId = PoId,
                ReceivedBy      = currentStaff.Id,
                Supplier        = gRNService.GetPO(PoId).Supplier,
                SupplierId      = gRNService.GetPO(PoId).Supplier.Id,
                staffs          = new SelectList(SessionData.CurrentSession.StaffList, "Id", "StaffName"),
                PurchaseOrders  = new SelectList(gRNService.GetGRNPurchaseOrders(), "Id", "RefNumber"),
                SubOffices      = new SelectList(SessionData.CurrentSession.CountrySubOfficeList, "Id", "Name"),
                Warehouses      = new SelectList(gRNService.GetSubOfficeWareHouses(Guid.Empty), "Id", "Name"),
                ApproversList   = new SelectList(staffService.GetStaffByApprovalDoc(NotificationHelper.grnCode, countryProg.Id), "Id", "StaffName"),
                RefNumber       = string.Format("--{0}--", Resources.GoodsReceivedNote_LoadGRN_NewGRN),
                POItemz         = gRNService.GetPOItemsDetails(PoId),
                SupplierName    = gRNService.GetPO(PoId).Supplier.Name
            };

            return(View(viewName, model));
        }