@using ShwasherSys.Authorization.Permissions @using ShwasherSys.BasicInfo @using ShwasherSys.Models.Layout @using ShwasherSys.Views.Shared.New.Modals @using ShwasherSys.Views.Shared.New.Table @{ ViewBag.Title = "人员信息维护"; string activeMenu = PermissionNames.PagesCompanyEmployee; //The menu item will be active for this page. ViewBag.ActiveMenu = activeMenu; List gender = new List { new SelectListItem(){Value = @"1",Text = "男"}, new SelectListItem(){Value = @"2",Text = "女"} },duty = ViewBag.Duty, depart = ViewBag.Department; var searchForm = new SearchFormViewModal(new List() { new SearchItem("no","人员编号"), new SearchItem("name","人员姓名"), new SearchItem("departmentNo","部门",FiledType.S,ExpType.Equal).SetSearchItem(depart), new SearchItem("dutyNo","职务",FiledType.I,ExpType.Equal).SetSearchItem(duty), new SearchItem("userName","登陆账号"), }); var table = new TableViewModel("/api/services/app/Employee/GetAll", activeMenu, searchForm) .SetFields(new List() { new FieldItem("no", "人员编号"), new FieldItem("name", "人员姓名"), new FieldItem("phoneNumber", "手机号"), new FieldItem("cardId", "身份证号"), new FieldItem("gender", "性别","GenderFormatter"), new FieldItem("departmentNo", "部门","DepartmentFormatter"), new FieldItem("dutyNo", "职务","DutyFormatter"), new FieldItem("userName", "登陆账号","UserNameFormatter") }); } @section css{ } @Html.Partial("New/Table/_Table", table) @section modal{ @{ var modal = new ModalViewModel("人员", new ModalBodyViewModel(new List() { new InputHide("id"), new Input("no", "人员编号",@class:"num4"), new Input("name", "人员姓名"), new Input("phoneNumber", "手机号").SetNotRequired(), new Input("cardId", "身份证号",@class:"isIdCardNo").SetNotRequired(), new Input("gender", "性别").SetSelectOptions(gender), new Input("departmentNo", "部门").SetNotRequired().SetSelectOptions(depart), new Input("dutyNo", "职务").SetNotRequired().SetSelectOptions(duty), new InputTextarea("description", "详情").SetNotRequired(), //new Input("userName", "登陆账号").SetNotRequired(), })); var accountModal = new ModalViewModel("绑定账号", new ModalBodyViewModel( new List() { new InputHide("id"), new Input("userName", "登陆账号",InputTypes.List), }), "Account_Modal"); } @Html.Partial("New/Modals/_Modal", modal) @Html.Partial("New/Modals/_Modal", accountModal) } @section scripts { }
@Html.DropDownList("hid-du", duty) @Html.DropDownList("hid-de", depart) @Html.DropDownList("hid-gender", gender)