更改为自己版本
parent
522e2125a1
commit
1883f7dad9
Binary file not shown.
|
After Width: | Height: | Size: 2.1 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 1.8 KiB |
@ -1 +1,196 @@
|
||||
html{height:100%}body.signin{height:auto;background:url(../img/login-background.jpg) no-repeat center fixed;-webkit-background-size:cover;-moz-background-size:cover;-o-background-size:cover;background-size:cover}.signinpanel{width:750px;margin:10% auto 0;color:rgba(255,255,255,.95)}.signinpanel .logopanel{float:none;width:auto;padding:0;background:0}.signinpanel .signin-info ul{list-style:none;padding:0;margin:20px 0}.signinpanel .form-control{display:block;margin-top:15px}.signinpanel .uname{background:#fff url(../img/user.png) no-repeat 95% center;color:#333}.signinpanel .pword{background:#fff url(../img/locked.png) no-repeat 95% center;color:#333}.signinpanel .code{background:#fff no-repeat 95% center;color:#333;margin:0 0 15px 0}.signinpanel .btn{margin-top:15px}.signinpanel form{background:rgba(255,255,255,.2);border:1px solid rgba(255,255,255,.3);-moz-box-shadow:0 3px 0 rgba(12,12,12,.03);-webkit-box-shadow:0 3px 0 rgba(12,12,12,.03);box-shadow:0 3px 0 rgba(12,12,12,.03);-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;padding:30px}.signup-footer{border-top:solid 1px rgba(255,255,255,.3);margin:20px 0;padding-top:15px}@media screen and (max-width:768px){.signinpanel,.signuppanel{margin:0 auto;width:380px!important;padding:20px}.signinpanel form{margin-top:20px}.signup-footer,.signuppanel .form-control{margin-bottom:10px}.signup-footer .pull-left,.signup-footer .pull-right{float:none!important;text-align:center}.signinpanel .signin-info ul{display:none}}@media screen and (max-width:320px){.signinpanel,.signuppanel{margin:0 20px;width:auto}}.checkbox-custom{position:relative;padding:0 15px 0 25px;margin-bottom:7px;display:inline-block}.checkbox-custom input[type="checkbox"]{opacity:0;position:absolute;cursor:pointer;z-index:2;margin:-6px 0 0 0;top:50%;left:3px}.checkbox-custom label:before{content:'';position:absolute;top:50%;left:0;margin-top:-9px;width:18px;height:17px;display:inline-block;border-radius:2px;border:1px solid #bbb;background:#fff}.checkbox-custom input[type="checkbox"]:checked+label:after{position:absolute;display:inline-block;font-family:'Glyphicons Halflings';content:"\e013";top:42%;left:3px;margin-top:-5px;font-size:11px;line-height:1;width:16px;height:16px;color:#333}.checkbox-custom label{cursor:pointer;line-height:1.2;font-weight:normal;margin-bottom:0;text-align:left}.form-control,.form-control:focus,.has-error .form-control:focus,.has-success .form-control:focus,.has-warning .form-control:focus,.navbar-collapse,.navbar-form,.navbar-form-custom .form-control:focus,.navbar-form-custom .form-control:hover,.open .btn.dropdown-toggle,.panel,.popover,.progress,.progress-bar{box-shadow:none}.form-control{border-radius:1px!important;padding:6px 12px!important;height:34px!important}.form-control:focus{border-color:#1ab394!important}body .layer-ext-moon-msg[type="dialog"]{min-width:100px!important}body .layer-ext-moon-msg{background-color:rgba(0,0,0,0.6);color:#fff;border:0}body .layer-ext-moon-msg .layui-layer-content{padding:12px 25px;text-align:center}
|
||||
html {
|
||||
height: 100%
|
||||
}
|
||||
|
||||
body.signin {
|
||||
height: auto;
|
||||
background: url(../img/man_bg2.png) no-repeat center fixed;
|
||||
-webkit-background-size: cover;
|
||||
-moz-background-size: cover;
|
||||
-o-background-size: cover;
|
||||
background-size: cover
|
||||
background-attachment: fixed;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.signinpanel {
|
||||
width: 900px;
|
||||
/*margin: 10% auto 0;*/
|
||||
margin-top: 14%;
|
||||
margin-bottom: 0px;
|
||||
margin-left: 40%;
|
||||
color: rgba(255, 255, 255, .95)
|
||||
}
|
||||
|
||||
.signinpanel .logopanel {
|
||||
float: none;
|
||||
width: auto;
|
||||
padding: 0;
|
||||
background: 0
|
||||
}
|
||||
|
||||
.signinpanel .signin-info ul {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 20px 0
|
||||
}
|
||||
|
||||
.signinpanel .form-control {
|
||||
display: block;
|
||||
margin-top: 15px
|
||||
}
|
||||
|
||||
.signinpanel .uname {
|
||||
background: #fff url(../img/user.png) no-repeat 95% center;
|
||||
color: #333
|
||||
}
|
||||
|
||||
.signinpanel .pword {
|
||||
background: #fff url(../img/locked.png) no-repeat 95% center;
|
||||
color: #333
|
||||
}
|
||||
|
||||
.signinpanel .code {
|
||||
background: #fff no-repeat 95% center;
|
||||
color: #333;
|
||||
margin: 0 0 15px 0
|
||||
}
|
||||
|
||||
.signinpanel .btn {
|
||||
margin-top: 15px
|
||||
}
|
||||
|
||||
.signinpanel form {
|
||||
background: rgba(255, 255, 255, .7);
|
||||
border: 1px solid rgba(255, 255, 255, .3);
|
||||
-moz-box-shadow: 0 3px 0 rgba(12, 12, 12, .03);
|
||||
-webkit-box-shadow: 0 3px 0 rgba(12, 12, 12, .03);
|
||||
box-shadow: 0 3px 0 rgba(12, 12, 12, .03);
|
||||
-moz-border-radius: 3px;
|
||||
-webkit-border-radius: 3px;
|
||||
border-radius: 3px;
|
||||
padding: 30px
|
||||
}
|
||||
|
||||
.signup-footer {
|
||||
border-top: solid 1px rgba(255, 255, 255, .3);
|
||||
margin: 20px 0;
|
||||
padding-top: 15px
|
||||
}
|
||||
|
||||
@media screen and (max-width: 768px) {
|
||||
.signinpanel, .signuppanel {
|
||||
margin: 0 auto;
|
||||
width: 380px !important;
|
||||
padding: 20px
|
||||
}
|
||||
|
||||
.signinpanel form {
|
||||
margin-top: 20px
|
||||
}
|
||||
|
||||
.signup-footer, .signuppanel .form-control {
|
||||
margin-bottom: 10px
|
||||
}
|
||||
|
||||
.signup-footer .pull-left, .signup-footer .pull-right {
|
||||
float: none !important;
|
||||
text-align: center
|
||||
}
|
||||
|
||||
.signinpanel .signin-info ul {
|
||||
display: none
|
||||
}
|
||||
}
|
||||
|
||||
@media screen and (max-width: 320px) {
|
||||
.signinpanel, .signuppanel {
|
||||
margin: 0 20px;
|
||||
width: auto
|
||||
}
|
||||
}
|
||||
|
||||
.checkbox-custom {
|
||||
position: relative;
|
||||
padding: 0 15px 0 25px;
|
||||
margin-bottom: 7px;
|
||||
display: inline-block
|
||||
}
|
||||
|
||||
.checkbox-custom input[type="checkbox"] {
|
||||
opacity: 0;
|
||||
position: absolute;
|
||||
cursor: pointer;
|
||||
z-index: 2;
|
||||
margin: -6px 0 0 0;
|
||||
top: 50%;
|
||||
left: 3px
|
||||
}
|
||||
|
||||
.checkbox-custom label:before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -9px;
|
||||
width: 18px;
|
||||
height: 17px;
|
||||
display: inline-block;
|
||||
border-radius: 2px;
|
||||
border: 1px solid #bbb;
|
||||
background: #fff
|
||||
}
|
||||
|
||||
.checkbox-custom input[type="checkbox"]:checked + label:after {
|
||||
position: absolute;
|
||||
display: inline-block;
|
||||
font-family: 'Glyphicons Halflings';
|
||||
content: "\e013";
|
||||
top: 42%;
|
||||
left: 3px;
|
||||
margin-top: -5px;
|
||||
font-size: 11px;
|
||||
line-height: 1;
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
color: #333
|
||||
}
|
||||
|
||||
.checkbox-custom label {
|
||||
cursor: pointer;
|
||||
line-height: 1.2;
|
||||
font-weight: normal;
|
||||
margin-bottom: 0;
|
||||
text-align: left
|
||||
}
|
||||
|
||||
.form-control, .form-control:focus, .has-error .form-control:focus, .has-success .form-control:focus, .has-warning .form-control:focus, .navbar-collapse, .navbar-form, .navbar-form-custom .form-control:focus, .navbar-form-custom .form-control:hover, .open .btn.dropdown-toggle, .panel, .popover, .progress, .progress-bar {
|
||||
box-shadow: none
|
||||
}
|
||||
|
||||
.form-control {
|
||||
border-radius: 1px !important;
|
||||
padding: 6px 12px !important;
|
||||
height: 34px !important
|
||||
}
|
||||
|
||||
.form-control:focus {
|
||||
border-color: #1ab394 !important
|
||||
}
|
||||
|
||||
body .layer-ext-moon-msg[type="dialog"] {
|
||||
min-width: 100px !important
|
||||
}
|
||||
|
||||
body .layer-ext-moon-msg {
|
||||
background-color: rgba(0, 0, 0, 0.6);
|
||||
color: #fff;
|
||||
border: 0
|
||||
}
|
||||
|
||||
body .layer-ext-moon-msg .layui-layer-content {
|
||||
padding: 12px 25px;
|
||||
text-align: center
|
||||
}
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 432 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 860 KiB |
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,32 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi</artifactId>
|
||||
<version>4.8.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ruoyi-api</artifactId>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>8</maven.compiler.source>
|
||||
<maven.compiler.target>8</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-manage</artifactId>
|
||||
<version>4.8.3</version>
|
||||
</dependency>
|
||||
<!-- 通用工具-->
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-common</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
</project>
|
||||
@ -0,0 +1,378 @@
|
||||
package com.ruoyi.api.controller;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.api.domain.CheckTaskInfo;
|
||||
import com.ruoyi.api.domain.InStoreDto;
|
||||
import com.ruoyi.api.domain.OutStoreDto;
|
||||
import com.ruoyi.api.domain.StockDto;
|
||||
import com.ruoyi.api.service.impl.ApiService;
|
||||
import com.ruoyi.common.config.RuoYiConfig;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||
import com.ruoyi.manage.domain.*;
|
||||
import com.ruoyi.manage.service.*;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import static com.ruoyi.common.core.domain.AjaxResult.error;
|
||||
import static com.ruoyi.common.core.domain.AjaxResult.success;
|
||||
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/1/11 8:55
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/api")
|
||||
public class ApiController {
|
||||
@Autowired
|
||||
private IBaseLocationService baseLocationService;
|
||||
@Autowired
|
||||
private IBaseManufacturerService baseManufacturerService;
|
||||
@Autowired
|
||||
private ApiService apiService;
|
||||
|
||||
//入库
|
||||
// 查询库位 和 品牌
|
||||
@PostMapping("/instore/select")
|
||||
public AjaxResult instoreSelect() {
|
||||
BaseLocation baseLocation = new BaseLocation();
|
||||
baseLocation.setStoteTag(1L);
|
||||
baseLocation.setIsEnable("Y");
|
||||
List<BaseLocation> baseLocationList = baseLocationService.selectBaseLocationList(baseLocation);
|
||||
BaseManufacturer baseManufacturer = new BaseManufacturer();
|
||||
baseManufacturer.setIsEnable("Y");
|
||||
List<BaseManufacturer> baseManufacturerList = baseManufacturerService.selectBaseManufacturerList(baseManufacturer);
|
||||
Map<String, List> map = new HashMap<>();
|
||||
map.put("baseLocationList", baseLocationList);
|
||||
map.put("baseManufacturerList", baseManufacturerList);
|
||||
return success(map);
|
||||
}
|
||||
|
||||
@PostMapping("/instore/submit")
|
||||
public AjaxResult instoreSubmit(@RequestBody InStoreDto inStore) {
|
||||
List<String> epcList = inStore.getEpcList();
|
||||
int size = epcList.size();
|
||||
System.out.println("数据条数:" + size);
|
||||
Iterator<String> iterator = epcList.iterator();
|
||||
while (iterator.hasNext()) {
|
||||
String epc = iterator.next();
|
||||
String tag = apiService.selectLedgerbyEpcForInStore(epc);
|
||||
if (tag != null) {
|
||||
iterator.remove();
|
||||
}
|
||||
}
|
||||
int size1 = epcList.size();
|
||||
int i = size - size1;
|
||||
if (size1 > 0) {
|
||||
apiService.submintInsertRecordIn(inStore);
|
||||
apiService.submintInsertLedger(inStore);
|
||||
}
|
||||
|
||||
|
||||
return success("本次入库成功:" + size1 + "条,屏蔽重复入库:" + i + "条");
|
||||
}
|
||||
|
||||
|
||||
@PostMapping("/outStore/select")
|
||||
public AjaxResult outStoreSelect() {
|
||||
BaseLocation baseLocation = new BaseLocation();
|
||||
baseLocation.setStoteTag(2L);
|
||||
baseLocation.setIsEnable("Y");
|
||||
List<BaseLocation> baseLocationList = baseLocationService.selectBaseLocationList(baseLocation);
|
||||
return success(baseLocationList);
|
||||
}
|
||||
|
||||
@PostMapping("/outStore/submit")
|
||||
public AjaxResult outStoreSubmit(@RequestBody OutStoreDto outStoreDto) {
|
||||
try {
|
||||
List<String> epcList = outStoreDto.getEpcList();
|
||||
//int i=0;
|
||||
for (String epc : epcList) {
|
||||
String tag = apiService.selectLedgerbyEpcForOutStore(epc);
|
||||
if (tag != null) {
|
||||
apiService.submitInsertRecordOut(outStoreDto, epc);
|
||||
apiService.updataLedgerFoyOut(outStoreDto, epc);
|
||||
//i++;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
/* int size = epcList.size();
|
||||
Iterator<String> iterator = epcList.iterator();
|
||||
while (iterator.hasNext()) {
|
||||
String epc = iterator.next();
|
||||
|
||||
if (tag != null) {
|
||||
iterator.remove();
|
||||
}
|
||||
}
|
||||
int size1 = epcList.size();
|
||||
int i = size - size1;
|
||||
if (i>0){
|
||||
apiService.submitInsertRecordOut(outStoreDto);
|
||||
apiService.updataLedger(outStoreDto);
|
||||
}*/
|
||||
|
||||
return success();
|
||||
} catch (Exception e) {
|
||||
return error();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@PostMapping("/storecheck/select")
|
||||
public AjaxResult storeCheckSelect() {
|
||||
List<StockDto> list = apiService.storeCheckSelect();
|
||||
if (list == null || list.isEmpty()) {
|
||||
return error("库存为空");
|
||||
}
|
||||
return success(list);
|
||||
}
|
||||
|
||||
@Autowired
|
||||
private IRecordStoreCheckService checkService;
|
||||
|
||||
@Transactional
|
||||
@PostMapping("/storecheck/submit")
|
||||
public AjaxResult storeCheckSubmit(String json, String user) {
|
||||
try {
|
||||
List<StockDto> list = JSONObject.parseArray(json, StockDto.class);
|
||||
RecordStoreCheck recordStoreCheck = new RecordStoreCheck();
|
||||
recordStoreCheck.setCheckNumber(list.size());
|
||||
recordStoreCheck.setCheckTime(DateUtils.getNowDate());
|
||||
recordStoreCheck.setCheckUser(user);
|
||||
int key = checkService.insertRecordStoreCheck(recordStoreCheck);
|
||||
apiService.insertCheckInfo(list, recordStoreCheck.getCheckId());
|
||||
return success();
|
||||
} catch (Exception e) {
|
||||
return error("数据异常,请求失败");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@PostMapping("/bf/select")
|
||||
public AjaxResult bfSelect(String epc) {
|
||||
LedgerRfid ledgerRfid = apiService.bfSelect(epc);
|
||||
if (ledgerRfid == null) {
|
||||
return error("RFID 扫描不正确");
|
||||
}
|
||||
return success(ledgerRfid);
|
||||
}
|
||||
|
||||
@Autowired
|
||||
private IRecordInvalidatedService recordInvalidatedService;
|
||||
|
||||
|
||||
@PostMapping("/xj/selectLite")
|
||||
public String xjSelectLite(String user) {
|
||||
List<StockDto> list = apiService.xjSelect(user);
|
||||
if (list == null) {
|
||||
return "null";
|
||||
}
|
||||
return JSONObject.toJSONString(list);
|
||||
}
|
||||
|
||||
@Autowired
|
||||
private IRecordInspectionService inspectionService;
|
||||
|
||||
@PostMapping("/inspection/skipTask")
|
||||
public AjaxResult inspectionSubmit(long tableId, String remark) {
|
||||
apiService.updataInspectionTaskByObjid(tableId, remark, "跳过");
|
||||
return success();
|
||||
}
|
||||
|
||||
/**
|
||||
* 完成巡检
|
||||
*
|
||||
* @param tableId
|
||||
* @param json
|
||||
* @param inspectionId
|
||||
* @param user
|
||||
* @param files
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/xj/submit")
|
||||
public AjaxResult inspectionSubmit(long tableId, String json, long inspectionId, String user,String locationCode, List<MultipartFile> files) {
|
||||
//插入 info 表
|
||||
List<StockDto> list = JSONObject.parseArray(json, StockDto.class);
|
||||
if (list != null && !list.isEmpty()) {
|
||||
|
||||
locationCode=list.get(0).getLocationCode();
|
||||
apiService.deleteInspectionInfo(locationCode, inspectionId);
|
||||
apiService.insertInspectionInfo(list, inspectionId);
|
||||
}
|
||||
|
||||
//修改task状态
|
||||
apiService.updataInspectionTaskByObjid(tableId, null, "已完成");
|
||||
|
||||
//存储图片,插库
|
||||
String filePath = RuoYiConfig.getUploadPath() + "/inspection";
|
||||
if (files != null && files.size() > 0) {
|
||||
for (MultipartFile multipartFile : files) {
|
||||
String pathName = null;
|
||||
try {
|
||||
pathName = FileUploadUtils.upload(filePath, multipartFile);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
System.out.println("上传图片路径:" + pathName);
|
||||
|
||||
apiService.insertInspetionPictrue(inspectionId, tableId, user, pathName, locationCode);
|
||||
}
|
||||
}
|
||||
|
||||
return success();
|
||||
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 根据机位查询轮挡
|
||||
*
|
||||
* @param
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/inspection/select")
|
||||
public AjaxResult inspectionSelect(String code) {
|
||||
List<StockDto> list = apiService.inspectionSelectLocation(code);
|
||||
if (list == null) {
|
||||
return error("没有领用轮挡");
|
||||
}
|
||||
return success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建巡检机位列表和巡检任务
|
||||
*
|
||||
* @param user
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/xj/createTask")
|
||||
public AjaxResult inspectionCreateTask(String user) {
|
||||
List<CheckTaskInfo> list = apiService.selectLocationByAreaUser(user);
|
||||
if (list == null || list.isEmpty()) {
|
||||
return error("没有维护巡检区域");
|
||||
}
|
||||
RecordInspection recordInspection = new RecordInspection();
|
||||
recordInspection.setInspectionUser(user);
|
||||
int insertNumber = inspectionService.insertRecordInspection(recordInspection);
|
||||
|
||||
apiService.insertCheckTask(Math.toIntExact(recordInspection.getInspectionId()), list);
|
||||
return success("创建成功", insertNumber);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询巡检机位
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/inspection/selectTask")
|
||||
public AjaxResult inspectionSelectTask(@RequestParam(value = "state", defaultValue = "") String state) {
|
||||
try {
|
||||
int inspectionid = apiService.selectCodeFromRecode();
|
||||
System.out.println(inspectionid + "-" + state);
|
||||
List<CheckTaskInfo> list = apiService.inspectionSelectTask(state, inspectionid);
|
||||
// if (list == null || list.isEmpty()) {
|
||||
// return error("需要领用轮挡到机位");
|
||||
// }
|
||||
return success(list);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return error("需要创建");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 轮挡报废
|
||||
*
|
||||
* @param epc
|
||||
* @param user
|
||||
* @param remark
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/bf/submit")
|
||||
public AjaxResult bfSubmit(String epc, String reason, String user, int type, String remark, List<MultipartFile> files) {
|
||||
//插入记录
|
||||
RecordInvalidated recordInvalidated = new RecordInvalidated();
|
||||
recordInvalidated.setReason(reason);
|
||||
recordInvalidated.setEpc(epc);
|
||||
recordInvalidated.setCreateBy(user);
|
||||
recordInvalidated.setRemark(remark);
|
||||
recordInvalidated.setTypeName(Long.valueOf(type));
|
||||
recordInvalidatedService.insertRecordInvalidated(recordInvalidated);
|
||||
//修改台账
|
||||
apiService.updataLedgerForBf(epc, type + "");
|
||||
//存储图片,插库
|
||||
String filePath = RuoYiConfig.getUploadPath() + "/inspection";
|
||||
if (files != null && files.size() > 0) {
|
||||
for (MultipartFile multipartFile : files) {
|
||||
String pathName = null;
|
||||
try {
|
||||
pathName = FileUploadUtils.upload(filePath, multipartFile);
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
System.out.println("上传图片路径:" + pathName);
|
||||
apiService.insertBfImg(recordInvalidated.getObjid(), epc, user, pathName);
|
||||
}
|
||||
}
|
||||
|
||||
return success();
|
||||
}
|
||||
|
||||
@PostMapping("/fpin/select")
|
||||
public AjaxResult fpInSelect(String epc) {
|
||||
LedgerRfid ledgerRfid = apiService.fpInSelect(epc);
|
||||
if (ledgerRfid == null) {
|
||||
return error("RFID 扫描不正确");
|
||||
}
|
||||
BaseLocation baseLocation = new BaseLocation();
|
||||
baseLocation.setStoteTag(1L);
|
||||
baseLocation.setIsEnable("Y");
|
||||
List<BaseLocation> baseLocationList = baseLocationService.selectBaseLocationList(baseLocation);
|
||||
ledgerRfid.setBaseLocationList(baseLocationList);
|
||||
return success(ledgerRfid);
|
||||
}
|
||||
|
||||
@PostMapping("/fpin/submit")
|
||||
public AjaxResult fpInSubmit(String epc, String localtionCode, String user, String bf, String subCode) {
|
||||
int i = apiService.fpInSubmit(epc, localtionCode, user, bf, subCode);
|
||||
apiService.updataLedgerIn(epc, subCode);
|
||||
return success();
|
||||
}
|
||||
|
||||
@PostMapping("/fpout/select")
|
||||
public AjaxResult fpOutSelect() {
|
||||
List<StockDto> list = apiService.fpOutSelect();
|
||||
if (list == null || list.isEmpty()) {
|
||||
return error("暂无废品库存");
|
||||
}
|
||||
return success(list);
|
||||
}
|
||||
|
||||
@PostMapping("/fpout/submit")
|
||||
public AjaxResult fpoutSubmit(String json, String user) {
|
||||
try {
|
||||
List<StockDto> list = JSONObject.parseArray(json, StockDto.class);
|
||||
apiService.insertWasreOutRecord(list, user);
|
||||
apiService.updataLedgerForWasreOut(list, user);
|
||||
return success();
|
||||
} catch (Exception e) {
|
||||
return error();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,61 @@
|
||||
package com.ruoyi.api.controller;
|
||||
|
||||
import com.ruoyi.api.domain.BroadCountNumber;
|
||||
import com.ruoyi.api.domain.NoPowerDevice;
|
||||
import com.ruoyi.api.service.impl.BroadApiService;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.manage.domain.BaseStore;
|
||||
import com.ruoyi.manage.domain.LedgerRfid;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/3/1 13:29
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/api")
|
||||
public class BroadApiController {
|
||||
|
||||
@Autowired
|
||||
private BroadApiService service;
|
||||
|
||||
//获取区域
|
||||
@PostMapping("/getArea")
|
||||
@ResponseBody
|
||||
public AjaxResult getArea() {
|
||||
List<BaseStore> list = service.getArea();
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
//获取统计
|
||||
@PostMapping("/getCountNumberById")
|
||||
@ResponseBody
|
||||
public AjaxResult getCountNumberById(int id) {
|
||||
List<BroadCountNumber> list = service.getCountNumberById(id);
|
||||
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
//获取详细轮挡
|
||||
@PostMapping("/getLedgerByCode")
|
||||
@ResponseBody
|
||||
public AjaxResult getLedgerByCode(String locationCode){
|
||||
List<LedgerRfid> list=service.getLedgerByCode(locationCode);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
|
||||
@PostMapping("/getDevice")
|
||||
@ResponseBody
|
||||
public AjaxResult getDevice(String storeName){
|
||||
List<NoPowerDevice> list=service.getDevice(storeName);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,55 @@
|
||||
package com.ruoyi.api.controller;
|
||||
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.api.domain.APKVersion;
|
||||
import com.ruoyi.api.service.impl.LoginService;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* Created by wangh on 2020/7/17-15:18。
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/api")
|
||||
public class LoginController {
|
||||
@Autowired
|
||||
LoginService service;
|
||||
|
||||
|
||||
|
||||
@GetMapping("/login/finduser")
|
||||
public String finduser(String name, String pass){
|
||||
System.out.println("登录名称= "+name+" pass= "+pass);
|
||||
return service.login(name,pass);
|
||||
}
|
||||
@GetMapping("/login/finduser1")
|
||||
public AjaxResult finduser1(String name, String pass){
|
||||
System.out.println("登录名称= "+name+" pass= "+pass);
|
||||
return service.login1(name,pass);
|
||||
}
|
||||
|
||||
@GetMapping("/getVersion")
|
||||
public String getVersion(){
|
||||
APKVersion apkVersion=service.getVersion();
|
||||
apkVersion.setCode(0);
|
||||
apkVersion.setMsg("");
|
||||
if (apkVersion==null){
|
||||
apkVersion=new APKVersion();
|
||||
apkVersion.setUpdateStatus(0);
|
||||
}else {
|
||||
apkVersion.setUpdateStatus(1);
|
||||
}
|
||||
|
||||
|
||||
String s = JSONObject.toJSONString(apkVersion);
|
||||
System.out.println("请求版本信息"+s);
|
||||
return s;
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,117 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
import com.alibaba.fastjson.annotation.JSONField;
|
||||
|
||||
/**
|
||||
* 手持版本升级对象 pda_apk_version
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2023-04-06
|
||||
*/
|
||||
public class APKVersion {
|
||||
@JSONField(name = "Code")
|
||||
private int Code;
|
||||
@JSONField(name = "Msg")
|
||||
private String Msg;
|
||||
@JSONField(name = "UpdateStatus")
|
||||
private int UpdateStatus;
|
||||
@JSONField(name = "VersionCode")
|
||||
private Long VersionCode;
|
||||
@JSONField(name = "VersionName")
|
||||
private String VersionName;
|
||||
@JSONField(name = "ModifyContent")
|
||||
private String ModifyContent;
|
||||
@JSONField(name = "DownloadUrl")
|
||||
private String DownloadUrl;
|
||||
@JSONField(name = "ApkSize")
|
||||
private int ApkSize;
|
||||
@JSONField(name = "ApkMd5")
|
||||
private String ApkMd5;
|
||||
|
||||
public int getCode() {
|
||||
return Code;
|
||||
}
|
||||
|
||||
public void setCode(int code) {
|
||||
Code = code;
|
||||
}
|
||||
|
||||
public String getMsg() {
|
||||
return Msg;
|
||||
}
|
||||
|
||||
public void setMsg(String msg) {
|
||||
Msg = msg;
|
||||
}
|
||||
|
||||
public int getUpdateStatus() {
|
||||
return UpdateStatus;
|
||||
}
|
||||
|
||||
public void setUpdateStatus(int updateStatus) {
|
||||
UpdateStatus = updateStatus;
|
||||
}
|
||||
|
||||
public Long getVersionCode() {
|
||||
return VersionCode;
|
||||
}
|
||||
|
||||
public void setVersionCode(Long versionCode) {
|
||||
VersionCode = versionCode;
|
||||
}
|
||||
|
||||
public String getVersionName() {
|
||||
return VersionName;
|
||||
}
|
||||
|
||||
public void setVersionName(String versionName) {
|
||||
VersionName = versionName;
|
||||
}
|
||||
|
||||
public String getModifyContent() {
|
||||
return ModifyContent;
|
||||
}
|
||||
|
||||
public void setModifyContent(String modifyContent) {
|
||||
ModifyContent = modifyContent;
|
||||
}
|
||||
|
||||
public String getDownloadUrl() {
|
||||
return DownloadUrl;
|
||||
}
|
||||
|
||||
public void setDownloadUrl(String downloadUrl) {
|
||||
DownloadUrl = downloadUrl;
|
||||
}
|
||||
|
||||
public int getApkSize() {
|
||||
return ApkSize;
|
||||
}
|
||||
|
||||
public void setApkSize(int apkSize) {
|
||||
ApkSize = apkSize;
|
||||
}
|
||||
|
||||
public String getApkMd5() {
|
||||
return ApkMd5;
|
||||
}
|
||||
|
||||
public void setApkMd5(String apkMd5) {
|
||||
ApkMd5 = apkMd5;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "APKVersion{" +
|
||||
"Code=" + Code +
|
||||
", Msg='" + Msg + '\'' +
|
||||
", UpdateStatus=" + UpdateStatus +
|
||||
", VersionCode=" + VersionCode +
|
||||
", VersionName='" + VersionName + '\'' +
|
||||
", ModifyContent='" + ModifyContent + '\'' +
|
||||
", DownloadUrl='" + DownloadUrl + '\'' +
|
||||
", ApkSize=" + ApkSize +
|
||||
", ApkMd5='" + ApkMd5 + '\'' +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,45 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2023/8/23 10:25
|
||||
*/
|
||||
public class ApiUser {
|
||||
private int id;
|
||||
private String name;
|
||||
private int status;
|
||||
private String role_name;
|
||||
|
||||
|
||||
public int getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(int id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public int getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(int status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getRole_name() {
|
||||
return role_name;
|
||||
}
|
||||
|
||||
public void setRole_name(String role_name) {
|
||||
this.role_name = role_name;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,33 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
public class BroadCountNumber {
|
||||
private String areaName;
|
||||
private String locationCode;
|
||||
private int countNumber;
|
||||
|
||||
|
||||
public String getAreaName() {
|
||||
|
||||
return areaName;
|
||||
}
|
||||
|
||||
public void setAreaName(String areaName) {
|
||||
this.areaName = areaName;
|
||||
}
|
||||
|
||||
public String getLocationCode() {
|
||||
return locationCode;
|
||||
}
|
||||
|
||||
public void setLocationCode(String locationCode) {
|
||||
this.locationCode = locationCode;
|
||||
}
|
||||
|
||||
public int getCountNumber() {
|
||||
return countNumber;
|
||||
}
|
||||
|
||||
public void setCountNumber(int countNumber) {
|
||||
this.countNumber = countNumber;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,69 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
public class CheckTaskInfo {
|
||||
private int index;
|
||||
private Long id;
|
||||
private Long areaId;
|
||||
private String locationCode;
|
||||
private String areaName;
|
||||
private String taskState;
|
||||
|
||||
private Long inspectionId;
|
||||
|
||||
|
||||
public Long getInspectionId() {
|
||||
return inspectionId;
|
||||
}
|
||||
|
||||
public void setInspectionId(Long inspectionId) {
|
||||
this.inspectionId = inspectionId;
|
||||
}
|
||||
|
||||
public Long getAreaId() {
|
||||
return areaId;
|
||||
}
|
||||
|
||||
public void setAreaId(Long areaId) {
|
||||
this.areaId = areaId;
|
||||
}
|
||||
|
||||
public String getTaskState() {
|
||||
return taskState;
|
||||
}
|
||||
|
||||
public void setTaskState(String taskState) {
|
||||
this.taskState = taskState;
|
||||
}
|
||||
|
||||
public int getIndex() {
|
||||
return index;
|
||||
}
|
||||
|
||||
public void setIndex(int index) {
|
||||
this.index = index;
|
||||
}
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getLocationCode() {
|
||||
return locationCode;
|
||||
}
|
||||
|
||||
public void setLocationCode(String locationCode) {
|
||||
this.locationCode = locationCode;
|
||||
}
|
||||
|
||||
public String getAreaName() {
|
||||
return areaName;
|
||||
}
|
||||
|
||||
public void setAreaName(String areaName) {
|
||||
this.areaName = areaName;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,65 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/1/11 16:21
|
||||
*/
|
||||
public class InStoreDto {
|
||||
|
||||
private String binchCode;
|
||||
private String selectManuText;
|
||||
private String selectLocationText;
|
||||
private List<String> epcList;
|
||||
private String submitUser;
|
||||
private Long manufacturerId;
|
||||
public String getBinchCode() {
|
||||
return binchCode;
|
||||
}
|
||||
|
||||
public void setBinchCode(String binchCode) {
|
||||
this.binchCode = binchCode;
|
||||
}
|
||||
|
||||
public String getSelectManuText() {
|
||||
return selectManuText;
|
||||
}
|
||||
|
||||
public void setSelectManuText(String selectManuText) {
|
||||
this.selectManuText = selectManuText;
|
||||
}
|
||||
|
||||
public String getSelectLocationText() {
|
||||
return selectLocationText;
|
||||
}
|
||||
|
||||
public void setSelectLocationText(String selectLocationText) {
|
||||
this.selectLocationText = selectLocationText;
|
||||
}
|
||||
|
||||
public List<String> getEpcList() {
|
||||
return epcList;
|
||||
}
|
||||
|
||||
public void setEpcList(List<String> epcList) {
|
||||
this.epcList = epcList;
|
||||
}
|
||||
|
||||
public String getSubmitUser() {
|
||||
return submitUser;
|
||||
}
|
||||
|
||||
public void setSubmitUser(String submitUser) {
|
||||
this.submitUser = submitUser;
|
||||
}
|
||||
|
||||
public Long getManufacturerId() {
|
||||
return manufacturerId;
|
||||
}
|
||||
|
||||
public void setManufacturerId(Long manufacturerId) {
|
||||
this.manufacturerId = manufacturerId;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,78 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
|
||||
public class NoPowerDevice {
|
||||
|
||||
/** 摆放桩位 */
|
||||
@Excel(name = "摆放桩位")
|
||||
private String locationName;
|
||||
|
||||
/** 设备编码 */
|
||||
@Excel(name = "设备编码")
|
||||
private String deviceCode;
|
||||
|
||||
/** 设备名称 */
|
||||
@Excel(name = "设备名称")
|
||||
private String deviceName;
|
||||
|
||||
/** 设备类型 */
|
||||
@Excel(name = "设备类型")
|
||||
private Long deviceType;
|
||||
|
||||
/** 使用状态 */
|
||||
@Excel(name = "使用状态 0=空闲 1=使用中")
|
||||
private String useState;
|
||||
|
||||
/** 设备状态 */
|
||||
@Excel(name = "设备状态 0=停用 1=正常 2=维修中")
|
||||
private String deviceState;
|
||||
|
||||
public String getLocationName() {
|
||||
return locationName;
|
||||
}
|
||||
|
||||
public void setLocationName(String locationName) {
|
||||
this.locationName = locationName;
|
||||
}
|
||||
|
||||
public String getDeviceCode() {
|
||||
return deviceCode;
|
||||
}
|
||||
|
||||
public void setDeviceCode(String deviceCode) {
|
||||
this.deviceCode = deviceCode;
|
||||
}
|
||||
|
||||
public String getDeviceName() {
|
||||
return deviceName;
|
||||
}
|
||||
|
||||
public void setDeviceName(String deviceName) {
|
||||
this.deviceName = deviceName;
|
||||
}
|
||||
|
||||
public Long getDeviceType() {
|
||||
return deviceType;
|
||||
}
|
||||
|
||||
public void setDeviceType(Long deviceType) {
|
||||
this.deviceType = deviceType;
|
||||
}
|
||||
|
||||
public String getUseState() {
|
||||
return useState;
|
||||
}
|
||||
|
||||
public void setUseState(String useState) {
|
||||
this.useState = useState;
|
||||
}
|
||||
|
||||
public String getDeviceState() {
|
||||
return deviceState;
|
||||
}
|
||||
|
||||
public void setDeviceState(String deviceState) {
|
||||
this.deviceState = deviceState;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,50 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/1/17 16:17
|
||||
*/
|
||||
public class OutStoreDto {
|
||||
private List<String> epcList;
|
||||
private String areaCode;
|
||||
private String submitUser;
|
||||
private String useUser;
|
||||
|
||||
|
||||
|
||||
public List<String> getEpcList() {
|
||||
return epcList;
|
||||
}
|
||||
|
||||
public void setEpcList(List<String> epcList) {
|
||||
this.epcList = epcList;
|
||||
}
|
||||
|
||||
public String getAreaCode() {
|
||||
return areaCode;
|
||||
}
|
||||
|
||||
public void setAreaCode(String areaCode) {
|
||||
this.areaCode = areaCode;
|
||||
}
|
||||
|
||||
public String getSubmitUser() {
|
||||
return submitUser;
|
||||
}
|
||||
|
||||
public void setSubmitUser(String submitUser) {
|
||||
this.submitUser = submitUser;
|
||||
}
|
||||
|
||||
public String getUseUser() {
|
||||
return useUser;
|
||||
}
|
||||
|
||||
public void setUseUser(String useUser) {
|
||||
this.useUser = useUser;
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,122 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 手持版本升级对象 pda_apk_version
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2023-04-06
|
||||
*/
|
||||
public class PdaApkVersion extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键标识 */
|
||||
private Long objid;
|
||||
|
||||
/** 版本号 */
|
||||
@Excel(name = "版本号")
|
||||
private Long versionCode;
|
||||
|
||||
/** 版本名 */
|
||||
@Excel(name = "版本名")
|
||||
private String versionName;
|
||||
|
||||
/** 信息 */
|
||||
@Excel(name = "信息")
|
||||
private String modifyContent;
|
||||
|
||||
/** 位置 */
|
||||
@Excel(name = "位置")
|
||||
private String downloadUrl;
|
||||
|
||||
/** 文件大小 */
|
||||
@Excel(name = "文件大小")
|
||||
private Long apkSize;
|
||||
|
||||
/** 文件标识 */
|
||||
@Excel(name = "文件标识")
|
||||
private String apkMd5;
|
||||
|
||||
public void setObjid(Long objid)
|
||||
{
|
||||
this.objid = objid;
|
||||
}
|
||||
|
||||
public Long getObjid()
|
||||
{
|
||||
return objid;
|
||||
}
|
||||
public void setVersionCode(Long versionCode)
|
||||
{
|
||||
this.versionCode = versionCode;
|
||||
}
|
||||
|
||||
public Long getVersionCode()
|
||||
{
|
||||
return versionCode;
|
||||
}
|
||||
public void setVersionName(String versionName)
|
||||
{
|
||||
this.versionName = versionName;
|
||||
}
|
||||
|
||||
public String getVersionName()
|
||||
{
|
||||
return versionName;
|
||||
}
|
||||
public void setModifyContent(String modifyContent)
|
||||
{
|
||||
this.modifyContent = modifyContent;
|
||||
}
|
||||
|
||||
public String getModifyContent()
|
||||
{
|
||||
return modifyContent;
|
||||
}
|
||||
public void setDownloadUrl(String downloadUrl)
|
||||
{
|
||||
this.downloadUrl = downloadUrl;
|
||||
}
|
||||
|
||||
public String getDownloadUrl()
|
||||
{
|
||||
return downloadUrl;
|
||||
}
|
||||
public void setApkSize(Long apkSize)
|
||||
{
|
||||
this.apkSize = apkSize;
|
||||
}
|
||||
|
||||
public Long getApkSize()
|
||||
{
|
||||
return apkSize;
|
||||
}
|
||||
public void setApkMd5(String apkMd5)
|
||||
{
|
||||
this.apkMd5 = apkMd5;
|
||||
}
|
||||
|
||||
public String getApkMd5()
|
||||
{
|
||||
return apkMd5;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objid", getObjid())
|
||||
.append("versionCode", getVersionCode())
|
||||
.append("versionName", getVersionName())
|
||||
.append("modifyContent", getModifyContent())
|
||||
.append("downloadUrl", getDownloadUrl())
|
||||
.append("apkSize", getApkSize())
|
||||
.append("apkMd5", getApkMd5())
|
||||
.append("createTime", getCreateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,66 @@
|
||||
package com.ruoyi.api.domain;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/1/19 13:45
|
||||
*/
|
||||
public class StockDto {
|
||||
private int index;
|
||||
private String epcCode;
|
||||
private String locationCode;
|
||||
private String state;
|
||||
private String createTime;
|
||||
private String remark;
|
||||
public String getCreateTime() {
|
||||
return createTime;
|
||||
}
|
||||
|
||||
public void setCreateTime(String createTime) {
|
||||
this.createTime = createTime;
|
||||
}
|
||||
|
||||
public String getState() {
|
||||
return state;
|
||||
}
|
||||
|
||||
public void setState(String state) {
|
||||
this.state = state;
|
||||
}
|
||||
|
||||
public int getIndex() {
|
||||
return index;
|
||||
}
|
||||
|
||||
public void setIndex(int index) {
|
||||
this.index = index;
|
||||
}
|
||||
|
||||
public String getEpcCode() {
|
||||
return epcCode;
|
||||
}
|
||||
|
||||
public void setEpcCode(String epcCode) {
|
||||
this.epcCode = epcCode;
|
||||
}
|
||||
|
||||
public String getLocationCode() {
|
||||
return locationCode;
|
||||
}
|
||||
|
||||
public void setLocationCode(String locationCode) {
|
||||
this.locationCode = locationCode;
|
||||
}
|
||||
|
||||
public String getRemark() {
|
||||
return remark;
|
||||
}
|
||||
|
||||
public void setRemark(String remark) {
|
||||
this.remark = remark;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "StockDto{" + "index=" + index + ", epcCode='" + epcCode + '\'' + ", locationCode='" + locationCode + '\'' + ", state='" + state + '\'' + '}';
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,89 @@
|
||||
package com.ruoyi.api.mapper;
|
||||
|
||||
import com.ruoyi.api.domain.CheckTaskInfo;
|
||||
import com.ruoyi.api.domain.InStoreDto;
|
||||
import com.ruoyi.api.domain.OutStoreDto;
|
||||
import com.ruoyi.api.domain.StockDto;
|
||||
import com.ruoyi.manage.domain.LedgerRfid;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/1/17 14:28
|
||||
*/
|
||||
@Repository
|
||||
public interface ApiMapper {
|
||||
int submintInsertRecordIn(@Param("inStore") InStoreDto inStore);
|
||||
|
||||
int submintInsertLedger(@Param("inStore") InStoreDto inStore);
|
||||
|
||||
int submitInsertRecordOut(@Param("outStoreDto") OutStoreDto outStoreDto,@Param("epc") String epc);
|
||||
|
||||
int updataLedger(@Param("outStoreDto") OutStoreDto outStoreDto);
|
||||
|
||||
List<StockDto> storeCheckSelect();
|
||||
|
||||
void insertCheckInfo(@Param("list") List<StockDto> list, @Param("id") Long checkId);
|
||||
|
||||
List<StockDto> xjSelect(String user);
|
||||
|
||||
LedgerRfid bfSelect(String epc);
|
||||
|
||||
void updataLedgerForBf(@Param("epc") String epc, @Param("state") String state);
|
||||
|
||||
LedgerRfid fpInSelect(String epc);
|
||||
|
||||
int fpInSubmit(@Param("epc") String epc, @Param("localtionCode") String localtionCode,
|
||||
@Param("user") String user, @Param("bf") String bf, @Param("subCode") String subCode);
|
||||
|
||||
void updataLedgerIn(@Param("epc") String epc,@Param("code") String locationCode);
|
||||
|
||||
void insertInspectionInfo(@Param("list") List<StockDto> list,@Param("id") Long inspectionId);
|
||||
|
||||
List<StockDto> fpOutSelect();
|
||||
|
||||
void insertWasreOutRecord(@Param("list") List<StockDto> list,@Param("user") String user);
|
||||
|
||||
void updataLedgerForWasreOut(@Param("list")List<StockDto> list);
|
||||
|
||||
String selectLedgerbyEpcForInStore(String epc);
|
||||
|
||||
String selectLedgerbyEpcForOutStore(String epc);
|
||||
|
||||
int updataLedgerFoyOut(@Param("outStoreDto") OutStoreDto outStoreDto, @Param("epc") String epc);
|
||||
|
||||
List<CheckTaskInfo> selectLocationByAreaUser(String user);
|
||||
|
||||
void insertCheckTask(@Param("id") int id,@Param("list") List<CheckTaskInfo> list);
|
||||
|
||||
List<CheckTaskInfo> inspectionSelectTask(@Param("state") String state,
|
||||
@Param("id")int id);
|
||||
|
||||
List<StockDto> inspectionSelectLocation(String code);
|
||||
|
||||
void updataInspectionTaskByObjid( @Param("tableId")long tableId,
|
||||
@Param("remark") String remark,
|
||||
@Param("state") String state
|
||||
);
|
||||
|
||||
void insertInspetionPictrue(@Param("inspetionId") long inspectionId,
|
||||
@Param("tableId") long tableId,
|
||||
@Param("user") String user,
|
||||
@Param("pathName") String pathName,
|
||||
@Param("locationCode") String locationCode
|
||||
);
|
||||
|
||||
void insertBfImg(@Param("objid") Long objid,
|
||||
@Param("epc") String epc,
|
||||
@Param("user") String user,
|
||||
@Param("pathName") String pathName);
|
||||
|
||||
List<CheckTaskInfo> selectLocationFromLedger();
|
||||
|
||||
int selectCodeFromRecode();
|
||||
|
||||
void deleteInspectionInfo(@Param("inspectionId") long inspectionId,@Param("locationCode") String locationCode);
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
package com.ruoyi.api.mapper;
|
||||
|
||||
import com.ruoyi.api.domain.BroadCountNumber;
|
||||
import com.ruoyi.api.domain.NoPowerDevice;
|
||||
import com.ruoyi.manage.domain.BaseStore;
|
||||
import com.ruoyi.manage.domain.LedgerRfid;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/3/1 13:30
|
||||
*/
|
||||
@Repository
|
||||
public interface BroadApiMapper {
|
||||
|
||||
|
||||
List<BaseStore> getArea();
|
||||
|
||||
List<BroadCountNumber> getCountNumberById(int id);
|
||||
|
||||
List<LedgerRfid> getLedgerByCode(String locationCode);
|
||||
|
||||
List<NoPowerDevice> getDevice(String storeName);
|
||||
}
|
||||
@ -0,0 +1,26 @@
|
||||
package com.ruoyi.api.mapper;
|
||||
|
||||
import com.ruoyi.api.domain.APKVersion;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by wangh on 2021/4/26-9:32。
|
||||
*/
|
||||
@Repository
|
||||
public interface LoginMapper {
|
||||
String login_findSalt(String name);
|
||||
|
||||
int login_getUser(@Param("name") String name, @Param("passw") String passw);
|
||||
|
||||
List<String> selectMenuNameByUserID(Integer userID);
|
||||
|
||||
APKVersion getVersion();
|
||||
|
||||
List<String> selectMenuName();
|
||||
|
||||
SysUser login_getUser1(@Param("name")String name, @Param("passw")String md5Str);
|
||||
}
|
||||
@ -0,0 +1,66 @@
|
||||
package com.ruoyi.api.mapper;
|
||||
|
||||
import com.ruoyi.api.domain.PdaApkVersion;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 手持版本升级Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2023-04-06
|
||||
*/
|
||||
@Repository
|
||||
public interface PdaApkVersionMapper
|
||||
{
|
||||
/**
|
||||
* 查询手持版本升级
|
||||
*
|
||||
* @param objid 手持版本升级主键
|
||||
* @return 手持版本升级
|
||||
*/
|
||||
public PdaApkVersion selectPdaApkVersionByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 查询手持版本升级列表
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 手持版本升级集合
|
||||
*/
|
||||
public List<PdaApkVersion> selectPdaApkVersionList(PdaApkVersion pdaApkVersion);
|
||||
|
||||
/**
|
||||
* 新增手持版本升级
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertPdaApkVersion(PdaApkVersion pdaApkVersion);
|
||||
|
||||
/**
|
||||
* 修改手持版本升级
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 结果
|
||||
*/
|
||||
public int updatePdaApkVersion(PdaApkVersion pdaApkVersion);
|
||||
|
||||
/**
|
||||
* 删除手持版本升级
|
||||
*
|
||||
* @param objid 手持版本升级主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePdaApkVersionByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 批量删除手持版本升级
|
||||
*
|
||||
* @param objids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePdaApkVersionByObjids(String[] objids);
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,64 @@
|
||||
package com.ruoyi.api.service;
|
||||
|
||||
import com.ruoyi.api.domain.PdaApkVersion;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 手持版本升级Service接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2023-04-06
|
||||
*/
|
||||
public interface IPdaApkVersionService {
|
||||
|
||||
/**
|
||||
* 查询手持版本升级
|
||||
*
|
||||
* @param objid 手持版本升级主键
|
||||
* @return 手持版本升级
|
||||
*/
|
||||
public PdaApkVersion selectPdaApkVersionByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 查询手持版本升级列表
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 手持版本升级集合
|
||||
*/
|
||||
public List<PdaApkVersion> selectPdaApkVersionList(PdaApkVersion pdaApkVersion);
|
||||
|
||||
/**
|
||||
* 新增手持版本升级
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertPdaApkVersion(PdaApkVersion pdaApkVersion);
|
||||
|
||||
/**
|
||||
* 修改手持版本升级
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 结果
|
||||
*/
|
||||
public int updatePdaApkVersion(PdaApkVersion pdaApkVersion);
|
||||
|
||||
/**
|
||||
* 批量删除手持版本升级
|
||||
*
|
||||
* @param objids 需要删除的手持版本升级主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePdaApkVersionByObjids(String objids);
|
||||
|
||||
/**
|
||||
* 删除手持版本升级信息
|
||||
*
|
||||
* @param objid 手持版本升级主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePdaApkVersionByObjid(Long objid);
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,143 @@
|
||||
package com.ruoyi.api.service.impl;
|
||||
|
||||
import com.ruoyi.api.domain.CheckTaskInfo;
|
||||
import com.ruoyi.api.domain.InStoreDto;
|
||||
import com.ruoyi.api.domain.OutStoreDto;
|
||||
import com.ruoyi.api.domain.StockDto;
|
||||
import com.ruoyi.api.mapper.ApiMapper;
|
||||
import com.ruoyi.manage.domain.LedgerRfid;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/1/17 14:26
|
||||
*/
|
||||
@Service
|
||||
public class ApiService {
|
||||
@Autowired
|
||||
private ApiMapper mapper;
|
||||
|
||||
@Transactional
|
||||
public int submintInsertRecordIn(InStoreDto inStore) {
|
||||
return mapper.submintInsertRecordIn(inStore);
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public int submintInsertLedger(InStoreDto inStore) {
|
||||
return mapper.submintInsertLedger(inStore);
|
||||
}
|
||||
|
||||
public int submitInsertRecordOut(OutStoreDto outStoreDto, String epc) {
|
||||
return mapper.submitInsertRecordOut(outStoreDto, epc);
|
||||
}
|
||||
|
||||
public int updataLedger(OutStoreDto outStoreDto) {
|
||||
return mapper.updataLedger(outStoreDto);
|
||||
}
|
||||
|
||||
public List<StockDto> storeCheckSelect() {
|
||||
return mapper.storeCheckSelect();
|
||||
}
|
||||
|
||||
public void insertCheckInfo(List<StockDto> list, Long checkId) {
|
||||
mapper.insertCheckInfo(list, checkId);
|
||||
}
|
||||
|
||||
public List<StockDto> xjSelect(String user) {
|
||||
return mapper.xjSelect(user);
|
||||
}
|
||||
|
||||
public LedgerRfid bfSelect(String epc) {
|
||||
return mapper.bfSelect(epc);
|
||||
}
|
||||
|
||||
public void updataLedgerForBf(String epc, String state) {
|
||||
mapper.updataLedgerForBf(epc, state);
|
||||
}
|
||||
|
||||
public LedgerRfid fpInSelect(String epc) {
|
||||
return mapper.fpInSelect(epc);
|
||||
}
|
||||
|
||||
public int fpInSubmit(String epc, String localtionCode, String user, String bf, String subCode) {
|
||||
return mapper.fpInSubmit(epc, localtionCode, user, bf, subCode);
|
||||
}
|
||||
|
||||
public void updataLedgerIn(String epc, String locationCode) {
|
||||
mapper.updataLedgerIn(epc, locationCode);
|
||||
}
|
||||
|
||||
public void insertInspectionInfo(List<StockDto> list, Long inspectionId) {
|
||||
mapper.insertInspectionInfo(list, inspectionId);
|
||||
}
|
||||
|
||||
public List<StockDto> fpOutSelect() {
|
||||
return mapper.fpOutSelect();
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public void insertWasreOutRecord(List<StockDto> list, String user) {
|
||||
mapper.insertWasreOutRecord(list, user);
|
||||
}
|
||||
|
||||
@Transactional
|
||||
public void updataLedgerForWasreOut(List<StockDto> list, String user) {
|
||||
mapper.updataLedgerForWasreOut(list);
|
||||
}
|
||||
|
||||
public String selectLedgerbyEpcForInStore(String epc) {
|
||||
return mapper.selectLedgerbyEpcForInStore(epc);
|
||||
}
|
||||
|
||||
public String selectLedgerbyEpcForOutStore(String epc) {
|
||||
return mapper.selectLedgerbyEpcForOutStore(epc);
|
||||
}
|
||||
|
||||
public int updataLedgerFoyOut(OutStoreDto outStoreDto, String epc) {
|
||||
return mapper.updataLedgerFoyOut(outStoreDto, epc);
|
||||
}
|
||||
|
||||
public List<CheckTaskInfo> selectLocationByAreaUser(String user) {
|
||||
return mapper.selectLocationByAreaUser(user);
|
||||
}
|
||||
|
||||
public void insertCheckTask(int id, List<CheckTaskInfo> list) {
|
||||
mapper.insertCheckTask(id, list);
|
||||
}
|
||||
|
||||
public List<CheckTaskInfo> inspectionSelectTask(String state,int id) {
|
||||
return mapper.inspectionSelectTask(state,id);
|
||||
}
|
||||
|
||||
public List<StockDto> inspectionSelectLocation(String code) {
|
||||
return mapper.inspectionSelectLocation(code);
|
||||
}
|
||||
|
||||
public void updataInspectionTaskByObjid(long tableId, String remark,String state) {
|
||||
mapper.updataInspectionTaskByObjid(tableId,remark,state);
|
||||
}
|
||||
|
||||
public void insertInspetionPictrue(long inspectionId, long tableId, String user, String pathName,String locationCode) {
|
||||
mapper.insertInspetionPictrue(inspectionId, tableId,user, pathName,locationCode);
|
||||
}
|
||||
|
||||
public void insertBfImg(Long objid, String epc, String user, String pathName) {
|
||||
mapper.insertBfImg(objid,epc,user, pathName);
|
||||
}
|
||||
|
||||
public List<CheckTaskInfo> selectLocationFromLedger() {
|
||||
return mapper.selectLocationFromLedger();
|
||||
}
|
||||
|
||||
public int selectCodeFromRecode() {
|
||||
return mapper.selectCodeFromRecode();
|
||||
}
|
||||
|
||||
public void deleteInspectionInfo(String locationCode, long inspectionId) {
|
||||
mapper.deleteInspectionInfo(inspectionId,locationCode);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,41 @@
|
||||
package com.ruoyi.api.service.impl;
|
||||
|
||||
import com.ruoyi.api.domain.BroadCountNumber;
|
||||
import com.ruoyi.api.domain.NoPowerDevice;
|
||||
import com.ruoyi.api.mapper.BroadApiMapper;
|
||||
import com.ruoyi.common.annotation.DataSource;
|
||||
import com.ruoyi.common.enums.DataSourceType;
|
||||
import com.ruoyi.manage.domain.BaseStore;
|
||||
import com.ruoyi.manage.domain.LedgerRfid;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author wanghao
|
||||
* @date 2024/3/1 13:30
|
||||
*/
|
||||
@Service
|
||||
public class BroadApiService {
|
||||
@Autowired
|
||||
private BroadApiMapper mapper;
|
||||
|
||||
|
||||
public List<BaseStore> getArea() {
|
||||
return mapper.getArea();
|
||||
}
|
||||
|
||||
public List<BroadCountNumber> getCountNumberById(int id) {
|
||||
return mapper.getCountNumberById(id);
|
||||
}
|
||||
|
||||
public List<LedgerRfid> getLedgerByCode(String locationCode) {
|
||||
return mapper.getLedgerByCode(locationCode);
|
||||
}
|
||||
|
||||
@DataSource(value = DataSourceType.SLAVE)
|
||||
public List<NoPowerDevice> getDevice(String storeName) {
|
||||
return mapper.getDevice(storeName);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,105 @@
|
||||
package com.ruoyi.api.service.impl;
|
||||
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.api.domain.APKVersion;
|
||||
import com.ruoyi.api.mapper.LoginMapper;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.domain.entity.SysUser;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.security.MessageDigest;
|
||||
import java.security.NoSuchAlgorithmException;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by wangh on 2021/4/26-9:27。
|
||||
*/
|
||||
@Service
|
||||
public class LoginService {
|
||||
|
||||
@Autowired
|
||||
LoginMapper mapper;
|
||||
|
||||
public String login(String name, String pass) {
|
||||
try {
|
||||
String salt = mapper.login_findSalt(name);
|
||||
Integer userID = mapper.login_getUser(name, getMD5Str(name + pass + salt));
|
||||
if (userID != null) {
|
||||
List<String> menuNameList=name.equals("admin")?
|
||||
mapper.selectMenuName():
|
||||
mapper.selectMenuNameByUserID(userID);
|
||||
if (menuNameList==null||menuNameList.isEmpty()){
|
||||
return "isEmpty";
|
||||
}
|
||||
return JSONObject.toJSONString(menuNameList);
|
||||
} else {
|
||||
return "Error";
|
||||
}
|
||||
}catch (Exception e){
|
||||
return "Error";
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public AjaxResult login1(String name, String pass) {
|
||||
try {
|
||||
String salt = mapper.login_findSalt(name);
|
||||
SysUser user = mapper.login_getUser1(name, getMD5Str(name + pass + salt));
|
||||
if (user != null) {
|
||||
return AjaxResult.success(user);
|
||||
} else {
|
||||
return AjaxResult.error();
|
||||
}
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
return AjaxResult.error();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private static String getMD5Str(String str) {
|
||||
MessageDigest messageDigest = null;
|
||||
|
||||
try {
|
||||
messageDigest = MessageDigest.getInstance("MD5");
|
||||
|
||||
messageDigest.reset();
|
||||
|
||||
messageDigest.update(str.getBytes("UTF-8"));
|
||||
} catch (NoSuchAlgorithmException e) {
|
||||
System.out.println("NoSuchAlgorithmException caught!");
|
||||
System.exit(-1);
|
||||
} catch (UnsupportedEncodingException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
byte[] byteArray = messageDigest.digest();
|
||||
|
||||
StringBuffer md5StrBuff = new StringBuffer();
|
||||
|
||||
for (int i = 0; i < byteArray.length; i++) {
|
||||
if (Integer.toHexString(0xFF & byteArray[i]).length() == 1) {
|
||||
|
||||
|
||||
md5StrBuff.append("0").append(Integer.toHexString(0xFF & byteArray[i]));
|
||||
} else {
|
||||
|
||||
|
||||
md5StrBuff.append(Integer.toHexString(0xFF & byteArray[i]));
|
||||
}
|
||||
}
|
||||
|
||||
return md5StrBuff.toString();
|
||||
}
|
||||
|
||||
public APKVersion getVersion() {
|
||||
return mapper.getVersion();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,99 @@
|
||||
package com.ruoyi.api.service.impl;
|
||||
|
||||
import com.ruoyi.api.domain.PdaApkVersion;
|
||||
import com.ruoyi.api.mapper.PdaApkVersionMapper;
|
||||
import com.ruoyi.api.service.IPdaApkVersionService;
|
||||
import com.ruoyi.common.core.text.Convert;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 手持版本升级Service业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2023-04-06
|
||||
*/
|
||||
@Service
|
||||
public class PdaApkVersionServiceImpl implements IPdaApkVersionService
|
||||
{
|
||||
@Autowired
|
||||
private PdaApkVersionMapper pdaApkVersionMapper;
|
||||
|
||||
/**
|
||||
* 查询手持版本升级
|
||||
*
|
||||
* @param objid 手持版本升级主键
|
||||
* @return 手持版本升级
|
||||
*/
|
||||
@Override
|
||||
public PdaApkVersion selectPdaApkVersionByObjid(Long objid)
|
||||
{
|
||||
return pdaApkVersionMapper.selectPdaApkVersionByObjid(objid);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询手持版本升级列表
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 手持版本升级
|
||||
*/
|
||||
@Override
|
||||
public List<PdaApkVersion> selectPdaApkVersionList(PdaApkVersion pdaApkVersion)
|
||||
{
|
||||
return pdaApkVersionMapper.selectPdaApkVersionList(pdaApkVersion);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增手持版本升级
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertPdaApkVersion(PdaApkVersion pdaApkVersion)
|
||||
{
|
||||
pdaApkVersion.setCreateTime(DateUtils.getNowDate());
|
||||
return pdaApkVersionMapper.insertPdaApkVersion(pdaApkVersion);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改手持版本升级
|
||||
*
|
||||
* @param pdaApkVersion 手持版本升级
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updatePdaApkVersion(PdaApkVersion pdaApkVersion)
|
||||
{
|
||||
return pdaApkVersionMapper.updatePdaApkVersion(pdaApkVersion);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除手持版本升级
|
||||
*
|
||||
* @param objids 需要删除的手持版本升级主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deletePdaApkVersionByObjids(String objids)
|
||||
{
|
||||
return pdaApkVersionMapper.deletePdaApkVersionByObjids(Convert.toStrArray(objids));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除手持版本升级信息
|
||||
*
|
||||
* @param objid 手持版本升级主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deletePdaApkVersionByObjid(Long objid)
|
||||
{
|
||||
return pdaApkVersionMapper.deletePdaApkVersionByObjid(objid);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,37 @@
|
||||
package com.ruoyi.api.service.impl;
|
||||
|
||||
import com.ruoyi.api.domain.CheckTaskInfo;
|
||||
import com.ruoyi.api.mapper.ApiMapper;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.manage.domain.RecordInspection;
|
||||
import com.ruoyi.manage.mapper.RecordInspectionMapper;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
@Service
|
||||
@Component("TaskService")
|
||||
public class TaskService {
|
||||
|
||||
@Autowired
|
||||
private ApiMapper mapper;
|
||||
@Autowired
|
||||
private RecordInspectionMapper recordInspectionMapper;
|
||||
|
||||
//定时任务创建巡检单
|
||||
public void inspectionCreate(){
|
||||
System.out.println("创建成功");
|
||||
int number=recordInspectionMapper.countInsertRecordNumber();
|
||||
number++;
|
||||
RecordInspection recordInspection = new RecordInspection();
|
||||
recordInspection.setInspectionCode(DateUtils.parseDateToStr("yyyyMMdd",new Date())+"00"+number);
|
||||
System.out.println();
|
||||
//插入主表
|
||||
int insertNumber = recordInspectionMapper.insertRecordInspection(recordInspection);
|
||||
List<CheckTaskInfo> list = mapper.selectLocationFromLedger();
|
||||
mapper.insertCheckTask(Math.toIntExact(recordInspection.getInspectionId()), list);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,15 @@
|
||||
-- auto-generated definition
|
||||
create table pda_apk_version
|
||||
(
|
||||
objid int auto_increment comment '主键标识'
|
||||
primary key,
|
||||
version_code int null comment '版本号',
|
||||
version_name varchar(20) null comment '版本名',
|
||||
modify_content varchar(100) null comment '信息',
|
||||
download_url varchar(200) null comment '位置',
|
||||
apk_size int null comment '文件大小',
|
||||
apk_md5 varchar(200) null comment '文件标识',
|
||||
create_time datetime default CURRENT_TIMESTAMP null comment '创建时间'
|
||||
)
|
||||
comment '手持版本升级' charset = utf8
|
||||
row_format = DYNAMIC;
|
||||
@ -0,0 +1,22 @@
|
||||
-- 菜单 SQL
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('手持版本升级', '3', '1', '/pda/pda_version', 'C', '0', 'pda:pda_version:view', '#', 'admin', sysdate(), '', null, '手持版本升级菜单');
|
||||
|
||||
-- 按钮父菜单ID
|
||||
SELECT @parentId := LAST_INSERT_ID();
|
||||
|
||||
-- 按钮 SQL
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('手持版本升级查询', @parentId, '1', '#', 'F', '0', 'pda:pda_version:list', '#', 'admin', sysdate(), '', null, '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('手持版本升级新增', @parentId, '2', '#', 'F', '0', 'pda:pda_version:add', '#', 'admin', sysdate(), '', null, '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('手持版本升级修改', @parentId, '3', '#', 'F', '0', 'pda:pda_version:edit', '#', 'admin', sysdate(), '', null, '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('手持版本升级删除', @parentId, '4', '#', 'F', '0', 'pda:pda_version:remove', '#', 'admin', sysdate(), '', null, '');
|
||||
|
||||
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
|
||||
values('手持版本升级导出', @parentId, '5', '#', 'F', '0', 'pda:pda_version:export', '#', 'admin', sysdate(), '', null, '');
|
||||
@ -0,0 +1,284 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.api.mapper.ApiMapper">
|
||||
|
||||
|
||||
<select id="selectLedgerbyEpcForOutStore" resultType="string">
|
||||
select rifd_code from ledger_rfid where rifd_code = #{epc}
|
||||
and is_scrap in (1,4)
|
||||
and location_type = '1'
|
||||
limit 1
|
||||
</select>
|
||||
<select id="selectLedgerbyEpcForInStore" resultType="string">
|
||||
select rifd_code from ledger_rfid where rifd_code = #{epc} limit 1
|
||||
</select>
|
||||
<insert id="submintInsertRecordIn">
|
||||
INSERT ignore into record_in (epc_code, batch_code, location_code,manufacturer_id,
|
||||
manufacturer_Name,
|
||||
create_by,create_time)
|
||||
VALUES
|
||||
<foreach collection="inStore.epclist" item="item" separator=",">
|
||||
(#{item},#{inStore.binchCode},#{inStore.selectLocationText},#{inStore.manufacturerId},#{inStore.selectManuText},#{inStore.submitUser},now())
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
|
||||
<insert id="submintInsertLedger">
|
||||
INSERT ignore into ledger_rfid (manufacturer_id, rifd_code, batch_code, location_code)
|
||||
VALUES
|
||||
<foreach collection="inStore.epclist" item="item" separator=",">
|
||||
(#{inStore.manufacturerId},#{item},#{inStore.binchCode},#{inStore.selectLocationText})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<!-- -->
|
||||
|
||||
<insert id="submitInsertRecordOut">
|
||||
INSERT INTO record_out (epc_code, location_code, use_user, create_by)
|
||||
VALUES
|
||||
<foreach collection="outStoreDto.epcList" item="epc" separator=",">
|
||||
(
|
||||
#{epc}, #{outStoreDto.areaCode}, #{outStoreDto.useUser}, #{outStoreDto.submitUser}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<update id="updataLedger">
|
||||
UPDATE ledger_rfid
|
||||
SET
|
||||
location_type = '2',
|
||||
location_code = #{outStoreDto.areaCode},
|
||||
update_time = now()
|
||||
WHERE rifd_code in
|
||||
<foreach collection="outStoreDto.epcList" item="epc" separator="," open="(" close=")">
|
||||
#{epc}
|
||||
</foreach>
|
||||
</update>
|
||||
<update id="updataLedgerFoyOut">
|
||||
UPDATE ledger_rfid
|
||||
SET
|
||||
location_type = '2',
|
||||
location_code = #{outStoreDto.areaCode},
|
||||
is_scrap =1,
|
||||
update_time = now()
|
||||
WHERE rifd_code =#{epc}
|
||||
</update>
|
||||
|
||||
<select id="storeCheckSelect" resultType="com.ruoyi.api.domain.StockDto">
|
||||
select row_number() over (order by location_code) as 'index',
|
||||
rifd_code as epcCode,
|
||||
location_code as locationCode,
|
||||
'N' as state
|
||||
from ledger_rfid
|
||||
where location_type = 1
|
||||
and is_scrap = 1
|
||||
</select>
|
||||
|
||||
<insert id="insertCheckInfo">
|
||||
INSERT INTO record_store_check_info (check_id, epc_code, location_code, check_state)
|
||||
VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(#{id}, #{item.epcCode},#{item.locationCode},#{item.state})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<select id="xjSelect" resultType="com.ruoyi.api.domain.StockDto">
|
||||
select row_number() over (order by lf.location_code) as 'index',
|
||||
rifd_code as epcCode,
|
||||
lf.location_code as locationCode,
|
||||
lf.create_time as createTime,
|
||||
'未检' as state
|
||||
from ledger_rfid lf
|
||||
left join base_location bl on lf.location_code = bl.location_code
|
||||
left join base_area_user bau on bl.store_id = bau.area_id
|
||||
where user_id = #{user}
|
||||
and is_scrap = 1
|
||||
</select>
|
||||
|
||||
<select id="bfSelect" resultMap="com.ruoyi.manage.mapper.LedgerRfidMapper.LedgerRfidResult">
|
||||
select objid,
|
||||
manufacturer_id,
|
||||
rifd_code,
|
||||
batch_code,
|
||||
location_type,
|
||||
location_code,
|
||||
dict_label
|
||||
from ledger_rfid lf
|
||||
left join sys_dict_data sdd on sdd.dict_value = is_scrap and sdd.dict_type = 'bf_y_n'
|
||||
where rifd_code = #{epc}
|
||||
</select>
|
||||
<update id="updataLedgerForBf">
|
||||
UPDATE ledger_rfid
|
||||
SET is_scrap = #{state},
|
||||
update_time=now()
|
||||
WHERE rifd_code = #{epc}
|
||||
</update>
|
||||
|
||||
<select id="fpInSelect" resultMap="com.ruoyi.manage.mapper.LedgerRfidMapper.LedgerRfidResult">
|
||||
select rifd_code,
|
||||
batch_code,
|
||||
sdd1.dict_label as location_type,
|
||||
location_code,
|
||||
sdd.dict_label,
|
||||
ri.create_time
|
||||
from ledger_rfid lf
|
||||
left join sys_dict_data sdd on sdd.dict_value = is_scrap and sdd.dict_type = 'bf_y_n'
|
||||
left join sys_dict_data sdd1 on sdd1.dict_value = location_type and sdd1.dict_type = 'store_tag'
|
||||
left join record_invalidated ri on lf.rifd_code = ri.epc
|
||||
where rifd_code = #{epc}
|
||||
limit 1
|
||||
</select>
|
||||
<insert id="fpInSubmit">
|
||||
INSERT INTO record_waste_in (epc, location_code, bf_time, in_code, create_by)
|
||||
VALUES (#{epc}, #{localtionCode}, #{bf}, #{subCode}, #{user});
|
||||
|
||||
</insert>
|
||||
<update id="updataLedgerIn">
|
||||
UPDATE ledger_rfid
|
||||
SET location_type = '1',
|
||||
location_code = #{code},
|
||||
update_time = now()
|
||||
WHERE rifd_code = #{epc}
|
||||
</update>
|
||||
|
||||
<insert id="insertInspectionInfo">
|
||||
INSERT INTO record_inspection_info (inspection_id, epc_code, location_code, inspection_state,
|
||||
inspection_remark)
|
||||
VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(#{id}, #{item.epcCode},#{item.locationCode},#{item.state}, #{item.remark})
|
||||
</foreach>
|
||||
|
||||
|
||||
</insert>
|
||||
|
||||
<select id="fpOutSelect" resultType="com.ruoyi.api.domain.StockDto">
|
||||
select row_number() over (order by location_code) as 'index',
|
||||
rifd_code as epcCode,
|
||||
location_code as locationCode,
|
||||
'N' as state
|
||||
from ledger_rfid
|
||||
where location_type = 1
|
||||
and is_scrap = 2
|
||||
</select>
|
||||
|
||||
<insert id="insertWasreOutRecord">
|
||||
INSERT INTO record_waste_out (epc_code, location_code, create_by) VALUES
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
( #{item.epcCode},#{item.locationCode},#{user})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<update id="updataLedgerForWasreOut">
|
||||
UPDATE ledger_rfid
|
||||
SET location_type = null,
|
||||
location_code = null,
|
||||
is_scrap = '3',
|
||||
update_time = now()
|
||||
<where>
|
||||
rifd_code in
|
||||
<foreach item="item" collection="list" open="(" separator="," close=")">
|
||||
#{item.epcCode}
|
||||
</foreach>
|
||||
|
||||
</where>
|
||||
</update>
|
||||
|
||||
<resultMap id="checkTaskResultMap" type="com.ruoyi.api.domain.CheckTaskInfo">
|
||||
<result column="index" property="index"/>
|
||||
<result column="location_code" property="locationCode"/>
|
||||
<result column="plane_position" property="locationCode"/>
|
||||
<result column="store_name" property="areaName"/>
|
||||
<result column="area_name" property="areaName"/>
|
||||
<result column="task_state" property="taskState"/>
|
||||
<result column="objid" property="id"/>
|
||||
<result column="area_id" property="areaId"/>
|
||||
<result column="store_id" property="areaId"/>
|
||||
<result column="inspection_id" property="inspectionId"/>
|
||||
|
||||
</resultMap>
|
||||
<select id="selectLocationByAreaUser" resultMap="checkTaskResultMap">
|
||||
select bs.store_id as objid ,
|
||||
bs.store_name,
|
||||
location_code
|
||||
from base_location bl
|
||||
left join base_store bs on bl.store_id = bs.store_id
|
||||
right join base_area_user bau on bau.area_id = bl.store_id
|
||||
where bl.stote_tag = 2 and bau.user_id=#{user}
|
||||
</select>
|
||||
<insert id="insertCheckTask">
|
||||
INSERT INTO record_inspection_task (inspection_id, area_id,area_name, plane_position) VALUES
|
||||
<foreach collection="list" item="data" separator=",">
|
||||
(#{id}, #{data.id}, #{data.areaName}, #{data.locationCode})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
|
||||
<select id="inspectionSelectTask" resultMap="checkTaskResultMap">
|
||||
select rit.objid,
|
||||
area_id,
|
||||
area_name,
|
||||
plane_position,
|
||||
row_number() over (order by rit.objid) as 'index',
|
||||
task_state,
|
||||
rit.inspection_id
|
||||
from record_inspection_task rit
|
||||
|
||||
<where>
|
||||
inspection_id=#{id}
|
||||
<if test="state != null and state != '全部'">
|
||||
AND task_state = #{state}
|
||||
</if>
|
||||
</where>
|
||||
|
||||
</select>
|
||||
|
||||
<select id="inspectionSelectLocation" resultType="com.ruoyi.api.domain.StockDto">
|
||||
select row_number() over (order by location_code) as 'index',
|
||||
rifd_code as epcCode,
|
||||
location_code as locationCode,
|
||||
create_time as createTime,
|
||||
'未检' as state
|
||||
from ledger_rfid
|
||||
where is_scrap = 1
|
||||
and location_code = #{code}
|
||||
</select>
|
||||
<!--完成任务-->
|
||||
<update id="updataInspectionTaskByObjid">
|
||||
UPDATE record_inspection_task SET task_state = #{state},remark = #{remark},update_time=now() WHERE objid = #{tableId};
|
||||
</update>
|
||||
|
||||
<insert id="insertInspetionPictrue">
|
||||
INSERT INTO record_inspection_img (inspection_id, task_id, img_path, create_by,location_code)
|
||||
VALUES (#{inspetionId},#{tableId}, #{pathName}, #{user},#{locationCode});
|
||||
</insert>
|
||||
|
||||
<insert id="insertBfImg">
|
||||
INSERT INTO bg_wheel_chocks.record_invalidated_img (invalidated_id, epc, img_path, create_by)
|
||||
VALUES (#{objid}, #{epc},#{pathName},#{user});
|
||||
</insert>
|
||||
<!--查询台账绑定RFID的机位信息-->
|
||||
<select id="selectLocationFromLedger" resultMap="checkTaskResultMap">
|
||||
select lr.location_code,
|
||||
bs.store_name,
|
||||
bs.store_id
|
||||
from ledger_rfid lr
|
||||
left join base_location bl on lr.location_code = bl.location_code
|
||||
left join base_store bs on bl.store_id = bs.store_id
|
||||
where lr.location_type = 2
|
||||
and is_scrap = 1
|
||||
group by bl.location_code
|
||||
order by bl.location_code
|
||||
</select>
|
||||
|
||||
<select id="selectCodeFromRecode" resultType="int">
|
||||
select inspection_id
|
||||
from record_inspection
|
||||
-- where date(inspection_time) = date(now())
|
||||
order by inspection_time desc
|
||||
limit 1
|
||||
</select>
|
||||
<delete id="deleteInspectionInfo">
|
||||
delete from bg_wheel_chocks.record_inspection_info where inspection_id = #{inspectionId} and location_code =#{locationCode}
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,52 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.api.mapper.BroadApiMapper">
|
||||
|
||||
|
||||
<select id="getArea" resultMap="com.ruoyi.manage.mapper.BaseStoreMapper.BaseStoreResult">
|
||||
select store_name,store_id from base_store where store_tag=2
|
||||
</select>
|
||||
<resultMap id="BroadCountNumberMap" type="com.ruoyi.api.domain.BroadCountNumber">
|
||||
<result property="areaName" column="store_name"/>
|
||||
<result property="locationCode" column="location_code"/>
|
||||
<result property="countNumber" column="conum"/>
|
||||
</resultMap>
|
||||
<select id="getCountNumberById" resultMap="BroadCountNumberMap">
|
||||
select bs.store_name, bl.location_code, count(lr.objid) as conum
|
||||
from base_location bl
|
||||
left join base_store bs on bs.store_id = bl.store_id
|
||||
left join ledger_rfid lr on bl.location_code = lr.location_code
|
||||
where stote_tag = 2
|
||||
and bl.store_id = #{id}
|
||||
group by bl.location_code
|
||||
</select>
|
||||
|
||||
|
||||
<select id="getLedgerByCode" resultMap="com.ruoyi.manage.mapper.LedgerRfidMapper.LedgerRfidResult">
|
||||
select manufacturer_name, rifd_code, batch_code, create_time
|
||||
from ledger_rfid lr
|
||||
left join base_manufacturer bm on lr.manufacturer_id = bm.manufacturer_id
|
||||
where is_scrap = 1
|
||||
and location_code = #{locationCode}
|
||||
</select>
|
||||
<resultMap id="DeviceResult" type="com.ruoyi.api.domain.NoPowerDevice">
|
||||
|
||||
<result property="deviceCode" column="device_code" />
|
||||
<result property="deviceName" column="device_name" />
|
||||
<result property="deviceType" column="device_type" />
|
||||
<result property="useState" column="use_state" />
|
||||
<result property="deviceState" column="device_state" />
|
||||
<result property="locationName" column="location_name" />
|
||||
|
||||
</resultMap>
|
||||
<select id="getDevice" resultMap="DeviceResult">
|
||||
select device_code, device_name, use_state, device_state, location.air_location as location_name
|
||||
from device_base_info info
|
||||
left join device_base_location location on info.location_name=location.rfid_code
|
||||
|
||||
where location.air_location =#{storeName}
|
||||
|
||||
</select>
|
||||
|
||||
|
||||
</mapper>
|
||||
@ -0,0 +1,51 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.api.mapper.LoginMapper">
|
||||
|
||||
<!--登陆-->
|
||||
<select id="login_getUser" resultType="java.lang.Integer">
|
||||
SELECT user_id FROM sys_user where login_name=#{name} and `password`=#{passw} limit 1;
|
||||
</select>
|
||||
|
||||
<select id="login_getUser1" resultMap="com.ruoyi.system.mapper.SysUserMapper.SysUserResult">
|
||||
SELECT user_id,dept_id FROM sys_user where login_name=#{name} and `password`=#{passw} limit 1;
|
||||
</select>
|
||||
|
||||
<select id="login_findSalt" resultType="java.lang.String">
|
||||
|
||||
SELECT salt FROM sys_user where login_name=#{name}
|
||||
</select>
|
||||
|
||||
<select id="selectMenuName" resultType="java.lang.String">
|
||||
select menu_name
|
||||
from sys_menu where parent_id=2027 order by order_num
|
||||
</select>
|
||||
<select id="selectMenuNameByUserID" resultType="java.lang.String">
|
||||
select menu_name
|
||||
from sys_role_menu r
|
||||
left join sys_menu m on r.menu_id = m.menu_id
|
||||
where r.role_id in (select role_id from sys_user_role where user_id=#{userID})
|
||||
and parent_id=2027
|
||||
group by menu_name,m.menu_id,m.order_num
|
||||
order by m.order_num;
|
||||
</select>
|
||||
|
||||
|
||||
<resultMap type="com.ruoyi.api.domain.APKVersion" id="PdaApkVersionResult">
|
||||
<result property="VersionCode" column="version_code" />
|
||||
<result property="VersionName" column="version_name" />
|
||||
<result property="ModifyContent" column="modify_content" />
|
||||
<result property="DownloadUrl" column="download_url" />
|
||||
<result property="ApkSize" column="apk_size" />
|
||||
<result property="ApkMd5" column="apk_md5" />
|
||||
</resultMap>
|
||||
|
||||
|
||||
<select id="getVersion" resultMap="PdaApkVersionResult">
|
||||
select version_code, version_name, modify_content, download_url, apk_size, apk_md5 from pda_apk_version order by create_time desc limit 1
|
||||
|
||||
</select>
|
||||
|
||||
|
||||
|
||||
</mapper>
|
||||
@ -0,0 +1,82 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.api.mapper.PdaApkVersionMapper">
|
||||
|
||||
<resultMap type="com.ruoyi.api.domain.PdaApkVersion" id="PdaApkVersionResult">
|
||||
<result property="objid" column="objid"/>
|
||||
<result property="versionCode" column="version_code"/>
|
||||
<result property="versionName" column="version_name"/>
|
||||
<result property="modifyContent" column="modify_content"/>
|
||||
<result property="downloadUrl" column="download_url"/>
|
||||
<result property="apkSize" column="apk_size"/>
|
||||
<result property="apkMd5" column="apk_md5"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectPdaApkVersionVo">
|
||||
select objid, version_code, version_name, modify_content, download_url, apk_size, apk_md5, create_time from pda_apk_version
|
||||
</sql>
|
||||
|
||||
<select id="selectPdaApkVersionList" parameterType="PdaApkVersion" resultMap="PdaApkVersionResult">
|
||||
<include refid="selectPdaApkVersionVo"/>
|
||||
<where>
|
||||
<if test="versionCode != null ">and version_code = #{versionCode}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectPdaApkVersionByObjid" parameterType="Long" resultMap="PdaApkVersionResult">
|
||||
<include refid="selectPdaApkVersionVo"/>
|
||||
where objid = #{objid}
|
||||
</select>
|
||||
|
||||
<insert id="insertPdaApkVersion" parameterType="PdaApkVersion" useGeneratedKeys="true" keyProperty="objid">
|
||||
insert into pda_apk_version
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="versionCode != null">version_code,</if>
|
||||
<if test="versionName != null">version_name,</if>
|
||||
<if test="modifyContent != null">modify_content,</if>
|
||||
<if test="downloadUrl != null">download_url,</if>
|
||||
<if test="apkSize != null">apk_size,</if>
|
||||
<if test="apkMd5 != null">apk_md5,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="versionCode != null">#{versionCode},</if>
|
||||
<if test="versionName != null">#{versionName},</if>
|
||||
<if test="modifyContent != null">#{modifyContent},</if>
|
||||
<if test="downloadUrl != null">#{downloadUrl},</if>
|
||||
<if test="apkSize != null">#{apkSize},</if>
|
||||
<if test="apkMd5 != null">#{apkMd5},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updatePdaApkVersion" parameterType="PdaApkVersion">
|
||||
update pda_apk_version
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="versionCode != null">version_code = #{versionCode},</if>
|
||||
<if test="versionName != null">version_name = #{versionName},</if>
|
||||
<if test="modifyContent != null">modify_content = #{modifyContent},</if>
|
||||
<if test="downloadUrl != null">download_url = #{downloadUrl},</if>
|
||||
<if test="apkSize != null">apk_size = #{apkSize},</if>
|
||||
<if test="apkMd5 != null">apk_md5 = #{apkMd5},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
</trim>
|
||||
where objid = #{objid}
|
||||
</update>
|
||||
|
||||
<delete id="deletePdaApkVersionByObjid" parameterType="Long">
|
||||
delete from pda_apk_version where objid = #{objid}
|
||||
</delete>
|
||||
|
||||
<delete id="deletePdaApkVersionByObjids" parameterType="String">
|
||||
delete from pda_apk_version where objid in
|
||||
<foreach item="objid" collection="array" open="(" separator="," close=")">
|
||||
#{objid}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
|
||||
</mapper>
|
||||
@ -0,0 +1,125 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('新增手持版本升级')" />
|
||||
<th:block th:include="include :: bootstrap-fileinput-css"/>
|
||||
<th:block th:include="include :: summernote-css" />
|
||||
</head>
|
||||
<body class="white-bg">
|
||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||
<form class="form-horizontal m" id="form-pda_version-add">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">版本号:</label>
|
||||
<div class="col-sm-8">
|
||||
<input name="versionCode" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">版本名:</label>
|
||||
<div class="col-sm-8">
|
||||
<input name="versionName" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">信息:</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="hidden" class="form-control" name="modifyContent">
|
||||
<div class="summernote" id="modifyContent"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">位置:</label>
|
||||
<div class="col-sm-8">
|
||||
<!-- <input type="hidden" name="downloadUrl">-->
|
||||
<!-- <div class="file-loading">-->
|
||||
<!-- <input class="form-control file-upload" id="downloadUrl" name="file" type="file">-->
|
||||
<input id="filePath" name="filePath" class="form-control" type="file">
|
||||
<!-- </div>-->
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<th:block th:include="include :: footer" />
|
||||
<th:block th:include="include :: bootstrap-fileinput-js"/>
|
||||
<th:block th:include="include :: summernote-js" />
|
||||
<script th:inline="javascript">
|
||||
var prefix = ctx + "pda/pda_version"
|
||||
$("#form-pda_version-add").validate({
|
||||
focusCleanup: true
|
||||
});
|
||||
|
||||
function submitHandler() {
|
||||
// if ($.validate.form()) {
|
||||
// $.operate.save(prefix + "/add", $('#form-pda_version-add').serialize());
|
||||
// }
|
||||
var formData = new FormData();
|
||||
if ($('#filePath')[0].files[0] == null) {
|
||||
$.modal.alertWarning("请先选择文件路径");
|
||||
return false;
|
||||
}
|
||||
formData.append('versionCode', $("input[name='versionCode']").val());
|
||||
formData.append('versionName', $("input[name='versionName']").val());
|
||||
formData.append('modifyContent', $("input[name='modifyContent']").val());
|
||||
formData.append('file', $('#filePath')[0].files[0]);
|
||||
$.ajax({
|
||||
url: prefix + "/add",
|
||||
type: 'post',
|
||||
cache: false,
|
||||
data: formData,
|
||||
processData: false,
|
||||
contentType: false,
|
||||
dataType: "json",
|
||||
success: function(result) {
|
||||
$.operate.successCallback(result);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// $(".file-upload").fileinput({
|
||||
// uploadUrl: ctx + 'common/upload',
|
||||
// maxFileCount: 1,
|
||||
// autoReplace: true
|
||||
// }).on('fileuploaded', function (event, data, previewId, index) {
|
||||
// $("input[name='" + event.currentTarget.id + "']").val(data.response.url)
|
||||
// }).on('fileremoved', function (event, id, index) {
|
||||
// $("input[name='" + event.currentTarget.id + "']").val('')
|
||||
// })
|
||||
|
||||
$(function() {
|
||||
$('.summernote').summernote({
|
||||
lang: 'zh-CN',
|
||||
dialogsInBody: true,
|
||||
callbacks: {
|
||||
onChange: function(contents, $edittable) {
|
||||
$("input[name='" + this.id + "']").val(contents);
|
||||
},
|
||||
onImageUpload: function(files) {
|
||||
var obj = this;
|
||||
var data = new FormData();
|
||||
data.append("file", files[0]);
|
||||
$.ajax({
|
||||
type: "post",
|
||||
url: ctx + "common/upload",
|
||||
data: data,
|
||||
cache: false,
|
||||
contentType: false,
|
||||
processData: false,
|
||||
dataType: 'json',
|
||||
success: function(result) {
|
||||
if (result.code == web_status.SUCCESS) {
|
||||
$('#' + obj.id).summernote('insertImage', result.url);
|
||||
} else {
|
||||
$.modal.alertError(result.msg);
|
||||
}
|
||||
},
|
||||
error: function(error) {
|
||||
$.modal.alertWarning("图片上传失败。");
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@ -0,0 +1,114 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('修改手持版本升级')" />
|
||||
<th:block th:include="include :: bootstrap-fileinput-css"/>
|
||||
<th:block th:include="include :: summernote-css" />
|
||||
</head>
|
||||
<body class="white-bg">
|
||||
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||
<form class="form-horizontal m" id="form-pda_version-edit" th:object="${pdaApkVersion}">
|
||||
<input name="objid" th:field="*{objid}" type="hidden">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">版本号:</label>
|
||||
<div class="col-sm-8">
|
||||
<input name="versionCode" th:field="*{versionCode}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">版本名:</label>
|
||||
<div class="col-sm-8">
|
||||
<input name="versionName" th:field="*{versionName}" class="form-control" type="text">
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">信息:</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="hidden" class="form-control" th:field="*{modifyContent}">
|
||||
<div class="summernote" id="modifyContent"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-sm-3 control-label">位置:</label>
|
||||
<div class="col-sm-8">
|
||||
<input type="hidden" name="downloadUrl" th:field="*{downloadUrl}">
|
||||
<div class="file-loading">
|
||||
<input class="form-control file-upload" id="downloadUrl" name="file" type="file">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<th:block th:include="include :: footer" />
|
||||
<th:block th:include="include :: bootstrap-fileinput-js"/>
|
||||
<th:block th:include="include :: summernote-js" />
|
||||
<script th:inline="javascript">
|
||||
var prefix = ctx + "pda/pda_version";
|
||||
$("#form-pda_version-edit").validate({
|
||||
focusCleanup: true
|
||||
});
|
||||
|
||||
function submitHandler() {
|
||||
if ($.validate.form()) {
|
||||
$.operate.save(prefix + "/edit", $('#form-pda_version-edit').serialize());
|
||||
}
|
||||
}
|
||||
|
||||
$(".file-upload").each(function (i) {
|
||||
var val = $("input[name='" + this.id + "']").val()
|
||||
$(this).fileinput({
|
||||
'uploadUrl': ctx + 'common/upload',
|
||||
initialPreviewAsData: true,
|
||||
initialPreview: [val],
|
||||
maxFileCount: 1,
|
||||
autoReplace: true
|
||||
}).on('fileuploaded', function (event, data, previewId, index) {
|
||||
$("input[name='" + event.currentTarget.id + "']").val(data.response.url)
|
||||
}).on('fileremoved', function (event, id, index) {
|
||||
$("input[name='" + event.currentTarget.id + "']").val('')
|
||||
})
|
||||
$(this).fileinput('_initFileActions');
|
||||
});
|
||||
|
||||
$(function() {
|
||||
$('.summernote').each(function(i) {
|
||||
$('#' + this.id).summernote({
|
||||
lang: 'zh-CN',
|
||||
dialogsInBody: true,
|
||||
callbacks: {
|
||||
onChange: function(contents, $edittable) {
|
||||
$("input[name='" + this.id + "']").val(contents);
|
||||
},
|
||||
onImageUpload: function(files) {
|
||||
var obj = this;
|
||||
var data = new FormData();
|
||||
data.append("file", files[0]);
|
||||
$.ajax({
|
||||
type: "post",
|
||||
url: ctx + "common/upload",
|
||||
data: data,
|
||||
cache: false,
|
||||
contentType: false,
|
||||
processData: false,
|
||||
dataType: 'json',
|
||||
success: function(result) {
|
||||
if (result.code == web_status.SUCCESS) {
|
||||
$('#' + obj.id).summernote('insertImage', result.url);
|
||||
} else {
|
||||
$.modal.alertError(result.msg);
|
||||
}
|
||||
},
|
||||
error: function(error) {
|
||||
$.modal.alertWarning("图片上传失败。");
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
var content = $("input[name='" + this.id + "']").val();
|
||||
$('#' + this.id).summernote('code', content);
|
||||
})
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@ -0,0 +1,112 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||
<head>
|
||||
<th:block th:include="include :: header('手持版本升级列表')" />
|
||||
</head>
|
||||
<body class="gray-bg">
|
||||
<div class="container-div">
|
||||
<div class="row">
|
||||
<div class="col-sm-12 search-collapse">
|
||||
<form id="formId">
|
||||
<div class="select-list">
|
||||
<ul>
|
||||
<li>
|
||||
<label>版本号:</label>
|
||||
<input type="text" name="versionCode"/>
|
||||
</li>
|
||||
<li>
|
||||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<div class="btn-group-sm" id="toolbar" role="group">
|
||||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="pda:pda_version:add">
|
||||
<i class="fa fa-plus"></i> 添加
|
||||
</a>
|
||||
<!-- <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="pda:pda_version:edit">-->
|
||||
<!-- <i class="fa fa-edit"></i> 删除-->
|
||||
<!-- </a>-->
|
||||
<!-- <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="pda:pda_version:remove">-->
|
||||
<!-- <i class="fa fa-remove"></i> 删除-->
|
||||
<!-- </a>-->
|
||||
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="pda:pda_version:export">
|
||||
<i class="fa fa-download"></i> 导出
|
||||
</a>
|
||||
</div>
|
||||
<div class="col-sm-12 select-table table-striped">
|
||||
<table id="bootstrap-table"></table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<th:block th:include="include :: footer" />
|
||||
<script th:inline="javascript">
|
||||
var editFlag = [[${@permission.hasPermi('pda:pda_version:edit')}]];
|
||||
var removeFlag = [[${@permission.hasPermi('pda:pda_version:remove')}]];
|
||||
var prefix = ctx + "pda/pda_version";
|
||||
|
||||
$(function() {
|
||||
var options = {
|
||||
url: prefix + "/list",
|
||||
createUrl: prefix + "/add",
|
||||
updateUrl: prefix + "/edit/{id}",
|
||||
removeUrl: prefix + "/remove",
|
||||
exportUrl: prefix + "/export",
|
||||
modalName: "手持版本升级",
|
||||
sortName: "versionCode",
|
||||
sortOrder: "desc",
|
||||
columns: [{
|
||||
checkbox: true
|
||||
},
|
||||
{
|
||||
field: 'objid',
|
||||
title: '主键标识',
|
||||
visible: false
|
||||
},
|
||||
{
|
||||
field: 'versionCode',
|
||||
title: '版本号'
|
||||
},
|
||||
{
|
||||
field: 'versionName',
|
||||
title: '版本名'
|
||||
},
|
||||
{
|
||||
field: 'modifyContent',
|
||||
title: '信息'
|
||||
},
|
||||
{
|
||||
field: 'downloadUrl',
|
||||
title: '位置'
|
||||
},
|
||||
{
|
||||
field: 'apkSize',
|
||||
title: '文件大小'
|
||||
},
|
||||
{
|
||||
field: 'apkMd5',
|
||||
title: '文件标识'
|
||||
},
|
||||
{
|
||||
field: 'createTime',
|
||||
title: '创建时间'
|
||||
},
|
||||
{
|
||||
title: '操作',
|
||||
align: 'center',
|
||||
formatter: function(value, row, index) {
|
||||
var actions = [];
|
||||
// actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.objid + '\')"><i class="fa fa-edit"></i>删除</a> ');
|
||||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.objid + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||
return actions.join('');
|
||||
}
|
||||
}]
|
||||
};
|
||||
$.table.init(options);
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<parent>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi</artifactId>
|
||||
<version>4.8.3</version>
|
||||
</parent>
|
||||
|
||||
<artifactId>ruoyi-device</artifactId>
|
||||
<properties>
|
||||
<maven.compiler.source>8</maven.compiler.source>
|
||||
<maven.compiler.target>8</maven.compiler.target>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.ruoyi</groupId>
|
||||
<artifactId>ruoyi-common</artifactId>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
||||
</project>
|
||||
@ -0,0 +1,125 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.device.domain.BaseDeviceLocation;
|
||||
import com.ruoyi.device.service.IBaseDeviceLocationService;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 桩位信息维护Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-28
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/base_location")
|
||||
public class BaseDeviceLocationController extends BaseController
|
||||
{
|
||||
private String prefix = "device/base_location";
|
||||
|
||||
@Autowired
|
||||
private IBaseDeviceLocationService baseLocationService;
|
||||
|
||||
@RequiresPermissions("device:base_location:view")
|
||||
@GetMapping()
|
||||
public String base_location()
|
||||
{
|
||||
return prefix + "/base_location";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询桩位信息维护列表
|
||||
*/
|
||||
@RequiresPermissions("device:base_location:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(BaseDeviceLocation baseDeviceLocation)
|
||||
{
|
||||
startPage();
|
||||
List<BaseDeviceLocation> list = baseLocationService.selectBaseLocationList(baseDeviceLocation);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出桩位信息维护列表
|
||||
*/
|
||||
@RequiresPermissions("device:base_location:export")
|
||||
@Log(title = "桩位信息维护", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(BaseDeviceLocation baseDeviceLocation)
|
||||
{
|
||||
List<BaseDeviceLocation> list = baseLocationService.selectBaseLocationList(baseDeviceLocation);
|
||||
ExcelUtil<BaseDeviceLocation> util = new ExcelUtil<BaseDeviceLocation>(BaseDeviceLocation.class);
|
||||
return util.exportExcel(list, "桩位信息维护数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增桩位信息维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_location:add")
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存桩位信息维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_location:add")
|
||||
@Log(title = "桩位信息维护", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(BaseDeviceLocation baseDeviceLocation)
|
||||
{
|
||||
return toAjax(baseLocationService.insertBaseLocation(baseDeviceLocation));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改桩位信息维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_location:edit")
|
||||
@GetMapping("/edit/{locationId}")
|
||||
public String edit(@PathVariable("locationId") Long locationId, ModelMap mmap)
|
||||
{
|
||||
BaseDeviceLocation baseDeviceLocation = baseLocationService.selectBaseLocationByLocationId(locationId);
|
||||
mmap.put("baseLocation", baseDeviceLocation);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存桩位信息维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_location:edit")
|
||||
@Log(title = "桩位信息维护", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(BaseDeviceLocation baseDeviceLocation)
|
||||
{
|
||||
return toAjax(baseLocationService.updateBaseLocation(baseDeviceLocation));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除桩位信息维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_location:remove")
|
||||
@Log(title = "桩位信息维护", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(baseLocationService.deleteBaseLocationByLocationIds(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,124 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.device.domain.BaseDeviceManufacturer;
|
||||
import com.ruoyi.device.service.IBaseManufacturerService;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 设备生产厂家Controller
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2022-04-02
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/base_manufacturer")
|
||||
public class BaseDeviceManufacturerController extends BaseController {
|
||||
private String prefix = "device/base_manufacturer";
|
||||
|
||||
@Autowired
|
||||
private IBaseManufacturerService baseManufacturerService;
|
||||
|
||||
@RequiresPermissions("device:base_manufacturer:view")
|
||||
@GetMapping()
|
||||
public String base_manufacturer() {
|
||||
return prefix + "/base_manufacturer";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询设备生产厂家列表
|
||||
*/
|
||||
@RequiresPermissions("device:base_manufacturer:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(BaseDeviceManufacturer baseDeviceManufacturer) {
|
||||
startPage();
|
||||
List<BaseDeviceManufacturer> list = baseManufacturerService.selectBaseManufacturerList(baseDeviceManufacturer);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出设备生产厂家列表
|
||||
*/
|
||||
@RequiresPermissions("device:base_manufacturer:export")
|
||||
@Log(title = "设备生产厂家", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(BaseDeviceManufacturer baseDeviceManufacturer) {
|
||||
List<BaseDeviceManufacturer> list = baseManufacturerService.selectBaseManufacturerList(baseDeviceManufacturer);
|
||||
ExcelUtil<BaseDeviceManufacturer> util = new ExcelUtil<BaseDeviceManufacturer>(BaseDeviceManufacturer.class);
|
||||
return util.exportExcel(list, "设备生产厂家数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增设备生产厂家
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add() {
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存设备生产厂家
|
||||
*/
|
||||
@RequiresPermissions("device:base_manufacturer:add")
|
||||
@Log(title = "设备生产厂家", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(BaseDeviceManufacturer baseDeviceManufacturer) {
|
||||
BaseDeviceManufacturer tag = baseManufacturerService.selectBaseManufacturerByName(baseDeviceManufacturer.getManufacturerName());
|
||||
if (tag==null){
|
||||
return toAjax(baseManufacturerService.insertBaseManufacturer(baseDeviceManufacturer));
|
||||
}
|
||||
return error("设备生产厂家名称重复");
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改设备生产厂家
|
||||
*/
|
||||
@RequiresPermissions("device:base_manufacturer:edit")
|
||||
@GetMapping("/edit/{objid}")
|
||||
public String edit(@PathVariable("objid") Long objid, ModelMap mmap) {
|
||||
BaseDeviceManufacturer baseDeviceManufacturer = baseManufacturerService.selectBaseManufacturerByObjid(objid);
|
||||
mmap.put("baseManufacturer", baseDeviceManufacturer);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存设备生产厂家
|
||||
*/
|
||||
@RequiresPermissions("device:base_manufacturer:edit")
|
||||
@Log(title = "设备生产厂家", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(BaseDeviceManufacturer baseDeviceManufacturer) {
|
||||
BaseDeviceManufacturer tag = baseManufacturerService.selectBaseManufacturerByName(baseDeviceManufacturer.getManufacturerName());
|
||||
if (tag==null||tag.getObjid().equals(baseDeviceManufacturer.getObjid())){
|
||||
return toAjax(baseManufacturerService.updateBaseManufacturer(baseDeviceManufacturer));
|
||||
}
|
||||
return error("设备生产厂家名称重复");
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除设备生产厂家
|
||||
*/
|
||||
@RequiresPermissions("device:base_manufacturer:remove")
|
||||
@Log(title = "设备生产厂家", businessType = BusinessType.DELETE)
|
||||
@PostMapping("/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids) {
|
||||
return toAjax(baseManufacturerService.deleteBaseManufacturerByObjids(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,134 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.device.domain.BaseInfo;
|
||||
import com.ruoyi.device.service.IBaseInfoService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 设备基础信息Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/base_info")
|
||||
public class BaseInfoController extends BaseController
|
||||
{
|
||||
private String prefix = "device/base_info";
|
||||
|
||||
@Autowired
|
||||
private IBaseInfoService baseInfoService;
|
||||
|
||||
@RequiresPermissions("device:base_info:view")
|
||||
@GetMapping()
|
||||
public String base_info()
|
||||
{
|
||||
return prefix + "/base_info";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询设备基础信息列表
|
||||
*/
|
||||
@RequiresPermissions("device:base_info:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(BaseInfo baseInfo)
|
||||
{
|
||||
startPage();
|
||||
List<BaseInfo> list = baseInfoService.selectBaseInfoList(baseInfo);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出设备基础信息列表
|
||||
*/
|
||||
@RequiresPermissions("device:base_info:export")
|
||||
@Log(title = "设备基础信息", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(BaseInfo baseInfo)
|
||||
{
|
||||
List<BaseInfo> list = baseInfoService.selectBaseInfoList(baseInfo);
|
||||
ExcelUtil<BaseInfo> util = new ExcelUtil<BaseInfo>(BaseInfo.class);
|
||||
return util.exportExcel(list, "设备基础信息数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增设备基础信息
|
||||
*/
|
||||
@RequiresPermissions("device:base_info:add")
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存设备基础信息
|
||||
*/
|
||||
@RequiresPermissions("device:base_info:add")
|
||||
@Log(title = "设备基础信息", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(BaseInfo baseInfo)
|
||||
{
|
||||
return toAjax(baseInfoService.insertBaseInfo(baseInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改设备基础信息
|
||||
*/
|
||||
@RequiresPermissions("device:base_info:edit")
|
||||
@GetMapping("/edit/{objId}")
|
||||
public String edit(@PathVariable("objId") Long objId, ModelMap mmap)
|
||||
{
|
||||
BaseInfo baseInfo = baseInfoService.selectBaseInfoByObjId(objId);
|
||||
mmap.put("baseInfo", baseInfo);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存设备基础信息
|
||||
*/
|
||||
@RequiresPermissions("device:base_info:edit")
|
||||
@Log(title = "设备基础信息", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(BaseInfo baseInfo)
|
||||
{
|
||||
return toAjax(baseInfoService.updateBaseInfo(baseInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除设备基础信息
|
||||
*/
|
||||
@RequiresPermissions("device:base_info:remove")
|
||||
@Log(title = "设备基础信息", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(baseInfoService.deleteBaseInfoByObjIds(ids));
|
||||
}
|
||||
|
||||
@PostMapping("/checkDeviceCode")
|
||||
@ResponseBody
|
||||
public boolean ccheckDeviceCode(BaseInfo baseInfo){
|
||||
return baseInfoService.checkDeviceCode(baseInfo);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,141 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.device.domain.BaseType;
|
||||
import com.ruoyi.device.service.IBaseTypeService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 设备类型维护Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/base_type")
|
||||
public class BaseTypeController extends BaseController
|
||||
{
|
||||
private String prefix = "device/base_type";
|
||||
|
||||
@Autowired
|
||||
private IBaseTypeService baseTypeService;
|
||||
|
||||
@RequiresPermissions("device:base_type:view")
|
||||
@GetMapping()
|
||||
public String base_type()
|
||||
{
|
||||
return prefix + "/base_type";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询设备类型维护列表
|
||||
*/
|
||||
@RequiresPermissions("device:base_type:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(BaseType baseType)
|
||||
{
|
||||
startPage();
|
||||
List<BaseType> list = baseTypeService.selectBaseTypeList(baseType);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出设备类型维护列表
|
||||
*/
|
||||
@RequiresPermissions("device:base_type:export")
|
||||
@Log(title = "设备类型维护", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(BaseType baseType)
|
||||
{
|
||||
List<BaseType> list = baseTypeService.selectBaseTypeList(baseType);
|
||||
ExcelUtil<BaseType> util = new ExcelUtil<BaseType>(BaseType.class);
|
||||
return util.exportExcel(list, "设备类型维护数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增设备类型维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_type:add")
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存设备类型维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_type:add")
|
||||
@Log(title = "设备类型维护", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(BaseType baseType)
|
||||
{
|
||||
return toAjax(baseTypeService.insertBaseType(baseType));
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 修改设备类型维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_type:edit")
|
||||
@GetMapping("/edit/{objId}")
|
||||
public String edit(@PathVariable("objId") Long objId, ModelMap mmap)
|
||||
{
|
||||
BaseType baseType = baseTypeService.selectBaseTypeByObjId(objId);
|
||||
mmap.put("baseType", baseType);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存设备类型维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_type:edit")
|
||||
@Log(title = "设备类型维护", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(BaseType baseType)
|
||||
{
|
||||
return toAjax(baseTypeService.updateBaseType(baseType));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除设备类型维护
|
||||
*/
|
||||
@RequiresPermissions("device:base_type:remove")
|
||||
@Log(title = "设备类型维护", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(baseTypeService.deleteBaseTypeByObjIds(ids));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
*校验名称重复
|
||||
*/
|
||||
@PostMapping("/checkDeviceTypeName")
|
||||
@ResponseBody
|
||||
public boolean checkDeviceTypeName(BaseType baseType) {
|
||||
return baseTypeService.checkDeviceTypeName(baseType);
|
||||
}
|
||||
|
||||
}
|
||||
@ -0,0 +1,127 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.device.domain.DeviceBaseFault;
|
||||
import com.ruoyi.device.service.IDeviceBaseFaultService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 故障类别维护Controller
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-24
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/device_fault")
|
||||
public class DeviceBaseFaultController extends BaseController
|
||||
{
|
||||
private String prefix = "device/device_fault";
|
||||
|
||||
@Autowired
|
||||
private IDeviceBaseFaultService deviceBaseFaultService;
|
||||
|
||||
@RequiresPermissions("device:device_fault:view")
|
||||
@GetMapping()
|
||||
public String device_fault()
|
||||
{
|
||||
return prefix + "/device_fault";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询故障类别维护列表
|
||||
*/
|
||||
@RequiresPermissions("device:device_fault:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(DeviceBaseFault deviceBaseFault)
|
||||
{
|
||||
startPage();
|
||||
List<DeviceBaseFault> list = deviceBaseFaultService.selectDeviceBaseFaultList(deviceBaseFault);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出故障类别维护列表
|
||||
*/
|
||||
@RequiresPermissions("device:device_fault:export")
|
||||
@Log(title = "故障类别维护", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(DeviceBaseFault deviceBaseFault)
|
||||
{
|
||||
List<DeviceBaseFault> list = deviceBaseFaultService.selectDeviceBaseFaultList(deviceBaseFault);
|
||||
ExcelUtil<DeviceBaseFault> util = new ExcelUtil<DeviceBaseFault>(DeviceBaseFault.class);
|
||||
return util.exportExcel(list, "故障类别维护数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增故障类别维护
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存故障类别维护
|
||||
*/
|
||||
@RequiresPermissions("device:device_fault:add")
|
||||
@Log(title = "故障类别维护", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(DeviceBaseFault deviceBaseFault)
|
||||
{
|
||||
return toAjax(deviceBaseFaultService.insertDeviceBaseFault(deviceBaseFault));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改故障类别维护
|
||||
*/
|
||||
@RequiresPermissions("device:device_fault:edit")
|
||||
@GetMapping("/edit/{objid}")
|
||||
public String edit(@PathVariable("objid") Long objid, ModelMap mmap)
|
||||
{
|
||||
DeviceBaseFault deviceBaseFault = deviceBaseFaultService.selectDeviceBaseFaultByObjid(objid);
|
||||
mmap.put("deviceBaseFault", deviceBaseFault);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存故障类别维护
|
||||
*/
|
||||
@RequiresPermissions("device:device_fault:edit")
|
||||
@Log(title = "故障类别维护", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(DeviceBaseFault deviceBaseFault)
|
||||
{
|
||||
return toAjax(deviceBaseFaultService.updateDeviceBaseFault(deviceBaseFault));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除故障类别维护
|
||||
*/
|
||||
@RequiresPermissions("device:device_fault:remove")
|
||||
@Log(title = "故障类别维护", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(deviceBaseFaultService.deleteDeviceBaseFaultByObjids(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,123 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.device.domain.DeviceInspectProject;
|
||||
import com.ruoyi.device.service.IDeviceInspectProjectService;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 巡检项目管理Controller
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-30
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/inspect_project")
|
||||
public class DeviceInspectProjectController extends BaseController {
|
||||
private String prefix = "device/inspect_project";
|
||||
|
||||
@Autowired
|
||||
private IDeviceInspectProjectService deviceInspectProjectService;
|
||||
|
||||
@RequiresPermissions("device:inspect_project:view")
|
||||
@GetMapping()
|
||||
public String inspect_project() {
|
||||
return prefix + "/inspect_project";
|
||||
}
|
||||
|
||||
@GetMapping("/open/{objId}")
|
||||
public String open(@PathVariable("objId") Long objId, ModelMap mmap) {
|
||||
mmap.put("objId", objId);
|
||||
return prefix + "/inspect_project";
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询巡检项目管理列表
|
||||
*/
|
||||
@RequiresPermissions("device:inspect_project:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(DeviceInspectProject deviceInspectProject) {
|
||||
startPage();
|
||||
List<DeviceInspectProject> list = deviceInspectProjectService.selectDeviceInspectProjectList(deviceInspectProject);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出巡检项目管理列表
|
||||
*/
|
||||
@RequiresPermissions("device:inspect_project:export")
|
||||
@Log(title = "巡检项目管理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(DeviceInspectProject deviceInspectProject) {
|
||||
List<DeviceInspectProject> list = deviceInspectProjectService.selectDeviceInspectProjectList(deviceInspectProject);
|
||||
ExcelUtil<DeviceInspectProject> util = new ExcelUtil<DeviceInspectProject>(DeviceInspectProject.class);
|
||||
return util.exportExcel(list, "巡检项目管理数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增巡检项目管理
|
||||
*/
|
||||
@GetMapping("/add/{manualId}")
|
||||
public String add(@PathVariable("manualId") Long manualId, ModelMap mmap) {
|
||||
mmap.put("manualId", manualId);
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存巡检项目管理
|
||||
*/
|
||||
@RequiresPermissions("device:inspect_project:add")
|
||||
@Log(title = "巡检项目管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(DeviceInspectProject deviceInspectProject) {
|
||||
return toAjax(deviceInspectProjectService.insertDeviceInspectProject(deviceInspectProject));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改巡检项目管理
|
||||
*/
|
||||
@RequiresPermissions("device:inspect_project:edit")
|
||||
@GetMapping("/edit/{objId}")
|
||||
public String edit(@PathVariable("objId") Long objId, ModelMap mmap) {
|
||||
DeviceInspectProject deviceInspectProject = deviceInspectProjectService.selectDeviceInspectProjectByObjId(objId);
|
||||
mmap.put("deviceInspectProject", deviceInspectProject);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存巡检项目管理
|
||||
*/
|
||||
@RequiresPermissions("device:inspect_project:edit")
|
||||
@Log(title = "巡检项目管理", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(DeviceInspectProject deviceInspectProject) {
|
||||
return toAjax(deviceInspectProjectService.updateDeviceInspectProject(deviceInspectProject));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除巡检项目管理
|
||||
*/
|
||||
@RequiresPermissions("device:inspect_project:remove")
|
||||
@Log(title = "巡检项目管理", businessType = BusinessType.DELETE)
|
||||
@PostMapping("/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids) {
|
||||
return toAjax(deviceInspectProjectService.deleteDeviceInspectProjectByObjIds(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,127 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.device.domain.DeviceInspectionManual;
|
||||
import com.ruoyi.device.service.IDeviceInspectionManualService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 巡检手册管理Controller
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-30
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/inspection_manual")
|
||||
public class DeviceInspectionManualController extends BaseController
|
||||
{
|
||||
private String prefix = "device/inspection_manual";
|
||||
|
||||
@Autowired
|
||||
private IDeviceInspectionManualService deviceInspectionManualService;
|
||||
|
||||
@RequiresPermissions("device:inspection_manual:view")
|
||||
@GetMapping()
|
||||
public String inspection_manual()
|
||||
{
|
||||
return prefix + "/inspection_manual";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询巡检手册管理列表
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_manual:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(DeviceInspectionManual deviceInspectionManual)
|
||||
{
|
||||
startPage();
|
||||
List<DeviceInspectionManual> list = deviceInspectionManualService.selectDeviceInspectionManualList(deviceInspectionManual);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出巡检手册管理列表
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_manual:export")
|
||||
@Log(title = "巡检手册管理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(DeviceInspectionManual deviceInspectionManual)
|
||||
{
|
||||
List<DeviceInspectionManual> list = deviceInspectionManualService.selectDeviceInspectionManualList(deviceInspectionManual);
|
||||
ExcelUtil<DeviceInspectionManual> util = new ExcelUtil<DeviceInspectionManual>(DeviceInspectionManual.class);
|
||||
return util.exportExcel(list, "巡检手册管理数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增巡检手册管理
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存巡检手册管理
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_manual:add")
|
||||
@Log(title = "巡检手册管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(DeviceInspectionManual deviceInspectionManual)
|
||||
{
|
||||
return toAjax(deviceInspectionManualService.insertDeviceInspectionManual(deviceInspectionManual));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改巡检手册管理
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_manual:edit")
|
||||
@GetMapping("/edit/{objId}")
|
||||
public String edit(@PathVariable("objId") Long objId, ModelMap mmap)
|
||||
{
|
||||
DeviceInspectionManual deviceInspectionManual = deviceInspectionManualService.selectDeviceInspectionManualByObjId(objId);
|
||||
mmap.put("deviceInspectionManual", deviceInspectionManual);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存巡检手册管理
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_manual:edit")
|
||||
@Log(title = "巡检手册管理", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(DeviceInspectionManual deviceInspectionManual)
|
||||
{
|
||||
return toAjax(deviceInspectionManualService.updateDeviceInspectionManual(deviceInspectionManual));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除巡检手册管理
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_manual:remove")
|
||||
@Log(title = "巡检手册管理", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(deviceInspectionManualService.deleteDeviceInspectionManualByObjIds(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,127 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.device.domain.DeviceInspectionRoute;
|
||||
import com.ruoyi.device.service.IDeviceInspectionRouteService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 巡检线路Controller
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-10-23
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/inspection_route")
|
||||
public class DeviceInspectionRouteController extends BaseController
|
||||
{
|
||||
private String prefix = "device/inspection_route";
|
||||
|
||||
@Autowired
|
||||
private IDeviceInspectionRouteService deviceInspectionRouteService;
|
||||
|
||||
@RequiresPermissions("device:inspection_route:view")
|
||||
@GetMapping()
|
||||
public String inspection_route()
|
||||
{
|
||||
return prefix + "/inspection_route";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询巡检线路列表
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_route:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(DeviceInspectionRoute deviceInspectionRoute)
|
||||
{
|
||||
startPage();
|
||||
List<DeviceInspectionRoute> list = deviceInspectionRouteService.selectDeviceInspectionRouteList(deviceInspectionRoute);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出巡检线路列表
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_route:export")
|
||||
@Log(title = "巡检线路", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(DeviceInspectionRoute deviceInspectionRoute)
|
||||
{
|
||||
List<DeviceInspectionRoute> list = deviceInspectionRouteService.selectDeviceInspectionRouteList(deviceInspectionRoute);
|
||||
ExcelUtil<DeviceInspectionRoute> util = new ExcelUtil<DeviceInspectionRoute>(DeviceInspectionRoute.class);
|
||||
return util.exportExcel(list, "巡检线路数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增巡检线路
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存巡检线路
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_route:add")
|
||||
@Log(title = "巡检线路", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(DeviceInspectionRoute deviceInspectionRoute)
|
||||
{
|
||||
return toAjax(deviceInspectionRouteService.insertDeviceInspectionRoute(deviceInspectionRoute));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改巡检线路
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_route:edit")
|
||||
@GetMapping("/edit/{routeId}")
|
||||
public String edit(@PathVariable("routeId") Long routeId, ModelMap mmap)
|
||||
{
|
||||
DeviceInspectionRoute deviceInspectionRoute = deviceInspectionRouteService.selectDeviceInspectionRouteByRouteId(routeId);
|
||||
mmap.put("deviceInspectionRoute", deviceInspectionRoute);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存巡检线路
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_route:edit")
|
||||
@Log(title = "巡检线路", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(DeviceInspectionRoute deviceInspectionRoute)
|
||||
{
|
||||
return toAjax(deviceInspectionRouteService.updateDeviceInspectionRoute(deviceInspectionRoute));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除巡检线路
|
||||
*/
|
||||
@RequiresPermissions("device:inspection_route:remove")
|
||||
@Log(title = "巡检线路", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(deviceInspectionRouteService.deleteDeviceInspectionRouteByRouteIds(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,210 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.ruoyi.common.config.RuoYiConfig;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||
import com.ruoyi.device.domain.*;
|
||||
import com.ruoyi.device.service.*;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.http.client.SimpleClientHttpRequestFactory;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.client.RestClientException;
|
||||
import org.springframework.web.client.RestTemplate;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.time.LocalDate;
|
||||
import java.time.YearMonth;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.ruoyi.common.core.domain.AjaxResult.error;
|
||||
import static com.ruoyi.common.core.domain.AjaxResult.success;
|
||||
|
||||
@RestController
|
||||
@RequestMapping("/api")
|
||||
public class PdaApiController {
|
||||
@Autowired
|
||||
private IPdaApiService service;
|
||||
@Autowired
|
||||
private IBaseInfoService baseInfoService;
|
||||
|
||||
@Autowired
|
||||
private IRecordUseService recordUseService;
|
||||
|
||||
@PostMapping("/home/selectDeviceInfo")
|
||||
public AjaxResult selectDeviceInfo(String code) {
|
||||
BaseInfo baseInfo = baseInfoService.selectDeviceInfo(code);
|
||||
if (baseInfo == null) return error("查询失败,条码扫描错误");
|
||||
String deviceState = baseInfo.getDeviceState();
|
||||
String deviceName = baseInfo.getDeviceName();
|
||||
if (deviceState.equals("0")) return error(deviceName + "已停用,使用其他设备吧");
|
||||
if (deviceState.equals("2")) return error(deviceName + "正在维修,使用其他设备吧");
|
||||
if (baseInfo.getUseState().equals("1")) return error(deviceName + "在使用中,更换其他设备吧");
|
||||
return success(baseInfo);
|
||||
}
|
||||
@PostMapping("/home/closeDevice")
|
||||
public AjaxResult closeDevice(String code) {
|
||||
BaseInfo baseInfo = baseInfoService.selectDeviceInfo(code);
|
||||
if (baseInfo == null) return error("查询失败,条码扫描错误");
|
||||
String deviceState = baseInfo.getDeviceState();
|
||||
String deviceName = baseInfo.getDeviceName();
|
||||
|
||||
ResponseEntity<String> response = null;
|
||||
try {
|
||||
SimpleClientHttpRequestFactory requestFactory = new SimpleClientHttpRequestFactory();
|
||||
requestFactory.setConnectTimeout(3000); // 连接超时3秒
|
||||
requestFactory.setReadTimeout(3000); // 读取超时3秒
|
||||
RestTemplate restTemplate = new RestTemplate(requestFactory);
|
||||
String url = "http://119.45.202.115:7789/devcontrolbusiness/unlock?idStr=" + baseInfo.getOpenCode() + "&password=" + baseInfo.getOpenPassword();
|
||||
// 根据实际情况调整参数值
|
||||
response = restTemplate.getForEntity(url, String.class);
|
||||
if (response.getStatusCode().is2xxSuccessful()) {
|
||||
MyResult myResult = JSONObject.parseObject(response.getBody(), MyResult.class);
|
||||
System.out.println(myResult.toString());
|
||||
if (myResult.getCode() == 200) {
|
||||
// 修改设备状态
|
||||
BaseInfo updateBaseInfo = new BaseInfo();
|
||||
updateBaseInfo.setObjId(baseInfo.getObjId());
|
||||
updateBaseInfo.setUseState("0");
|
||||
updateBaseInfo.setLocationName("A455C1B8500104E0");
|
||||
baseInfoService.updateBaseInfoForApi(updateBaseInfo);
|
||||
// service.updateRecord(code);
|
||||
return success("关锁,打开成功");
|
||||
}else {
|
||||
return error(myResult.getMsg());
|
||||
}
|
||||
}
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
return error("通讯失败");
|
||||
|
||||
}
|
||||
return success("关锁,打开成功");
|
||||
}
|
||||
|
||||
|
||||
@PostMapping("/home/openDeviceLock")
|
||||
public AjaxResult openDeviceLock(@RequestBody BaseInfo baseInfo) {
|
||||
String openCode = baseInfo.getOpenCode();
|
||||
String openPassword = baseInfo.getOpenPassword();
|
||||
System.out.println("开锁:"+openCode+",密码:"+openPassword);
|
||||
ResponseEntity<String> response = null;
|
||||
try {
|
||||
SimpleClientHttpRequestFactory requestFactory = new SimpleClientHttpRequestFactory();
|
||||
requestFactory.setConnectTimeout(3000); // 连接超时3秒
|
||||
requestFactory.setReadTimeout(3000); // 读取超时3秒
|
||||
RestTemplate restTemplate = new RestTemplate(requestFactory);
|
||||
String url = "http://119.45.202.115:7789/devcontrolbusiness/unlock?idStr=" + openCode + "&password=" + openPassword;
|
||||
// 根据实际情况调整参数值
|
||||
response = restTemplate.getForEntity(url, String.class);
|
||||
|
||||
if (response.getStatusCode().is2xxSuccessful()) {
|
||||
// {"code":200/500,"isSuc":true,"msg":"开锁指令下发成功,已收到设备回复","buffer":null,"data":null}
|
||||
MyResult myResult = JSONObject.parseObject(response.getBody(), MyResult.class);
|
||||
|
||||
System.out.println("返回值:"+myResult.toString());
|
||||
if (myResult.getCode() == 200) {
|
||||
/**
|
||||
* 插入记录
|
||||
*/
|
||||
RecordUse recordUse = new RecordUse();
|
||||
BeanUtils.copyProperties(baseInfo, recordUse);
|
||||
recordUse.setBaseDeviceCode(baseInfo.getDeviceCode());
|
||||
recordUse.setDeviceCode(openCode);
|
||||
recordUse.setDeviceId(String.valueOf(baseInfo.getObjId()));//设备ID
|
||||
recordUse.setDeviceType(baseInfo.getTypeName());//设备类型
|
||||
recordUse.setChargePrice(baseInfo.getDefaultPrice());//计费价格
|
||||
recordUse.setUseState("1");
|
||||
// 获取当前日期和时间
|
||||
LocalDate now = LocalDate.now();
|
||||
// 从LocalDate获取YearMonth
|
||||
YearMonth currentYearMonth = YearMonth.from(now);
|
||||
// 获取年份和月份
|
||||
recordUse.setQueryYear(String.valueOf(currentYearMonth.getYear()));
|
||||
recordUse.setQueryMonth(String.valueOf(currentYearMonth.getMonthValue()));
|
||||
recordUseService.insertRecordUse(recordUse);
|
||||
/**
|
||||
* 修改基础信息
|
||||
*/
|
||||
BaseInfo updateBaseInfo = new BaseInfo();
|
||||
updateBaseInfo.setObjId(baseInfo.getObjId());
|
||||
updateBaseInfo.setUseState("1");
|
||||
updateBaseInfo.setLocationName("-");
|
||||
baseInfoService.updateBaseInfoForApi(updateBaseInfo);
|
||||
return success("开锁成功");
|
||||
} else {
|
||||
return error(myResult.getMsg());
|
||||
}
|
||||
}
|
||||
} catch (RestClientException e) {
|
||||
return error("通讯失败");
|
||||
}
|
||||
|
||||
return success("开锁成功");
|
||||
}
|
||||
|
||||
@PostMapping("/home/selectDeviceInfoList")
|
||||
public AjaxResult selectDeviceInfoList() {
|
||||
List<BaseInfo> list=baseInfoService.selectDeviceInfoList();
|
||||
return success(list);
|
||||
}
|
||||
|
||||
@PostMapping("/record/selectUseList")
|
||||
public AjaxResult selectUseList() {
|
||||
List<RecordUse> list=service.selectUseList();
|
||||
|
||||
return success(list);
|
||||
}
|
||||
@Autowired
|
||||
private IDeviceBaseFaultService faultInfoService;
|
||||
@PostMapping("/fault/selectFaultList")
|
||||
public AjaxResult selectFaultList() {
|
||||
List<DeviceBaseFault> list=faultInfoService.selectFaultList();
|
||||
return success(list);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 提交报修
|
||||
*
|
||||
* @param json
|
||||
* @param file
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/bx/subment")
|
||||
private AjaxResult bx_subment(@RequestParam("json") String json, @RequestParam("file") List<MultipartFile> file) {
|
||||
System.out.println("报修-生成记录");
|
||||
String pictruePath = "";
|
||||
try {
|
||||
if (file != null && !file.isEmpty()) {
|
||||
List<String> pictruePaths = new ArrayList<>(file.size());
|
||||
String filePath = RuoYiConfig.getUploadPath() + "/fault";
|
||||
for (MultipartFile multipartFile : file) {
|
||||
System.out.println("上传图片路径:" + multipartFile.getOriginalFilename());
|
||||
String pathName = FileUploadUtils.upload(filePath, multipartFile);
|
||||
System.out.println("上传图片路径:" + pathName);
|
||||
pictruePaths.add(pathName);
|
||||
}
|
||||
pictruePath = String.join(",", pictruePaths);
|
||||
}
|
||||
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
String bills_code = "WX" + DateUtils.dateTimeNow();
|
||||
DeviceRepartBills been = JSONObject.parseObject(json, DeviceRepartBills.class);
|
||||
been.setWorkOrder(bills_code);
|
||||
been.setPictures(pictruePath);
|
||||
boolean b = deviceRepartBillsService.insertDeviceRepartBills(been) > 0;
|
||||
return b ?success():error();
|
||||
}
|
||||
@Autowired
|
||||
private IDeviceRepartBillsService deviceRepartBillsService;
|
||||
}
|
||||
@ -0,0 +1,128 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import java.util.List;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.device.domain.RecordUse;
|
||||
import com.ruoyi.device.service.IRecordUseService;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 使用记录Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/record_use")
|
||||
public class RecordUseController extends BaseController
|
||||
{
|
||||
private String prefix = "device/record_use";
|
||||
|
||||
@Autowired
|
||||
private IRecordUseService recordUseService;
|
||||
|
||||
@RequiresPermissions("device:record_use:view")
|
||||
@GetMapping()
|
||||
public String record_use()
|
||||
{
|
||||
return prefix + "/record_use";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询使用记录列表
|
||||
*/
|
||||
@RequiresPermissions("device:record_use:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(RecordUse recordUse)
|
||||
{
|
||||
startPage();
|
||||
List<RecordUse> list = recordUseService.selectRecordUseList(recordUse);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出使用记录列表
|
||||
*/
|
||||
@RequiresPermissions("device:record_use:export")
|
||||
@Log(title = "使用记录", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(RecordUse recordUse)
|
||||
{
|
||||
List<RecordUse> list = recordUseService.selectRecordUseList(recordUse);
|
||||
ExcelUtil<RecordUse> util = new ExcelUtil<RecordUse>(RecordUse.class);
|
||||
return util.exportExcel(list, "使用记录数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增使用记录
|
||||
*/
|
||||
@RequiresPermissions("device:record_use:add")
|
||||
@GetMapping("/add")
|
||||
public String add()
|
||||
{
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存使用记录
|
||||
*/
|
||||
@RequiresPermissions("device:record_use:add")
|
||||
@Log(title = "使用记录", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(RecordUse recordUse)
|
||||
{
|
||||
return toAjax(recordUseService.insertRecordUse(recordUse));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改使用记录
|
||||
*/
|
||||
@RequiresPermissions("device:record_use:edit")
|
||||
@GetMapping("/edit/{objId}")
|
||||
public String edit(@PathVariable("objId") Long objId, ModelMap mmap)
|
||||
{
|
||||
RecordUse recordUse = recordUseService.selectRecordUseByObjId(objId);
|
||||
mmap.put("recordUse", recordUse);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存使用记录
|
||||
*/
|
||||
@RequiresPermissions("device:record_use:edit")
|
||||
@Log(title = "使用记录", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(RecordUse recordUse)
|
||||
{
|
||||
return toAjax(recordUseService.updateRecordUse(recordUse));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除使用记录
|
||||
*/
|
||||
@RequiresPermissions("device:record_use:remove")
|
||||
@Log(title = "使用记录", businessType = BusinessType.DELETE)
|
||||
@PostMapping( "/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids)
|
||||
{
|
||||
return toAjax(recordUseService.deleteRecordUseByObjIds(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,149 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.device.domain.BaseDeviceManufacturer;
|
||||
import com.ruoyi.device.domain.BaseInfo;
|
||||
import com.ruoyi.device.domain.DeviceRepartBills;
|
||||
import com.ruoyi.device.domain.RepairOutsourcing;
|
||||
import com.ruoyi.device.service.*;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 委外工单Controller
|
||||
*
|
||||
* @author wh
|
||||
* @date 2022-06-08
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/repair_outsourcing")
|
||||
public class RepairOutsourcingController extends BaseController {
|
||||
private String prefix = "device/repair_outsourcing";
|
||||
|
||||
@Autowired
|
||||
private IRepairOutsourcingService repairOutsourcingService;
|
||||
@Autowired
|
||||
private IBaseInfoService baseScadaDeviceInfoService;
|
||||
private List<BaseInfo> baseScadaDeviceInfos;
|
||||
@Autowired
|
||||
private IBaseManufacturerService baseManufacturerService;
|
||||
private List<BaseDeviceManufacturer> baseManufacturerList;
|
||||
|
||||
|
||||
@RequiresPermissions("device:repair_outsourcing:view")
|
||||
@GetMapping()
|
||||
public String repair_outsourcing() {
|
||||
return prefix + "/repair_outsourcing";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询委外工单列表
|
||||
*/
|
||||
@RequiresPermissions("device:repair_outsourcing:list")
|
||||
@PostMapping("/list")
|
||||
@ResponseBody
|
||||
public TableDataInfo list(RepairOutsourcing repairOutsourcing) {
|
||||
startPage();
|
||||
List<RepairOutsourcing> list = repairOutsourcingService.selectRepairOutsourcingList(repairOutsourcing);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出委外工单列表
|
||||
*/
|
||||
@RequiresPermissions("device:repair_outsourcing:export")
|
||||
@Log(title = "委外工单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(RepairOutsourcing repairOutsourcing) {
|
||||
List<RepairOutsourcing> list = repairOutsourcingService.selectRepairOutsourcingList(repairOutsourcing);
|
||||
ExcelUtil<RepairOutsourcing> util = new ExcelUtil<RepairOutsourcing>(RepairOutsourcing.class);
|
||||
return util.exportExcel(list, "委外工单数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增委外工单
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add(ModelMap mmap) {
|
||||
if (baseScadaDeviceInfos == null || baseScadaDeviceInfos.isEmpty()) {
|
||||
baseScadaDeviceInfos = baseScadaDeviceInfoService.selectBaseInfoList(null);
|
||||
}
|
||||
mmap.put("baseScadaDeviceInfos", baseScadaDeviceInfos);
|
||||
if (baseManufacturerList == null || baseManufacturerList.isEmpty()) {
|
||||
baseManufacturerList = baseManufacturerService.selectBaseManufacturerList(null);
|
||||
}
|
||||
mmap.put("baseManufacturerList", baseManufacturerList);
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
@Autowired
|
||||
IDeviceRepartBillsService deviceRepartBillsService;
|
||||
|
||||
/**
|
||||
* 新增保存委外工单
|
||||
*/
|
||||
@RequiresPermissions("device:repair_outsourcing:add")
|
||||
@Log(title = "委外工单", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(RepairOutsourcing repairOutsourcing) {
|
||||
repairOutsourcing.setBillsCode("WW" + DateUtils.dateTimeNow());
|
||||
int i = repairOutsourcingService.insertRepairOutsourcing(repairOutsourcing);
|
||||
if (i > 0 && repairOutsourcing.getRepairBillsCode() != null) {
|
||||
DeviceRepartBills deviceRepartBills = new DeviceRepartBills();
|
||||
deviceRepartBills.setObjid(repairOutsourcing.getRepairBillsCode());
|
||||
deviceRepartBills.setOrderState(3L);
|
||||
deviceRepartBillsService.updateDeviceRepartBills(deviceRepartBills);
|
||||
}
|
||||
return toAjax(i);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改委外工单
|
||||
*/
|
||||
@RequiresPermissions("device:repair_outsourcing:edit")
|
||||
@GetMapping("/edit/{objid}")
|
||||
public String edit(@PathVariable("objid") Long objid, ModelMap mmap) {
|
||||
RepairOutsourcing repairOutsourcing = repairOutsourcingService.selectRepairOutsourcingByObjid(objid);
|
||||
mmap.put("repairOutsourcing", repairOutsourcing);
|
||||
if (baseManufacturerList == null || baseManufacturerList.isEmpty()) {
|
||||
baseManufacturerList = baseManufacturerService.selectBaseManufacturerList(null);
|
||||
}
|
||||
mmap.put("baseManufacturerList", baseManufacturerList);
|
||||
return prefix + "/edit";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存委外工单
|
||||
*/
|
||||
@RequiresPermissions("device:repair_outsourcing:edit")
|
||||
@Log(title = "委外工单", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(RepairOutsourcing repairOutsourcing) {
|
||||
return toAjax(repairOutsourcingService.updateRepairOutsourcing(repairOutsourcing));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除委外工单
|
||||
*/
|
||||
@RequiresPermissions("device:repair_outsourcing:remove")
|
||||
@Log(title = "委外工单", businessType = BusinessType.DELETE)
|
||||
@PostMapping("/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids) {
|
||||
return toAjax(repairOutsourcingService.deleteRepairOutsourcingByObjids(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,130 @@
|
||||
package com.ruoyi.device.controller;
|
||||
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.device.domain.BaseDeviceManufacturer;
|
||||
import com.ruoyi.device.domain.DeviceRepartBills;
|
||||
import com.ruoyi.device.service.IBaseManufacturerService;
|
||||
import com.ruoyi.device.service.IDeviceRepartBillsService;
|
||||
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.ui.ModelMap;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 维修工单Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2022-05-26
|
||||
*/
|
||||
@Controller
|
||||
@RequestMapping("/device/repart_bills")
|
||||
public class RepartBillsController extends BaseController {
|
||||
private String prefix = "device/repart_bills";
|
||||
|
||||
@Autowired
|
||||
private IDeviceRepartBillsService deviceRepartBillsService;
|
||||
// @Autowired
|
||||
// private IBaseScadaDeviceInfoService baseScadaDeviceInfoService;
|
||||
// private List<BaseInfo> baseScadaDeviceInfos;
|
||||
@Autowired
|
||||
private IBaseManufacturerService baseManufacturerService;
|
||||
private List<BaseDeviceManufacturer> baseDeviceManufacturerList;
|
||||
|
||||
@RequiresPermissions("device:repart_bills:view")
|
||||
@GetMapping()
|
||||
public String repart_bills() {
|
||||
return prefix + "/repart_bills";
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询维修工单列表
|
||||
*/
|
||||
@RequiresPermissions("device:repart_bills:list")
|
||||
@PostMapping({"/list"})
|
||||
@ResponseBody
|
||||
public TableDataInfo list(DeviceRepartBills deviceRepartBills) {
|
||||
startPage();
|
||||
|
||||
List<DeviceRepartBills> list = deviceRepartBillsService.selectDeviceRepartBillsList(deviceRepartBills);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出维修工单列表
|
||||
*/
|
||||
@RequiresPermissions("device:repart_bills:export")
|
||||
@Log(title = "维修工单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
@ResponseBody
|
||||
public AjaxResult export(DeviceRepartBills deviceRepartBills) {
|
||||
List<DeviceRepartBills> list = deviceRepartBillsService.selectDeviceRepartBillsList(deviceRepartBills);
|
||||
ExcelUtil<DeviceRepartBills> util = new ExcelUtil<DeviceRepartBills>(DeviceRepartBills.class);
|
||||
return util.exportExcel(list, "维修工单数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增维修工单
|
||||
*/
|
||||
@GetMapping("/add")
|
||||
public String add() {
|
||||
return prefix + "/add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增保存维修工单
|
||||
*/
|
||||
@RequiresPermissions("device:repart_bills:add")
|
||||
@Log(title = "维修工单", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/add")
|
||||
@ResponseBody
|
||||
public AjaxResult addSave(DeviceRepartBills deviceRepartBills) {
|
||||
return toAjax(deviceRepartBillsService.insertDeviceRepartBills(deviceRepartBills));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改维修工单
|
||||
*/
|
||||
@RequiresPermissions("device:repart_bills:edit")
|
||||
@GetMapping("/edit/{objid}")
|
||||
public String edit(@PathVariable("objid") Long objid, ModelMap mmap) {
|
||||
DeviceRepartBills deviceRepartBills = deviceRepartBillsService.selectDeviceRepartBillsByObjid(objid);
|
||||
mmap.put("deviceRepartBills", deviceRepartBills);
|
||||
if (baseDeviceManufacturerList == null || baseDeviceManufacturerList.isEmpty()) {
|
||||
baseDeviceManufacturerList = baseManufacturerService.selectBaseManufacturerList(null);
|
||||
}
|
||||
mmap.put("baseManufacturerList", baseDeviceManufacturerList);
|
||||
return "device/repair_outsourcing/repair_add";
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改保存维修工单
|
||||
*/
|
||||
@RequiresPermissions("device:repart_bills:edit")
|
||||
@Log(title = "维修工单", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("/edit")
|
||||
@ResponseBody
|
||||
public AjaxResult editSave(DeviceRepartBills deviceRepartBills) {
|
||||
return toAjax(deviceRepartBillsService.updateDeviceRepartBills(deviceRepartBills));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除维修工单
|
||||
*/
|
||||
@RequiresPermissions("device:repart_bills:remove")
|
||||
@Log(title = "维修工单", businessType = BusinessType.DELETE)
|
||||
@PostMapping("/remove")
|
||||
@ResponseBody
|
||||
public AjaxResult remove(String ids) {
|
||||
return toAjax(deviceRepartBillsService.deleteDeviceRepartBillsByObjids(ids));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@ -0,0 +1,102 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 桩位信息维护对象 device_base_location
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-28
|
||||
*/
|
||||
public class BaseDeviceLocation extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 桩位主键 */
|
||||
private Long locationId;
|
||||
|
||||
/** 桩位编码 */
|
||||
@Excel(name = "桩位编码")
|
||||
private String rfidCode;
|
||||
|
||||
/** 桩位名称 */
|
||||
@Excel(name = "桩位名称")
|
||||
private String locationName;
|
||||
|
||||
/** 所属机坪 */
|
||||
@Excel(name = "所属机坪")
|
||||
private String airLocation;
|
||||
|
||||
/** 安装位置 */
|
||||
@Excel(name = "安装位置")
|
||||
private String installPosition;
|
||||
|
||||
public Long getLocationId()
|
||||
{
|
||||
return locationId;
|
||||
}
|
||||
|
||||
public void setLocationId(Long locationId)
|
||||
{
|
||||
this.locationId = locationId;
|
||||
}
|
||||
|
||||
public String getRfidCode()
|
||||
{
|
||||
return rfidCode;
|
||||
}
|
||||
|
||||
public void setRfidCode(String rfidCode)
|
||||
{
|
||||
this.rfidCode = rfidCode;
|
||||
}
|
||||
|
||||
public String getLocationName()
|
||||
{
|
||||
return locationName;
|
||||
}
|
||||
|
||||
public void setLocationName(String locationName)
|
||||
{
|
||||
this.locationName = locationName;
|
||||
}
|
||||
|
||||
public String getAirLocation()
|
||||
{
|
||||
return airLocation;
|
||||
}
|
||||
|
||||
public void setAirLocation(String airLocation)
|
||||
{
|
||||
this.airLocation = airLocation;
|
||||
}
|
||||
|
||||
public String getInstallPosition()
|
||||
{
|
||||
return installPosition;
|
||||
}
|
||||
|
||||
public void setInstallPosition(String installPosition)
|
||||
{
|
||||
this.installPosition = installPosition;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("locationId", getLocationId())
|
||||
.append("rfidCode", getRfidCode())
|
||||
.append("locationName", getLocationName())
|
||||
.append("airLocation", getAirLocation())
|
||||
.append("remark", getRemark())
|
||||
.append("installPosition", getInstallPosition())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,125 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 设备生产厂家对象 device_base_manufacturer
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2022-04-02
|
||||
*/
|
||||
public class BaseDeviceManufacturer extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
private Long objid;
|
||||
|
||||
/** 厂商名称 */
|
||||
@Excel(name = "厂商名称")
|
||||
private String manufacturerName;
|
||||
|
||||
/** 联系电话 */
|
||||
@Excel(name = "联系电话")
|
||||
private String phone;
|
||||
|
||||
/** 联系人 */
|
||||
@Excel(name = "联系人")
|
||||
private String contacts;
|
||||
|
||||
/** 传真 */
|
||||
@Excel(name = "传真")
|
||||
private String fax;
|
||||
|
||||
/** 地址 */
|
||||
@Excel(name = "地址")
|
||||
private String address;
|
||||
|
||||
/** 邮箱 */
|
||||
@Excel(name = "邮箱")
|
||||
private String mail;
|
||||
|
||||
public void setObjid(Long objid)
|
||||
{
|
||||
this.objid = objid;
|
||||
}
|
||||
|
||||
public Long getObjid()
|
||||
{
|
||||
return objid;
|
||||
}
|
||||
public void setManufacturerName(String manufacturerName)
|
||||
{
|
||||
this.manufacturerName = manufacturerName;
|
||||
}
|
||||
|
||||
public String getManufacturerName()
|
||||
{
|
||||
return manufacturerName;
|
||||
}
|
||||
public void setPhone(String phone)
|
||||
{
|
||||
this.phone = phone;
|
||||
}
|
||||
|
||||
public String getPhone()
|
||||
{
|
||||
return phone;
|
||||
}
|
||||
public void setContacts(String contacts)
|
||||
{
|
||||
this.contacts = contacts;
|
||||
}
|
||||
|
||||
public String getContacts()
|
||||
{
|
||||
return contacts;
|
||||
}
|
||||
public void setFax(String fax)
|
||||
{
|
||||
this.fax = fax;
|
||||
}
|
||||
|
||||
public String getFax()
|
||||
{
|
||||
return fax;
|
||||
}
|
||||
public void setAddress(String address)
|
||||
{
|
||||
this.address = address;
|
||||
}
|
||||
|
||||
public String getAddress()
|
||||
{
|
||||
return address;
|
||||
}
|
||||
public void setMail(String mail)
|
||||
{
|
||||
this.mail = mail;
|
||||
}
|
||||
|
||||
public String getMail()
|
||||
{
|
||||
return mail;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objid", getObjid())
|
||||
.append("manufacturerName", getManufacturerName())
|
||||
.append("phone", getPhone())
|
||||
.append("contacts", getContacts())
|
||||
.append("fax", getFax())
|
||||
.append("address", getAddress())
|
||||
.append("mail", getMail())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,230 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 设备基础信息对象 device_base_info
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
public class BaseInfo extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
private Long objId;
|
||||
|
||||
/**
|
||||
* 设备编码
|
||||
*/
|
||||
@Excel(name = "设备编码")
|
||||
private String deviceCode;
|
||||
|
||||
/**
|
||||
* 设备名称
|
||||
*/
|
||||
@Excel(name = "设备名称")
|
||||
private String deviceName;
|
||||
|
||||
/**
|
||||
* 设备类型
|
||||
*/
|
||||
@Excel(name = "设备类型")
|
||||
private Long deviceType;
|
||||
|
||||
/**
|
||||
* 使用状态
|
||||
*/
|
||||
@Excel(name = "使用状态")
|
||||
private String useState;
|
||||
|
||||
/**
|
||||
* 设备状态
|
||||
*/
|
||||
@Excel(name = "设备状态")
|
||||
private String deviceState;
|
||||
|
||||
/**
|
||||
* 摆放桩位
|
||||
*/
|
||||
@Excel(name = "摆放桩位")
|
||||
private String locationName;
|
||||
|
||||
/**
|
||||
* 开锁密码
|
||||
*/
|
||||
@Excel(name = "开锁密码")
|
||||
private String openPassword;
|
||||
private String typeName;
|
||||
private Double defaultPrice;
|
||||
|
||||
/**
|
||||
* 默认使用时间
|
||||
*/
|
||||
@Excel(name = "默认使用时间")
|
||||
private Double defaultTime;
|
||||
// 锁编码
|
||||
private String openCode;
|
||||
|
||||
/**
|
||||
* 用户ID
|
||||
*/
|
||||
private Long userId;
|
||||
private String asName;
|
||||
/**
|
||||
* 部门ID
|
||||
*/
|
||||
private Long deptId;
|
||||
private String useUser;
|
||||
|
||||
public String getAsName() {
|
||||
return asName;
|
||||
}
|
||||
|
||||
public void setAsName(String asName) {
|
||||
this.asName = asName;
|
||||
}
|
||||
|
||||
public String getOpenCode() {
|
||||
return openCode;
|
||||
}
|
||||
|
||||
public void setOpenCode(String openCode) {
|
||||
this.openCode = openCode;
|
||||
}
|
||||
|
||||
public Long getUserId() {
|
||||
return userId;
|
||||
}
|
||||
|
||||
public void setUserId(Long userId) {
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getDeptId() {
|
||||
return deptId;
|
||||
}
|
||||
|
||||
public void setDeptId(Long deptId) {
|
||||
this.deptId = deptId;
|
||||
}
|
||||
|
||||
public String getUseUser() {
|
||||
return useUser;
|
||||
}
|
||||
|
||||
public void setUseUser(String useUser) {
|
||||
this.useUser = useUser;
|
||||
}
|
||||
|
||||
public Double getDefaultPrice() {
|
||||
return defaultPrice;
|
||||
}
|
||||
|
||||
public void setDefaultPrice(Double defaultPrice) {
|
||||
this.defaultPrice = defaultPrice;
|
||||
}
|
||||
|
||||
public Double getDefaultTime() {
|
||||
return defaultTime;
|
||||
}
|
||||
|
||||
public void setDefaultTime(Double defaultTime) {
|
||||
this.defaultTime = defaultTime;
|
||||
}
|
||||
|
||||
public String getTypeName() {
|
||||
return typeName;
|
||||
}
|
||||
|
||||
public void setTypeName(String typeName) {
|
||||
this.typeName = typeName;
|
||||
}
|
||||
|
||||
public Long getObjId() {
|
||||
return objId;
|
||||
}
|
||||
|
||||
public void setObjId(Long objId) {
|
||||
this.objId = objId;
|
||||
}
|
||||
|
||||
public String getDeviceCode() {
|
||||
return deviceCode;
|
||||
}
|
||||
|
||||
public void setDeviceCode(String deviceCode) {
|
||||
this.deviceCode = deviceCode;
|
||||
}
|
||||
|
||||
public String getDeviceName() {
|
||||
return deviceName;
|
||||
}
|
||||
|
||||
public void setDeviceName(String deviceName) {
|
||||
this.deviceName = deviceName;
|
||||
}
|
||||
|
||||
public Long getDeviceType() {
|
||||
return deviceType;
|
||||
}
|
||||
|
||||
public void setDeviceType(Long deviceType) {
|
||||
this.deviceType = deviceType;
|
||||
}
|
||||
|
||||
public String getUseState() {
|
||||
return useState;
|
||||
}
|
||||
|
||||
public void setUseState(String useState) {
|
||||
this.useState = useState;
|
||||
}
|
||||
|
||||
public String getDeviceState() {
|
||||
return deviceState;
|
||||
}
|
||||
|
||||
public void setDeviceState(String deviceState) {
|
||||
this.deviceState = deviceState;
|
||||
}
|
||||
|
||||
public String getLocationName() {
|
||||
return locationName;
|
||||
}
|
||||
|
||||
public void setLocationName(String locationName) {
|
||||
this.locationName = locationName;
|
||||
}
|
||||
|
||||
public String getOpenPassword() {
|
||||
return openPassword;
|
||||
}
|
||||
|
||||
public void setOpenPassword(String openPassword) {
|
||||
this.openPassword = openPassword;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objId", getObjId())
|
||||
.append("deviceCode", getDeviceCode())
|
||||
.append("deviceName", getDeviceName())
|
||||
.append("deviceType", getDeviceType())
|
||||
.append("useState", getUseState())
|
||||
.append("deviceState", getDeviceState())
|
||||
.append("locationName", getLocationName())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("openPassword", getOpenPassword())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,86 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 设备类型维护对象 device_base_type
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
public class BaseType extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
private Long objId;
|
||||
|
||||
/** 设备类型名称 */
|
||||
@Excel(name = "设备类型名称")
|
||||
private String deviceTypeName;
|
||||
|
||||
/** 默认计费价格(小时) */
|
||||
@Excel(name = "默认计费价格(小时)")
|
||||
private Double defaultPrice;
|
||||
|
||||
/** 默认使用时间 */
|
||||
@Excel(name = "默认使用时间")
|
||||
private Double defaultTime;
|
||||
|
||||
public void setObjId(Long objId)
|
||||
{
|
||||
this.objId = objId;
|
||||
}
|
||||
|
||||
public Long getObjId()
|
||||
{
|
||||
return objId;
|
||||
}
|
||||
|
||||
public void setDeviceTypeName(String deviceTypeName)
|
||||
{
|
||||
this.deviceTypeName = deviceTypeName;
|
||||
}
|
||||
|
||||
public String getDeviceTypeName()
|
||||
{
|
||||
return deviceTypeName;
|
||||
}
|
||||
|
||||
public void setDefaultPrice(Double defaultPrice)
|
||||
{
|
||||
this.defaultPrice = defaultPrice;
|
||||
}
|
||||
|
||||
public Double getDefaultPrice()
|
||||
{
|
||||
return defaultPrice;
|
||||
}
|
||||
|
||||
public void setDefaultTime(Double defaultTime)
|
||||
{
|
||||
this.defaultTime = defaultTime;
|
||||
}
|
||||
|
||||
public Double getDefaultTime()
|
||||
{
|
||||
return defaultTime;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objId", getObjId())
|
||||
.append("deviceTypeName", getDeviceTypeName())
|
||||
.append("defaultPrice", getDefaultPrice())
|
||||
.append("defaultTime", getDefaultTime())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,97 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 故障类别维护对象 device_base_fault
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-24
|
||||
*/
|
||||
public class DeviceBaseFault extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** */
|
||||
private Long objid;
|
||||
|
||||
/** 故障代码 */
|
||||
@Excel(name = "故障代码")
|
||||
private String faultCode;
|
||||
|
||||
/** 故障名称 */
|
||||
@Excel(name = "故障名称")
|
||||
private String faultName;
|
||||
|
||||
/** 故障说明 */
|
||||
@Excel(name = "故障说明")
|
||||
private String faultInfo;
|
||||
|
||||
/** 应急措施 */
|
||||
@Excel(name = "应急措施")
|
||||
private String emergencyMeasures;
|
||||
|
||||
public void setObjid(Long objid)
|
||||
{
|
||||
this.objid = objid;
|
||||
}
|
||||
|
||||
public Long getObjid()
|
||||
{
|
||||
return objid;
|
||||
}
|
||||
public void setFaultCode(String faultCode)
|
||||
{
|
||||
this.faultCode = faultCode;
|
||||
}
|
||||
|
||||
public String getFaultCode()
|
||||
{
|
||||
return faultCode;
|
||||
}
|
||||
public void setFaultName(String faultName)
|
||||
{
|
||||
this.faultName = faultName;
|
||||
}
|
||||
|
||||
public String getFaultName()
|
||||
{
|
||||
return faultName;
|
||||
}
|
||||
public void setFaultInfo(String faultInfo)
|
||||
{
|
||||
this.faultInfo = faultInfo;
|
||||
}
|
||||
|
||||
public String getFaultInfo()
|
||||
{
|
||||
return faultInfo;
|
||||
}
|
||||
public void setEmergencyMeasures(String emergencyMeasures)
|
||||
{
|
||||
this.emergencyMeasures = emergencyMeasures;
|
||||
}
|
||||
|
||||
public String getEmergencyMeasures()
|
||||
{
|
||||
return emergencyMeasures;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objid", getObjid())
|
||||
.append("faultcode", getFaultCode())
|
||||
.append("faultName", getFaultName())
|
||||
.append("faultInfo", getFaultInfo())
|
||||
.append("emergencyMeasures", getEmergencyMeasures())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,125 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 巡检项目管理对象 device_inspect_project
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-30
|
||||
*/
|
||||
public class DeviceInspectProject extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
private Long objId;
|
||||
|
||||
/** 关联手册 */
|
||||
@Excel(name = "关联手册")
|
||||
private Long manualId;
|
||||
|
||||
/** 项目编号 */
|
||||
@Excel(name = "项目编号")
|
||||
private String inspectProjectCode;
|
||||
|
||||
/** 巡检项目 */
|
||||
@Excel(name = "巡检项目")
|
||||
private String inspectProject;
|
||||
|
||||
/** 巡检项目属性 */
|
||||
@Excel(name = "巡检项目属性")
|
||||
private String inspectProjectProperty;
|
||||
|
||||
/** 上限 */
|
||||
@Excel(name = "上限")
|
||||
private String upLimit;
|
||||
|
||||
/** 下限 */
|
||||
@Excel(name = "下限")
|
||||
private String lowLimit;
|
||||
|
||||
public void setObjId(Long objId)
|
||||
{
|
||||
this.objId = objId;
|
||||
}
|
||||
|
||||
public Long getObjId()
|
||||
{
|
||||
return objId;
|
||||
}
|
||||
public void setManualId(Long manualId)
|
||||
{
|
||||
this.manualId = manualId;
|
||||
}
|
||||
|
||||
public Long getManualId()
|
||||
{
|
||||
return manualId;
|
||||
}
|
||||
public void setInspectProjectCode(String inspectProjectCode)
|
||||
{
|
||||
this.inspectProjectCode = inspectProjectCode;
|
||||
}
|
||||
|
||||
public String getInspectProjectCode()
|
||||
{
|
||||
return inspectProjectCode;
|
||||
}
|
||||
public void setInspectProject(String inspectProject)
|
||||
{
|
||||
this.inspectProject = inspectProject;
|
||||
}
|
||||
|
||||
public String getInspectProject()
|
||||
{
|
||||
return inspectProject;
|
||||
}
|
||||
public void setInspectProjectProperty(String inspectProjectProperty)
|
||||
{
|
||||
this.inspectProjectProperty = inspectProjectProperty;
|
||||
}
|
||||
|
||||
public String getInspectProjectProperty()
|
||||
{
|
||||
return inspectProjectProperty;
|
||||
}
|
||||
public void setUpLimit(String upLimit)
|
||||
{
|
||||
this.upLimit = upLimit;
|
||||
}
|
||||
|
||||
public String getUpLimit()
|
||||
{
|
||||
return upLimit;
|
||||
}
|
||||
public void setLowLimit(String lowLimit)
|
||||
{
|
||||
this.lowLimit = lowLimit;
|
||||
}
|
||||
|
||||
public String getLowLimit()
|
||||
{
|
||||
return lowLimit;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objId", getObjId())
|
||||
.append("manualId", getManualId())
|
||||
.append("inspectProjectCode", getInspectProjectCode())
|
||||
.append("inspectProject", getInspectProject())
|
||||
.append("inspectProjectProperty", getInspectProjectProperty())
|
||||
.append("upLimit", getUpLimit())
|
||||
.append("lowLimit", getLowLimit())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,69 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 巡检手册管理对象 device_inspection_manual
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-30
|
||||
*/
|
||||
public class DeviceInspectionManual extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
private Long objId;
|
||||
|
||||
/** 手册编码 */
|
||||
@Excel(name = "手册编码")
|
||||
private String manualCode;
|
||||
|
||||
/** 手册名称 */
|
||||
@Excel(name = "手册名称")
|
||||
private String manualName;
|
||||
|
||||
public void setObjId(Long objId)
|
||||
{
|
||||
this.objId = objId;
|
||||
}
|
||||
|
||||
public Long getObjId()
|
||||
{
|
||||
return objId;
|
||||
}
|
||||
public void setManualCode(String manualCode)
|
||||
{
|
||||
this.manualCode = manualCode;
|
||||
}
|
||||
|
||||
public String getManualCode()
|
||||
{
|
||||
return manualCode;
|
||||
}
|
||||
public void setManualName(String manualName)
|
||||
{
|
||||
this.manualName = manualName;
|
||||
}
|
||||
|
||||
public String getManualName()
|
||||
{
|
||||
return manualName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objId", getObjId())
|
||||
.append("manualCode", getManualCode())
|
||||
.append("manualName", getManualName())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,54 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 巡检线路对象 device_inspection_route
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-10-23
|
||||
*/
|
||||
public class DeviceInspectionRoute extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 线路ID */
|
||||
private Long routeId;
|
||||
|
||||
/** 线路名称 */
|
||||
@Excel(name = "线路名称")
|
||||
private String routeName;
|
||||
|
||||
public void setRouteId(Long routeId)
|
||||
{
|
||||
this.routeId = routeId;
|
||||
}
|
||||
|
||||
public Long getRouteId()
|
||||
{
|
||||
return routeId;
|
||||
}
|
||||
public void setRouteName(String routeName)
|
||||
{
|
||||
this.routeName = routeName;
|
||||
}
|
||||
|
||||
public String getRouteName()
|
||||
{
|
||||
return routeName;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("routeId", getRouteId())
|
||||
.append("routeName", getRouteName())
|
||||
.append("remark", getRemark())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,41 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
|
||||
public class LundangBaseStore {
|
||||
|
||||
/** 仓库id */
|
||||
private Long storeId;
|
||||
|
||||
/** 仓库编号 */
|
||||
@Excel(name = "仓库编号")
|
||||
private String storeCode;
|
||||
|
||||
/** 仓库名称 */
|
||||
@Excel(name = "仓库名称")
|
||||
private String storeName;
|
||||
|
||||
public Long getStoreId() {
|
||||
return storeId;
|
||||
}
|
||||
|
||||
public void setStoreId(Long storeId) {
|
||||
this.storeId = storeId;
|
||||
}
|
||||
|
||||
public String getStoreCode() {
|
||||
return storeCode;
|
||||
}
|
||||
|
||||
public void setStoreCode(String storeCode) {
|
||||
this.storeCode = storeCode;
|
||||
}
|
||||
|
||||
public String getStoreName() {
|
||||
return storeName;
|
||||
}
|
||||
|
||||
public void setStoreName(String storeName) {
|
||||
this.storeName = storeName;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,41 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
public class MyResult {
|
||||
private int code;
|
||||
private String msg;
|
||||
|
||||
private Object data;
|
||||
|
||||
public int getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(int code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getMsg() {
|
||||
return msg;
|
||||
}
|
||||
|
||||
public void setMsg(String msg) {
|
||||
this.msg = msg;
|
||||
}
|
||||
|
||||
public Object getData() {
|
||||
return data;
|
||||
}
|
||||
|
||||
public void setData(Object data) {
|
||||
this.data = data;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "MyResult{" +
|
||||
"code=" + code +
|
||||
", msg='" + msg + '\'' +
|
||||
// ", data=" + data +
|
||||
'}';
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,308 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 使用记录对象 device_record_use
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
public class RecordUse extends BaseEntity {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
private Long objId;
|
||||
|
||||
/**
|
||||
* 设备ID
|
||||
*/
|
||||
@Excel(name = "设备ID")
|
||||
private String deviceId;
|
||||
|
||||
/**
|
||||
* 设备编码
|
||||
*/
|
||||
@Excel(name = "设备编码")
|
||||
private String deviceCode;
|
||||
/**
|
||||
* 基础信息设备编码
|
||||
*/
|
||||
@Excel(name = "设备编码")
|
||||
private String baseDeviceCode;
|
||||
|
||||
/**
|
||||
* 设备名称
|
||||
*/
|
||||
@Excel(name = "设备名称")
|
||||
private String deviceName;
|
||||
|
||||
/**
|
||||
* 设备类型
|
||||
*/
|
||||
@Excel(name = "设备类型")
|
||||
private String deviceType;
|
||||
|
||||
/**
|
||||
* 开锁时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@Excel(name = "开锁时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date openTime;
|
||||
|
||||
/**
|
||||
* 关锁时间
|
||||
*/
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
|
||||
@Excel(name = "关锁时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
|
||||
private Date closeTime;
|
||||
|
||||
/**
|
||||
* 使用时间(小时)
|
||||
*/
|
||||
@Excel(name = "使用时间(小时)")
|
||||
private double useTime;
|
||||
|
||||
/**
|
||||
* 默认使用时间
|
||||
*/
|
||||
@Excel(name = "默认使用时间")
|
||||
private double defaultTime;
|
||||
|
||||
/**
|
||||
* 计费价格
|
||||
*/
|
||||
@Excel(name = "计费价格")
|
||||
private double chargePrice;
|
||||
|
||||
/**
|
||||
* 超时状态
|
||||
*/
|
||||
@Excel(name = "超时状态")
|
||||
private String overtimeState;
|
||||
|
||||
/**
|
||||
* 使用状态
|
||||
*/
|
||||
@Excel(name = "使用状态")
|
||||
private String useState;
|
||||
|
||||
/**
|
||||
* 借用人
|
||||
*/
|
||||
@Excel(name = "借用人")
|
||||
private String useUser;
|
||||
|
||||
/**
|
||||
* 借用单位
|
||||
*/
|
||||
@Excel(name = "借用单位")
|
||||
private String useUnit;
|
||||
|
||||
/**
|
||||
* 统计年份
|
||||
*/
|
||||
private String queryYear;
|
||||
|
||||
/**
|
||||
* 统计月份
|
||||
*/
|
||||
private String queryMonth;
|
||||
|
||||
/**
|
||||
* 数据权限1
|
||||
*/
|
||||
private String deptId;
|
||||
|
||||
/**
|
||||
* 数据权限2
|
||||
*/
|
||||
private String userId;
|
||||
|
||||
|
||||
public String getBaseDeviceCode() {
|
||||
return baseDeviceCode;
|
||||
}
|
||||
|
||||
public void setBaseDeviceCode(String baseDeviceCode) {
|
||||
this.baseDeviceCode = baseDeviceCode;
|
||||
}
|
||||
|
||||
public Long getObjId() {
|
||||
return objId;
|
||||
}
|
||||
|
||||
public void setObjId(Long objId) {
|
||||
this.objId = objId;
|
||||
}
|
||||
|
||||
public String getDeviceId() {
|
||||
return deviceId;
|
||||
}
|
||||
|
||||
public void setDeviceId(String deviceId) {
|
||||
this.deviceId = deviceId;
|
||||
}
|
||||
|
||||
public String getDeviceCode() {
|
||||
return deviceCode;
|
||||
}
|
||||
|
||||
public void setDeviceCode(String deviceCode) {
|
||||
this.deviceCode = deviceCode;
|
||||
}
|
||||
|
||||
public String getDeviceName() {
|
||||
return deviceName;
|
||||
}
|
||||
|
||||
public void setDeviceName(String deviceName) {
|
||||
this.deviceName = deviceName;
|
||||
}
|
||||
|
||||
public String getDeviceType() {
|
||||
return deviceType;
|
||||
}
|
||||
|
||||
public void setDeviceType(String deviceType) {
|
||||
this.deviceType = deviceType;
|
||||
}
|
||||
|
||||
public Date getOpenTime() {
|
||||
return openTime;
|
||||
}
|
||||
|
||||
public void setOpenTime(Date openTime) {
|
||||
this.openTime = openTime;
|
||||
}
|
||||
|
||||
public Date getCloseTime() {
|
||||
return closeTime;
|
||||
}
|
||||
|
||||
public void setCloseTime(Date closeTime) {
|
||||
this.closeTime = closeTime;
|
||||
}
|
||||
|
||||
public double getUseTime() {
|
||||
return useTime;
|
||||
}
|
||||
|
||||
public void setUseTime(double useTime) {
|
||||
this.useTime = useTime;
|
||||
}
|
||||
|
||||
public double getDefaultTime() {
|
||||
return defaultTime;
|
||||
}
|
||||
|
||||
public void setDefaultTime(double defaultTime) {
|
||||
this.defaultTime = defaultTime;
|
||||
}
|
||||
|
||||
public double getChargePrice() {
|
||||
return chargePrice;
|
||||
}
|
||||
|
||||
public void setChargePrice(double chargePrice) {
|
||||
this.chargePrice = chargePrice;
|
||||
}
|
||||
|
||||
public String getOvertimeState() {
|
||||
return overtimeState;
|
||||
}
|
||||
|
||||
public void setOvertimeState(String overtimeState) {
|
||||
this.overtimeState = overtimeState;
|
||||
}
|
||||
|
||||
public String getUseState() {
|
||||
return useState;
|
||||
}
|
||||
|
||||
public void setUseState(String useState) {
|
||||
this.useState = useState;
|
||||
}
|
||||
|
||||
public String getUseUser() {
|
||||
return useUser;
|
||||
}
|
||||
|
||||
public void setUseUser(String useUser) {
|
||||
this.useUser = useUser;
|
||||
}
|
||||
|
||||
public String getUseUnit() {
|
||||
return useUnit;
|
||||
}
|
||||
|
||||
public void setUseUnit(String useUnit) {
|
||||
this.useUnit = useUnit;
|
||||
}
|
||||
|
||||
public String getQueryYear() {
|
||||
return queryYear;
|
||||
}
|
||||
|
||||
public void setQueryYear(String queryYear) {
|
||||
this.queryYear = queryYear;
|
||||
}
|
||||
|
||||
public String getQueryMonth() {
|
||||
return queryMonth;
|
||||
}
|
||||
|
||||
public void setQueryMonth(String queryMonth) {
|
||||
this.queryMonth = queryMonth;
|
||||
}
|
||||
|
||||
public String getDeptId() {
|
||||
return deptId;
|
||||
}
|
||||
|
||||
public void setDeptId(String deptId) {
|
||||
this.deptId = deptId;
|
||||
}
|
||||
|
||||
public String getUserId() {
|
||||
return userId;
|
||||
}
|
||||
|
||||
public void setUserId(String userId) {
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objId", getObjId())
|
||||
.append("deviceId", getDeviceId())
|
||||
.append("deviceCode", getDeviceCode())
|
||||
.append("deviceName", getDeviceName())
|
||||
.append("deviceType", getDeviceType())
|
||||
.append("openTime", getOpenTime())
|
||||
.append("closeTime", getCloseTime())
|
||||
.append("useTime", getUseTime())
|
||||
.append("defaultTime", getDefaultTime())
|
||||
.append("chargePrice", getChargePrice())
|
||||
.append("overtimeState", getOvertimeState())
|
||||
.append("useState", getUseState())
|
||||
.append("useUser", getUseUser())
|
||||
.append("useUnit", getUseUnit())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("queryYear", getQueryYear())
|
||||
.append("queryMonth", getQueryMonth())
|
||||
.append("deptId", getDeptId())
|
||||
.append("userId", getUserId())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,154 @@
|
||||
package com.ruoyi.device.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 委外工单对象 device_repair_outsourcing
|
||||
*
|
||||
* @author wh
|
||||
* @date 2022-06-08
|
||||
*/
|
||||
public class RepairOutsourcing extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** 主键 */
|
||||
private Long objid;
|
||||
|
||||
/** 单号 */
|
||||
@Excel(name = "单号")
|
||||
private String billsCode;
|
||||
|
||||
/** 设备ID */
|
||||
@Excel(name = "设备ID")
|
||||
private Long deviceId;
|
||||
|
||||
/** 委外单位 */
|
||||
@Excel(name = "委外单位")
|
||||
private String manufacturerName;
|
||||
|
||||
/** 联系人 */
|
||||
@Excel(name = "联系人")
|
||||
private String contacts;
|
||||
|
||||
/** 联系方式 */
|
||||
@Excel(name = "联系方式")
|
||||
private String phone;
|
||||
|
||||
/** 申请原因 */
|
||||
@Excel(name = "申请原因")
|
||||
private String reason;
|
||||
/** 结束时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date endDay;
|
||||
private BaseInfo deviceInfo;
|
||||
private Long repairBillsCode;
|
||||
public BaseInfo getDeviceInfo() {
|
||||
return deviceInfo;
|
||||
}
|
||||
|
||||
public Long getRepairBillsCode() {
|
||||
return repairBillsCode;
|
||||
}
|
||||
|
||||
public void setRepairBillsCode(Long repairBillsCode) {
|
||||
this.repairBillsCode = repairBillsCode;
|
||||
}
|
||||
|
||||
public void setDeviceInfo(BaseInfo deviceInfo) {
|
||||
this.deviceInfo = deviceInfo;
|
||||
}
|
||||
public void setObjid(Long objid)
|
||||
{
|
||||
this.objid = objid;
|
||||
}
|
||||
|
||||
public Long getObjid()
|
||||
{
|
||||
return objid;
|
||||
}
|
||||
public void setBillsCode(String billsCode)
|
||||
{
|
||||
this.billsCode = billsCode;
|
||||
}
|
||||
|
||||
public String getBillsCode()
|
||||
{
|
||||
return billsCode;
|
||||
}
|
||||
public void setDeviceId(Long deviceId)
|
||||
{
|
||||
this.deviceId = deviceId;
|
||||
}
|
||||
|
||||
public Long getDeviceId()
|
||||
{
|
||||
return deviceId;
|
||||
}
|
||||
public void setManufacturerName(String manufacturerName)
|
||||
{
|
||||
this.manufacturerName = manufacturerName;
|
||||
}
|
||||
|
||||
public String getManufacturerName()
|
||||
{
|
||||
return manufacturerName;
|
||||
}
|
||||
public void setContacts(String contacts)
|
||||
{
|
||||
this.contacts = contacts;
|
||||
}
|
||||
|
||||
public String getContacts()
|
||||
{
|
||||
return contacts;
|
||||
}
|
||||
public void setPhone(String phone)
|
||||
{
|
||||
this.phone = phone;
|
||||
}
|
||||
|
||||
public String getPhone()
|
||||
{
|
||||
return phone;
|
||||
}
|
||||
public void setReason(String reason)
|
||||
{
|
||||
this.reason = reason;
|
||||
}
|
||||
|
||||
public String getReason()
|
||||
{
|
||||
return reason;
|
||||
}
|
||||
|
||||
public Date getEndDay() {
|
||||
return endDay;
|
||||
}
|
||||
|
||||
public void setEndDay(Date endDay) {
|
||||
this.endDay = endDay;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("objid", getObjid())
|
||||
.append("billsCode", getBillsCode())
|
||||
.append("deviceId", getDeviceId())
|
||||
.append("manufacturerName", getManufacturerName())
|
||||
.append("contacts", getContacts())
|
||||
.append("phone", getPhone())
|
||||
.append("reason", getReason())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,64 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import com.ruoyi.device.domain.BaseDeviceLocation;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 桩位信息维护Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-28
|
||||
*/
|
||||
@Repository
|
||||
public interface BaseDeviceLocationMapper
|
||||
{
|
||||
/**
|
||||
* 查询桩位信息维护
|
||||
*
|
||||
* @param locationId 桩位信息维护主键
|
||||
* @return 桩位信息维护
|
||||
*/
|
||||
public BaseDeviceLocation selectBaseLocationByLocationId(Long locationId);
|
||||
|
||||
/**
|
||||
* 查询桩位信息维护列表
|
||||
*
|
||||
* @param baseDeviceLocation 桩位信息维护
|
||||
* @return 桩位信息维护集合
|
||||
*/
|
||||
public List<BaseDeviceLocation> selectBaseLocationList(BaseDeviceLocation baseDeviceLocation);
|
||||
|
||||
/**
|
||||
* 新增桩位信息维护
|
||||
*
|
||||
* @param baseDeviceLocation 桩位信息维护
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBaseLocation(BaseDeviceLocation baseDeviceLocation);
|
||||
|
||||
/**
|
||||
* 修改桩位信息维护
|
||||
*
|
||||
* @param baseDeviceLocation 桩位信息维护
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateBaseLocation(BaseDeviceLocation baseDeviceLocation);
|
||||
|
||||
/**
|
||||
* 删除桩位信息维护
|
||||
*
|
||||
* @param locationId 桩位信息维护主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseLocationByLocationId(Long locationId);
|
||||
|
||||
/**
|
||||
* 批量删除桩位信息维护
|
||||
*
|
||||
* @param locationIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseLocationByLocationIds(String[] locationIds);
|
||||
}
|
||||
@ -0,0 +1,66 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import com.ruoyi.device.domain.BaseDeviceManufacturer;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 设备生产厂家Mapper接口
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2022-04-02
|
||||
*/
|
||||
@Repository
|
||||
public interface BaseDeviceManufacturerMapper
|
||||
{
|
||||
/**
|
||||
* 查询设备生产厂家
|
||||
*
|
||||
* @param objid 设备生产厂家主键
|
||||
* @return 设备生产厂家
|
||||
*/
|
||||
public BaseDeviceManufacturer selectBaseManufacturerByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 查询设备生产厂家列表
|
||||
*
|
||||
* @param baseDeviceManufacturer 设备生产厂家
|
||||
* @return 设备生产厂家集合
|
||||
*/
|
||||
public List<BaseDeviceManufacturer> selectBaseManufacturerList(BaseDeviceManufacturer baseDeviceManufacturer);
|
||||
|
||||
/**
|
||||
* 新增设备生产厂家
|
||||
*
|
||||
* @param baseDeviceManufacturer 设备生产厂家
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBaseManufacturer(BaseDeviceManufacturer baseDeviceManufacturer);
|
||||
|
||||
/**
|
||||
* 修改设备生产厂家
|
||||
*
|
||||
* @param baseDeviceManufacturer 设备生产厂家
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateBaseManufacturer(BaseDeviceManufacturer baseDeviceManufacturer);
|
||||
|
||||
/**
|
||||
* 删除设备生产厂家
|
||||
*
|
||||
* @param objid 设备生产厂家主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseManufacturerByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 批量删除设备生产厂家
|
||||
*
|
||||
* @param objids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseManufacturerByObjids(String[] objids);
|
||||
|
||||
BaseDeviceManufacturer selectBaseManufacturerByName(String name);
|
||||
}
|
||||
@ -0,0 +1,71 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.ruoyi.device.domain.BaseType;
|
||||
import org.springframework.stereotype.Repository;
|
||||
import com.ruoyi.device.domain.BaseInfo;
|
||||
|
||||
/**
|
||||
* 设备基础信息Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
@Repository
|
||||
public interface BaseInfoMapper
|
||||
{
|
||||
/**
|
||||
* 查询设备基础信息
|
||||
*
|
||||
* @param objId 设备基础信息主键
|
||||
* @return 设备基础信息
|
||||
*/
|
||||
public BaseInfo selectBaseInfoByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询设备基础信息列表
|
||||
*
|
||||
* @param baseInfo 设备基础信息
|
||||
* @return 设备基础信息集合
|
||||
*/
|
||||
public List<BaseInfo> selectBaseInfoList(BaseInfo baseInfo);
|
||||
|
||||
/**
|
||||
* 新增设备基础信息
|
||||
*
|
||||
* @param baseInfo 设备基础信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBaseInfo(BaseInfo baseInfo);
|
||||
|
||||
/**
|
||||
* 修改设备基础信息
|
||||
*
|
||||
* @param baseInfo 设备基础信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateBaseInfo(BaseInfo baseInfo);
|
||||
|
||||
/**
|
||||
* 删除设备基础信息
|
||||
*
|
||||
* @param objId 设备基础信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseInfoByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 批量删除设备基础信息
|
||||
*
|
||||
* @param objIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseInfoByObjIds(String[] objIds);
|
||||
|
||||
BaseInfo checkDeviceCode(BaseInfo baseInfo);
|
||||
|
||||
BaseInfo selectDeviceInfo(String deviceCode);
|
||||
|
||||
List<BaseInfo> selectDeviceInfoList();
|
||||
}
|
||||
@ -0,0 +1,65 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.device.domain.BaseType;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
/**
|
||||
* 设备类型维护Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
@Repository
|
||||
public interface BaseTypeMapper
|
||||
{
|
||||
/**
|
||||
* 查询设备类型维护
|
||||
*
|
||||
* @param objId 设备类型维护主键
|
||||
* @return 设备类型维护
|
||||
*/
|
||||
public BaseType selectBaseTypeByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询设备类型维护列表
|
||||
*
|
||||
* @param baseType 设备类型维护
|
||||
* @return 设备类型维护集合
|
||||
*/
|
||||
public List<BaseType> selectBaseTypeList(BaseType baseType);
|
||||
|
||||
/**
|
||||
* 新增设备类型维护
|
||||
*
|
||||
* @param baseType 设备类型维护
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBaseType(BaseType baseType);
|
||||
|
||||
/**
|
||||
* 修改设备类型维护
|
||||
*
|
||||
* @param baseType 设备类型维护
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateBaseType(BaseType baseType);
|
||||
|
||||
/**
|
||||
* 删除设备类型维护
|
||||
*
|
||||
* @param objId 设备类型维护主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseTypeByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 批量删除设备类型维护
|
||||
*
|
||||
* @param objIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseTypeByObjIds(String[] objIds);
|
||||
|
||||
BaseType checkDeviceTypeName(BaseType baseType);
|
||||
}
|
||||
@ -0,0 +1,64 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.device.domain.DeviceBaseFault;
|
||||
import org.springframework.stereotype.Repository;
|
||||
/**
|
||||
* 故障类别维护Mapper接口
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-24
|
||||
*/
|
||||
@Repository
|
||||
public interface DeviceBaseFaultMapper
|
||||
{
|
||||
/**
|
||||
* 查询故障类别维护
|
||||
*
|
||||
* @param objid 故障类别维护主键
|
||||
* @return 故障类别维护
|
||||
*/
|
||||
public DeviceBaseFault selectDeviceBaseFaultByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 查询故障类别维护列表
|
||||
*
|
||||
* @param deviceBaseFault 故障类别维护
|
||||
* @return 故障类别维护集合
|
||||
*/
|
||||
public List<DeviceBaseFault> selectDeviceBaseFaultList(DeviceBaseFault deviceBaseFault);
|
||||
|
||||
/**
|
||||
* 新增故障类别维护
|
||||
*
|
||||
* @param deviceBaseFault 故障类别维护
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDeviceBaseFault(DeviceBaseFault deviceBaseFault);
|
||||
|
||||
/**
|
||||
* 修改故障类别维护
|
||||
*
|
||||
* @param deviceBaseFault 故障类别维护
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDeviceBaseFault(DeviceBaseFault deviceBaseFault);
|
||||
|
||||
/**
|
||||
* 删除故障类别维护
|
||||
*
|
||||
* @param objid 故障类别维护主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceBaseFaultByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 批量删除故障类别维护
|
||||
*
|
||||
* @param objids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceBaseFaultByObjids(String[] objids);
|
||||
|
||||
List<DeviceBaseFault> selectFaultList();
|
||||
}
|
||||
@ -0,0 +1,62 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.device.domain.DeviceInspectProject;
|
||||
import org.springframework.stereotype.Repository;
|
||||
/**
|
||||
* 巡检项目管理Mapper接口
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-30
|
||||
*/
|
||||
@Repository
|
||||
public interface DeviceInspectProjectMapper
|
||||
{
|
||||
/**
|
||||
* 查询巡检项目管理
|
||||
*
|
||||
* @param objId 巡检项目管理主键
|
||||
* @return 巡检项目管理
|
||||
*/
|
||||
public DeviceInspectProject selectDeviceInspectProjectByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询巡检项目管理列表
|
||||
*
|
||||
* @param deviceInspectProject 巡检项目管理
|
||||
* @return 巡检项目管理集合
|
||||
*/
|
||||
public List<DeviceInspectProject> selectDeviceInspectProjectList(DeviceInspectProject deviceInspectProject);
|
||||
|
||||
/**
|
||||
* 新增巡检项目管理
|
||||
*
|
||||
* @param deviceInspectProject 巡检项目管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDeviceInspectProject(DeviceInspectProject deviceInspectProject);
|
||||
|
||||
/**
|
||||
* 修改巡检项目管理
|
||||
*
|
||||
* @param deviceInspectProject 巡检项目管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDeviceInspectProject(DeviceInspectProject deviceInspectProject);
|
||||
|
||||
/**
|
||||
* 删除巡检项目管理
|
||||
*
|
||||
* @param objId 巡检项目管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceInspectProjectByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 批量删除巡检项目管理
|
||||
*
|
||||
* @param objIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceInspectProjectByObjIds(String[] objIds);
|
||||
}
|
||||
@ -0,0 +1,62 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.device.domain.DeviceInspectionManual;
|
||||
import org.springframework.stereotype.Repository;
|
||||
/**
|
||||
* 巡检手册管理Mapper接口
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-09-30
|
||||
*/
|
||||
@Repository
|
||||
public interface DeviceInspectionManualMapper
|
||||
{
|
||||
/**
|
||||
* 查询巡检手册管理
|
||||
*
|
||||
* @param objId 巡检手册管理主键
|
||||
* @return 巡检手册管理
|
||||
*/
|
||||
public DeviceInspectionManual selectDeviceInspectionManualByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询巡检手册管理列表
|
||||
*
|
||||
* @param deviceInspectionManual 巡检手册管理
|
||||
* @return 巡检手册管理集合
|
||||
*/
|
||||
public List<DeviceInspectionManual> selectDeviceInspectionManualList(DeviceInspectionManual deviceInspectionManual);
|
||||
|
||||
/**
|
||||
* 新增巡检手册管理
|
||||
*
|
||||
* @param deviceInspectionManual 巡检手册管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDeviceInspectionManual(DeviceInspectionManual deviceInspectionManual);
|
||||
|
||||
/**
|
||||
* 修改巡检手册管理
|
||||
*
|
||||
* @param deviceInspectionManual 巡检手册管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDeviceInspectionManual(DeviceInspectionManual deviceInspectionManual);
|
||||
|
||||
/**
|
||||
* 删除巡检手册管理
|
||||
*
|
||||
* @param objId 巡检手册管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceInspectionManualByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 批量删除巡检手册管理
|
||||
*
|
||||
* @param objIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceInspectionManualByObjIds(String[] objIds);
|
||||
}
|
||||
@ -0,0 +1,62 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.device.domain.DeviceInspectionRoute;
|
||||
import org.springframework.stereotype.Repository;
|
||||
/**
|
||||
* 巡检线路Mapper接口
|
||||
*
|
||||
* @author wangh
|
||||
* @date 2025-10-23
|
||||
*/
|
||||
@Repository
|
||||
public interface DeviceInspectionRouteMapper
|
||||
{
|
||||
/**
|
||||
* 查询巡检线路
|
||||
*
|
||||
* @param routeId 巡检线路主键
|
||||
* @return 巡检线路
|
||||
*/
|
||||
public DeviceInspectionRoute selectDeviceInspectionRouteByRouteId(Long routeId);
|
||||
|
||||
/**
|
||||
* 查询巡检线路列表
|
||||
*
|
||||
* @param deviceInspectionRoute 巡检线路
|
||||
* @return 巡检线路集合
|
||||
*/
|
||||
public List<DeviceInspectionRoute> selectDeviceInspectionRouteList(DeviceInspectionRoute deviceInspectionRoute);
|
||||
|
||||
/**
|
||||
* 新增巡检线路
|
||||
*
|
||||
* @param deviceInspectionRoute 巡检线路
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDeviceInspectionRoute(DeviceInspectionRoute deviceInspectionRoute);
|
||||
|
||||
/**
|
||||
* 修改巡检线路
|
||||
*
|
||||
* @param deviceInspectionRoute 巡检线路
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDeviceInspectionRoute(DeviceInspectionRoute deviceInspectionRoute);
|
||||
|
||||
/**
|
||||
* 删除巡检线路
|
||||
*
|
||||
* @param routeId 巡检线路主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceInspectionRouteByRouteId(Long routeId);
|
||||
|
||||
/**
|
||||
* 批量删除巡检线路
|
||||
*
|
||||
* @param routeIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceInspectionRouteByRouteIds(String[] routeIds);
|
||||
}
|
||||
@ -0,0 +1,64 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import com.ruoyi.device.domain.DeviceRepartBills;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 维修工单Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2022-05-26
|
||||
*/
|
||||
@Repository
|
||||
public interface DeviceRepartBillsMapper
|
||||
{
|
||||
/**
|
||||
* 查询维修工单
|
||||
*
|
||||
* @param objid 维修工单主键
|
||||
* @return 维修工单
|
||||
*/
|
||||
public DeviceRepartBills selectDeviceRepartBillsByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 查询维修工单列表
|
||||
*
|
||||
* @param deviceRepartBills 维修工单
|
||||
* @return 维修工单集合
|
||||
*/
|
||||
public List<DeviceRepartBills> selectDeviceRepartBillsList(DeviceRepartBills deviceRepartBills);
|
||||
|
||||
/**
|
||||
* 新增维修工单
|
||||
*
|
||||
* @param deviceRepartBills 维修工单
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDeviceRepartBills(DeviceRepartBills deviceRepartBills);
|
||||
|
||||
/**
|
||||
* 修改维修工单
|
||||
*
|
||||
* @param deviceRepartBills 维修工单
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDeviceRepartBills(DeviceRepartBills deviceRepartBills);
|
||||
|
||||
/**
|
||||
* 删除维修工单
|
||||
*
|
||||
* @param objid 维修工单主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceRepartBillsByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 批量删除维修工单
|
||||
*
|
||||
* @param objids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceRepartBillsByObjids(String[] objids);
|
||||
}
|
||||
@ -0,0 +1,11 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import com.ruoyi.device.domain.LundangBaseStore;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Repository
|
||||
public interface LundangMapper {
|
||||
List<LundangBaseStore> selectLundangBaseStoreList();
|
||||
}
|
||||
@ -0,0 +1,13 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import com.ruoyi.device.domain.RecordUse;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Repository
|
||||
public interface PdaApiMapper {
|
||||
List<RecordUse> selectUseList();
|
||||
|
||||
void updateRecord(String code);
|
||||
}
|
||||
@ -0,0 +1,63 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.stereotype.Repository;
|
||||
import com.ruoyi.device.domain.RecordUse;
|
||||
|
||||
/**
|
||||
* 使用记录Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
@Repository
|
||||
public interface RecordUseMapper
|
||||
{
|
||||
/**
|
||||
* 查询使用记录
|
||||
*
|
||||
* @param objId 使用记录主键
|
||||
* @return 使用记录
|
||||
*/
|
||||
public RecordUse selectRecordUseByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询使用记录列表
|
||||
*
|
||||
* @param recordUse 使用记录
|
||||
* @return 使用记录集合
|
||||
*/
|
||||
public List<RecordUse> selectRecordUseList(RecordUse recordUse);
|
||||
|
||||
/**
|
||||
* 新增使用记录
|
||||
*
|
||||
* @param recordUse 使用记录
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertRecordUse(RecordUse recordUse);
|
||||
|
||||
/**
|
||||
* 修改使用记录
|
||||
*
|
||||
* @param recordUse 使用记录
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateRecordUse(RecordUse recordUse);
|
||||
|
||||
/**
|
||||
* 删除使用记录
|
||||
*
|
||||
* @param objId 使用记录主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRecordUseByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 批量删除使用记录
|
||||
*
|
||||
* @param objIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRecordUseByObjIds(String[] objIds);
|
||||
}
|
||||
@ -0,0 +1,62 @@
|
||||
package com.ruoyi.device.mapper;
|
||||
|
||||
import com.ruoyi.device.domain.RepairOutsourcing;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 委外工单Mapper接口
|
||||
*
|
||||
* @author wh
|
||||
* @date 2022-06-08
|
||||
*/
|
||||
public interface RepairOutsourcingMapper
|
||||
{
|
||||
/**
|
||||
* 查询委外工单
|
||||
*
|
||||
* @param objid 委外工单主键
|
||||
* @return 委外工单
|
||||
*/
|
||||
public RepairOutsourcing selectRepairOutsourcingByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 查询委外工单列表
|
||||
*
|
||||
* @param repairOutsourcing 委外工单
|
||||
* @return 委外工单集合
|
||||
*/
|
||||
public List<RepairOutsourcing> selectRepairOutsourcingList(RepairOutsourcing repairOutsourcing);
|
||||
|
||||
/**
|
||||
* 新增委外工单
|
||||
*
|
||||
* @param repairOutsourcing 委外工单
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertRepairOutsourcing(RepairOutsourcing repairOutsourcing);
|
||||
|
||||
/**
|
||||
* 修改委外工单
|
||||
*
|
||||
* @param repairOutsourcing 委外工单
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateRepairOutsourcing(RepairOutsourcing repairOutsourcing);
|
||||
|
||||
/**
|
||||
* 删除委外工单
|
||||
*
|
||||
* @param objid 委外工单主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRepairOutsourcingByObjid(Long objid);
|
||||
|
||||
/**
|
||||
* 批量删除委外工单
|
||||
*
|
||||
* @param objids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteRepairOutsourcingByObjids(String[] objids);
|
||||
}
|
||||
@ -0,0 +1,62 @@
|
||||
package com.ruoyi.device.service;
|
||||
|
||||
import com.ruoyi.device.domain.BaseDeviceLocation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 桩位信息维护Service接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-28
|
||||
*/
|
||||
public interface IBaseDeviceLocationService
|
||||
{
|
||||
/**
|
||||
* 查询桩位信息维护
|
||||
*
|
||||
* @param locationId 桩位信息维护主键
|
||||
* @return 桩位信息维护
|
||||
*/
|
||||
public BaseDeviceLocation selectBaseLocationByLocationId(Long locationId);
|
||||
|
||||
/**
|
||||
* 查询桩位信息维护列表
|
||||
*
|
||||
* @param baseDeviceLocation 桩位信息维护
|
||||
* @return 桩位信息维护集合
|
||||
*/
|
||||
public List<BaseDeviceLocation> selectBaseLocationList(BaseDeviceLocation baseDeviceLocation);
|
||||
|
||||
/**
|
||||
* 新增桩位信息维护
|
||||
*
|
||||
* @param baseDeviceLocation 桩位信息维护
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBaseLocation(BaseDeviceLocation baseDeviceLocation);
|
||||
|
||||
/**
|
||||
* 修改桩位信息维护
|
||||
*
|
||||
* @param baseDeviceLocation 桩位信息维护
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateBaseLocation(BaseDeviceLocation baseDeviceLocation);
|
||||
|
||||
/**
|
||||
* 批量删除桩位信息维护
|
||||
*
|
||||
* @param locationIds 需要删除的桩位信息维护主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseLocationByLocationIds(String locationIds);
|
||||
|
||||
/**
|
||||
* 删除桩位信息维护信息
|
||||
*
|
||||
* @param locationId 桩位信息维护主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseLocationByLocationId(Long locationId);
|
||||
}
|
||||
@ -0,0 +1,69 @@
|
||||
package com.ruoyi.device.service;
|
||||
|
||||
import com.ruoyi.device.domain.BaseInfo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 设备基础信息Service接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-05-19
|
||||
*/
|
||||
public interface IBaseInfoService
|
||||
{
|
||||
/**
|
||||
* 查询设备基础信息
|
||||
*
|
||||
* @param objId 设备基础信息主键
|
||||
* @return 设备基础信息
|
||||
*/
|
||||
public BaseInfo selectBaseInfoByObjId(Long objId);
|
||||
|
||||
/**
|
||||
* 查询设备基础信息列表
|
||||
*
|
||||
* @param baseInfo 设备基础信息
|
||||
* @return 设备基础信息集合
|
||||
*/
|
||||
public List<BaseInfo> selectBaseInfoList(BaseInfo baseInfo);
|
||||
|
||||
/**
|
||||
* 新增设备基础信息
|
||||
*
|
||||
* @param baseInfo 设备基础信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBaseInfo(BaseInfo baseInfo);
|
||||
|
||||
/**
|
||||
* 修改设备基础信息
|
||||
*
|
||||
* @param baseInfo 设备基础信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateBaseInfo(BaseInfo baseInfo);
|
||||
public int updateBaseInfoForApi(BaseInfo baseInfo);
|
||||
|
||||
/**
|
||||
* 批量删除设备基础信息
|
||||
*
|
||||
* @param objIds 需要删除的设备基础信息主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseInfoByObjIds(String objIds);
|
||||
|
||||
/**
|
||||
* 删除设备基础信息信息
|
||||
*
|
||||
* @param objId 设备基础信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBaseInfoByObjId(Long objId);
|
||||
|
||||
boolean checkDeviceCode(BaseInfo baseInfo);
|
||||
|
||||
BaseInfo selectDeviceInfo(String code);
|
||||
|
||||
List<BaseInfo> selectDeviceInfoList();
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue