@using IwbZero.IwbDataQuery @using IwbZero.ToolCommon.StringModel @using WeEngine.Enum @using WePlatform.Configuration @using WePlatform.Authorization @using WePlatform.Views.Shared.Modals @using WePlatform.Views.Shared.Query @using WePlatform.Views.Shared.SearchForm @using WePlatform.Views.Shared.Table @{ ViewBag.Title = "情景库管理"; string activeMenu = PermissionNames.PagesResourceMgSceneMg; string category = ViewBag.Category, sceneType = ViewBag.SceneType, guideType = ViewBag.GuideType, environment = ViewBag.Environment, behaviorType = ViewBag.BehaviorType, behaviorType2 = ViewBag.BehaviorType2, variableType = IwbDataType.GetDataTypeSelectStr(); ViewBag.ActiveMenu = activeMenu; var searchForm = new SearchFormViewModel(new List() { new SearchItem("name","情景名称"), //new SearchItem("sceneCategory","场景类别").SetSelectItem(category,isTree:true), new SearchItem("sceneType","情景类型",FieldType.I).SetSelectItem(sceneType), }); var table = new TableViewModel(IwbConsts.ApiAppUrl + "Scene/GetAll", activeMenu, searchForm) .SetFields(new List() { new FieldItem("id", "编码"), new FieldItem("name", "情景名称"), new FieldItem("sceneCategoryName", "场景类别",isSort:false), new FieldItem("sceneType", "情景类型","SceneTypeFormatter"), new FieldItem("sceneTag", "情景标签"), }); } @section css{ } @* *@
场景类别
@Html.Partial("Table/_Table", table)
@section modal{ @{ var baseInput = new ModalBodyViewModel(new List() { new InputHide("id"), new InputHide("guideNos"), new Input("name", "情景名称"), new Input("sceneCategory", "场景类别").SetSelectOptions(category), new Input("sceneType", "情景类型").SetSelectOptions(sceneType), new Input("sceneTag", "情景标签").SetNotRequired(), new Input("guideNames", "情景引导").SetNotRequired().SetDisabled().SetSearchIcon("qm_guide","modal"), new InputTextarea("description", "情景描述").SetNotRequired(), }); var uploadModal = new ModalViewModel("上传情景", "", new ModalBodyViewModel(new List(){ new InputFile("uploadExcel","上传文件").SetFileOption("excelInfo","excelName","excelExt") }, "upload-form"), "upload-modal"); }
@Html.Partial("Query/_GuideInfo", new QueryWithSelect("guideNos,guideNames", new Dictionary() { ["guideType"] = guideType })) @Html.Partial("Modals/_Modal", uploadModal) } @section scripts { }
@*@Html.DropDownList("hid-type", type)*@