瀏覽代碼

工单修改 附件等

liyuanyuan 2 年之前
父節點
當前提交
2a05bb890c

+ 242 - 64
zxkf-api/src/main/java/api/controller/order/WorkOrderBaseController.java

@@ -1,13 +1,14 @@
1 1
 package api.controller.order;
2 2
 
3 3
 import api.entity.database.order.WorkOrderOperateLog;
4
+import api.entity.database.system.Customer;
4 5
 import api.entity.database.system.DictData;
6
+import api.entity.database.system.SysAccessories;
5 7
 import api.entity.database.system.User;
6 8
 import api.entity.view.order.WorkOrderBaseView;
7 9
 import api.mapper.system.UserMapper;
8 10
 import api.service.order.IWorkOrderOperateLogService;
9
-import api.service.system.IDictDataService;
10
-import api.service.system.IUserService;
11
+import api.service.system.*;
11 12
 import api.util.annotation.Anonymous;
12 13
 import com.alibaba.fastjson2.JSON;
13 14
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
@@ -23,11 +24,17 @@ import api.util.enums.BusinessType;
23 24
 import api.util.helper.StringHelper;
24 25
 import io.swagger.annotations.Api;
25 26
 import io.swagger.annotations.ApiOperation;
27
+import lombok.var;
26 28
 import org.springframework.beans.factory.annotation.Autowired;
27 29
 import org.springframework.web.bind.annotation.*;
28 30
 
31
+import java.net.InetAddress;
32
+import java.net.UnknownHostException;
29 33
 import java.text.SimpleDateFormat;
34
+import java.time.LocalDate;
30 35
 import java.time.LocalDateTime;
36
+import java.time.LocalTime;
37
+import java.time.format.DateTimeFormatter;
31 38
 import java.util.*;
32 39
 
33 40
 @Api(value = "wo_workorderbase",tags = "wo_workorderbase")
@@ -35,6 +42,10 @@ import java.util.*;
35 42
 @RequestMapping("/order/workorderbase")
36 43
 public class WorkOrderBaseController extends BaseController {
37 44
     @Autowired
45
+    private ICustomerService customerService;
46
+    @Autowired
47
+    private IConfigService configService;
48
+    @Autowired
38 49
     private IWorkOrderBaseService workorderbaseService;
39 50
     @Autowired
40 51
     private IDictDataService dictDataService;
@@ -46,8 +57,11 @@ public class WorkOrderBaseController extends BaseController {
46 57
     @Autowired
47 58
     private IWorkOrderOperateLogService workorderoperatelogService;
48 59
 
60
+    @Autowired
61
+    private ISysAccessoriesService sysaccessoriesService;
62
+
49 63
     @ApiOperation("列表")
50
-    @Log(title = "查询wo_workorderbase列表",businessType = BusinessType.QUERY)
64
+    @Log(title = "查询wo_workorderbase列表", businessType = BusinessType.QUERY)
51 65
     @GetMapping
52 66
     @Anonymous
53 67
     public AjaxResult getList(WorkOrderBase input, PageInput pageInput) {
@@ -67,40 +81,16 @@ public class WorkOrderBaseController extends BaseController {
67 81
         if (page != null) {
68 82
             IPage<WorkOrderBase> iPage = workorderbaseService.getListPage(page, qw);
69 83
 
70
-         List<WorkOrderBase> returnlist=iPage.getRecords();
71
-            List<WorkOrderBaseView> orderViewList=new ArrayList<>();
84
+            List<WorkOrderBase> returnlist = iPage.getRecords();
85
+            List<WorkOrderBaseView> orderViewList = new ArrayList<>();
72 86
             //处理数据
73
-            if (returnlist!=null && returnlist.size()>0)
74
-            {
75
-                for (WorkOrderBase orderBase:returnlist) {
76
-
77
-                    WorkOrderBaseView ov = JSON.parseObject(JSON.toJSONString(orderBase), WorkOrderBaseView.class);
78
-                   if (orderBase.getProject()>0)
79
-                   {
80
-                       DictData dicdata=  dictDataService.getEntity(orderBase.getProject());
81
-
82
-                       ov.setProjectname(dicdata.getDictValue());
83
-                   }
84
-                   if (orderBase.getWorkordercate()>0)
85
-                   {
86
-                       DictData dicdata=  dictDataService.getEntity(orderBase.getWorkordercate());
87
-                       ov.setWorkordercatename(dicdata.getDictValue());
88
-                   }
89
-                    if (!StringHelper.isEmpty(orderBase.getDealuser()))
90
-                    {
91
-                        User user = userMapper.selectUserByUserName(orderBase.getDealuser());
92
-                        ov.setDealusername(user.getNickName());
93
-                    }
94
-                    if (!StringHelper.isEmpty(orderBase.getCreateuser()))
95
-                    {
96
-                        User user = userMapper.selectUserByUserName(orderBase.getCreateuser());
97
-                        ov.setCreateusername(user.getNickName());
98
-                    }
87
+            if (returnlist != null && returnlist.size() > 0) {
88
+                for (WorkOrderBase orderBase : returnlist) {
89
+
90
+                    WorkOrderBaseView ov = trans(orderBase);
99 91
 
100 92
                     orderViewList.add(ov);
101 93
                 }
102
-                
103
-
104 94
             }
105 95
 
106 96
             return Success("成功", orderViewList, iPage.getTotal());
@@ -110,81 +100,269 @@ public class WorkOrderBaseController extends BaseController {
110 100
     }
111 101
 
112 102
     @ApiOperation("详情")
113
-    @Log(title = "查询wo_workorderbase详情",businessType = BusinessType.QUERY)
103
+    @Log(title = "查询wo_workorderbase详情", businessType = BusinessType.QUERY)
114 104
     @GetMapping("/{id}")
115 105
     public AjaxResult getInfo(@PathVariable long id) {
116
-        return Success("成功", workorderbaseService.getEntity(id));
106
+        WorkOrderBase orderBase = workorderbaseService.getEntity(id);
107
+        WorkOrderBaseView ov = trans(orderBase);
108
+        return Success("成功", ov);
117 109
     }
118 110
 
119 111
     @ApiOperation("新增")
120
-    @Log(title = "新增wo_workorderbase",businessType = BusinessType.INSERT)
112
+    @Log(title = "新增wo_workorderbase", businessType = BusinessType.INSERT)
121 113
     @PostMapping
122 114
     public AjaxResult add(@RequestBody WorkOrderBase input) {
123 115
         Date currentDate = new Date(System.currentTimeMillis());
116
+        Random random = new Random();
117
+        int rannum = random.nextInt(900) + 100;
124 118
 
125
-        SimpleDateFormat format=new SimpleDateFormat("yyyyMMddHHmmss");
126
-        String ordercode=format.format(currentDate);
119
+        SimpleDateFormat format = new SimpleDateFormat("yyyyMMddHHmmss");
120
+        String ordercode = format.format(currentDate) + rannum;
127 121
         input.setWorkordercode(ordercode);
128 122
         input.setIsdelete(0L);
129 123
         input.setCreateuser(CurrentUser().getUserName());
130 124
         input.setCreatetime(currentDate);
131
-       //没结束 处理中
132
-        if (input.getIsend()==0)
133
-        {
125
+        //没结束 处理中
126
+        if (input.getIsend() == 0) {
134 127
             input.setWorkorderstate(0L);
135
-        }
136
-        else
137
-        {
128
+            input.setDealuser(input.getDealuser());
129
+        } else {
138 130
             //结束了 已完成
139 131
             input.setWorkorderstate(1L);
140 132
             input.setEndtime(currentDate);
141 133
             input.setDealuser(CurrentUser().getUserName());
142 134
         }
143
-
144
-         boolean result = workorderbaseService.insert(input);
135
+        input.setSource("来电");
136
+        boolean result = workorderbaseService.insert(input);
145 137
         if (result) {
146 138
             //添加操作日志
147
-            WorkOrderOperateLog loginput=new WorkOrderOperateLog();
148
-            loginput.setIsdelete(0L);
149
-            loginput.setLogcontent("创建了工单");
150
-
151
-
152
-            loginput.setOperationtime(currentDate);
139
+            boolean logresult = addlog("创建了工单", 1L, CurrentUser().getUserName(), input.getWorkordercode());
140
+            //判断手机号存在不customer,不存在就添加新用户
141
+            LambdaQueryWrapper<Customer> qw = new LambdaQueryWrapper<>();
142
+            qw.eq(Customer::getCustomerPhone, input.getCallnum());
153 143
 
154
-            loginput.setOperationtype(1L);
155
-            loginput.setOperator(CurrentUser().getUserName());
156
-            loginput.setWorkordercode(input.getWorkordercode());
144
+            Customer record = customerService.getEntity(qw);
145
+            if (record == null) {
146
+                Customer customer = new Customer();
147
+                customer.setCustomerName(input.getCaller());
148
+                customer.setCustomerPhone(input.getCallnum());
149
+                customer.setType(1L);
150
+                customer.setFIsdelete(0L);
151
+                customer.setFCreatetime(currentDate);
152
+                boolean customerresult = customerService.insert(customer);
153
+            }
154
+            return Success("成功",input.getWorkorderid());
155
+        } else {
156
+            return Error("新增失败");
157
+        }
158
+    }
157 159
 
160
+    @ApiOperation("编辑")
161
+    @Log(title = "编辑wo_workorderbase", businessType = BusinessType.UPDATE)
162
+    @PutMapping
163
+    public AjaxResult edit(@RequestBody WorkOrderBase input) {
164
+        Date currentDate = new Date(System.currentTimeMillis());
165
+        WorkOrderBase orderBase = workorderbaseService.getEntity(input.getWorkorderid());
166
+        orderBase.setCaller(input.getCaller());
167
+        orderBase.setCallnum(input.getCallnum());
168
+        orderBase.setProject(input.getProject());
169
+        orderBase.setWorkordercate(input.getWorkordercate());
170
+        orderBase.setContent(input.getContent());
171
+        orderBase.setIsend(input.getIsend());
172
+        orderBase.setResult(input.getResult());
173
+        //没结束 处理中
174
+        if (input.getIsend() == 0) {
175
+            input.setWorkorderstate(0L);
176
+            input.setDealuser(input.getDealuser());
177
+        } else {
178
+            //结束了 已完成
179
+            input.setWorkorderstate(1L);
180
+            input.setEndtime(currentDate);
181
+            input.setDealuser(CurrentUser().getUserName());
182
+        }
158 183
 
159
-            boolean logresult = workorderoperatelogService.insert(loginput);
184
+        boolean result = workorderbaseService.update(orderBase);
185
+        if (result) {
186
+            if (orderBase.getIsend()==0 && input.getIsend()==1)
187
+            {
188
+                boolean logresult = addlog("修改并结束了工单", 3L, CurrentUser().getUserName(), input.getWorkordercode());
189
+            }
190
+            else
191
+            {
192
+                boolean logresult = addlog("修改并完成了工单", 4L, CurrentUser().getUserName(), input.getWorkordercode());
193
+            }
160 194
             return Success("成功");
161 195
         } else {
162
-            return Error("新增失败");
196
+            return Error("修改失败");
163 197
         }
164 198
     }
165 199
 
166 200
     @ApiOperation("编辑")
167
-    @Log(title = "编辑wo_workorderbase",businessType = BusinessType.UPDATE)
168
-    @PutMapping
169
-    public AjaxResult edit(@RequestBody WorkOrderBase input)  {
201
+    @Log(title = "编辑wo_workorderbase", businessType = BusinessType.UPDATE)
202
+    @PutMapping("/editresult")
203
+    public AjaxResult editresult(@RequestBody WorkOrderBase input) {
204
+
205
+        Date currentDate = new Date(System.currentTimeMillis());
206
+        WorkOrderBase orderBase = new WorkOrderBaseView();
207
+
208
+        orderBase.setResult(input.getResult());
209
+        orderBase.setIsend(1L);
210
+        orderBase.setEndtime(currentDate);
211
+        orderBase.setFile(input.getFile());
170 212
         boolean result = workorderbaseService.update(input);
171 213
         if (result) {
214
+            boolean logresult = addlog("完成了工单", 2L, CurrentUser().getUserName(), input.getWorkordercode());
172 215
             return Success("成功");
173 216
         } else {
174 217
             return Error("修改失败");
175 218
         }
176 219
     }
177 220
 
221
+
178 222
     @ApiOperation("删除")
179
-    @Log(title = "删除wo_workorderbase",businessType = BusinessType.DELETE)
223
+    @Log(title = "删除wo_workorderbase", businessType = BusinessType.DELETE)
180 224
     @DeleteMapping("/{ids}")
181
-    public AjaxResult delete(@PathVariable Long[] ids)  {
182
-        boolean result = workorderbaseService.delete(Arrays.asList(ids));
225
+    public AjaxResult delete(@PathVariable Long[] ids) {
226
+        StringBuilder error= new StringBuilder();
227
+        for (int i=0;i<ids .length;i++)
228
+        {
229
+            WorkOrderBase workOrderBase=workorderbaseService.getEntity(ids[i] );
230
+            if (workOrderBase!=null)
231
+            {
232
+                workOrderBase .setIsdelete(1L);
233
+                boolean result = workorderbaseService.update(workOrderBase);
234
+                if (!result)
235
+                {
236
+                    error.append(workOrderBase.getWorkordercode()).append("删除失败;");
237
+                }
238
+            }
239
+            else
240
+            {
241
+                error.append("第").append(i).append("行删除失败;");
242
+            }
243
+        }
244
+        if (error.toString().equals("")) {
245
+            return Success("成功");
246
+        } else {
247
+            return Error(error.toString());
248
+        }
249
+    }
250
+
251
+
252
+    @ApiOperation("留言新增")
253
+    @Log(title = "新增wo_workorderbase", businessType = BusinessType.INSERT)
254
+    @PostMapping("/addbyly")
255
+    public AjaxResult addbyly(@RequestBody WorkOrderBase input) {
256
+        Date currentDate = new Date(System.currentTimeMillis());
257
+        try {
258
+            String ip = InetAddress.getLocalHost().getHostAddress();
259
+            input.setIp(ip);
260
+            LambdaQueryWrapper<WorkOrderBase> qw = new LambdaQueryWrapper<>();
261
+            qw.eq(WorkOrderBase::getIp, ip);
262
+            qw.eq(WorkOrderBase::getCreatetime,LocalDate.now());
263
+
264
+            List<WorkOrderBase> orderBase = workorderbaseService.getList(qw);
265
+            if (orderBase != null && orderBase.stream().count() > 9) {
266
+                return Error("添加失败");
267
+            }
268
+        } catch (UnknownHostException e) {
269
+            e.printStackTrace();
270
+        }
271
+
272
+
273
+        SimpleDateFormat format = new SimpleDateFormat("yyyyMMddHHmmss");
274
+        String ordercode = format.format(currentDate);
275
+        input.setWorkordercode(ordercode);
276
+        input.setIsdelete(0L);
277
+
278
+        input.setCreatetime(currentDate);
279
+        //没结束 处理中
280
+        input.setIsend(0L);
281
+        input.setWorkorderstate(0L);
282
+
283
+        boolean result = workorderbaseService.insert(input);
183 284
         if (result) {
285
+            boolean logresult = addlog("留言创建了工单", 1L, CurrentUser().getUserName(), input.getWorkordercode());
286
+            //判断手机号存在不customer,不存在就添加新用户
287
+            LambdaQueryWrapper<Customer> qw = new LambdaQueryWrapper<>();
288
+            qw.eq(Customer::getCustomerPhone, input.getCallnum());
289
+
290
+            Customer record = customerService.getEntity(qw);
291
+            if (record == null) {
292
+                Customer customer = new Customer();
293
+                customer.setType(1L);
294
+                customer.setCustomerName(input.getCaller());
295
+                customer.setCustomerPhone(input.getCallnum());
296
+                customer.setFIsdelete(0L);
297
+                customer.setFCreatetime(currentDate);
298
+
299
+
300
+                boolean customerresult = customerService.insert(customer);
301
+            }
184 302
             return Success("成功");
185 303
         } else {
186
-            return Error("删除失败");
304
+            return Error("添加失败");
187 305
         }
188 306
     }
189 307
 
308
+    public boolean addlog(String content, Long type, String operator, String code) {
309
+        Date currentDate = new Date(System.currentTimeMillis());
310
+        //添加操作日志
311
+        WorkOrderOperateLog loginput = new WorkOrderOperateLog();
312
+        loginput.setIsdelete(0L);
313
+        loginput.setLogcontent(content);
314
+        loginput.setOperationtime(currentDate);
315
+        loginput.setOperationtype(type);
316
+        loginput.setOperator(operator);
317
+        loginput.setWorkordercode(code);
318
+        boolean logresult = workorderoperatelogService.insert(loginput);
319
+        return logresult;
320
+    }
321
+
322
+    public WorkOrderBaseView trans(WorkOrderBase orderBase) {
323
+
324
+        WorkOrderBaseView ov = JSON.parseObject(JSON.toJSONString(orderBase), WorkOrderBaseView.class);
325
+        if (orderBase.getProject() > 0) {
326
+            DictData dicdata = dictDataService.getEntity(orderBase.getProject());
327
+
328
+            ov.setProjectname(dicdata.getDictValue());
329
+        }
330
+        if (orderBase.getWorkordercate() > 0) {
331
+            DictData dicdata = dictDataService.getEntity(orderBase.getWorkordercate());
332
+            ov.setWorkordercatename(dicdata.getDictValue());
333
+        }
334
+        if (!StringHelper.isEmpty(orderBase.getDealuser())) {
335
+            User user = userMapper.selectUserByUserName(orderBase.getDealuser());
336
+            ov.setDealusername(user.getNickName());
337
+        }
338
+        if (!StringHelper.isEmpty(orderBase.getCreateuser())) {
339
+            User user = userMapper.selectUserByUserName(orderBase.getCreateuser());
340
+            ov.setCreateusername(user.getNickName());
341
+        }
342
+        if (orderBase.getWorkordercate() == 0) {
343
+            ov.setWorkorderstatename("待处理");
344
+        } else if (orderBase.getWorkordercate() == 1) {
345
+            ov.setWorkorderstatename("已完成");
346
+        } else {
347
+            ov.setWorkorderstatename("");
348
+        }
349
+        if (!StringHelper.isEmpty(orderBase.getFile()))
350
+        {
351
+            String captchaEnabled = configService.selectCaptchaEnabled("FileUrl");
352
+            LambdaQueryWrapper<SysAccessories> qw = new LambdaQueryWrapper<>();
353
+            qw.in(SysAccessories::getFileid, orderBase.getFile());
354
+           List<SysAccessories> accessoriesList= sysaccessoriesService.getList(qw);
355
+           if (accessoriesList!=null && accessoriesList.stream().count()>0)
356
+           {
357
+               List<String> strlist=new ArrayList<>();
358
+               for (SysAccessories accessories:accessoriesList
359
+                    ) {
360
+                   strlist.add( captchaEnabled+accessories.getFileurl())  ;
361
+               }
362
+            ov.setFileurl(strlist);
363
+           }
364
+
365
+        }
366
+        return ov;
367
+    }
190 368
 }

+ 117 - 0
zxkf-api/src/main/java/api/controller/system/SysAccessoriesController.java

@@ -0,0 +1,117 @@
1
+package api.controller.system;
2
+
3
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4
+import com.baomidou.mybatisplus.core.metadata.IPage;
5
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
6
+import api.controller.BaseController;
7
+import api.entity.database.system.SysAccessories;
8
+import api.entity.input.PageInput;
9
+import api.model.AjaxResult;
10
+import api.service.system.ISysAccessoriesService;
11
+import api.util.annotation.Log;
12
+import api.util.enums.BusinessType;
13
+import api.util.helper.StringHelper;
14
+import io.swagger.annotations.Api;
15
+import io.swagger.annotations.ApiOperation;
16
+import lombok.extern.slf4j.Slf4j;
17
+import org.apache.commons.lang3.StringUtils;
18
+import org.springframework.beans.factory.annotation.Autowired;
19
+import org.springframework.web.bind.annotation.*;
20
+import org.springframework.web.multipart.MultipartFile;
21
+
22
+import java.io.File;
23
+import java.io.IOException;
24
+import java.util.Arrays;
25
+import java.util.Date;
26
+import java.util.HashMap;
27
+import java.util.UUID;
28
+@Slf4j
29
+@Api(value = "sys_accessories",tags = "sys_accessories")
30
+@RestController
31
+@RequestMapping("/system/sysaccessories")
32
+public class SysAccessoriesController extends BaseController {
33
+    @Autowired
34
+    private ISysAccessoriesService sysaccessoriesService;
35
+
36
+
37
+
38
+    @ApiOperation(value = "上传文件")
39
+    @PostMapping("/upload")
40
+    public AjaxResult uploadFile(MultipartFile file) {
41
+        //无文件返回错误
42
+        if (file == null  ) {
43
+            return Error("无文件");
44
+        }
45
+        //新文件名
46
+        StringBuilder newFileName;
47
+
48
+        //全部文件名,若多个,则逗号分隔
49
+        StringBuilder allFileNames = new StringBuilder();
50
+
51
+        //上传路径
52
+        String fileSavePath = "files";
53
+
54
+        //若文件夹不存在,则创建文件夹
55
+        File pFile = new File(fileSavePath);
56
+        if (!pFile.exists()) {
57
+            pFile.mkdirs();
58
+        }
59
+
60
+            //得到原始文件名
61
+            newFileName = new StringBuilder(file.getOriginalFilename());
62
+            //查询文件名中点号所处位置
63
+            int i = newFileName.lastIndexOf(".");
64
+            //若点号位置大于0,则文件名正常
65
+            if (i > 0) {
66
+                //在点号前拼接UUID防止文件重名
67
+                newFileName=   newFileName.insert(i, "_" + UUID.randomUUID().toString().substring(0, 5));
68
+            } else {
69
+                //若点号位置小于等于0,则文件名不规范
70
+                return Error("文件'" + newFileName + "'名称不规范");
71
+            }
72
+            try {
73
+                // 保存文件
74
+                file.transferTo(new File(pFile.getAbsolutePath()+"/" + newFileName));
75
+                //若全部文件名为空,则此为第一个文件,直接追加此文件名
76
+                if (StringUtils.isBlank(allFileNames.toString())) {
77
+                    allFileNames.append(newFileName);
78
+                } else {
79
+                    //若全部文件名不为空,则追加逗号和文件名
80
+                    allFileNames.append(",").append(newFileName).toString();
81
+                }
82
+            } catch (IOException e) {
83
+                log.error("上传失败",e);
84
+                return Error("上传失败");
85
+            }
86
+
87
+
88
+
89
+        Date currentDate = new Date(System.currentTimeMillis());
90
+        SysAccessories sysAccessories=new SysAccessories();
91
+        sysAccessories.setCreatetime(currentDate);
92
+        sysAccessories.setFilename(String.valueOf(newFileName));
93
+        sysAccessories.setFiletype(file.getContentType());
94
+        sysAccessories.setFilesize(file.getSize());
95
+        sysAccessories.setFileurl(pFile.getAbsolutePath()+"/" + newFileName);
96
+        sysAccessories.setCreateuser(CurrentUser().getUserName());
97
+
98
+            Boolean result=  sysaccessoriesService.insert(sysAccessories);
99
+            if (result)
100
+            {
101
+                //返回信息
102
+                return Success("上传成功", sysAccessories.getFileid());
103
+            }
104
+             else
105
+            {
106
+                return Success("上传失败");
107
+
108
+            }
109
+
110
+
111
+
112
+    }
113
+
114
+
115
+
116
+
117
+}

+ 2 - 1
zxkf-entity/src/main/java/api/entity/database/order/WorkOrderBase.java

@@ -89,6 +89,7 @@ public class WorkOrderBase {
89 89
     @ApiModelProperty("来源")
90 90
     private String source;
91 91
 
92
-
92
+    @ApiModelProperty("ip地址")
93
+    private String ip;
93 94
 
94 95
 }

+ 1 - 1
zxkf-entity/src/main/java/api/entity/database/system/Customer.java

@@ -120,7 +120,7 @@ public class Customer {
120 120
     @ApiModelProperty("icon")
121 121
     private String icon;
122 122
     /** 类型 */
123
-    @ApiModelProperty("类型")
123
+    @ApiModelProperty("类型") //1系统添加2微信3网站
124 124
     private Long type;
125 125
 
126 126
 }

+ 41 - 0
zxkf-entity/src/main/java/api/entity/database/system/SysAccessories.java

@@ -0,0 +1,41 @@
1
+package api.entity.database.system;
2
+
3
+import com.baomidou.mybatisplus.annotation.IdType;
4
+import com.baomidou.mybatisplus.annotation.TableId;
5
+import com.baomidou.mybatisplus.annotation.TableName;
6
+import io.swagger.annotations.ApiModel;
7
+import io.swagger.annotations.ApiModelProperty;
8
+import lombok.Data;
9
+import java.util.Date;
10
+
11
+/** sys_accessories */
12
+@ApiModel(value = "SysAccessories", description = "sys_accessories实体")
13
+@Data
14
+@TableName("sys_accessories")
15
+public class SysAccessories {
16
+    /** fileid */
17
+    @ApiModelProperty("fileid")
18
+    @TableId(type = IdType.AUTO)
19
+    private Long fileid;
20
+    /** filename */
21
+    @ApiModelProperty("filename")
22
+    private String filename;
23
+    /** filetype */
24
+    @ApiModelProperty("filetype")
25
+    private String filetype;
26
+    /** fileurl */
27
+    @ApiModelProperty("fileurl")
28
+    private String fileurl;
29
+    /** createuser */
30
+    @ApiModelProperty("createuser")
31
+    private String createuser;
32
+    /** createtime */
33
+    @ApiModelProperty("createtime")
34
+    private Date createtime;
35
+    /** filesize */
36
+    @ApiModelProperty("filesize")
37
+    private Long filesize;
38
+    /** oriname */
39
+    @ApiModelProperty("oriname")
40
+    private String oriname;
41
+}

+ 9 - 0
zxkf-entity/src/main/java/api/entity/view/order/WorkOrderBaseView.java

@@ -4,6 +4,7 @@ import api.entity.database.order.WorkOrderBase;
4 4
 import io.swagger.annotations.ApiModelProperty;
5 5
 import lombok.Data;
6 6
 
7
+import java.util.List;
7 8
 
8 9
 
9 10
 @Data
@@ -24,5 +25,13 @@ public class WorkOrderBaseView extends WorkOrderBase {
24 25
     @ApiModelProperty("工单类型名")
25 26
     private String workordercatename;
26 27
 
28
+    /** 工单类型 */
29
+    @ApiModelProperty("工单状态")
30
+    private String workorderstatename;
31
+
32
+    /** 工单类型 */
33
+    @ApiModelProperty("文件路径")
34
+    private List<String> fileurl;
35
+
27 36
 
28 37
 }

+ 9 - 0
zxkf-mapper/src/main/java/api/mapper/system/SysAccessoriesMapper.java

@@ -0,0 +1,9 @@
1
+package api.mapper.system;
2
+
3
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4
+import api.entity.database.system.SysAccessories;
5
+import org.apache.ibatis.annotations.Mapper;
6
+
7
+@Mapper
8
+public interface SysAccessoriesMapper extends BaseMapper<SysAccessories> {
9
+}

+ 7 - 0
zxkf-service/src/main/java/api/service/system/ISysAccessoriesService.java

@@ -0,0 +1,7 @@
1
+package api.service.system;
2
+
3
+import api.entity.database.system.SysAccessories;
4
+import api.service.IBaseService;
5
+
6
+public interface ISysAccessoriesService extends IBaseService<SysAccessories> {
7
+}

+ 14 - 0
zxkf-service/src/main/java/api/service/system/impl/SysAccessoriesServiceImpl.java

@@ -0,0 +1,14 @@
1
+package api.service.system.impl;
2
+
3
+import api.entity.database.system.SysAccessories;
4
+import api.mapper.system.SysAccessoriesMapper;
5
+import api.service.system.ISysAccessoriesService;
6
+import api.service.BaseServiceImpl;
7
+import org.springframework.stereotype.Service;
8
+import org.springframework.transaction.annotation.Transactional;
9
+
10
+@Transactional
11
+@Service
12
+public class SysAccessoriesServiceImpl extends BaseServiceImpl<SysAccessoriesMapper, SysAccessories> implements ISysAccessoriesService{
13
+    public SysAccessoriesServiceImpl(){ super(false); }
14
+}