浏览代码

报账页面BUG修复,页面优化

ly 1 周之前
父节点
当前提交
998a2bd0b0

+ 1 - 1
src/main/java/com/liang/controller/PrjContractController.java

@@ -175,7 +175,7 @@ public class PrjContractController extends BaseController {
175
      */
175
      */
176
     @RequestMapping(value = "/forAdd", method = RequestMethod.GET)
176
     @RequestMapping(value = "/forAdd", method = RequestMethod.GET)
177
     public String forAdd() {
177
     public String forAdd() {
178
-        return "prjcontract/add";
178
+        return "prjcontract/new_add";
179
     }
179
     }
180
 
180
 
181
     /**
181
     /**

+ 5 - 1
src/main/java/com/liang/controller/StaReimbursementController.java

@@ -1,5 +1,7 @@
1
 package com.liang.controller;
1
 package com.liang.controller;
2
 
2
 
3
+import cn.hutool.json.JSON;
4
+import cn.hutool.json.JSONObject;
3
 import com.fasterxml.jackson.databind.ObjectMapper;
5
 import com.fasterxml.jackson.databind.ObjectMapper;
4
 import com.github.pagehelper.PageHelper;
6
 import com.github.pagehelper.PageHelper;
5
 import com.github.pagehelper.PageInfo;
7
 import com.github.pagehelper.PageInfo;
@@ -29,6 +31,7 @@ import org.springframework.stereotype.Controller;
29
 import org.springframework.transaction.annotation.Transactional;
31
 import org.springframework.transaction.annotation.Transactional;
30
 import org.springframework.ui.Model;
32
 import org.springframework.ui.Model;
31
 import org.springframework.web.bind.annotation.*;
33
 import org.springframework.web.bind.annotation.*;
34
+import springfox.documentation.spring.web.json.Json;
32
 
35
 
33
 import javax.annotation.Resource;
36
 import javax.annotation.Resource;
34
 import javax.servlet.http.HttpServletResponse;
37
 import javax.servlet.http.HttpServletResponse;
@@ -476,8 +479,9 @@ public class StaReimbursementController extends BaseController {
476
      */
479
      */
477
     @ResponseBody
480
     @ResponseBody
478
     @RequestMapping(value = "/doUpdate", method = RequestMethod.POST)
481
     @RequestMapping(value = "/doUpdate", method = RequestMethod.POST)
479
-    public BaseResult doUpdate(StaReimbursement reimbursement) {
482
+    public BaseResult doUpdate(@RequestBody String reimbursements){
480
         // 获取当前人员账户
483
         // 获取当前人员账户
484
+        StaReimbursement reimbursement = JsonTool.parseObject(reimbursements,StaReimbursement.class);
481
         SysUserInfo  sysUserInfo = getSysUserInfo();
485
         SysUserInfo  sysUserInfo = getSysUserInfo();
482
         StaBudgetapproval staBudgetapproval =  staBudgetapprovalService.getBayID(reimbursement.getFysq());
486
         StaBudgetapproval staBudgetapproval =  staBudgetapprovalService.getBayID(reimbursement.getFysq());
483
         StaReimbursement reimbursement1 = staReimbursementService.queryById(reimbursement.getId());
487
         StaReimbursement reimbursement1 = staReimbursementService.queryById(reimbursement.getId());

+ 7 - 0
src/main/java/com/liang/entity/StaReimbursement.java

@@ -111,5 +111,12 @@ public class StaReimbursement implements Serializable {
111
      */
111
      */
112
     private Integer bzjh;
112
     private Integer bzjh;
113
 
113
 
114
+    private Double slval;
115
+
116
+    private String file;
117
+
118
+    private String htmc;
119
+
120
+
114
 }
121
 }
115
 
122
 

+ 4 - 1
src/main/resources/templates/prjcontract/add.html

@@ -214,6 +214,9 @@
214
                         </div>
214
                         </div>
215
                         <!-- 右侧悬浮按钮 -->
215
                         <!-- 右侧悬浮按钮 -->
216
                         <div class="right-bottom-btn" style="margin-bottom: 5px">
216
                         <div class="right-bottom-btn" style="margin-bottom: 5px">
217
+                            <button type="button" class="layui-btn" lay-submit lay-filter="saveBtn2">
218
+                                <i class="layui-icon layui-icon-ok"></i>保存
219
+                            </button>
217
                             <button class="layui-btn" lay-filter="cancleBtn">
220
                             <button class="layui-btn" lay-filter="cancleBtn">
218
                                 <i class="layui-icon layui-icon-close"></i>取消
221
                                 <i class="layui-icon layui-icon-close"></i>取消
219
                             </button>
222
                             </button>
@@ -240,7 +243,7 @@
240
     var bzjh = [];
243
     var bzjh = [];
241
     var fkjh = [];
244
     var fkjh = [];
242
 
245
 
243
-    layui.use(['form', 'table', 'treeTable', 'layCascader', 'upload','laydate'], function () {
246
+    layui.use(['form', 'table', 'treeTable', 'layCascader', 'upload','laydate','step'], function () {
244
         var form = layui.form,
247
         var form = layui.form,
245
             table = layui.table,
248
             table = layui.table,
246
             layer = layui.layer,
249
             layer = layui.layer,

+ 0 - 1
src/main/resources/templates/prjcontract/list.html

@@ -11,7 +11,6 @@
11
 <body>
11
 <body>
12
 <div class="layuimini-container">
12
 <div class="layuimini-container">
13
     <div class="layuimini-main">
13
     <div class="layuimini-main">
14
-
15
         <fieldset class="table-search-fieldset">
14
         <fieldset class="table-search-fieldset">
16
             <legend>搜索信息(<b>收起-展开</b>)</legend>
15
             <legend>搜索信息(<b>收起-展开</b>)</legend>
17
             <div id="search-div" style="margin: 5px 10px -10px 0px">
16
             <div id="search-div" style="margin: 5px 10px -10px 0px">

文件差异内容过多而无法显示
+ 1117 - 0
src/main/resources/templates/prjcontract/new_add.html


+ 23 - 3
src/main/resources/templates/reimburse/update.html

@@ -638,16 +638,36 @@
638
             data.field.sl = data.field.slval;
638
             data.field.sl = data.field.slval;
639
             var index = layer.load(0, {shade: 0.1});
639
             var index = layer.load(0, {shade: 0.1});
640
 
640
 
641
-            console.log(data.field)
641
+            console.log(data.field);
642
+
643
+            var datas = {
644
+               "bhsje": data.field.id,
645
+                "bxpz": data.field.bzje,
646
+                "bzje": data.field.bzje,
647
+                "bzjh": data.field.bzjh,
648
+                "file": data.field.file,
649
+                "fylb": data.field.fylb,
650
+                "fylbmc" : data.field.fylbmc,
651
+                "fysq" : data.field.fysq,
652
+                "fylbmc" : data.field.fylbmc,
653
+                "htmc": data.field.htmc,
654
+                "id": data.field.id,
655
+                "mc": data.field.mc,
656
+                "sf": data.field.sf,
657
+                "sl": data.field.sl,
658
+                "slval": data.field.slval,
659
+                "sqje": data.field.sqje
660
+            }
661
+            console.log(datas);
642
             AjaxUtil.post({
662
             AjaxUtil.post({
643
                 url: AjaxUtil.ctx + "staReimbursement/doUpdate",
663
                 url: AjaxUtil.ctx + "staReimbursement/doUpdate",
644
-                data: data.field,
664
+                data: JSON.stringify(data.field),
665
+                contentType: "application/json",
645
                 success: function (res) {
666
                 success: function (res) {
646
                     layer.close(index);
667
                     layer.close(index);
647
                     if (res.code === 0) {
668
                     if (res.code === 0) {
648
                         Message.success(1500, res.message, function () {
669
                         Message.success(1500, res.message, function () {
649
                             parent.setUpdateFlag();
670
                             parent.setUpdateFlag();
650
-
651
                             //差旅费
671
                             //差旅费
652
                             var travleExpenses = [];
672
                             var travleExpenses = [];
653
                             for (const item of dataExpense) {
673
                             for (const item of dataExpense) {