コード例 #1
0
        public ActionResult EditForm(int?id)
        {
            var obj = new ProductManufacturerItem();

            var listProductType = manufacturerRepository.GetListForTree <object>();

            if (id.HasValue)
            {
                obj = manufacturerRepository.GetItemById <ProductManufacturerItem>(id.Value);
            }

            return(Json(new
            {
                data = obj,
                listType = listProductType
            }, JsonRequestBehavior.AllowGet));
        }