コード例 #1
0
        //
        // GET: CreateEdit
        public ActionResult CreateEdit(string wid)
        {
            UWareHouse wareHouse = new UWareHouse();

            wareHouse.LocationSelect =
                new SelectList(wareHouseService.LocationObj.GetLocations(), "Id", "Name");

            wareHouse.SubOffSelect = new SelectList(wareHouseService.CtrySubOffObj.GetCountrySubOffices(countryProg.Id),
                                                    "Id", "Address");

            Guid whId;

            if (Guid.TryParse(wid, out whId))
            {
                ViewBag.Action       = Resources.Global_String_Edit;
                wareHouse._wareHouse = wareHouseService.GetWareHouse(whId);
            }
            return(View(wareHouse));
        }