123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122 |
- @using Bowin.Web.Controls.Mvc;
- @using EMISOnline.Entities;
- @using EMISOnline.Web.Controls;
- @{
- ViewBag.Title = "List";
-
- }
- <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;overflow:auto;">
- @Html.Position()
- <div style="float: left; width: 19%; overflow: auto">
- @Html.Tree(new TreeOptions
- {
- ID = "ulTree",
- ItemSourceUrl = Url.Content("~/PaperSetting/ListQuesLibTree"),
- CssClass = "m_video_tree",
- }, null)
- </div>
- <div style="float: left; width: 80%">
- <div class="p_SearchTitle">
- <div style="float: left; margin-left: 10px; font-size: 12px; line-height: 30px;">
- 查询条件</div>
- </div>
- <form id="formQuery" method="post" action="@Url.Content("~/Students/Excel")">
- @Html.Hidden("libaryid")
- <div class="search_keyword">
- <div class="search_input">
- <ul>
- <li class="sn" style="padding-left: 5px;">试题类型:</li>
- <li class="sv">
- @Html.DropdownList(new DropdownListOptions { BindType = DropdownListBindType.SelectAll, ItemSourceUrl = Url.Content("~/SubjectMgr/GetQuestionType?isEmpty=true"), TextField = "Name", ValueField = "base_question_type_id", ID = "QuestionType", Name = "QuestionType" }, new Dictionary<string, string> { { "data-condition", "dgList" } })
- </li>
- <li class="sn" style="padding-left: 5px;">采用频次:</li>
- <li class="sv">
- @Html.TextBox(new TextBoxOptions() { ID = "UsedCountFrom" }, new Dictionary<string, string> { { "style", "width:80px" } })
- 至
- @Html.TextBox(new TextBoxOptions() { ID = "UsedCountTo" }, new Dictionary<string, string> { { "style", "width:80px" } })
- </li>
- <li>
- @Html.Button(new ButtonOptions() { ID = "btnSearch", Text = "查 询" })
- @Html.Button(new ButtonOptions() { ID = "btnAdd", Text = "新增" })
- @Html.Button(new ButtonOptions() { ID = "btnDel", Text = "删除" })
- </li>
- </ul>
- <ul>
- <li class="sn" style="padding-left: 5px;">试题内容:</li>
- <li class="sv">
- @Html.TextBox("Content")
- </li>
- <li class="sn" style="padding-left: 5px;">难度系数:</li>
- <li class="sv">
- @Html.TextBox(new TextBoxOptions() { ID = "DifficultyFrom" }, new Dictionary<string, string> { { "style", "width:80px" } })
- 至
- @Html.TextBox(new TextBoxOptions() { ID = "DifficultyTo" }, new Dictionary<string, string> { { "style", "width:80px" } })
- </li>
- <li class="sn" style="padding-left: 5px;">试题状态:</li>
- <li class="sv">
- @Html.DropdownList(new DropdownListOptions { BindType = DropdownListBindType.SelectAll, ItemSourceUrl = Url.Content("~/Campus/CampusDropdownListBanid"), ID = "IsValid", Name = "IsValid" }, new Dictionary<string, string> { { "data-condition", "dgList" } })
- </li>
- </ul>
- </div>
- </div>
- </form>
-
- <div class="search_list">
- @Html.DataGrid(new DataGridOptions
- {
- Columns = new List<DataGridColumn>()
- {
- new CheckBoxFieldColumn{ HeaderText="", FieldName="UserID"},
- new LinkButtonColumn { FieldName="content", HeaderText="题干内容", Align=AlignStyle.Center,Handle="view" , Width=400 },
- new BoundFieldColumn { FieldName="base_question_type_name", HeaderText="试题类型", Align=AlignStyle.Center },
- new BoundFieldColumn { FieldName="difficulty_degree", HeaderText="难度", Align=AlignStyle.Center},
- new BoundFieldColumn { FieldName="used_count", HeaderText="采用频次", Align=AlignStyle.Center },
- new BoundFieldColumn { FieldName="test_question_libary_name", HeaderText="题库", Align=AlignStyle.Center },
- new BoundFieldColumn { FieldName="isEnable", HeaderText="是否有效", Align=AlignStyle.Center },
- new BoundFieldColumn { FieldName="created_date", HeaderText="创建日期", Align=AlignStyle.Center, Formatter= Formatter.OnlyYearMonthDay },
- new LinkButtonColumn { HeaderText="操作", Align=AlignStyle.Center , Text="编辑", Handle="edit" },
- },
- IsCheckOnSelect = true,
- DataSourceUrl = Url.Content("~/SubjectMgr/List"),
- ID = "dgList",
- IsPagination = true,
- IsShowRowNumbers = true,
- IsSingleSelect = false,
- IsVerticalExpand = true,
- IsAutoHeight = false,
- })
- </div>
- </div>
- </div>
- @section scripts{
- <script type="text/javascript">
- $(function () {
- $('#btnAdd').click(function () {
- var node = $('#ulTree').tree('getSelected');
- if (node == null) {
- alertMsg("请选择题库!");
- return false;
- }
- var libaryid = node == null ? "" : node.id;
- window.location.href = "@Url.Content("~/SubjectMgr/TestQuestionAdd")?libaryid=" + libaryid;
- })
- $("#btnSearch").click(function () {
- var node = $('#ulTree').tree('getSelected');
- var libaryid = node == null ? "" : node.id;
- $('#libaryid').val(libaryid);
- var queryForm = $("#formQuery").getFormData();
- $("#dgList").cmsXDataTable("load", queryForm);
- });
- })
- function edit(index, row) {
- var node = $('#ulTree').tree('getSelected');
- var libaryid = node == null ? "" : node.id;
- window.location.href = "@Url.Content("~/SubjectMgr/TestQuestionAdd")?test_question_id=" + row.test_question_Id + "&ac=edit&libaryid=" + libaryid;
- }
- function view(index, row) {
- window.location.href = "@Url.Content("~/SubjectMgr/TestQuestionAdd")?test_question_id=" + row.test_question_Id;
- }
- </script>
- }
|