BatchInitPassword.cshtml 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. @model EMIS.ViewModel.SystemView.BatchInitPasswordView
  2. @using Bowin.Web.Controls.Mvc;
  3. @using EMIS.Web.Controls;
  4. @{
  5. ViewBag.Title = "BatchInitPassword";
  6. }
  7. @section scripts{
  8. <script type="text/javascript">
  9. $(function () {
  10. //获取选择的信息ID
  11. windowID = $.SystemGeneral.getUrlParam("WindowID");
  12. userIDs = top.$("#" + windowID).data("inputData");
  13. //top.$("#@(Request["WindowID"])").data("inputData").join(',');
  14. $("#userID").val(userIDs);
  15. });
  16. function Student_BatchInitPasswordSave() {
  17. User_PwdEdit_Save();
  18. }
  19. function Student_BatchSetPasswordSave() {
  20. User_PwdEdit_Save();
  21. }
  22. function User_BatchInitPasswordSave() {
  23. User_PwdEdit_Save();
  24. }
  25. function User_BatchSetPasswordSave() {
  26. User_PwdEdit_Save();
  27. }
  28. function User_PwdEdit_Save() {
  29. var BatchInt = $("#BatchInt")[0].checked;
  30. var pwd = $("#Password")[0].value;
  31. if (BatchInt == true && pwd == "") {
  32. $.messager.alert("系统提示", "请输入自定义密码。");
  33. return;
  34. }
  35. $(document.forms[0]).submit();
  36. }
  37. </script>
  38. }
  39. <div class="easyui-panel" data-options="border:false,fit:true" style="position: relative;">
  40. @using (Ajax.BeginForm(new AjaxOptions
  41. {
  42. OnSuccess = "EMISFunction.FormSuccess",
  43. OnBegin = "EMISFunction.FormSubmit",
  44. OnComplete = "EMISFunction.FormComplete"
  45. }))
  46. {
  47. <div class="p_title">
  48. @if (Request["isView"] == "1")
  49. {
  50. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Edit")</div>
  51. }
  52. @if (Request["isView"] == "2")
  53. {
  54. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Edits")</div>
  55. }
  56. @if (Request["isView"] == "3")
  57. {
  58. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Save")</div>
  59. }
  60. @if (Request["isView"] == "4")
  61. {
  62. <div style="margin-right: 10px; line-height: 30px; font-size: 12px;">@Html.ContextMenuBar("Saves")</div>
  63. }
  64. </div>
  65. <div class="search_list">
  66. @Html.Hidden("userID")
  67. @Html.HiddenFor(x => x.User)
  68. @Html.HiddenFor(x => x.type)
  69. <table cellpadding="0" cellspacing="0" id="BatchInitPassword">
  70. <tr>
  71. <td style="width:20px">@Html.RadioButtonFor(x => x.BatchInt, true)
  72. </td>
  73. <td>@Html.LabelFor(x=>x.Password):
  74. </td>
  75. <td>@Html.PasswordFor(x => x.Password, new { autocomplete = "off" })
  76. </td>
  77. </tr>
  78. <tr>
  79. <td style="width:20px">@Html.RadioButtonFor(x => x.BatchInt, false)
  80. </td>
  81. <td colspan="2">
  82. @if (Request["isView"] == "1" || Request["isView"] == "2")
  83. {
  84. <p>默认密码为A+教职工号</p>
  85. }
  86. @if (Request["isView"] == "3" || Request["isView"] == "4")
  87. {
  88. <p>默认密码为A+学号</p>
  89. }
  90. </td>
  91. </tr>
  92. </table>
  93. </div>
  94. }
  95. </div>