@model Ninesky.Models.Category
@{
ViewBag.Title = "栏目信息";
Layout = "~/Views/Layout/_Manage.cshtml";
}
<
div
class
=
"workspace"
>
<
div
class
=
"inside"
>
<
div
class
=
"notebar"
>
<
img
alt
=
""
src
=
"~/Skins/Default/Manage/Images/Category.gif"
/>栏目信息
</
div
>
@using (Html.BeginForm("ManageUpdate","Category"))
{
@Html.ValidationSummary(true)
<
fieldset
>
<
legend
>详细资料</
legend
>
<
ul
>
@Html.HiddenFor(model => model.CategoryId)
<
li
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.CategoryId)
</
div
>
<
div
class
=
"editor-field"
>
@Html.DisplayTextFor(model => model.CategoryId)
</
div
>
</
li
>
<
li
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.Name)
</
div
>
<
div
class
=
"editor-field"
>
@Html.EditorFor(model => model.Name)
@Html.ValidationMessageFor(model => model.Name)
</
div
>
</
li
>
<
li
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.ParentId)
</
div
>
<
div
class
=
"editor-field"
>
@Html.TextBoxFor(model => model.ParentId, new { @class = "easyui-combotree", data_options = "url:'" + Url.Action("JsonTreeParent", "Category") + "'" })
@Html.ValidationMessageFor(model => model.ParentId)
</
div
>
</
li
>
<
li
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.Type)
</
div
>
<
div
class
=
"editor-field"
>
@Html.DropDownList("Type")
@Html.ValidationMessageFor(model => model.Type)
</
div
>
</
li
>
<
li
id
=
"li_model"
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.Model)
</
div
>
<
div
class
=
"editor-field"
>
@Html.DropDownList("Model")
@Html.ValidationMessageFor(model => model.Model)
</
div
>
</
li
>
<
li
id
=
"li_categoryview"
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.CategoryView)
</
div
>
<
div
class
=
"editor-field"
>
@Html.EditorFor(model => model.CategoryView)
@Html.ValidationMessageFor(model => model.CategoryView)
</
div
>
</
li
>
<
li
id
=
"li_contentview"
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.ContentView)
</
div
>
<
div
class
=
"editor-field"
>
@Html.EditorFor(model => model.ContentView)
@Html.ValidationMessageFor(model => model.ContentView)
</
div
>
</
li
>
<
li
id
=
"li_nav"
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.Navigation)
</
div
>
<
div
class
=
"editor-field"
>
@Html.EditorFor(model => model.Navigation)
@Html.ValidationMessageFor(model => model.Navigation)
</
div
>
</
li
>
<
li
>
<
div
class
=
"editor-label"
>
@Html.LabelFor(model => model.Order)
</
div
>
<
div
class
=
"editor-field"
>
@Html.EditorFor(model => model.Order)
@Html.ValidationMessageFor(model => model.Order)
</
div
>
</
li
>
<
li
>
<
div
class
=
"editor-label"
>
<
input
id
=
"Submit1"
type
=
"submit"
value
=
"修改"
/>
</
div
>
<
div
class
=
"editor-field"
>
</
div
>
</
li
>
</
ul
>
</
fieldset
>
}
</
div
>
</
div
>
<
div
class
=
"left"
>
<
div
class
=
"top"
></
div
>
@Html.Action("ManagePartialTree", "Category")
</
div
>
<
div
class
=
"split"
></
div
>
<
div
class
=
"clear"
></
div
>
<
script
type
=
"text/javascript"
>
Details();
$("#Type").change(function () {
Details();
});
function Details() {
var v = $("#Type").val();
if (v == "0") {
$("#li_model").show();
$("#li_categoryview").show();
$("#li_contentview").show();
$("#li_nav").hide();
$("#Navigation").val("");
}
else if (v == "1") {
$("#li_model").hide();
$("#li_categoryview").show();
$("#li_contentview").hide();
$("#ContentView").val("");
$("#li_nav").hide();
$("#Navigation").val("");
}
else if (v == "2") {
$("#li_model").hide();
$("#li_categoryview").hide();
$("#CategoryView").val("");
$("#li_contentview").hide();
$("#ContentView").val("");
$("#li_nav").show();
}
}
</
script
>
@section Scripts {
@Styles.Render("~/EasyUi/icon")
@Scripts.Render("~/bundles/EasyUi")
@Scripts.Render("~/bundles/jqueryval")
}