Quellcode durchsuchen

临时人员模块绑定字段修改

ly vor 5 Monaten
Ursprung
Commit
7ca52d0be5

+ 3 - 1
src/main/java/com/liang/controller/LsUserController.java

@@ -82,12 +82,14 @@ public class LsUserController {
82 82
                               @RequestParam("limit") Integer pageSize,
83 83
                               @RequestParam(required = false, defaultValue = "", value = "xm") String xm,
84 84
                               @RequestParam(required = false, defaultValue = "", value = "zt") Integer zt,
85
-                              @RequestParam(required = false, defaultValue = "", value = "xl") String xl){
85
+                              @RequestParam(required = false, defaultValue = "", value = "xl") String xl,
86
+                              @RequestParam(required = false, defaultValue = "", value = "sfzh") String sfzh){
86 87
         Map<String, String> paraMap = new HashMap<>();
87 88
         PageHelper.startPage(pageNum, pageSize);
88 89
         if (zt == null){
89 90
             paraMap.put("xm", xm);
90 91
             paraMap.put("xl",xl);
92
+            paraMap.put("sfzh",sfzh);
91 93
             List<SysLsUserEntity> list = lsUserService.UserAll(paraMap);
92 94
             PageInfo<SysLsUserEntity> pageinfo = new PageInfo<>(list);
93 95
             // 取出查询结果

+ 9 - 1
src/main/java/com/liang/controller/StaSourceFeeController.java

@@ -1,6 +1,7 @@
1 1
 package com.liang.controller;
2 2
 
3 3
 import cn.hutool.core.util.StrUtil;
4
+import com.github.pagehelper.PageHelper;
4 5
 import com.github.pagehelper.PageInfo;
5 6
 import com.liang.common.JsonTool;
6 7
 import com.liang.common.base.BaseController;
@@ -178,8 +179,15 @@ public class StaSourceFeeController extends BaseController {
178 179
     //资料费用全部及条件查询
179 180
     @ResponseBody
180 181
     @RequestMapping(value = "/searchData", method = RequestMethod.POST)
181
-    public BaseResult searchData(@RequestParam(required = false, defaultValue = "", value = "MC") String mc, @RequestParam(required = false, defaultValue = "", value = "TSMC") String tsmc, @RequestParam(required = false, defaultValue = "", value = "CBS") String cbs, @RequestParam(required = false, defaultValue = "", value = "QSRQ") String qsrq, @RequestParam(required = false, defaultValue = "", value = "JZRQ") String jzrq) {
182
+    public BaseResult searchData(@RequestParam("page") Integer pageNum,
183
+                                 @RequestParam("limit") Integer pageSize,
184
+                                 @RequestParam(required = false, defaultValue = "", value = "MC") String mc,
185
+                                 @RequestParam(required = false, defaultValue = "", value = "TSMC") String tsmc,
186
+                                 @RequestParam(required = false, defaultValue = "", value = "CBS") String cbs,
187
+                                 @RequestParam(required = false, defaultValue = "", value = "QSRQ") String qsrq,
188
+                                 @RequestParam(required = false, defaultValue = "", value = "JZRQ") String jzrq) {
182 189
         List<HashMap<String, Object>> staFeasibilityreport = staSourceFeeService.searchSourceCost(mc, tsmc, cbs, qsrq, jzrq);
190
+        PageHelper.startPage(pageNum, pageSize);
183 191
         PageInfo<HashMap<String, Object>> pageinfo = new PageInfo<>(staFeasibilityreport);
184 192
         List<HashMap<String, Object>> rows = pageinfo.getList();
185 193
         int total = (int) pageinfo.getTotal();

+ 3 - 0
src/main/resources/mapper/LsUserDao.xml

@@ -39,6 +39,9 @@
39 39
                  <if test="zt != null and zt != ''">
40 40
                  and ZT = #{zt}
41 41
                  </if>
42
+                    <if test="sfzh != null and sfzh != ''">
43
+                        and SFZH = #{sfzh}
44
+                    </if>
42 45
                  order by cjsj DESC
43 46
 
44 47
     </select>

+ 1 - 39
src/main/resources/templates/lsuserinfo/adds.html

@@ -48,8 +48,7 @@
48 48
             </div>
49 49
             <label class="layui-form-label" style="width: 80px;top: 10px">毕业学校</label>
50 50
             <div class="layui-input-inline" style="width: 250px;top: 10px">
51
-                <input type="hidden" id="byxx" name="byxy" class="layui-input">
52
-                <input type="text" id="byxxmc" name="byxxmc" class="layui-input">
51
+                <input type="text" id="byxy" name="byxy" class="layui-input" th:value="${ls.byxy}">
53 52
             </div>
54 53
 
55 54
             <label class="layui-form-label required" style="width:80px;top: 20px;">电话</label>
@@ -105,44 +104,7 @@
105 104
         laydate.render({
106 105
             elem: '#dqsj'
107 106
         });
108
-        //毕业学校
109
-        var index3 = layer.load(0, {shade: 0.1});
110
-        AjaxUtil.get({
111
-            url: AjaxUtil.ctx + 'baseSchool/list',
112
-            success: function (res) {
113
-                layer.close(index3);
114
-                var datalist = [];
115
-                for (let item of res.data) {
116
-                    item.value = item.id;
117
-                    item.label = item.name;
118
-                    datalist.push(item);
119
-                }
120
-                // 扁平数据转树
121
-                var options = arrayToTree(datalist, "0");
122
-
123
-                // 初始化cascader实例
124
-                cascader = layCascader({
125
-                    elem: '#byxxmc',
126
-                    clearable: true,
127
-                    props: {
128
-                        checkStrictly: false // 配置选择任意一级选项
129
-                    },
130
-                    options: options
131
-                });
132 107
 
133
-                // 监听cascader变化
134
-                cascader.changeEvent(function (value, node) {
135
-                    $("#byxx").val(value);
136
-                    $("#byxxmc").val(node.data.label);
137
-                    // 主动关闭面板
138
-                    cascader.close();
139
-                });
140
-            },
141
-            error: function (error) {
142
-                layer.close(index3);
143
-                Message.error('获取学校信息失败!', 1000);
144
-            }
145
-        });
146 108
         //监听专业专长
147 109
         form.on('select(zyzc)', function (data) {
148 110
             let text = data.elem.selectedOptions[0].text;

+ 14 - 34
src/main/resources/templates/lsuserinfo/list.html

@@ -35,6 +35,12 @@
35 35
                                 </div>
36 36
                             </div>
37 37
                         </div>
38
+                        <div class="layui-inline">
39
+                            <label class="layui-form-label" style="width: 80px">身份证号</label>
40
+                            <div class="layui-input-inline">
41
+                                <input type="text" name="sfzh" autocomplete="off" class="layui-input">
42
+                            </div>
43
+                        </div>
38 44
                         <div class="layui-inline">
39 45
                             <div class="layui-inline">
40 46
                                 <label class="layui-form-label " style="width: 40px;">状态</label>
@@ -278,10 +284,8 @@
278 284
                         data: JSON.stringify(data),
279 285
                         success: function (res) {
280 286
                             if (res.code === 0) {
281
-                                Message.success(1500, res.message, function () {
282
-                                    // 重载表格
283
-                                    currTable.reload();
284
-                                });
287
+                                Message.success(1500, res.message);
288
+                                table.reload('currentTableId');
285 289
                             } else {
286 290
                                 Message.error(res.message, 1000);
287 291
                             }
@@ -297,7 +301,7 @@
297 301
                 AjaxUtil.get({
298 302
                     url:AjaxUtil.ctx +'lsUser/getAll',
299 303
                     success: function(res){
300
-                        table.exportFile('currentTableId',res.data,'xls');
304
+                        table.exportFile('currentTableId',res.data,'xlsx');
301 305
                     },
302 306
                     error:function (error) {
303 307
                         Message.error(error,2000)
@@ -347,29 +351,18 @@
347 351
                         url: AjaxUtil.ctx + "lsUser/delete/" + data.id,
348 352
                         success: function (res) {
349 353
                             if (res.code === 0) {
350
-                                layer.msg('删除成功', {icon: 6}, function () {
351
-                                    // 表格重载
352
-                                    table.reload('currentTableId', {
353
-                                        data: data,  // 更新后的数据源
354
-                                        page: false, // 不分页处理
355
-                                        limit: data.length // 限制数据条数,取数据源长度
356
-                                    }, true);
357
-                                })
354
+                                layer.msg(res.message);
355
+                                table.reload('currentTableId');
358 356
                             } else {
359
-                                layer.msg('删除失败', {icon: 5}, function () {
360
-                                    // 表格重载
361
-                                    table.reload('currentTableId', {
362
-                                        data: data,  // 更新后的数据源
363
-                                        page: false, // 不分页处理
364
-                                        limit: data.length // 限制数据条数,取数据源长度
365
-                                    }, true);
366
-                                });
357
+                                layer.msg(res.message);
358
+                                table.reload('currentTableId');
367 359
                             }
368 360
                         },
369 361
                         error: function (error) {
370 362
 
371 363
                             layer.alert('服务器睡着了', {icon: 5});
372 364
                             console.log(error);
365
+                            table.reload('currentTableId');
373 366
                         }
374 367
                     });
375 368
                 });
@@ -380,19 +373,6 @@
380 373
 
381 374
     });
382 375
 
383
-    function updateTable() {
384
-        // 表格重载
385
-        table.reload('currentTableId', {
386
-            data: data,  // 更新后的数据源
387
-            page: false, // 不分页处理
388
-            limit: data.length // 限制数据条数,取数据源长度
389
-        }, true);
390
-
391
-    }
392
-
393
-    function setUpdateFlag() {
394
-        updateflag = 1;
395
-    }
396 376
 </script>
397 377
 </body>
398 378
 </html>