RevIndex.cshtml 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111
  1. @{
  2. ViewBag.Title = "RevIndex";
  3. Layout = "~/Views/Shared/_Layout.cshtml";
  4. }
  5. @using MES.Production.Service;
  6. @using Central.Control.Domain;
  7. @using Ant.Service.Common;
  8. @using Ant.Service.Common.Enums;
  9. @using CommonToolHelper;
  10. @model PageInfo
  11. <div class="row col-lg-12">
  12. <div class="wrapper wrapper-content animated fadeInUp">
  13. <div class="ibox">
  14. <div class="ibox-title">
  15. <h5>已收列表</h5>
  16. <div class="ibox-content">
  17. <!-- search star -->
  18. @using (Ajax.BeginForm("RevIndex", null, new AjaxOptions() { }, new { @id = "form1", @class = "form-horizontal", @method = "get" }))
  19. {
  20. <div class="form-horizontal clearfix">
  21. <div class="col-lg-4 col-sm-3 pl0" style="width:38%;">
  22. <div class="form-group">
  23. <label class="control-label" style="width:50px; float:left;">状态:</label>
  24. <div class="col-lg-8 col-sm-7">
  25. <select id="msg_status" name="msg_status" class="input-sm form-control input-s-sm inline" style="width:auto;" onchange="submit()">
  26. <option value="" selected="selected">全部</option>
  27. <option value="1">已读</option>
  28. <option value="0">未读</option>
  29. </select>
  30. </div>
  31. </div>
  32. </div>
  33. <div class="col-lg-4 col-sm-4" style="float:right;">
  34. <div class="form-group">
  35. <div class="col-lg-12 col-sm-12 input-group">
  36. @Html.TextBox("Search", null, new { @class = "input-sm form-control", @placeholder = "请输入查询关键词" })
  37. <span class="input-group-btn">
  38. <button type="button" onclick="submit()" class="btn btn-sm btn-primary"> 搜索</button>
  39. </span>
  40. </div>
  41. </div>
  42. </div>
  43. </div>
  44. <!-- search end -->
  45. <div id="example_wrapper" class="dataTables_wrapper form-inline dt-bootstrap no-footer">
  46. <table id="example" class="table table-striped table-bordered table-hover dataTables-example dataTable" cellspacing="0" width="100%">
  47. <thead>
  48. <tr>
  49. <th>标题</th>
  50. <th style="width:150px !important;">发送人</th>
  51. <th style="width:140px !important;">发送时间</th>
  52. <th style="width:100px !important;">操作</th>
  53. </tr>
  54. </thead>
  55. <tbody>
  56. @{foreach (var item in Model.List)
  57. {
  58. <tr>
  59. <td style="text-align:left" title="@item.MSGNAME"><a href="javascript:show('@item.ID')"> @item.MSGNAME</a></td>
  60. <td style="text-align:left;">@item.NAME</td>
  61. <td>@item.CREATEDATE</td>
  62. <td>@item.READSTATUS</td>
  63. </tr>
  64. }
  65. }
  66. </tbody>
  67. </table>
  68. <!-- page -->
  69. <div class="bottom">
  70. <div class="dataTables_info" id="example_info" post="status" aria-live="polite">显示第 @Model.BeginPage 至 @Model.EndPage 项结果,共 @Model.Count 项</div>
  71. <div class="dataTables_length" id="example_length">
  72. <label>
  73. 显示
  74. <select name="example_length" onchange="submit()" aria-controls="example" class="form-control input-sm">
  75. <option value="10" @(Model.PageSize == 10 ? "selected" : "")>10</option>
  76. <option value="25" @(Model.PageSize == 25 ? "selected" : "")>25</option>
  77. <option value="50" @(Model.PageSize == 50 ? "selected" : "")>50</option>
  78. <option value="100" @(Model.PageSize == 100 ? "selected" : "")>100</option>
  79. </select> 项结果
  80. </label>
  81. </div>
  82. @CommonHtmlHelper.PaginationPager(Model.Index, Model.PageSize, Model.Count, 7, Model.Url)
  83. <div class="clear"></div>
  84. </div>
  85. <!-- page -->
  86. </div>
  87. }
  88. </div>
  89. </div>
  90. </div>
  91. </div>
  92. </div>
  93. @section scripts{
  94. <script type="text/javascript">
  95. //点击详情
  96. function show(n) {
  97. dig.addModel('消息详情', '/Sys/Msg/RevShow/' + n, 900, 500, function () {
  98. dig.remove();
  99. });
  100. //window.location.href = "/SysManage/Msg/RevShow/" + n;
  101. }
  102. $(function () {
  103. //添加
  104. $('#insert').click(function () {
  105. window.location.href = "/Sys/Msg/Detail/";
  106. });
  107. });
  108. </script>
  109. }