user_index.html 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8" />
  5. <meta name="keywords" content="dongke,mes,ibossmes">
  6. <meta name="description" content="制造企业生产过程执行管理系统">
  7. <meta name="author" content="xuwei">
  8. <title>东科软件</title>
  9. <script src="/plugins/xeasyui/xeasyui.min.js"></script>
  10. <link href="/plugins/xeasyui/toolbar.min.css" rel="stylesheet" />
  11. </head>
  12. <body>
  13. <!--工具条-->
  14. <div id="tb" class="i-toolbar">
  15. <a href="javascript:void(0)" style="display:none" id="btnInsert" title="添加" class="easyui-linkbutton" iconcls="icon-add" plain="true" onclick="tbAdd()">添加</a>
  16. <a href="javascript:void(0)" style="display:none" id="btnUpdate" title="编辑" class="easyui-linkbutton" iconcls="icon-edit" plain="true" onclick="tbEdit()">修改</a>
  17. <a href="javascript:void(0)" style="display:none" id="btnDelete" title="删除" class="easyui-linkbutton" iconcls="icon-remove" plain="true" onclick="tbDelete()">删除</a>
  18. <a href="javascript:void(0)" style="display:none" id="btnDetail" title="详细" class="easyui-linkbutton" iconcls="icon-detail" plain="true" onclick="tbDetail()">详细</a>
  19. <a href="javascript:void(0)" style="display:none" id="btnRight" title="权限分配" class="easyui-linkbutton" iconcls="icon-edit" plain="true" onclick="tbRight()">权限分配</a>
  20. <a href="javascript:void(0)" style="display:none" id="btnCheckbox" title="显示复选框" class="easyui-linkbutton" iconcls="icon-ok" plain="true" toggle="true" onclick="tbCheck()">复选</a>
  21. <a href="javascript:void(0)" style="display:none" id="btnSearch" title="搜索" class="easyui-linkbutton" iconcls="icon-search" plain="true" toggle="true" onclick="tbSearch()">搜索</a>
  22. <a href="javascript:void(0)" style="display:none" id="btnExport" title="导出" class="easyui-linkbutton" iconcls="icon-excel" plain="true" onclick="tbExport()">导出</a>
  23. <a href="javascript:void(0)" id="btnReload" title="刷新" class="easyui-linkbutton" iconcls="icon-reload" plain="true" onclick="tbReload()">刷新</a>
  24. <div id="tbSearchDiv" style="display:none;padding:10px;">
  25. <form id="ff">
  26. <div>
  27. <!--用户ID:
  28. <input class="easyui-textbox" id="USERID" name="USERID" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">-->
  29. 用户编码:
  30. <input class="easyui-textbox" id="USERCODE" name="USERCODE" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  31. 用户名:
  32. <input class="easyui-textbox" id="USERNAME" name="USERNAME" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  33. <!--所属部门:
  34. <input class="easyui-textbox" id="ORGANIZATIONID" name="ORGANIZATIONID" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  35. CANSMARTLOGIN:
  36. <input class="easyui-textbox" id="CANSMARTLOGIN" name="CANSMARTLOGIN" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  37. ISWORKER:
  38. <input class="easyui-textbox" id="ISWORKER" name="ISWORKER" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  39. REMARKS:
  40. <input class="easyui-textbox" id="REMARKS" name="REMARKS" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  41. ACCOUNTCODE:
  42. <input class="easyui-textbox" id="ACCOUNTCODE" name="ACCOUNTCODE" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  43. LIMITSTARTTIME:
  44. <input class="easyui-textbox" id="LIMITSTARTTIME" name="LIMITSTARTTIME" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  45. LIMITENDTIME:
  46. <input class="easyui-textbox" id="LIMITENDTIME" name="LIMITENDTIME" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  47. CANPCLOGIN:
  48. <input class="easyui-textbox" id="CANPCLOGIN" name="CANPCLOGIN" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  49. ISPUBLICBODY:
  50. <input class="easyui-textbox" id="ISPUBLICBODY" name="ISPUBLICBODY" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  51. CANLOGINPRD:
  52. <input class="easyui-textbox" id="CANLOGINPRD" name="CANLOGINPRD" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  53. CANLOGINMBC:
  54. <input class="easyui-textbox" id="CANLOGINMBC" name="CANLOGINMBC" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  55. POST:
  56. <input class="easyui-textbox" id="POST" name="POST" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  57. BARCODEPRINTERID:
  58. <input class="easyui-textbox" id="BARCODEPRINTERID" name="BARCODEPRINTERID" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  59. ISGROUTINGWORKER:
  60. <input class="easyui-textbox" id="ISGROUTINGWORKER" name="ISGROUTINGWORKER" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">
  61. PLCID:
  62. <input class="easyui-textbox" id="PLCID" name="PLCID" data-options="required:false,prompt:'',tipPosition:'top'" style="width:80px;height:32px;">-->
  63. <a href="javascript:void(0)" id="btnSearchSubmit" title="清空" class="easyui-linkbutton" plain="false" onclick="$('#ff').form('clear')">清空</a>
  64. <a href="javascript:void(0)" id="btnSearchSubmit" title="搜索" class="easyui-linkbutton" plain="false" onclick="tbSearchSubmit()">搜索</a>
  65. </div>
  66. </form>
  67. </div>
  68. </div>
  69. <!--表格-->
  70. <table id="dg" data-options="toolbar: '#tb',onDblClickRow: dgDblclickrow,showFooter:false">
  71. <!--
  72. <thead data-options="frozen:true">
  73. <tr>
  74. <th data-options="field:'标识',align:'left',sortable:true">标识</th>
  75. </tr>
  76. </thead>
  77. -->
  78. <thead>
  79. <tr>
  80. <th data-options="field:'SID',title:'SID',width:220,align:'left',checkbox:true,hidden:true">SID</th>
  81. <th data-options="field:'ORGANIZATIONFULLNAME',title:'部门',align:'left',sortable:true"></th>
  82. <th data-options="field:'POSTNAME',title:'职务',align:'left',sortable:true"></th>
  83. <!--<th data-options="field:'USERID',title:'用户ID',align:'left',sortable:true"></th>-->
  84. <th data-options="field:'USERCODE',title:'用户编码',align:'left',sortable:true"></th>
  85. <th data-options="field:'USERNAME',title:'用户名',align:'left',sortable:true"></th>
  86. <th data-options="field:'CANSMARTLOGIN',title:'PDA登录',align:'left',sortable:true"></th>
  87. <th data-options="field:'CANPCLOGIN',title:'PC登录',align:'left',sortable:true"></th>
  88. <th data-options="field:'ISWORKER',title:'生产工号',align:'left',sortable:true"></th>
  89. <th data-options="field:'ISGROUTINGWORKER',title:'注浆工号',align:'left',sortable:true"></th>
  90. <th data-options="field:'ISPUBLICBODY',title:'公坯标识',align:'left',sortable:true"></th>
  91. <th data-options="field:'BARCODEPRINTERID',title:'条码打印机',align:'left',sortable:true"></th>
  92. <th data-options="field:'PLCID',title:'PLC连接参数',align:'left',sortable:true"></th>
  93. <th data-options="field:'LIMITSTARTTIME',title:'限制登录开始',align:'left',sortable:true"></th>
  94. <th data-options="field:'LIMITENDTIME',title:'限登录时间结束',align:'left',sortable:true"></th>
  95. <th data-options="field:'VALUEFLAG',title:'有效标识',align:'left',sortable:true"></th>
  96. <!--<th data-options="field:'ACCOUNTID',title:'账套ID',align:'left',sortable:true"></th>-->
  97. <th data-options="field:'ACCOUNTCODE',title:'帐套编码',align:'left',sortable:true"></th>
  98. <!--<th data-options="field:'CREATEUSERID',title:'创建工号ID',align:'left',sortable:true"></th>-->
  99. <th data-options="field:'CREATETIME',title:'创建时间',align:'left',sortable:true"></th>
  100. <!--<th data-options="field:'UPDATEUSERID',title:'更新工号ID',align:'left',sortable:true"></th>-->
  101. <th data-options="field:'UPDATETIME',title:'更新时间',align:'left',sortable:true"></th>
  102. </tr>
  103. </thead>
  104. </table>
  105. <script type="text/javascript">
  106. //加载完成
  107. $(function () {
  108. //加载按钮
  109. $('#tb').buttonLoad({
  110. url:'user.ashx?m=b'
  111. });
  112. //加载表格数据
  113. tbSearchSubmit();
  114. $('#USERCODE').textbox('textbox').bind('keyup', function (e) {
  115. this.value = this.value.toUpperCase();
  116. });
  117. });
  118. //添加按钮
  119. function tbAdd() {
  120. $('#dg').datagridDialog({
  121. title: '添加数据',
  122. width: 640,
  123. height: 480,
  124. url: 'user_add.html'
  125. });
  126. }
  127. //修改按钮
  128. function tbEdit() {
  129. $('#dg').datagridDialog({
  130. title: '修改数据',
  131. width: 640,
  132. height: 480,
  133. url: 'user_edit.html',
  134. requireSelect: true
  135. });
  136. }
  137. //删除按钮
  138. function tbDelete() {
  139. $('#dg').datagridPost({
  140. title:'删除操作',
  141. url: 'user.ashx?m=d',
  142. onValidate: function (r) { return true; }
  143. });
  144. }
  145. //详细按钮
  146. function tbDetail() {
  147. $('#dg').datagridDialog({
  148. title: '详细数据',
  149. width: 640,
  150. height: 480,
  151. url: 'user_detail.html',
  152. requireSelect: true
  153. });
  154. }
  155. //功能权限
  156. function tbRight() {
  157. $('#dg').datagridDialog({
  158. title: '功能权限',
  159. width: 640,
  160. height: 600,
  161. url: 'user_right.html',
  162. requireSelect: true
  163. });
  164. }
  165. //复选按钮
  166. function tbCheck() {
  167. $('#dg').datagridCheckbox({
  168. buttonid: 'btnCheckbox',
  169. valuefield: 'SID'
  170. });
  171. }
  172. //搜索按钮
  173. function tbSearch() {
  174. $('#tbSearchDiv').toggle();
  175. $('#dg').datagrid('resize');
  176. }
  177. //搜索提交
  178. function tbSearchSubmit() {
  179. $('#dg').datagridLoad({
  180. title: '用户管理',
  181. idField: 'SID',
  182. queryParams: $('#ff').serializeJson(),
  183. url: 'user.ashx?m=s'
  184. });
  185. }
  186. //导出
  187. function tbExport() {
  188. $('#dg').datagridExport({
  189. fileName: '导出数据(TP_MST_USER).xls',
  190. workSheet: '导出数据(TP_MST_USER)'
  191. });
  192. }
  193. //刷新
  194. function tbReload() {
  195. tbSearchSubmit();
  196. }
  197. //表格双击
  198. function dgDblclickrow(rowIndex, rowData) {
  199. tbDetail();
  200. }
  201. function formatterTrueFalse(value, row, index) { return value == 'True' ? '是' : '否'; }
  202. function stylerTrueFalse(value, row, index) { return value == 'True' ? 'color:black' : 'color:red'; }
  203. </script>
  204. </body>
  205. </html>