提升机调度相关逻辑
This commit is contained in:
@@ -32,23 +32,37 @@ public class TaskStatusCode {
|
||||
/**
|
||||
* 任务执行阶段 AGV
|
||||
*/
|
||||
public static final String TASK_EP_AGV = "1";
|
||||
public static final String TASK_EP_SRGV_KC_TSJ_RK = "1";
|
||||
public static final String TASK_EP_TJS_KC_UNLOAD = "2";
|
||||
public static final String TASK_EP_SRGV_KC_TSJ = "3";
|
||||
public static final String TASK_EP_TJS_KC_LOAD = "4";
|
||||
public static final String TASK_EP_SRGV_KC_TSJ_CK = "5";
|
||||
public static final String TASK_EP_SRGV_QH = "6";
|
||||
public static final String TASK_EP_SRGV_MC_TSJ_RK = "7";
|
||||
public static final String TASK_EP_TJS_MC_UNLOAD = "8";
|
||||
public static final String TASK_EP_SRGV_MC_TSJ = "9";
|
||||
public static final String TASK_EP_TJS_MC_LOAD = "10";
|
||||
public static final String TASK_EP_SRGV_MC_TSJ_CK = "11";
|
||||
public static final String TASK_EP_SRGV_FH = "12";
|
||||
public static final String TASK_EP_SSJ = "13";
|
||||
public static final String TASK_EP_CK = "14";
|
||||
|
||||
/**
|
||||
* 任务执行阶段 入口输送机
|
||||
*/
|
||||
public static final String TASK_EP_SSJ = "2";
|
||||
//public static final String TASK_EP_SSJ = "2";
|
||||
/**
|
||||
* 任务执行阶段 巷道口
|
||||
*/
|
||||
public static final String TASK_EP_ROADWAY_SSJ = "3";
|
||||
//public static final String TASK_EP_ROADWAY_SSJ = "3";
|
||||
/**
|
||||
* 任务执行阶段 堆垛机
|
||||
*/
|
||||
public static final String TASK_EP_DDJ = "4";
|
||||
//public static final String TASK_EP_DDJ = "4";
|
||||
|
||||
/**
|
||||
* 任务执行阶段 回传wms完成
|
||||
*/
|
||||
public static final String TASK_EP_WMS_FINISH = "5";
|
||||
//public static final String TASK_EP_WMS_FINISH = "5";
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,104 @@
|
||||
package com.ruoyi.device.tsj.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.device.tsj.domain.DeviceTsj;
|
||||
import com.ruoyi.device.tsj.service.IDeviceTsjService;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 提升机设备Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/device/tsj")
|
||||
public class DeviceTsjController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private IDeviceTsjService deviceTsjService;
|
||||
|
||||
/**
|
||||
* 查询提升机设备列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('device:tsj:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(DeviceTsj deviceTsj)
|
||||
{
|
||||
startPage();
|
||||
List<DeviceTsj> list = deviceTsjService.selectDeviceTsjList(deviceTsj);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出提升机设备列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('device:tsj:export')")
|
||||
@Log(title = "提升机设备", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, DeviceTsj deviceTsj)
|
||||
{
|
||||
List<DeviceTsj> list = deviceTsjService.selectDeviceTsjList(deviceTsj);
|
||||
ExcelUtil<DeviceTsj> util = new ExcelUtil<DeviceTsj>(DeviceTsj.class);
|
||||
util.exportExcel(response, list, "提升机设备数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取提升机设备详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('device:tsj:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||
{
|
||||
return success(deviceTsjService.selectDeviceTsjById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增提升机设备
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('device:tsj:add')")
|
||||
@Log(title = "提升机设备", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody DeviceTsj deviceTsj)
|
||||
{
|
||||
return toAjax(deviceTsjService.insertDeviceTsj(deviceTsj));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改提升机设备
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('device:tsj:edit')")
|
||||
@Log(title = "提升机设备", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody DeviceTsj deviceTsj)
|
||||
{
|
||||
return toAjax(deviceTsjService.updateDeviceTsj(deviceTsj));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除提升机设备
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('device:tsj:remove')")
|
||||
@Log(title = "提升机设备", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable Long[] ids)
|
||||
{
|
||||
return toAjax(deviceTsjService.deleteDeviceTsjByIds(ids));
|
||||
}
|
||||
}
|
||||
@@ -1,87 +1,120 @@
|
||||
package com.ruoyi.device.tsj.domain;
|
||||
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.ToString;
|
||||
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;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* 输送机对象 device_ssj
|
||||
* 提升机设备对象 device_tsj
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-07-04
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@ToString
|
||||
public class DeviceTsj extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** $column.columnComment */
|
||||
/** id */
|
||||
private Long id;
|
||||
|
||||
/** 设备唯一编码 */
|
||||
@Excel(name = "设备唯一编码")
|
||||
private String deviceCode ;
|
||||
|
||||
/** 设备名称 */
|
||||
@Excel(name = "设备名称")
|
||||
private String name ;
|
||||
private String name;
|
||||
|
||||
/** 类型 */
|
||||
@Excel(name = "类型")
|
||||
private String type;
|
||||
/** ip */
|
||||
@Excel(name = "ip")
|
||||
private String ip;
|
||||
|
||||
/** 设备IP */
|
||||
@Excel(name = "设备IP")
|
||||
private String ipAddress;
|
||||
/** 端口 */
|
||||
@Excel(name = "端口")
|
||||
private String port;
|
||||
|
||||
/** PLC读取地址 */
|
||||
@Excel(name = "PLC读取地址")
|
||||
/** plc读取地址 */
|
||||
@Excel(name = "plc读取地址")
|
||||
private String plcDbReadAddress;
|
||||
|
||||
/** 0-F 1-T */
|
||||
@Excel(name = "0-F 1-T")
|
||||
private String isActive;
|
||||
|
||||
/** PLC写入地址 */
|
||||
@Excel(name = "PLC写入地址")
|
||||
/** plc写入地址 */
|
||||
@Excel(name = "plc写入地址")
|
||||
private String plcDbWriteAddress;
|
||||
|
||||
/** 入库请求 */
|
||||
@Excel(name = "入库请求")
|
||||
private int rkqq;
|
||||
|
||||
/** 空闲 */
|
||||
@Excel(name = "空闲")
|
||||
private int kx;
|
||||
|
||||
/** 到位 */
|
||||
@Excel(name = "到位")
|
||||
private int dw;
|
||||
|
||||
/** 条码 */
|
||||
@Excel(name = "条码")
|
||||
private String trayCode;
|
||||
|
||||
/** 任务号 */
|
||||
@Excel(name = "任务号")
|
||||
private int taskNo;
|
||||
private Long rwh;
|
||||
|
||||
@Excel(name = "异常")
|
||||
private int exception;
|
||||
/** 执行阶段 */
|
||||
@Excel(name = "执行阶段")
|
||||
private Integer jdbz;
|
||||
|
||||
@Excel(name = "托盘尺寸")
|
||||
private int traySize;
|
||||
/** 设备状态 */
|
||||
@Excel(name = "设备状态")
|
||||
private Integer sbzt;
|
||||
|
||||
@Excel(name="允许放货")
|
||||
private int allowPut;
|
||||
/** 触发方式 */
|
||||
@Excel(name = "触发方式")
|
||||
private Integer czfs;
|
||||
|
||||
@Excel(name="输送线模式 1-入库 2-出库")
|
||||
private int model;
|
||||
/** 允许下发 */
|
||||
@Excel(name = "允许下发")
|
||||
private Integer yxxf;
|
||||
|
||||
/** 原排 */
|
||||
@Excel(name = "原排")
|
||||
private Integer yph;
|
||||
|
||||
/** 原列 */
|
||||
@Excel(name = "原列")
|
||||
private Integer ylh;
|
||||
|
||||
/** 原层 */
|
||||
@Excel(name = "原层")
|
||||
private Integer ych;
|
||||
|
||||
/** 目标排 */
|
||||
@Excel(name = "目标排")
|
||||
private Integer mbph;
|
||||
|
||||
/** 目标列 */
|
||||
@Excel(name = "目标列")
|
||||
private Integer mblh;
|
||||
|
||||
/** 目标层 */
|
||||
@Excel(name = "目标层")
|
||||
private Integer mbch;
|
||||
|
||||
/** 心跳信号 */
|
||||
@Excel(name = "心跳信号")
|
||||
private Integer xtxh;
|
||||
|
||||
/** 当前层数 */
|
||||
@Excel(name = "当前层数")
|
||||
private Integer dqcs;
|
||||
|
||||
/** 载货状态 */
|
||||
@Excel(name = "载货状态")
|
||||
private Integer hczt;
|
||||
|
||||
/** 备用1 */
|
||||
@Excel(name = "备用1")
|
||||
private Integer spare1;
|
||||
|
||||
/** 备用2 */
|
||||
@Excel(name = "备用2")
|
||||
private Integer spare2;
|
||||
|
||||
/** 备用3 */
|
||||
@Excel(name = "备用3")
|
||||
private Integer spare3;
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,61 @@
|
||||
package com.ruoyi.device.tsj.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.device.tsj.domain.DeviceTsj;
|
||||
|
||||
/**
|
||||
* 提升机设备Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
public interface DeviceTsjMapper
|
||||
{
|
||||
/**
|
||||
* 查询提升机设备
|
||||
*
|
||||
* @param id 提升机设备主键
|
||||
* @return 提升机设备
|
||||
*/
|
||||
public DeviceTsj selectDeviceTsjById(Long id);
|
||||
|
||||
/**
|
||||
* 查询提升机设备列表
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 提升机设备集合
|
||||
*/
|
||||
public List<DeviceTsj> selectDeviceTsjList(DeviceTsj deviceTsj);
|
||||
|
||||
/**
|
||||
* 新增提升机设备
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDeviceTsj(DeviceTsj deviceTsj);
|
||||
|
||||
/**
|
||||
* 修改提升机设备
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDeviceTsj(DeviceTsj deviceTsj);
|
||||
|
||||
/**
|
||||
* 删除提升机设备
|
||||
*
|
||||
* @param id 提升机设备主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceTsjById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除提升机设备
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceTsjByIds(Long[] ids);
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
package com.ruoyi.device.tsj.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.device.tsj.domain.DeviceTsj;
|
||||
|
||||
/**
|
||||
* 提升机设备Service接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
public interface IDeviceTsjService
|
||||
{
|
||||
/**
|
||||
* 查询提升机设备
|
||||
*
|
||||
* @param id 提升机设备主键
|
||||
* @return 提升机设备
|
||||
*/
|
||||
public DeviceTsj selectDeviceTsjById(Long id);
|
||||
|
||||
/**
|
||||
* 查询提升机设备列表
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 提升机设备集合
|
||||
*/
|
||||
public List<DeviceTsj> selectDeviceTsjList(DeviceTsj deviceTsj);
|
||||
|
||||
/**
|
||||
* 新增提升机设备
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertDeviceTsj(DeviceTsj deviceTsj);
|
||||
|
||||
/**
|
||||
* 修改提升机设备
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateDeviceTsj(DeviceTsj deviceTsj);
|
||||
|
||||
/**
|
||||
* 批量删除提升机设备
|
||||
*
|
||||
* @param ids 需要删除的提升机设备主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceTsjByIds(Long[] ids);
|
||||
|
||||
/**
|
||||
* 删除提升机设备信息
|
||||
*
|
||||
* @param id 提升机设备主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteDeviceTsjById(Long id);
|
||||
}
|
||||
@@ -0,0 +1,93 @@
|
||||
package com.ruoyi.device.tsj.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.device.tsj.mapper.DeviceTsjMapper;
|
||||
import com.ruoyi.device.tsj.domain.DeviceTsj;
|
||||
import com.ruoyi.device.tsj.service.IDeviceTsjService;
|
||||
|
||||
/**
|
||||
* 提升机设备Service业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
@Service
|
||||
public class DeviceTsjServiceImpl implements IDeviceTsjService
|
||||
{
|
||||
@Autowired
|
||||
private DeviceTsjMapper deviceTsjMapper;
|
||||
|
||||
/**
|
||||
* 查询提升机设备
|
||||
*
|
||||
* @param id 提升机设备主键
|
||||
* @return 提升机设备
|
||||
*/
|
||||
@Override
|
||||
public DeviceTsj selectDeviceTsjById(Long id)
|
||||
{
|
||||
return deviceTsjMapper.selectDeviceTsjById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询提升机设备列表
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 提升机设备
|
||||
*/
|
||||
@Override
|
||||
public List<DeviceTsj> selectDeviceTsjList(DeviceTsj deviceTsj)
|
||||
{
|
||||
return deviceTsjMapper.selectDeviceTsjList(deviceTsj);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增提升机设备
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertDeviceTsj(DeviceTsj deviceTsj)
|
||||
{
|
||||
return deviceTsjMapper.insertDeviceTsj(deviceTsj);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改提升机设备
|
||||
*
|
||||
* @param deviceTsj 提升机设备
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateDeviceTsj(DeviceTsj deviceTsj)
|
||||
{
|
||||
return deviceTsjMapper.updateDeviceTsj(deviceTsj);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除提升机设备
|
||||
*
|
||||
* @param ids 需要删除的提升机设备主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteDeviceTsjByIds(Long[] ids)
|
||||
{
|
||||
return deviceTsjMapper.deleteDeviceTsjByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除提升机设备信息
|
||||
*
|
||||
* @param id 提升机设备主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteDeviceTsjById(Long id)
|
||||
{
|
||||
return deviceTsjMapper.deleteDeviceTsjById(id);
|
||||
}
|
||||
}
|
||||
@@ -104,7 +104,7 @@ public class JobCallBackController extends BaseController
|
||||
return toAjax(jobCallBackService.deleteJobCallBackByIds(ids));
|
||||
}
|
||||
|
||||
@Scheduled(fixedDelay=1500)
|
||||
//@Scheduled(fixedDelay=1500)
|
||||
public void jobCallBack() {
|
||||
jobCallBackService.jobCallBack();
|
||||
}
|
||||
|
||||
@@ -0,0 +1,104 @@
|
||||
package com.ruoyi.queue.tsj.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueue;
|
||||
import com.ruoyi.queue.tsj.service.ITsjDeviceExecutionQueueService;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 提升机执行队列Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/queue/tsj")
|
||||
public class TsjDeviceExecutionQueueController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private ITsjDeviceExecutionQueueService tsjDeviceExecutionQueueService;
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsj:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(TsjDeviceExecutionQueue tsjDeviceExecutionQueue)
|
||||
{
|
||||
startPage();
|
||||
List<TsjDeviceExecutionQueue> list = tsjDeviceExecutionQueueService.selectTsjDeviceExecutionQueueList(tsjDeviceExecutionQueue);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出提升机执行队列列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsj:export')")
|
||||
@Log(title = "提升机执行队列", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, TsjDeviceExecutionQueue tsjDeviceExecutionQueue)
|
||||
{
|
||||
List<TsjDeviceExecutionQueue> list = tsjDeviceExecutionQueueService.selectTsjDeviceExecutionQueueList(tsjDeviceExecutionQueue);
|
||||
ExcelUtil<TsjDeviceExecutionQueue> util = new ExcelUtil<TsjDeviceExecutionQueue>(TsjDeviceExecutionQueue.class);
|
||||
util.exportExcel(response, list, "提升机执行队列数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取提升机执行队列详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsj:query')")
|
||||
@GetMapping(value = "/{guid}")
|
||||
public AjaxResult getInfo(@PathVariable("guid") String guid)
|
||||
{
|
||||
return success(tsjDeviceExecutionQueueService.selectTsjDeviceExecutionQueueByGuid(guid));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增提升机执行队列
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsj:add')")
|
||||
@Log(title = "提升机执行队列", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody TsjDeviceExecutionQueue tsjDeviceExecutionQueue)
|
||||
{
|
||||
return toAjax(tsjDeviceExecutionQueueService.insertTsjDeviceExecutionQueue(tsjDeviceExecutionQueue));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改提升机执行队列
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsj:edit')")
|
||||
@Log(title = "提升机执行队列", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody TsjDeviceExecutionQueue tsjDeviceExecutionQueue)
|
||||
{
|
||||
return toAjax(tsjDeviceExecutionQueueService.updateTsjDeviceExecutionQueue(tsjDeviceExecutionQueue));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除提升机执行队列
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsj:remove')")
|
||||
@Log(title = "提升机执行队列", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{guids}")
|
||||
public AjaxResult remove(@PathVariable String[] guids)
|
||||
{
|
||||
return toAjax(tsjDeviceExecutionQueueService.deleteTsjDeviceExecutionQueueByGuids(guids));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,104 @@
|
||||
package com.ruoyi.queue.tsj.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueueFinish;
|
||||
import com.ruoyi.queue.tsj.service.ITsjDeviceExecutionQueueFinishService;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 提升机执行队列Controller
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/queue/tsjFinish")
|
||||
public class TsjDeviceExecutionQueueFinishController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private ITsjDeviceExecutionQueueFinishService tsjDeviceExecutionQueueFinishService;
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsjFinish:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish)
|
||||
{
|
||||
startPage();
|
||||
List<TsjDeviceExecutionQueueFinish> list = tsjDeviceExecutionQueueFinishService.selectTsjDeviceExecutionQueueFinishList(tsjDeviceExecutionQueueFinish);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出提升机执行队列列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsjFinish:export')")
|
||||
@Log(title = "提升机执行队列", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish)
|
||||
{
|
||||
List<TsjDeviceExecutionQueueFinish> list = tsjDeviceExecutionQueueFinishService.selectTsjDeviceExecutionQueueFinishList(tsjDeviceExecutionQueueFinish);
|
||||
ExcelUtil<TsjDeviceExecutionQueueFinish> util = new ExcelUtil<TsjDeviceExecutionQueueFinish>(TsjDeviceExecutionQueueFinish.class);
|
||||
util.exportExcel(response, list, "提升机执行队列数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取提升机执行队列详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsjFinish:query')")
|
||||
@GetMapping(value = "/{guid}")
|
||||
public AjaxResult getInfo(@PathVariable("guid") String guid)
|
||||
{
|
||||
return success(tsjDeviceExecutionQueueFinishService.selectTsjDeviceExecutionQueueFinishByGuid(guid));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增提升机执行队列
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsjFinish:add')")
|
||||
@Log(title = "提升机执行队列", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish)
|
||||
{
|
||||
return toAjax(tsjDeviceExecutionQueueFinishService.insertTsjDeviceExecutionQueueFinish(tsjDeviceExecutionQueueFinish));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改提升机执行队列
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsjFinish:edit')")
|
||||
@Log(title = "提升机执行队列", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish)
|
||||
{
|
||||
return toAjax(tsjDeviceExecutionQueueFinishService.updateTsjDeviceExecutionQueueFinish(tsjDeviceExecutionQueueFinish));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除提升机执行队列
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('queue:tsjFinish:remove')")
|
||||
@Log(title = "提升机执行队列", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{guids}")
|
||||
public AjaxResult remove(@PathVariable String[] guids)
|
||||
{
|
||||
return toAjax(tsjDeviceExecutionQueueFinishService.deleteTsjDeviceExecutionQueueFinishByGuids(guids));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,352 @@
|
||||
package com.ruoyi.queue.tsj.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;
|
||||
|
||||
/**
|
||||
* 提升机执行队列对象 tsj_device_execution_queue
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
public class TsjDeviceExecutionQueue extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** GUID */
|
||||
private String guid;
|
||||
|
||||
/** 设备编号 */
|
||||
@Excel(name = "设备编号")
|
||||
private Long deviceId;
|
||||
|
||||
/** 设备名称 */
|
||||
@Excel(name = "设备名称")
|
||||
private String deviceName;
|
||||
|
||||
/** 任务号 */
|
||||
@Excel(name = "任务号")
|
||||
private Long taskNo;
|
||||
|
||||
/** 原排 */
|
||||
@Excel(name = "原排")
|
||||
private String srcRow;
|
||||
|
||||
/** 原列 */
|
||||
@Excel(name = "原列")
|
||||
private String srcColumn;
|
||||
|
||||
/** 原层 */
|
||||
@Excel(name = "原层")
|
||||
private String srcLayer;
|
||||
|
||||
/** 目标排 */
|
||||
@Excel(name = "目标排")
|
||||
private String tarRow;
|
||||
|
||||
/** 目标列 */
|
||||
@Excel(name = "目标列")
|
||||
private String tarColumn;
|
||||
|
||||
/** 目标层 */
|
||||
@Excel(name = "目标层")
|
||||
private String tarLayer;
|
||||
|
||||
/** 原地址 */
|
||||
@Excel(name = "原地址")
|
||||
private String srcSite;
|
||||
|
||||
/** 目标地址 */
|
||||
@Excel(name = "目标地址")
|
||||
private String tarSite;
|
||||
|
||||
/** 下发 */
|
||||
@Excel(name = "下发")
|
||||
private String sendFlag;
|
||||
|
||||
/** 下发类型 */
|
||||
@Excel(name = "下发类型")
|
||||
private String sendType;
|
||||
|
||||
/** 任务类型 */
|
||||
@Excel(name = "任务类型")
|
||||
private String taskType;
|
||||
|
||||
/** 创建时间 */
|
||||
@Excel(name = "创建时间")
|
||||
private String createDate;
|
||||
|
||||
/** 开始时间 */
|
||||
@Excel(name = "开始时间")
|
||||
private String startDate;
|
||||
|
||||
/** 完成时间 */
|
||||
@Excel(name = "完成时间")
|
||||
private String finishDate;
|
||||
|
||||
/** 备用1 */
|
||||
@Excel(name = "备用1")
|
||||
private String spare1;
|
||||
|
||||
/** 备用2 */
|
||||
@Excel(name = "备用2")
|
||||
private String spare2;
|
||||
|
||||
/** 备用3 */
|
||||
@Excel(name = "备用3")
|
||||
private String spare3;
|
||||
|
||||
/** 任务类型 */
|
||||
@Excel(name = "任务类型")
|
||||
private String rwlx;
|
||||
|
||||
public void setGuid(String guid)
|
||||
{
|
||||
this.guid = guid;
|
||||
}
|
||||
|
||||
public String getGuid()
|
||||
{
|
||||
return guid;
|
||||
}
|
||||
|
||||
public void setDeviceId(Long deviceId)
|
||||
{
|
||||
this.deviceId = deviceId;
|
||||
}
|
||||
|
||||
public Long getDeviceId()
|
||||
{
|
||||
return deviceId;
|
||||
}
|
||||
|
||||
public void setDeviceName(String deviceName)
|
||||
{
|
||||
this.deviceName = deviceName;
|
||||
}
|
||||
|
||||
public String getDeviceName()
|
||||
{
|
||||
return deviceName;
|
||||
}
|
||||
|
||||
public void setTaskNo(Long taskNo)
|
||||
{
|
||||
this.taskNo = taskNo;
|
||||
}
|
||||
|
||||
public Long getTaskNo()
|
||||
{
|
||||
return taskNo;
|
||||
}
|
||||
|
||||
public void setSrcRow(String srcRow)
|
||||
{
|
||||
this.srcRow = srcRow;
|
||||
}
|
||||
|
||||
public String getSrcRow()
|
||||
{
|
||||
return srcRow;
|
||||
}
|
||||
|
||||
public void setSrcColumn(String srcColumn)
|
||||
{
|
||||
this.srcColumn = srcColumn;
|
||||
}
|
||||
|
||||
public String getSrcColumn()
|
||||
{
|
||||
return srcColumn;
|
||||
}
|
||||
|
||||
public void setSrcLayer(String srcLayer)
|
||||
{
|
||||
this.srcLayer = srcLayer;
|
||||
}
|
||||
|
||||
public String getSrcLayer()
|
||||
{
|
||||
return srcLayer;
|
||||
}
|
||||
|
||||
public void setTarRow(String tarRow)
|
||||
{
|
||||
this.tarRow = tarRow;
|
||||
}
|
||||
|
||||
public String getTarRow()
|
||||
{
|
||||
return tarRow;
|
||||
}
|
||||
|
||||
public void setTarColumn(String tarColumn)
|
||||
{
|
||||
this.tarColumn = tarColumn;
|
||||
}
|
||||
|
||||
public String getTarColumn()
|
||||
{
|
||||
return tarColumn;
|
||||
}
|
||||
|
||||
public void setTarLayer(String tarLayer)
|
||||
{
|
||||
this.tarLayer = tarLayer;
|
||||
}
|
||||
|
||||
public String getTarLayer()
|
||||
{
|
||||
return tarLayer;
|
||||
}
|
||||
|
||||
public void setSrcSite(String srcSite)
|
||||
{
|
||||
this.srcSite = srcSite;
|
||||
}
|
||||
|
||||
public String getSrcSite()
|
||||
{
|
||||
return srcSite;
|
||||
}
|
||||
|
||||
public void setTarSite(String tarSite)
|
||||
{
|
||||
this.tarSite = tarSite;
|
||||
}
|
||||
|
||||
public String getTarSite()
|
||||
{
|
||||
return tarSite;
|
||||
}
|
||||
|
||||
public void setSendFlag(String sendFlag)
|
||||
{
|
||||
this.sendFlag = sendFlag;
|
||||
}
|
||||
|
||||
public String getSendFlag()
|
||||
{
|
||||
return sendFlag;
|
||||
}
|
||||
|
||||
public void setSendType(String sendType)
|
||||
{
|
||||
this.sendType = sendType;
|
||||
}
|
||||
|
||||
public String getSendType()
|
||||
{
|
||||
return sendType;
|
||||
}
|
||||
|
||||
public void setTaskType(String taskType)
|
||||
{
|
||||
this.taskType = taskType;
|
||||
}
|
||||
|
||||
public String getTaskType()
|
||||
{
|
||||
return taskType;
|
||||
}
|
||||
|
||||
public void setCreateDate(String createDate)
|
||||
{
|
||||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
public String getCreateDate()
|
||||
{
|
||||
return createDate;
|
||||
}
|
||||
|
||||
public void setStartDate(String startDate)
|
||||
{
|
||||
this.startDate = startDate;
|
||||
}
|
||||
|
||||
public String getStartDate()
|
||||
{
|
||||
return startDate;
|
||||
}
|
||||
|
||||
public void setFinishDate(String finishDate)
|
||||
{
|
||||
this.finishDate = finishDate;
|
||||
}
|
||||
|
||||
public String getFinishDate()
|
||||
{
|
||||
return finishDate;
|
||||
}
|
||||
|
||||
public void setSpare1(String spare1)
|
||||
{
|
||||
this.spare1 = spare1;
|
||||
}
|
||||
|
||||
public String getSpare1()
|
||||
{
|
||||
return spare1;
|
||||
}
|
||||
|
||||
public void setSpare2(String spare2)
|
||||
{
|
||||
this.spare2 = spare2;
|
||||
}
|
||||
|
||||
public String getSpare2()
|
||||
{
|
||||
return spare2;
|
||||
}
|
||||
|
||||
public void setSpare3(String spare3)
|
||||
{
|
||||
this.spare3 = spare3;
|
||||
}
|
||||
|
||||
public String getSpare3()
|
||||
{
|
||||
return spare3;
|
||||
}
|
||||
|
||||
public void setRwlx(String rwlx)
|
||||
{
|
||||
this.rwlx = rwlx;
|
||||
}
|
||||
|
||||
public String getRwlx()
|
||||
{
|
||||
return rwlx;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("guid", getGuid())
|
||||
.append("deviceId", getDeviceId())
|
||||
.append("deviceName", getDeviceName())
|
||||
.append("taskNo", getTaskNo())
|
||||
.append("srcRow", getSrcRow())
|
||||
.append("srcColumn", getSrcColumn())
|
||||
.append("srcLayer", getSrcLayer())
|
||||
.append("tarRow", getTarRow())
|
||||
.append("tarColumn", getTarColumn())
|
||||
.append("tarLayer", getTarLayer())
|
||||
.append("srcSite", getSrcSite())
|
||||
.append("tarSite", getTarSite())
|
||||
.append("sendFlag", getSendFlag())
|
||||
.append("sendType", getSendType())
|
||||
.append("taskType", getTaskType())
|
||||
.append("createDate", getCreateDate())
|
||||
.append("startDate", getStartDate())
|
||||
.append("finishDate", getFinishDate())
|
||||
.append("spare1", getSpare1())
|
||||
.append("spare2", getSpare2())
|
||||
.append("spare3", getSpare3())
|
||||
.append("rwlx", getRwlx())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,352 @@
|
||||
package com.ruoyi.queue.tsj.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;
|
||||
|
||||
/**
|
||||
* 提升机执行队列对象 tsj_device_execution_queue_finish
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
public class TsjDeviceExecutionQueueFinish extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** GUID */
|
||||
private String guid;
|
||||
|
||||
/** 设备编号 */
|
||||
@Excel(name = "设备编号")
|
||||
private Long deviceId;
|
||||
|
||||
/** 设备名称 */
|
||||
@Excel(name = "设备名称")
|
||||
private String deviceName;
|
||||
|
||||
/** 任务号 */
|
||||
@Excel(name = "任务号")
|
||||
private Long taskNo;
|
||||
|
||||
/** 原排 */
|
||||
@Excel(name = "原排")
|
||||
private String srcRow;
|
||||
|
||||
/** 原列 */
|
||||
@Excel(name = "原列")
|
||||
private String srcColumn;
|
||||
|
||||
/** 原层 */
|
||||
@Excel(name = "原层")
|
||||
private String srcLayer;
|
||||
|
||||
/** 目标排 */
|
||||
@Excel(name = "目标排")
|
||||
private String tarRow;
|
||||
|
||||
/** 目标列 */
|
||||
@Excel(name = "目标列")
|
||||
private String tarColumn;
|
||||
|
||||
/** 目标层 */
|
||||
@Excel(name = "目标层")
|
||||
private String tarLayer;
|
||||
|
||||
/** 原地址 */
|
||||
@Excel(name = "原地址")
|
||||
private String srcSite;
|
||||
|
||||
/** 目标地址 */
|
||||
@Excel(name = "目标地址")
|
||||
private String tarSite;
|
||||
|
||||
/** 下发 */
|
||||
@Excel(name = "下发")
|
||||
private String sendFlag;
|
||||
|
||||
/** 下发类型 */
|
||||
@Excel(name = "下发类型")
|
||||
private String sendType;
|
||||
|
||||
/** 任务类型 */
|
||||
@Excel(name = "任务类型")
|
||||
private String taskType;
|
||||
|
||||
/** 创建时间 */
|
||||
@Excel(name = "创建时间")
|
||||
private String createDate;
|
||||
|
||||
/** 开始时间 */
|
||||
@Excel(name = "开始时间")
|
||||
private String startDate;
|
||||
|
||||
/** 完成时间 */
|
||||
@Excel(name = "完成时间")
|
||||
private String finishDate;
|
||||
|
||||
/** 备用1 */
|
||||
@Excel(name = "备用1")
|
||||
private String spare1;
|
||||
|
||||
/** 备用2 */
|
||||
@Excel(name = "备用2")
|
||||
private String spare2;
|
||||
|
||||
/** 备用3 */
|
||||
@Excel(name = "备用3")
|
||||
private String spare3;
|
||||
|
||||
/** 1-空车任务 2-载车任务 */
|
||||
@Excel(name = "1-空车任务 2-载车任务")
|
||||
private String rwlx;
|
||||
|
||||
public void setGuid(String guid)
|
||||
{
|
||||
this.guid = guid;
|
||||
}
|
||||
|
||||
public String getGuid()
|
||||
{
|
||||
return guid;
|
||||
}
|
||||
|
||||
public void setDeviceId(Long deviceId)
|
||||
{
|
||||
this.deviceId = deviceId;
|
||||
}
|
||||
|
||||
public Long getDeviceId()
|
||||
{
|
||||
return deviceId;
|
||||
}
|
||||
|
||||
public void setDeviceName(String deviceName)
|
||||
{
|
||||
this.deviceName = deviceName;
|
||||
}
|
||||
|
||||
public String getDeviceName()
|
||||
{
|
||||
return deviceName;
|
||||
}
|
||||
|
||||
public void setTaskNo(Long taskNo)
|
||||
{
|
||||
this.taskNo = taskNo;
|
||||
}
|
||||
|
||||
public Long getTaskNo()
|
||||
{
|
||||
return taskNo;
|
||||
}
|
||||
|
||||
public void setSrcRow(String srcRow)
|
||||
{
|
||||
this.srcRow = srcRow;
|
||||
}
|
||||
|
||||
public String getSrcRow()
|
||||
{
|
||||
return srcRow;
|
||||
}
|
||||
|
||||
public void setSrcColumn(String srcColumn)
|
||||
{
|
||||
this.srcColumn = srcColumn;
|
||||
}
|
||||
|
||||
public String getSrcColumn()
|
||||
{
|
||||
return srcColumn;
|
||||
}
|
||||
|
||||
public void setSrcLayer(String srcLayer)
|
||||
{
|
||||
this.srcLayer = srcLayer;
|
||||
}
|
||||
|
||||
public String getSrcLayer()
|
||||
{
|
||||
return srcLayer;
|
||||
}
|
||||
|
||||
public void setTarRow(String tarRow)
|
||||
{
|
||||
this.tarRow = tarRow;
|
||||
}
|
||||
|
||||
public String getTarRow()
|
||||
{
|
||||
return tarRow;
|
||||
}
|
||||
|
||||
public void setTarColumn(String tarColumn)
|
||||
{
|
||||
this.tarColumn = tarColumn;
|
||||
}
|
||||
|
||||
public String getTarColumn()
|
||||
{
|
||||
return tarColumn;
|
||||
}
|
||||
|
||||
public void setTarLayer(String tarLayer)
|
||||
{
|
||||
this.tarLayer = tarLayer;
|
||||
}
|
||||
|
||||
public String getTarLayer()
|
||||
{
|
||||
return tarLayer;
|
||||
}
|
||||
|
||||
public void setSrcSite(String srcSite)
|
||||
{
|
||||
this.srcSite = srcSite;
|
||||
}
|
||||
|
||||
public String getSrcSite()
|
||||
{
|
||||
return srcSite;
|
||||
}
|
||||
|
||||
public void setTarSite(String tarSite)
|
||||
{
|
||||
this.tarSite = tarSite;
|
||||
}
|
||||
|
||||
public String getTarSite()
|
||||
{
|
||||
return tarSite;
|
||||
}
|
||||
|
||||
public void setSendFlag(String sendFlag)
|
||||
{
|
||||
this.sendFlag = sendFlag;
|
||||
}
|
||||
|
||||
public String getSendFlag()
|
||||
{
|
||||
return sendFlag;
|
||||
}
|
||||
|
||||
public void setSendType(String sendType)
|
||||
{
|
||||
this.sendType = sendType;
|
||||
}
|
||||
|
||||
public String getSendType()
|
||||
{
|
||||
return sendType;
|
||||
}
|
||||
|
||||
public void setTaskType(String taskType)
|
||||
{
|
||||
this.taskType = taskType;
|
||||
}
|
||||
|
||||
public String getTaskType()
|
||||
{
|
||||
return taskType;
|
||||
}
|
||||
|
||||
public void setCreateDate(String createDate)
|
||||
{
|
||||
this.createDate = createDate;
|
||||
}
|
||||
|
||||
public String getCreateDate()
|
||||
{
|
||||
return createDate;
|
||||
}
|
||||
|
||||
public void setStartDate(String startDate)
|
||||
{
|
||||
this.startDate = startDate;
|
||||
}
|
||||
|
||||
public String getStartDate()
|
||||
{
|
||||
return startDate;
|
||||
}
|
||||
|
||||
public void setFinishDate(String finishDate)
|
||||
{
|
||||
this.finishDate = finishDate;
|
||||
}
|
||||
|
||||
public String getFinishDate()
|
||||
{
|
||||
return finishDate;
|
||||
}
|
||||
|
||||
public void setSpare1(String spare1)
|
||||
{
|
||||
this.spare1 = spare1;
|
||||
}
|
||||
|
||||
public String getSpare1()
|
||||
{
|
||||
return spare1;
|
||||
}
|
||||
|
||||
public void setSpare2(String spare2)
|
||||
{
|
||||
this.spare2 = spare2;
|
||||
}
|
||||
|
||||
public String getSpare2()
|
||||
{
|
||||
return spare2;
|
||||
}
|
||||
|
||||
public void setSpare3(String spare3)
|
||||
{
|
||||
this.spare3 = spare3;
|
||||
}
|
||||
|
||||
public String getSpare3()
|
||||
{
|
||||
return spare3;
|
||||
}
|
||||
|
||||
public void setRwlx(String rwlx)
|
||||
{
|
||||
this.rwlx = rwlx;
|
||||
}
|
||||
|
||||
public String getRwlx()
|
||||
{
|
||||
return rwlx;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("guid", getGuid())
|
||||
.append("deviceId", getDeviceId())
|
||||
.append("deviceName", getDeviceName())
|
||||
.append("taskNo", getTaskNo())
|
||||
.append("srcRow", getSrcRow())
|
||||
.append("srcColumn", getSrcColumn())
|
||||
.append("srcLayer", getSrcLayer())
|
||||
.append("tarRow", getTarRow())
|
||||
.append("tarColumn", getTarColumn())
|
||||
.append("tarLayer", getTarLayer())
|
||||
.append("srcSite", getSrcSite())
|
||||
.append("tarSite", getTarSite())
|
||||
.append("sendFlag", getSendFlag())
|
||||
.append("sendType", getSendType())
|
||||
.append("taskType", getTaskType())
|
||||
.append("createDate", getCreateDate())
|
||||
.append("startDate", getStartDate())
|
||||
.append("finishDate", getFinishDate())
|
||||
.append("spare1", getSpare1())
|
||||
.append("spare2", getSpare2())
|
||||
.append("spare3", getSpare3())
|
||||
.append("rwlx", getRwlx())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
package com.ruoyi.queue.tsj.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueueFinish;
|
||||
|
||||
/**
|
||||
* 提升机执行队列Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
public interface TsjDeviceExecutionQueueFinishMapper
|
||||
{
|
||||
/**
|
||||
* 查询提升机执行队列
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
public TsjDeviceExecutionQueueFinish selectTsjDeviceExecutionQueueFinishByGuid(String guid);
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列列表
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 提升机执行队列集合
|
||||
*/
|
||||
public List<TsjDeviceExecutionQueueFinish> selectTsjDeviceExecutionQueueFinishList(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish);
|
||||
|
||||
/**
|
||||
* 新增提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertTsjDeviceExecutionQueueFinish(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish);
|
||||
|
||||
/**
|
||||
* 修改提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateTsjDeviceExecutionQueueFinish(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish);
|
||||
|
||||
/**
|
||||
* 删除提升机执行队列
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteTsjDeviceExecutionQueueFinishByGuid(String guid);
|
||||
|
||||
/**
|
||||
* 批量删除提升机执行队列
|
||||
*
|
||||
* @param guids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteTsjDeviceExecutionQueueFinishByGuids(String[] guids);
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
package com.ruoyi.queue.tsj.mapper;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueue;
|
||||
|
||||
/**
|
||||
* 提升机执行队列Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
public interface TsjDeviceExecutionQueueMapper
|
||||
{
|
||||
/**
|
||||
* 查询提升机执行队列
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
public TsjDeviceExecutionQueue selectTsjDeviceExecutionQueueByGuid(String guid);
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列列表
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 提升机执行队列集合
|
||||
*/
|
||||
public List<TsjDeviceExecutionQueue> selectTsjDeviceExecutionQueueList(TsjDeviceExecutionQueue tsjDeviceExecutionQueue);
|
||||
|
||||
/**
|
||||
* 新增提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertTsjDeviceExecutionQueue(TsjDeviceExecutionQueue tsjDeviceExecutionQueue);
|
||||
|
||||
/**
|
||||
* 修改提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateTsjDeviceExecutionQueue(TsjDeviceExecutionQueue tsjDeviceExecutionQueue);
|
||||
|
||||
/**
|
||||
* 删除提升机执行队列
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteTsjDeviceExecutionQueueByGuid(String guid);
|
||||
|
||||
/**
|
||||
* 批量删除提升机执行队列
|
||||
*
|
||||
* @param guids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteTsjDeviceExecutionQueueByGuids(String[] guids);
|
||||
/**
|
||||
* 根据任务号查询提升机执行队列
|
||||
*
|
||||
* @param taskNo 任务号
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
TsjDeviceExecutionQueue selectTsjDeviceExecutionQueueByRwh(Long taskNo);
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
package com.ruoyi.queue.tsj.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueueFinish;
|
||||
|
||||
/**
|
||||
* 提升机执行队列Service接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
public interface ITsjDeviceExecutionQueueFinishService
|
||||
{
|
||||
/**
|
||||
* 查询提升机执行队列
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
public TsjDeviceExecutionQueueFinish selectTsjDeviceExecutionQueueFinishByGuid(String guid);
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列列表
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 提升机执行队列集合
|
||||
*/
|
||||
public List<TsjDeviceExecutionQueueFinish> selectTsjDeviceExecutionQueueFinishList(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish);
|
||||
|
||||
/**
|
||||
* 新增提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertTsjDeviceExecutionQueueFinish(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish);
|
||||
|
||||
/**
|
||||
* 修改提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateTsjDeviceExecutionQueueFinish(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish);
|
||||
|
||||
/**
|
||||
* 批量删除提升机执行队列
|
||||
*
|
||||
* @param guids 需要删除的提升机执行队列主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteTsjDeviceExecutionQueueFinishByGuids(String[] guids);
|
||||
|
||||
/**
|
||||
* 删除提升机执行队列信息
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteTsjDeviceExecutionQueueFinishByGuid(String guid);
|
||||
}
|
||||
@@ -0,0 +1,67 @@
|
||||
package com.ruoyi.queue.tsj.service;
|
||||
|
||||
import java.util.List;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueue;
|
||||
|
||||
/**
|
||||
* 提升机执行队列Service接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
public interface ITsjDeviceExecutionQueueService
|
||||
{
|
||||
/**
|
||||
* 查询提升机执行队列
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
public TsjDeviceExecutionQueue selectTsjDeviceExecutionQueueByGuid(String guid);
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列列表
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 提升机执行队列集合
|
||||
*/
|
||||
public List<TsjDeviceExecutionQueue> selectTsjDeviceExecutionQueueList(TsjDeviceExecutionQueue tsjDeviceExecutionQueue);
|
||||
|
||||
/**
|
||||
* 新增提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertTsjDeviceExecutionQueue(TsjDeviceExecutionQueue tsjDeviceExecutionQueue);
|
||||
|
||||
/**
|
||||
* 修改提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateTsjDeviceExecutionQueue(TsjDeviceExecutionQueue tsjDeviceExecutionQueue);
|
||||
|
||||
/**
|
||||
* 批量删除提升机执行队列
|
||||
*
|
||||
* @param guids 需要删除的提升机执行队列主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteTsjDeviceExecutionQueueByGuids(String[] guids);
|
||||
|
||||
/**
|
||||
* 删除提升机执行队列信息
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteTsjDeviceExecutionQueueByGuid(String guid);
|
||||
/**
|
||||
* 根据任务号查询提升机执行队列
|
||||
* @param taskNo
|
||||
* @return
|
||||
*/
|
||||
TsjDeviceExecutionQueue selectTsjDeviceExecutionQueueByRwh(Long taskNo);
|
||||
}
|
||||
@@ -0,0 +1,93 @@
|
||||
package com.ruoyi.queue.tsj.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.queue.tsj.mapper.TsjDeviceExecutionQueueFinishMapper;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueueFinish;
|
||||
import com.ruoyi.queue.tsj.service.ITsjDeviceExecutionQueueFinishService;
|
||||
|
||||
/**
|
||||
* 提升机执行队列Service业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
@Service
|
||||
public class TsjDeviceExecutionQueueFinishServiceImpl implements ITsjDeviceExecutionQueueFinishService
|
||||
{
|
||||
@Autowired
|
||||
private TsjDeviceExecutionQueueFinishMapper tsjDeviceExecutionQueueFinishMapper;
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
@Override
|
||||
public TsjDeviceExecutionQueueFinish selectTsjDeviceExecutionQueueFinishByGuid(String guid)
|
||||
{
|
||||
return tsjDeviceExecutionQueueFinishMapper.selectTsjDeviceExecutionQueueFinishByGuid(guid);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列列表
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
@Override
|
||||
public List<TsjDeviceExecutionQueueFinish> selectTsjDeviceExecutionQueueFinishList(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish)
|
||||
{
|
||||
return tsjDeviceExecutionQueueFinishMapper.selectTsjDeviceExecutionQueueFinishList(tsjDeviceExecutionQueueFinish);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertTsjDeviceExecutionQueueFinish(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish)
|
||||
{
|
||||
return tsjDeviceExecutionQueueFinishMapper.insertTsjDeviceExecutionQueueFinish(tsjDeviceExecutionQueueFinish);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueueFinish 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateTsjDeviceExecutionQueueFinish(TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish)
|
||||
{
|
||||
return tsjDeviceExecutionQueueFinishMapper.updateTsjDeviceExecutionQueueFinish(tsjDeviceExecutionQueueFinish);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除提升机执行队列
|
||||
*
|
||||
* @param guids 需要删除的提升机执行队列主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteTsjDeviceExecutionQueueFinishByGuids(String[] guids)
|
||||
{
|
||||
return tsjDeviceExecutionQueueFinishMapper.deleteTsjDeviceExecutionQueueFinishByGuids(guids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除提升机执行队列信息
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteTsjDeviceExecutionQueueFinishByGuid(String guid)
|
||||
{
|
||||
return tsjDeviceExecutionQueueFinishMapper.deleteTsjDeviceExecutionQueueFinishByGuid(guid);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,108 @@
|
||||
package com.ruoyi.queue.tsj.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.queue.tsj.mapper.TsjDeviceExecutionQueueMapper;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueue;
|
||||
import com.ruoyi.queue.tsj.service.ITsjDeviceExecutionQueueService;
|
||||
|
||||
/**
|
||||
* 提升机执行队列Service业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2025-11-19
|
||||
*/
|
||||
@Service
|
||||
public class TsjDeviceExecutionQueueServiceImpl implements ITsjDeviceExecutionQueueService
|
||||
{
|
||||
@Autowired
|
||||
private TsjDeviceExecutionQueueMapper tsjDeviceExecutionQueueMapper;
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
@Override
|
||||
public TsjDeviceExecutionQueue selectTsjDeviceExecutionQueueByGuid(String guid)
|
||||
{
|
||||
return tsjDeviceExecutionQueueMapper.selectTsjDeviceExecutionQueueByGuid(guid);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询提升机执行队列列表
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
@Override
|
||||
public List<TsjDeviceExecutionQueue> selectTsjDeviceExecutionQueueList(TsjDeviceExecutionQueue tsjDeviceExecutionQueue)
|
||||
{
|
||||
return tsjDeviceExecutionQueueMapper.selectTsjDeviceExecutionQueueList(tsjDeviceExecutionQueue);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertTsjDeviceExecutionQueue(TsjDeviceExecutionQueue tsjDeviceExecutionQueue)
|
||||
{
|
||||
return tsjDeviceExecutionQueueMapper.insertTsjDeviceExecutionQueue(tsjDeviceExecutionQueue);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改提升机执行队列
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue 提升机执行队列
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateTsjDeviceExecutionQueue(TsjDeviceExecutionQueue tsjDeviceExecutionQueue)
|
||||
{
|
||||
return tsjDeviceExecutionQueueMapper.updateTsjDeviceExecutionQueue(tsjDeviceExecutionQueue);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除提升机执行队列
|
||||
*
|
||||
* @param guids 需要删除的提升机执行队列主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteTsjDeviceExecutionQueueByGuids(String[] guids)
|
||||
{
|
||||
return tsjDeviceExecutionQueueMapper.deleteTsjDeviceExecutionQueueByGuids(guids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除提升机执行队列信息
|
||||
*
|
||||
* @param guid 提升机执行队列主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteTsjDeviceExecutionQueueByGuid(String guid)
|
||||
{
|
||||
return tsjDeviceExecutionQueueMapper.deleteTsjDeviceExecutionQueueByGuid(guid);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据任务号查询提升机执行队列
|
||||
*
|
||||
* @param taskNo 任务号
|
||||
* @return 提升机执行队列
|
||||
*/
|
||||
@Override
|
||||
public TsjDeviceExecutionQueue selectTsjDeviceExecutionQueueByRwh(Long taskNo) {
|
||||
return tsjDeviceExecutionQueueMapper.selectTsjDeviceExecutionQueueByRwh(taskNo);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -1,13 +1,17 @@
|
||||
package com.ruoyi.schedule.plcRead.tsj;
|
||||
|
||||
import HslCommunication.BasicFramework.SoftBasic;
|
||||
import HslCommunication.Core.Net.IReadWriteNet;
|
||||
import HslCommunication.Core.Types.OperateResult;
|
||||
import HslCommunication.Core.Types.OperateResultExOne;
|
||||
import HslCommunication.Profinet.Siemens.SiemensPLCS;
|
||||
import HslCommunication.Profinet.Siemens.SiemensS7Net;
|
||||
import cn.hutool.core.convert.Convert;
|
||||
import com.ruoyi.common.domain.HslRead;
|
||||
import com.ruoyi.common.domain.PlcConnectInfo;
|
||||
import com.ruoyi.common.domain.SendData;
|
||||
import com.ruoyi.device.tsj.domain.DeviceTsj;
|
||||
import com.ruoyi.schedule.plcRead.util.ParseUtil;
|
||||
import com.ruoyi.schedule.plcRead.util.Tools;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
@@ -31,7 +35,7 @@ public class PlcTsjRead implements Runnable {
|
||||
this.port = plcConnectInfo.getPort();
|
||||
}
|
||||
|
||||
public static int WriteToSSJ(String address, byte[] data) {
|
||||
public static int WriteToTSJ(String address, byte[] data) {
|
||||
int a = 0;
|
||||
if (readWriteNet != null) {
|
||||
a = HslRead.WriteResultRender(readWriteNet.Write(address, data), address);
|
||||
@@ -44,11 +48,9 @@ public class PlcTsjRead implements Runnable {
|
||||
while (isRun) {
|
||||
try {
|
||||
if (IsConnect()) {
|
||||
int step = 20;
|
||||
int baseOffset = 0;
|
||||
for (String tsjCode : deviceTsjMap.keySet()) {
|
||||
DeviceTsj tsjDevice = deviceTsjMap.get(tsjCode);
|
||||
|
||||
plcRead(tsjDevice);
|
||||
}
|
||||
Thread.sleep(1000);
|
||||
} else {
|
||||
@@ -65,6 +67,25 @@ public class PlcTsjRead implements Runnable {
|
||||
}
|
||||
}
|
||||
|
||||
private void plcRead(DeviceTsj tsjDevice) {
|
||||
OperateResultExOne<byte[]> read2 = readWriteNet.Read(tsjDevice.getPlcDbReadAddress(), Short.parseShort("220"));
|
||||
String ddsx1 = "0";
|
||||
if (read2.IsSuccess) {
|
||||
ddsx1 = SoftBasic.ByteToHexString(read2.Content);
|
||||
tsjDevice.setCzfs(ParseUtil.optInt(2, ddsx1));
|
||||
tsjDevice.setSbzt(ParseUtil.optInt(4, ddsx1));
|
||||
tsjDevice.setRwh(Convert.toLong(ParseUtil.optDInt(6, ddsx1)));
|
||||
tsjDevice.setDqcs(ParseUtil.optInt(10, ddsx1));
|
||||
tsjDevice.setJdbz(ParseUtil.optInt(12, ddsx1));
|
||||
tsjDevice.setYph(ParseUtil.optInt(14, ddsx1));
|
||||
tsjDevice.setYch(ParseUtil.optInt(16, ddsx1));
|
||||
tsjDevice.setMbph(ParseUtil.optInt(18, ddsx1));
|
||||
tsjDevice.setMbch(ParseUtil.optInt(20, ddsx1));
|
||||
tsjDevice.setYxxf(ParseUtil.optInt(22, ddsx1));
|
||||
tsjDevice.setXtxh(ParseUtil.optInt(24, ddsx1));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void ConnectServer() {
|
||||
siemensS7Net = new SiemensS7Net(SiemensPLCS.S1500);
|
||||
|
||||
@@ -0,0 +1,290 @@
|
||||
package com.ruoyi.schedule.scheduleTask.tsj;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.convert.Convert;
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import cn.hutool.core.util.IdUtil;
|
||||
import cn.hutool.core.util.ObjUtil;
|
||||
import com.ruoyi.bas.cargospace.domain.BasCargoSpace;
|
||||
import com.ruoyi.bas.cargospace.service.IBasCargoSpaceService;
|
||||
import com.ruoyi.bas.port.domain.WcsPort;
|
||||
import com.ruoyi.bas.port.service.IWcsPortService;
|
||||
import com.ruoyi.common.domain.SendData;
|
||||
import com.ruoyi.device.tsj.domain.DeviceTsj;
|
||||
import com.ruoyi.device.tsj.service.IDeviceTsjService;
|
||||
import com.ruoyi.job.domain.MydoJob;
|
||||
import com.ruoyi.job.service.IMydoJobService;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueue;
|
||||
import com.ruoyi.queue.tsj.domain.TsjDeviceExecutionQueueFinish;
|
||||
import com.ruoyi.queue.tsj.service.ITsjDeviceExecutionQueueFinishService;
|
||||
import com.ruoyi.queue.tsj.service.ITsjDeviceExecutionQueueService;
|
||||
import com.ruoyi.schedule.plcRead.tsj.PlcTsjRead;
|
||||
import com.ruoyi.schedule.plcRead.util.Tools;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
@Slf4j
|
||||
public class TsjThread implements Runnable {
|
||||
public boolean isRun = true;
|
||||
|
||||
private ITsjDeviceExecutionQueueService tsjDeviceExecutionQueueService;
|
||||
private ITsjDeviceExecutionQueueFinishService tsjDeviceExecutionQueueFinishService;
|
||||
private IDeviceTsjService deviceTsjService;
|
||||
|
||||
private IMydoJobService mydoJobService;
|
||||
|
||||
private IWcsPortService wcsPortService;
|
||||
private IBasCargoSpaceService basCargoSpaceService;
|
||||
|
||||
|
||||
public void init() {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
init();
|
||||
while (isRun) {
|
||||
for (String tsjCode : PlcTsjRead.deviceTsjMap.keySet()) {
|
||||
DeviceTsj tsj = PlcTsjRead.deviceTsjMap.get(tsjCode);
|
||||
|
||||
tsjTask(tsj);
|
||||
}
|
||||
|
||||
try {
|
||||
Thread.sleep(1500);
|
||||
} catch (InterruptedException e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
private void tsjTask(DeviceTsj tsj) {
|
||||
int sbzt = tsj.getSbzt();//设备状态
|
||||
int czfs = tsj.getCzfs();//操作方式 //0:未知,1:手动 2:自动
|
||||
int jdbz = tsj.getJdbz();//执行阶段
|
||||
Long rwh = tsj.getRwh();//任务号
|
||||
int yxxf = tsj.getYxxf();//允许下发
|
||||
|
||||
|
||||
|
||||
/*
|
||||
* 1、下发完成 如果设备状态为 2-工作 ,触发方式 2-自动,任务号大于999,则代表任务下发完成
|
||||
*
|
||||
* */
|
||||
if (czfs == 2 && sbzt == 2 && rwh > 999) {
|
||||
finishSend(rwh);
|
||||
}
|
||||
|
||||
/*
|
||||
* 2、任务完成
|
||||
*
|
||||
* */
|
||||
if (czfs == 2 && sbzt == 2 && jdbz == 5 && rwh > 999) {
|
||||
//任务完成
|
||||
finishTask(rwh);
|
||||
}
|
||||
|
||||
/*
|
||||
* 3、下发
|
||||
*
|
||||
* */
|
||||
if (czfs == 2 && yxxf == 1) {
|
||||
sendTsj();
|
||||
}
|
||||
|
||||
createLoadQueue(tsj);
|
||||
|
||||
createUnLoadQueue(tsj);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建装车队列
|
||||
*/
|
||||
private void createUnLoadQueue(DeviceTsj tsj) {
|
||||
//根据提升机入口点位循环如果提升机在某个占用的入口点位楼层,则锁定提升机否则生成提升机队列
|
||||
List<TsjDeviceExecutionQueue> tsjDeviceExecutionQueues = tsjDeviceExecutionQueueService.selectTsjDeviceExecutionQueueList(new TsjDeviceExecutionQueue());
|
||||
if (CollUtil.isNotEmpty(tsjDeviceExecutionQueues)) {
|
||||
// 提升机存在任务
|
||||
return;
|
||||
}
|
||||
WcsPort param = new WcsPort();
|
||||
param.setPortType("1");
|
||||
param.setStatus("1");
|
||||
param.setSpare2("0");
|
||||
List<WcsPort> wcsPorts = wcsPortService.selectWcsPortList(param);
|
||||
DeviceTsj deviceTsj = deviceTsjService.selectDeviceTsjById(tsj.getId());
|
||||
if (CollUtil.isNotEmpty(wcsPorts) && deviceTsj.getSpare1() == 0) {
|
||||
//todo 按时间顺序 或者是按提升机最近顺序
|
||||
Optional<WcsPort> existCurrentPort = wcsPorts.stream().filter(x -> x.getPortRegion().equals(Convert.toStr(deviceTsj.getDqcs()))).findFirst();
|
||||
if (existCurrentPort.isPresent()) {
|
||||
//修改承载锁定
|
||||
deviceTsj.setSpare1(1);
|
||||
deviceTsjService.updateDeviceTsj(deviceTsj);
|
||||
log.info("提升机任务锁定提升机承载 任务类型:{}", "提升机任务");
|
||||
} else {
|
||||
WcsPort wcsPort = wcsPorts.get(0);
|
||||
TsjDeviceExecutionQueue tsjDeviceExecutionQueue = new TsjDeviceExecutionQueue();
|
||||
tsjDeviceExecutionQueue.setGuid(IdUtil.simpleUUID());
|
||||
tsjDeviceExecutionQueue.setDeviceId(tsj.getId());
|
||||
tsjDeviceExecutionQueue.setDeviceName(tsj.getName());
|
||||
tsjDeviceExecutionQueue.setTaskNo(Convert.toLong(wcsPort.getSpare1()));
|
||||
tsjDeviceExecutionQueue.setSrcRow("0");
|
||||
tsjDeviceExecutionQueue.setSrcLayer("0");
|
||||
tsjDeviceExecutionQueue.setTarRow(wcsPort.getPortType());
|
||||
tsjDeviceExecutionQueue.setTarLayer(wcsPort.getPortRegion());
|
||||
tsjDeviceExecutionQueue.setSendFlag("0");
|
||||
tsjDeviceExecutionQueue.setSendType("1");
|
||||
tsjDeviceExecutionQueue.setRwlx("1");
|
||||
tsjDeviceExecutionQueue.setCreateDate(DateUtil.formatDateTime(new Date()));
|
||||
tsjDeviceExecutionQueueService.insertTsjDeviceExecutionQueue(tsjDeviceExecutionQueue);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 创建卸车队列
|
||||
*/
|
||||
private void createLoadQueue(DeviceTsj tsj) {
|
||||
//todo 根据当前楼层和执行阶段查询任务 获取目标队列 生成提升机队列 当小车出去后 解锁提升机
|
||||
List<TsjDeviceExecutionQueue> tsjDeviceExecutionQueues = tsjDeviceExecutionQueueService.selectTsjDeviceExecutionQueueList(new TsjDeviceExecutionQueue());
|
||||
if (CollUtil.isNotEmpty(tsjDeviceExecutionQueues)) {
|
||||
// 提升机存在任务
|
||||
return;
|
||||
}
|
||||
|
||||
DeviceTsj deviceTsj = deviceTsjService.selectDeviceTsjById(1L);
|
||||
//判断提升机锁定 并且 小车已进入提升机
|
||||
if (deviceTsj.getSpare1() == 1 && tsj.getSbzt() == 3 && tsj.getYxxf() == 1) {
|
||||
|
||||
//查询进入提升机的任务
|
||||
MydoJob param = new MydoJob();
|
||||
param.setRoadwayId("1");
|
||||
List<MydoJob> mydoJobs = mydoJobService.selectMydoJobList(param);
|
||||
|
||||
if (CollUtil.isNotEmpty(mydoJobs)){
|
||||
MydoJob mydoJob = mydoJobs.get(0);
|
||||
BasCargoSpace basCargoSpace = basCargoSpaceService.selectBasCargoSpaceByWmsCargoSpaceId(mydoJob.getCargoSpaceId());
|
||||
//生成提升机队列
|
||||
TsjDeviceExecutionQueue tsjDeviceExecutionQueue = new TsjDeviceExecutionQueue();
|
||||
tsjDeviceExecutionQueue.setGuid(IdUtil.simpleUUID());
|
||||
tsjDeviceExecutionQueue.setDeviceId(tsj.getId());
|
||||
tsjDeviceExecutionQueue.setDeviceName(tsj.getName());
|
||||
tsjDeviceExecutionQueue.setTaskNo(Convert.toLong(mydoJob.getTaskNo()));
|
||||
tsjDeviceExecutionQueue.setSrcRow("0");
|
||||
tsjDeviceExecutionQueue.setSrcLayer("0");
|
||||
tsjDeviceExecutionQueue.setTarRow(Convert.toStr(basCargoSpace.getThePlatoon()));
|
||||
tsjDeviceExecutionQueue.setTarLayer(Convert.toStr(basCargoSpace.getTheFloor()));
|
||||
tsjDeviceExecutionQueue.setSendFlag("0");
|
||||
tsjDeviceExecutionQueue.setSendType("1");
|
||||
tsjDeviceExecutionQueue.setRwlx("1");
|
||||
tsjDeviceExecutionQueue.setCreateDate(DateUtil.formatDateTime(new Date()));
|
||||
tsjDeviceExecutionQueueService.insertTsjDeviceExecutionQueue(tsjDeviceExecutionQueue);
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void sendTsj() {
|
||||
List<TsjDeviceExecutionQueue> tsjDeviceExecutionQueues = tsjDeviceExecutionQueueService.selectTsjDeviceExecutionQueueList(new TsjDeviceExecutionQueue());
|
||||
if (CollUtil.isNotEmpty(tsjDeviceExecutionQueues)) {
|
||||
TsjDeviceExecutionQueue tsjDeviceExecutionQueue = tsjDeviceExecutionQueues.get(0);
|
||||
|
||||
if ("1".equals(tsjDeviceExecutionQueue.getRwlx())) {
|
||||
//提升机移动到小车楼层 需要判断目标楼层入库点位小车是否到位
|
||||
WcsPort param = new WcsPort();
|
||||
param.setPortType("1");
|
||||
param.setPortRegion(tsjDeviceExecutionQueue.getTarLayer());
|
||||
param.setStatus("1");
|
||||
param.setSpare2("1");
|
||||
List<WcsPort> wcsPorts = wcsPortService.selectWcsPortList(param);
|
||||
if (CollUtil.isEmpty(wcsPorts)) {
|
||||
log.info("提升机任务[{}]下发 目标楼层[{}]入库点位空闲 无法下发提升机任务", tsjDeviceExecutionQueue.getTaskNo(), tsjDeviceExecutionQueue.getTarLayer());
|
||||
return;
|
||||
}
|
||||
} else if ("2".equals(tsjDeviceExecutionQueue.getRwlx())) {
|
||||
//提升机承载小车到目标楼层 需要判断目标楼层出库点位是否空闲
|
||||
WcsPort param = new WcsPort();
|
||||
param.setPortType("1");
|
||||
param.setPortRegion(tsjDeviceExecutionQueue.getTarLayer());
|
||||
param.setStatus("0");
|
||||
param.setSpare2("1");
|
||||
List<WcsPort> wcsPorts = wcsPortService.selectWcsPortList(param);
|
||||
if (CollUtil.isEmpty(wcsPorts)) {
|
||||
log.info("提升机任务[{}]下发 目标楼层[{}]出库点位占用 无法下发提升机任务", tsjDeviceExecutionQueue.getTaskNo(), tsjDeviceExecutionQueue.getTarLayer());
|
||||
return;
|
||||
}
|
||||
}
|
||||
writeToTsj(tsjDeviceExecutionQueues.get(0));
|
||||
log.info("提升机任务下发 taskNo{} 任务类型:{}", tsjDeviceExecutionQueue.getTaskNo(), tsjDeviceExecutionQueue.getRwlx());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 写入提升机任务
|
||||
*
|
||||
* @param tsjDeviceExecutionQueue
|
||||
*/
|
||||
private void writeToTsj(TsjDeviceExecutionQueue tsjDeviceExecutionQueue) {
|
||||
SendData taskNoSendData = new SendData(Tools.INT, Convert.toInt(tsjDeviceExecutionQueue.getTaskNo()));
|
||||
SendData srcRow = new SendData(Tools.INT, Convert.toInt(tsjDeviceExecutionQueue.getSrcRow()));
|
||||
SendData srcLayer = new SendData(Tools.INT, Convert.toInt(tsjDeviceExecutionQueue.getSrcLayer()));
|
||||
SendData tarRow = new SendData(Tools.INT, Convert.toInt(tsjDeviceExecutionQueue.getTarRow()));
|
||||
SendData tarLayer = new SendData(Tools.INT, Convert.toInt(tsjDeviceExecutionQueue.getTarLayer()));
|
||||
SendData sendType = new SendData(Tools.INT, Convert.toInt(tsjDeviceExecutionQueue.getSendType()));
|
||||
SendData completedSendData = new SendData(Tools.INT, 1);
|
||||
int jym = Tools.getJYM(taskNoSendData.getNum2(), srcRow.getNum2(), srcLayer.getNum2(), tarRow.getNum2(), tarLayer.getNum2(), sendType.getNum2(), completedSendData.getNum2());
|
||||
SendData jymSendData = new SendData(Tools.INT, jym);
|
||||
byte[] bytes = Tools.sendData(taskNoSendData, srcRow, srcLayer, tarRow, tarLayer, sendType, completedSendData, jymSendData);
|
||||
DeviceTsj deviceTsj = PlcTsjRead.deviceTsjMap.get(Convert.toStr(tsjDeviceExecutionQueue.getDeviceId()));
|
||||
if (ObjUtil.isNotNull(deviceTsj)) {
|
||||
PlcTsjRead.WriteToTSJ(deviceTsj.getPlcDbWriteAddress(), bytes);
|
||||
}
|
||||
}
|
||||
|
||||
private void finishTask(Long taskNo) {
|
||||
|
||||
//根据任务号查询队列 修改执行状态
|
||||
TsjDeviceExecutionQueue tsjDeviceExecutionQueue = tsjDeviceExecutionQueueService.selectTsjDeviceExecutionQueueByRwh(taskNo);
|
||||
if (ObjUtil.isNotNull(tsjDeviceExecutionQueue)) {
|
||||
//完成提升机任务 插入历史表
|
||||
TsjDeviceExecutionQueueFinish tsjDeviceExecutionQueueFinish = new TsjDeviceExecutionQueueFinish();
|
||||
BeanUtil.copyProperties(tsjDeviceExecutionQueue, tsjDeviceExecutionQueueFinish);
|
||||
tsjDeviceExecutionQueueFinish.setFinishDate(DateUtil.formatDateTime(DateUtil.date()));
|
||||
tsjDeviceExecutionQueueFinishService.insertTsjDeviceExecutionQueueFinish(tsjDeviceExecutionQueueFinish);
|
||||
tsjDeviceExecutionQueueService.deleteTsjDeviceExecutionQueueByGuid(tsjDeviceExecutionQueue.getGuid());
|
||||
log.info("提升机任务下发完成 taskNo{} 任务类型:{}", taskNo, "提升机任务");
|
||||
if ("1".equals(tsjDeviceExecutionQueue.getRwlx())) {
|
||||
//锁定提升机承载
|
||||
DeviceTsj deviceTsj = deviceTsjService.selectDeviceTsjById(tsjDeviceExecutionQueue.getDeviceId());
|
||||
deviceTsj.setSpare1(1);
|
||||
deviceTsjService.updateDeviceTsj(deviceTsj);
|
||||
log.info("提升机任务锁定提升机承载 taskNo{} 任务类型:{}", taskNo, "提升机任务");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 提升机下发任务完成
|
||||
*
|
||||
* @param taskNo
|
||||
*/
|
||||
private void finishSend(Long taskNo) {
|
||||
//根据任务号查询是否存在入库或者出库的正执行任务
|
||||
TsjDeviceExecutionQueue tsjDeviceExecutionQueue = tsjDeviceExecutionQueueService.selectTsjDeviceExecutionQueueByRwh(taskNo);
|
||||
if (ObjUtil.isNotNull(tsjDeviceExecutionQueue)) {
|
||||
tsjDeviceExecutionQueue.setSendFlag("1");
|
||||
tsjDeviceExecutionQueue.setStartDate(DateUtil.formatDateTime(DateUtil.date()));
|
||||
tsjDeviceExecutionQueueService.updateTsjDeviceExecutionQueue(tsjDeviceExecutionQueue);
|
||||
log.info("提升机任务完成 taskNo:{} 任务类型:{}", taskNo, "提升机任务");
|
||||
}
|
||||
}
|
||||
}
|
||||
163
ruoyi-admin/src/main/resources/mapper/device/DeviceTsjMapper.xml
Normal file
163
ruoyi-admin/src/main/resources/mapper/device/DeviceTsjMapper.xml
Normal file
@@ -0,0 +1,163 @@
|
||||
<?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.device.tsj.mapper.DeviceTsjMapper">
|
||||
|
||||
<resultMap type="DeviceTsj" id="DeviceTsjResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="name" column="name" />
|
||||
<result property="ip" column="ip" />
|
||||
<result property="port" column="port" />
|
||||
<result property="plcDbReadAddress" column="plc_db_read_address" />
|
||||
<result property="plcDbWriteAddress" column="plc_db_write_address" />
|
||||
<result property="rwh" column="rwh" />
|
||||
<result property="jdbz" column="jdbz" />
|
||||
<result property="sbzt" column="sbzt" />
|
||||
<result property="czfs" column="czfs" />
|
||||
<result property="yxxf" column="yxxf" />
|
||||
<result property="yph" column="yph" />
|
||||
<result property="ylh" column="ylh" />
|
||||
<result property="ych" column="ych" />
|
||||
<result property="mbph" column="mbph" />
|
||||
<result property="mblh" column="mblh" />
|
||||
<result property="mbch" column="mbch" />
|
||||
<result property="xtxh" column="xtxh" />
|
||||
<result property="dqcs" column="dqcs" />
|
||||
<result property="hczt" column="hczt" />
|
||||
<result property="spare1" column="spare1" />
|
||||
<result property="spare2" column="spare2" />
|
||||
<result property="spare3" column="spare3" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectDeviceTsjVo">
|
||||
select id, name, ip, port, plc_db_read_address, plc_db_write_address, rwh, jdbz, sbzt, czfs, yxxf, yph, ylh, ych, mbph, mblh, mbch, xtxh, dqcs, hczt, spare1, spare2, spare3 from device_tsj
|
||||
</sql>
|
||||
|
||||
<select id="selectDeviceTsjList" parameterType="DeviceTsj" resultMap="DeviceTsjResult">
|
||||
<include refid="selectDeviceTsjVo"/>
|
||||
<where>
|
||||
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||
<if test="ip != null and ip != ''"> and ip = #{ip}</if>
|
||||
<if test="port != null and port != ''"> and port = #{port}</if>
|
||||
<if test="plcDbReadAddress != null and plcDbReadAddress != ''"> and plc_db_read_address = #{plcDbReadAddress}</if>
|
||||
<if test="plcDbWriteAddress != null and plcDbWriteAddress != ''"> and plc_db_write_address = #{plcDbWriteAddress}</if>
|
||||
<if test="rwh != null "> and rwh = #{rwh}</if>
|
||||
<if test="jdbz != null "> and jdbz = #{jdbz}</if>
|
||||
<if test="sbzt != null "> and sbzt = #{sbzt}</if>
|
||||
<if test="czfs != null "> and czfs = #{czfs}</if>
|
||||
<if test="yxxf != null "> and yxxf = #{yxxf}</if>
|
||||
<if test="yph != null "> and yph = #{yph}</if>
|
||||
<if test="ylh != null "> and ylh = #{ylh}</if>
|
||||
<if test="ych != null "> and ych = #{ych}</if>
|
||||
<if test="mbph != null "> and mbph = #{mbph}</if>
|
||||
<if test="mblh != null "> and mblh = #{mblh}</if>
|
||||
<if test="mbch != null "> and mbch = #{mbch}</if>
|
||||
<if test="xtxh != null "> and xtxh = #{xtxh}</if>
|
||||
<if test="dqcs != null "> and dqcs = #{dqcs}</if>
|
||||
<if test="hczt != null "> and hczt = #{hczt}</if>
|
||||
<if test="spare1 != null "> and spare1 = #{spare1}</if>
|
||||
<if test="spare2 != null "> and spare2 = #{spare2}</if>
|
||||
<if test="spare3 != null "> and spare3 = #{spare3}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectDeviceTsjById" parameterType="Long" resultMap="DeviceTsjResult">
|
||||
<include refid="selectDeviceTsjVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertDeviceTsj" parameterType="DeviceTsj">
|
||||
insert into device_tsj
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
<if test="name != null">name,</if>
|
||||
<if test="ip != null">ip,</if>
|
||||
<if test="port != null">port,</if>
|
||||
<if test="plcDbReadAddress != null">plc_db_read_address,</if>
|
||||
<if test="plcDbWriteAddress != null">plc_db_write_address,</if>
|
||||
<if test="rwh != null">rwh,</if>
|
||||
<if test="jdbz != null">jdbz,</if>
|
||||
<if test="sbzt != null">sbzt,</if>
|
||||
<if test="czfs != null">czfs,</if>
|
||||
<if test="yxxf != null">yxxf,</if>
|
||||
<if test="yph != null">yph,</if>
|
||||
<if test="ylh != null">ylh,</if>
|
||||
<if test="ych != null">ych,</if>
|
||||
<if test="mbph != null">mbph,</if>
|
||||
<if test="mblh != null">mblh,</if>
|
||||
<if test="mbch != null">mbch,</if>
|
||||
<if test="xtxh != null">xtxh,</if>
|
||||
<if test="dqcs != null">dqcs,</if>
|
||||
<if test="hczt != null">hczt,</if>
|
||||
<if test="spare1 != null">spare1,</if>
|
||||
<if test="spare2 != null">spare2,</if>
|
||||
<if test="spare3 != null">spare3,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">#{id},</if>
|
||||
<if test="name != null">#{name},</if>
|
||||
<if test="ip != null">#{ip},</if>
|
||||
<if test="port != null">#{port},</if>
|
||||
<if test="plcDbReadAddress != null">#{plcDbReadAddress},</if>
|
||||
<if test="plcDbWriteAddress != null">#{plcDbWriteAddress},</if>
|
||||
<if test="rwh != null">#{rwh},</if>
|
||||
<if test="jdbz != null">#{jdbz},</if>
|
||||
<if test="sbzt != null">#{sbzt},</if>
|
||||
<if test="czfs != null">#{czfs},</if>
|
||||
<if test="yxxf != null">#{yxxf},</if>
|
||||
<if test="yph != null">#{yph},</if>
|
||||
<if test="ylh != null">#{ylh},</if>
|
||||
<if test="ych != null">#{ych},</if>
|
||||
<if test="mbph != null">#{mbph},</if>
|
||||
<if test="mblh != null">#{mblh},</if>
|
||||
<if test="mbch != null">#{mbch},</if>
|
||||
<if test="xtxh != null">#{xtxh},</if>
|
||||
<if test="dqcs != null">#{dqcs},</if>
|
||||
<if test="hczt != null">#{hczt},</if>
|
||||
<if test="spare1 != null">#{spare1},</if>
|
||||
<if test="spare2 != null">#{spare2},</if>
|
||||
<if test="spare3 != null">#{spare3},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateDeviceTsj" parameterType="DeviceTsj">
|
||||
update device_tsj
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="name != null">name = #{name},</if>
|
||||
<if test="ip != null">ip = #{ip},</if>
|
||||
<if test="port != null">port = #{port},</if>
|
||||
<if test="plcDbReadAddress != null">plc_db_read_address = #{plcDbReadAddress},</if>
|
||||
<if test="plcDbWriteAddress != null">plc_db_write_address = #{plcDbWriteAddress},</if>
|
||||
<if test="rwh != null">rwh = #{rwh},</if>
|
||||
<if test="jdbz != null">jdbz = #{jdbz},</if>
|
||||
<if test="sbzt != null">sbzt = #{sbzt},</if>
|
||||
<if test="czfs != null">czfs = #{czfs},</if>
|
||||
<if test="yxxf != null">yxxf = #{yxxf},</if>
|
||||
<if test="yph != null">yph = #{yph},</if>
|
||||
<if test="ylh != null">ylh = #{ylh},</if>
|
||||
<if test="ych != null">ych = #{ych},</if>
|
||||
<if test="mbph != null">mbph = #{mbph},</if>
|
||||
<if test="mblh != null">mblh = #{mblh},</if>
|
||||
<if test="mbch != null">mbch = #{mbch},</if>
|
||||
<if test="xtxh != null">xtxh = #{xtxh},</if>
|
||||
<if test="dqcs != null">dqcs = #{dqcs},</if>
|
||||
<if test="hczt != null">hczt = #{hczt},</if>
|
||||
<if test="spare1 != null">spare1 = #{spare1},</if>
|
||||
<if test="spare2 != null">spare2 = #{spare2},</if>
|
||||
<if test="spare3 != null">spare3 = #{spare3},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteDeviceTsjById" parameterType="Long">
|
||||
delete from device_tsj where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteDeviceTsjByIds" parameterType="String">
|
||||
delete from device_tsj where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,158 @@
|
||||
<?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.queue.tsj.mapper.TsjDeviceExecutionQueueFinishMapper">
|
||||
|
||||
<resultMap type="TsjDeviceExecutionQueueFinish" id="TsjDeviceExecutionQueueFinishResult">
|
||||
<result property="guid" column="guid" />
|
||||
<result property="deviceId" column="device_id" />
|
||||
<result property="deviceName" column="device_name" />
|
||||
<result property="taskNo" column="task_no" />
|
||||
<result property="srcRow" column="src_row" />
|
||||
<result property="srcColumn" column="src_column" />
|
||||
<result property="srcLayer" column="src_layer" />
|
||||
<result property="tarRow" column="tar_row" />
|
||||
<result property="tarColumn" column="tar_column" />
|
||||
<result property="tarLayer" column="tar_layer" />
|
||||
<result property="srcSite" column="src_site" />
|
||||
<result property="tarSite" column="tar_site" />
|
||||
<result property="sendFlag" column="send_flag" />
|
||||
<result property="sendType" column="send_type" />
|
||||
<result property="taskType" column="task_type" />
|
||||
<result property="createDate" column="create_date" />
|
||||
<result property="startDate" column="start_date" />
|
||||
<result property="finishDate" column="finish_date" />
|
||||
<result property="spare1" column="spare1" />
|
||||
<result property="spare2" column="spare2" />
|
||||
<result property="spare3" column="spare3" />
|
||||
<result property="rwlx" column="rwlx" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectTsjDeviceExecutionQueueFinishVo">
|
||||
select guid, device_id, device_name, task_no, src_row, src_column, src_layer, tar_row, tar_column, tar_layer, src_site, tar_site, send_flag, send_type, task_type, create_date, start_date, finish_date, spare1, spare2, spare3, rwlx from tsj_device_execution_queue_finish
|
||||
</sql>
|
||||
|
||||
<select id="selectTsjDeviceExecutionQueueFinishList" parameterType="TsjDeviceExecutionQueueFinish" resultMap="TsjDeviceExecutionQueueFinishResult">
|
||||
<include refid="selectTsjDeviceExecutionQueueFinishVo"/>
|
||||
<where>
|
||||
<if test="deviceId != null "> and device_id = #{deviceId}</if>
|
||||
<if test="deviceName != null and deviceName != ''"> and device_name like concat('%', #{deviceName}, '%')</if>
|
||||
<if test="taskNo != null "> and task_no = #{taskNo}</if>
|
||||
<if test="srcRow != null and srcRow != ''"> and src_row = #{srcRow}</if>
|
||||
<if test="srcColumn != null and srcColumn != ''"> and src_column = #{srcColumn}</if>
|
||||
<if test="srcLayer != null and srcLayer != ''"> and src_layer = #{srcLayer}</if>
|
||||
<if test="tarRow != null and tarRow != ''"> and tar_row = #{tarRow}</if>
|
||||
<if test="tarColumn != null and tarColumn != ''"> and tar_column = #{tarColumn}</if>
|
||||
<if test="tarLayer != null and tarLayer != ''"> and tar_layer = #{tarLayer}</if>
|
||||
<if test="srcSite != null and srcSite != ''"> and src_site = #{srcSite}</if>
|
||||
<if test="tarSite != null and tarSite != ''"> and tar_site = #{tarSite}</if>
|
||||
<if test="sendFlag != null and sendFlag != ''"> and send_flag = #{sendFlag}</if>
|
||||
<if test="sendType != null and sendType != ''"> and send_type = #{sendType}</if>
|
||||
<if test="taskType != null and taskType != ''"> and task_type = #{taskType}</if>
|
||||
<if test="createDate != null and createDate != ''"> and create_date = #{createDate}</if>
|
||||
<if test="startDate != null and startDate != ''"> and start_date = #{startDate}</if>
|
||||
<if test="finishDate != null and finishDate != ''"> and finish_date = #{finishDate}</if>
|
||||
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if>
|
||||
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
|
||||
<if test="spare3 != null and spare3 != ''"> and spare3 = #{spare3}</if>
|
||||
<if test="rwlx != null and rwlx != ''"> and rwlx = #{rwlx}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectTsjDeviceExecutionQueueFinishByGuid" parameterType="String" resultMap="TsjDeviceExecutionQueueFinishResult">
|
||||
<include refid="selectTsjDeviceExecutionQueueFinishVo"/>
|
||||
where guid = #{guid}
|
||||
</select>
|
||||
|
||||
<insert id="insertTsjDeviceExecutionQueueFinish" parameterType="TsjDeviceExecutionQueueFinish">
|
||||
insert into tsj_device_execution_queue_finish
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="guid != null">guid,</if>
|
||||
<if test="deviceId != null">device_id,</if>
|
||||
<if test="deviceName != null">device_name,</if>
|
||||
<if test="taskNo != null">task_no,</if>
|
||||
<if test="srcRow != null">src_row,</if>
|
||||
<if test="srcColumn != null">src_column,</if>
|
||||
<if test="srcLayer != null">src_layer,</if>
|
||||
<if test="tarRow != null">tar_row,</if>
|
||||
<if test="tarColumn != null">tar_column,</if>
|
||||
<if test="tarLayer != null">tar_layer,</if>
|
||||
<if test="srcSite != null">src_site,</if>
|
||||
<if test="tarSite != null">tar_site,</if>
|
||||
<if test="sendFlag != null">send_flag,</if>
|
||||
<if test="sendType != null">send_type,</if>
|
||||
<if test="taskType != null">task_type,</if>
|
||||
<if test="createDate != null">create_date,</if>
|
||||
<if test="startDate != null">start_date,</if>
|
||||
<if test="finishDate != null">finish_date,</if>
|
||||
<if test="spare1 != null">spare1,</if>
|
||||
<if test="spare2 != null">spare2,</if>
|
||||
<if test="spare3 != null">spare3,</if>
|
||||
<if test="rwlx != null">rwlx,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="guid != null">#{guid},</if>
|
||||
<if test="deviceId != null">#{deviceId},</if>
|
||||
<if test="deviceName != null">#{deviceName},</if>
|
||||
<if test="taskNo != null">#{taskNo},</if>
|
||||
<if test="srcRow != null">#{srcRow},</if>
|
||||
<if test="srcColumn != null">#{srcColumn},</if>
|
||||
<if test="srcLayer != null">#{srcLayer},</if>
|
||||
<if test="tarRow != null">#{tarRow},</if>
|
||||
<if test="tarColumn != null">#{tarColumn},</if>
|
||||
<if test="tarLayer != null">#{tarLayer},</if>
|
||||
<if test="srcSite != null">#{srcSite},</if>
|
||||
<if test="tarSite != null">#{tarSite},</if>
|
||||
<if test="sendFlag != null">#{sendFlag},</if>
|
||||
<if test="sendType != null">#{sendType},</if>
|
||||
<if test="taskType != null">#{taskType},</if>
|
||||
<if test="createDate != null">#{createDate},</if>
|
||||
<if test="startDate != null">#{startDate},</if>
|
||||
<if test="finishDate != null">#{finishDate},</if>
|
||||
<if test="spare1 != null">#{spare1},</if>
|
||||
<if test="spare2 != null">#{spare2},</if>
|
||||
<if test="spare3 != null">#{spare3},</if>
|
||||
<if test="rwlx != null">#{rwlx},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateTsjDeviceExecutionQueueFinish" parameterType="TsjDeviceExecutionQueueFinish">
|
||||
update tsj_device_execution_queue_finish
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="deviceId != null">device_id = #{deviceId},</if>
|
||||
<if test="deviceName != null">device_name = #{deviceName},</if>
|
||||
<if test="taskNo != null">task_no = #{taskNo},</if>
|
||||
<if test="srcRow != null">src_row = #{srcRow},</if>
|
||||
<if test="srcColumn != null">src_column = #{srcColumn},</if>
|
||||
<if test="srcLayer != null">src_layer = #{srcLayer},</if>
|
||||
<if test="tarRow != null">tar_row = #{tarRow},</if>
|
||||
<if test="tarColumn != null">tar_column = #{tarColumn},</if>
|
||||
<if test="tarLayer != null">tar_layer = #{tarLayer},</if>
|
||||
<if test="srcSite != null">src_site = #{srcSite},</if>
|
||||
<if test="tarSite != null">tar_site = #{tarSite},</if>
|
||||
<if test="sendFlag != null">send_flag = #{sendFlag},</if>
|
||||
<if test="sendType != null">send_type = #{sendType},</if>
|
||||
<if test="taskType != null">task_type = #{taskType},</if>
|
||||
<if test="createDate != null">create_date = #{createDate},</if>
|
||||
<if test="startDate != null">start_date = #{startDate},</if>
|
||||
<if test="finishDate != null">finish_date = #{finishDate},</if>
|
||||
<if test="spare1 != null">spare1 = #{spare1},</if>
|
||||
<if test="spare2 != null">spare2 = #{spare2},</if>
|
||||
<if test="spare3 != null">spare3 = #{spare3},</if>
|
||||
<if test="rwlx != null">rwlx = #{rwlx},</if>
|
||||
</trim>
|
||||
where guid = #{guid}
|
||||
</update>
|
||||
|
||||
<delete id="deleteTsjDeviceExecutionQueueFinishByGuid" parameterType="String">
|
||||
delete from tsj_device_execution_queue_finish where guid = #{guid}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteTsjDeviceExecutionQueueFinishByGuids" parameterType="String">
|
||||
delete from tsj_device_execution_queue_finish where guid in
|
||||
<foreach item="guid" collection="array" open="(" separator="," close=")">
|
||||
#{guid}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,162 @@
|
||||
<?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.queue.tsj.mapper.TsjDeviceExecutionQueueMapper">
|
||||
|
||||
<resultMap type="TsjDeviceExecutionQueue" id="TsjDeviceExecutionQueueResult">
|
||||
<result property="guid" column="guid" />
|
||||
<result property="deviceId" column="device_id" />
|
||||
<result property="deviceName" column="device_name" />
|
||||
<result property="taskNo" column="task_no" />
|
||||
<result property="srcRow" column="src_row" />
|
||||
<result property="srcColumn" column="src_column" />
|
||||
<result property="srcLayer" column="src_layer" />
|
||||
<result property="tarRow" column="tar_row" />
|
||||
<result property="tarColumn" column="tar_column" />
|
||||
<result property="tarLayer" column="tar_layer" />
|
||||
<result property="srcSite" column="src_site" />
|
||||
<result property="tarSite" column="tar_site" />
|
||||
<result property="sendFlag" column="send_flag" />
|
||||
<result property="sendType" column="send_type" />
|
||||
<result property="taskType" column="task_type" />
|
||||
<result property="createDate" column="create_date" />
|
||||
<result property="startDate" column="start_date" />
|
||||
<result property="finishDate" column="finish_date" />
|
||||
<result property="spare1" column="spare1" />
|
||||
<result property="spare2" column="spare2" />
|
||||
<result property="spare3" column="spare3" />
|
||||
<result property="rwlx" column="rwlx" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectTsjDeviceExecutionQueueVo">
|
||||
select guid, device_id, device_name, task_no, src_row, src_column, src_layer, tar_row, tar_column, tar_layer, src_site, tar_site, send_flag, send_type, task_type, create_date, start_date, finish_date, spare1, spare2, spare3, rwlx from tsj_device_execution_queue
|
||||
</sql>
|
||||
|
||||
<select id="selectTsjDeviceExecutionQueueList" parameterType="TsjDeviceExecutionQueue" resultMap="TsjDeviceExecutionQueueResult">
|
||||
<include refid="selectTsjDeviceExecutionQueueVo"/>
|
||||
<where>
|
||||
<if test="deviceId != null "> and device_id = #{deviceId}</if>
|
||||
<if test="deviceName != null and deviceName != ''"> and device_name like concat('%', #{deviceName}, '%')</if>
|
||||
<if test="taskNo != null "> and task_no = #{taskNo}</if>
|
||||
<if test="srcRow != null and srcRow != ''"> and src_row = #{srcRow}</if>
|
||||
<if test="srcColumn != null and srcColumn != ''"> and src_column = #{srcColumn}</if>
|
||||
<if test="srcLayer != null and srcLayer != ''"> and src_layer = #{srcLayer}</if>
|
||||
<if test="tarRow != null and tarRow != ''"> and tar_row = #{tarRow}</if>
|
||||
<if test="tarColumn != null and tarColumn != ''"> and tar_column = #{tarColumn}</if>
|
||||
<if test="tarLayer != null and tarLayer != ''"> and tar_layer = #{tarLayer}</if>
|
||||
<if test="srcSite != null and srcSite != ''"> and src_site = #{srcSite}</if>
|
||||
<if test="tarSite != null and tarSite != ''"> and tar_site = #{tarSite}</if>
|
||||
<if test="sendFlag != null and sendFlag != ''"> and send_flag = #{sendFlag}</if>
|
||||
<if test="sendType != null and sendType != ''"> and send_type = #{sendType}</if>
|
||||
<if test="taskType != null and taskType != ''"> and task_type = #{taskType}</if>
|
||||
<if test="createDate != null and createDate != ''"> and create_date = #{createDate}</if>
|
||||
<if test="startDate != null and startDate != ''"> and start_date = #{startDate}</if>
|
||||
<if test="finishDate != null and finishDate != ''"> and finish_date = #{finishDate}</if>
|
||||
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if>
|
||||
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
|
||||
<if test="spare3 != null and spare3 != ''"> and spare3 = #{spare3}</if>
|
||||
<if test="rwlx != null and rwlx != ''"> and rwlx = #{rwlx}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectTsjDeviceExecutionQueueByGuid" parameterType="String" resultMap="TsjDeviceExecutionQueueResult">
|
||||
<include refid="selectTsjDeviceExecutionQueueVo"/>
|
||||
where guid = #{guid}
|
||||
</select>
|
||||
<select id="selectTsjDeviceExecutionQueueByRwh" resultMap="TsjDeviceExecutionQueueResult">
|
||||
<include refid="selectTsjDeviceExecutionQueueVo"/>
|
||||
where task_no = #{taskNo}
|
||||
</select>
|
||||
|
||||
<insert id="insertTsjDeviceExecutionQueue" parameterType="TsjDeviceExecutionQueue">
|
||||
insert into tsj_device_execution_queue
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="guid != null">guid,</if>
|
||||
<if test="deviceId != null">device_id,</if>
|
||||
<if test="deviceName != null">device_name,</if>
|
||||
<if test="taskNo != null">task_no,</if>
|
||||
<if test="srcRow != null">src_row,</if>
|
||||
<if test="srcColumn != null">src_column,</if>
|
||||
<if test="srcLayer != null">src_layer,</if>
|
||||
<if test="tarRow != null">tar_row,</if>
|
||||
<if test="tarColumn != null">tar_column,</if>
|
||||
<if test="tarLayer != null">tar_layer,</if>
|
||||
<if test="srcSite != null">src_site,</if>
|
||||
<if test="tarSite != null">tar_site,</if>
|
||||
<if test="sendFlag != null">send_flag,</if>
|
||||
<if test="sendType != null">send_type,</if>
|
||||
<if test="taskType != null">task_type,</if>
|
||||
<if test="createDate != null">create_date,</if>
|
||||
<if test="startDate != null">start_date,</if>
|
||||
<if test="finishDate != null">finish_date,</if>
|
||||
<if test="spare1 != null">spare1,</if>
|
||||
<if test="spare2 != null">spare2,</if>
|
||||
<if test="spare3 != null">spare3,</if>
|
||||
<if test="rwlx != null">rwlx,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="guid != null">#{guid},</if>
|
||||
<if test="deviceId != null">#{deviceId},</if>
|
||||
<if test="deviceName != null">#{deviceName},</if>
|
||||
<if test="taskNo != null">#{taskNo},</if>
|
||||
<if test="srcRow != null">#{srcRow},</if>
|
||||
<if test="srcColumn != null">#{srcColumn},</if>
|
||||
<if test="srcLayer != null">#{srcLayer},</if>
|
||||
<if test="tarRow != null">#{tarRow},</if>
|
||||
<if test="tarColumn != null">#{tarColumn},</if>
|
||||
<if test="tarLayer != null">#{tarLayer},</if>
|
||||
<if test="srcSite != null">#{srcSite},</if>
|
||||
<if test="tarSite != null">#{tarSite},</if>
|
||||
<if test="sendFlag != null">#{sendFlag},</if>
|
||||
<if test="sendType != null">#{sendType},</if>
|
||||
<if test="taskType != null">#{taskType},</if>
|
||||
<if test="createDate != null">#{createDate},</if>
|
||||
<if test="startDate != null">#{startDate},</if>
|
||||
<if test="finishDate != null">#{finishDate},</if>
|
||||
<if test="spare1 != null">#{spare1},</if>
|
||||
<if test="spare2 != null">#{spare2},</if>
|
||||
<if test="spare3 != null">#{spare3},</if>
|
||||
<if test="rwlx != null">#{rwlx},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateTsjDeviceExecutionQueue" parameterType="TsjDeviceExecutionQueue">
|
||||
update tsj_device_execution_queue
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="deviceId != null">device_id = #{deviceId},</if>
|
||||
<if test="deviceName != null">device_name = #{deviceName},</if>
|
||||
<if test="taskNo != null">task_no = #{taskNo},</if>
|
||||
<if test="srcRow != null">src_row = #{srcRow},</if>
|
||||
<if test="srcColumn != null">src_column = #{srcColumn},</if>
|
||||
<if test="srcLayer != null">src_layer = #{srcLayer},</if>
|
||||
<if test="tarRow != null">tar_row = #{tarRow},</if>
|
||||
<if test="tarColumn != null">tar_column = #{tarColumn},</if>
|
||||
<if test="tarLayer != null">tar_layer = #{tarLayer},</if>
|
||||
<if test="srcSite != null">src_site = #{srcSite},</if>
|
||||
<if test="tarSite != null">tar_site = #{tarSite},</if>
|
||||
<if test="sendFlag != null">send_flag = #{sendFlag},</if>
|
||||
<if test="sendType != null">send_type = #{sendType},</if>
|
||||
<if test="taskType != null">task_type = #{taskType},</if>
|
||||
<if test="createDate != null">create_date = #{createDate},</if>
|
||||
<if test="startDate != null">start_date = #{startDate},</if>
|
||||
<if test="finishDate != null">finish_date = #{finishDate},</if>
|
||||
<if test="spare1 != null">spare1 = #{spare1},</if>
|
||||
<if test="spare2 != null">spare2 = #{spare2},</if>
|
||||
<if test="spare3 != null">spare3 = #{spare3},</if>
|
||||
<if test="rwlx != null">rwlx = #{rwlx},</if>
|
||||
</trim>
|
||||
where guid = #{guid}
|
||||
</update>
|
||||
|
||||
<delete id="deleteTsjDeviceExecutionQueueByGuid" parameterType="String">
|
||||
delete from tsj_device_execution_queue where guid = #{guid}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteTsjDeviceExecutionQueueByGuids" parameterType="String">
|
||||
delete from tsj_device_execution_queue where guid in
|
||||
<foreach item="guid" collection="array" open="(" separator="," close=")">
|
||||
#{guid}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
44
ruoyi-ui/src/api/queue/tsj.js
Normal file
44
ruoyi-ui/src/api/queue/tsj.js
Normal file
@@ -0,0 +1,44 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 查询提升机执行队列列表
|
||||
export function listTsj(query) {
|
||||
return request({
|
||||
url: '/queue/tsj/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
// 查询提升机执行队列详细
|
||||
export function getTsj(guid) {
|
||||
return request({
|
||||
url: '/queue/tsj/' + guid,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 新增提升机执行队列
|
||||
export function addTsj(data) {
|
||||
return request({
|
||||
url: '/queue/tsj',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 修改提升机执行队列
|
||||
export function updateTsj(data) {
|
||||
return request({
|
||||
url: '/queue/tsj',
|
||||
method: 'put',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 删除提升机执行队列
|
||||
export function delTsj(guid) {
|
||||
return request({
|
||||
url: '/queue/tsj/' + guid,
|
||||
method: 'delete'
|
||||
})
|
||||
}
|
||||
44
ruoyi-ui/src/api/queue/tsjFinish.js
Normal file
44
ruoyi-ui/src/api/queue/tsjFinish.js
Normal file
@@ -0,0 +1,44 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 查询提升机执行队列列表
|
||||
export function listTsjFinish(query) {
|
||||
return request({
|
||||
url: '/queue/tsjFinish/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
// 查询提升机执行队列详细
|
||||
export function getTsjFinish(guid) {
|
||||
return request({
|
||||
url: '/queue/tsjFinish/' + guid,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 新增提升机执行队列
|
||||
export function addTsjFinish(data) {
|
||||
return request({
|
||||
url: '/queue/tsjFinish',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 修改提升机执行队列
|
||||
export function updateTsjFinish(data) {
|
||||
return request({
|
||||
url: '/queue/tsjFinish',
|
||||
method: 'put',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 删除提升机执行队列
|
||||
export function delTsjFinish(guid) {
|
||||
return request({
|
||||
url: '/queue/tsjFinish/' + guid,
|
||||
method: 'delete'
|
||||
})
|
||||
}
|
||||
484
ruoyi-ui/src/views/queue/tsj/index.vue
Normal file
484
ruoyi-ui/src/views/queue/tsj/index.vue
Normal file
@@ -0,0 +1,484 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||
<el-form-item label="设备编号" prop="deviceId">
|
||||
<el-input
|
||||
v-model="queryParams.deviceId"
|
||||
placeholder="请输入设备编号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="设备名称" prop="deviceName">
|
||||
<el-input
|
||||
v-model="queryParams.deviceName"
|
||||
placeholder="请输入设备名称"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="任务号" prop="taskNo">
|
||||
<el-input
|
||||
v-model="queryParams.taskNo"
|
||||
placeholder="请输入任务号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="原排" prop="srcRow">
|
||||
<el-input
|
||||
v-model="queryParams.srcRow"
|
||||
placeholder="请输入原排"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="原列" prop="srcColumn">
|
||||
<el-input
|
||||
v-model="queryParams.srcColumn"
|
||||
placeholder="请输入原列"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="原层" prop="srcLayer">
|
||||
<el-input
|
||||
v-model="queryParams.srcLayer"
|
||||
placeholder="请输入原层"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="目标排" prop="tarRow">
|
||||
<el-input
|
||||
v-model="queryParams.tarRow"
|
||||
placeholder="请输入目标排"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="目标列" prop="tarColumn">
|
||||
<el-input
|
||||
v-model="queryParams.tarColumn"
|
||||
placeholder="请输入目标列"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="目标层" prop="tarLayer">
|
||||
<el-input
|
||||
v-model="queryParams.tarLayer"
|
||||
placeholder="请输入目标层"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="原地址" prop="srcSite">
|
||||
<el-input
|
||||
v-model="queryParams.srcSite"
|
||||
placeholder="请输入原地址"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="目标地址" prop="tarSite">
|
||||
<el-input
|
||||
v-model="queryParams.tarSite"
|
||||
placeholder="请输入目标地址"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="下发" prop="sendFlag">
|
||||
<el-input
|
||||
v-model="queryParams.sendFlag"
|
||||
placeholder="请输入下发"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备用1" prop="spare1">
|
||||
<el-input
|
||||
v-model="queryParams.spare1"
|
||||
placeholder="请输入备用1"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备用2" prop="spare2">
|
||||
<el-input
|
||||
v-model="queryParams.spare2"
|
||||
placeholder="请输入备用2"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备用3" prop="spare3">
|
||||
<el-input
|
||||
v-model="queryParams.spare3"
|
||||
placeholder="请输入备用3"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="任务类型" prop="rwlx">
|
||||
<el-select v-model="queryParams.rwlx" placeholder="请选择任务类型" clearable>
|
||||
<el-option
|
||||
v-for="dict in dict.type.tsj_rwlx"
|
||||
:key="dict.value"
|
||||
:label="dict.label"
|
||||
:value="dict.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="primary"
|
||||
plain
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="handleAdd"
|
||||
v-hasPermi="['queue:tsj:add']"
|
||||
>新增</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="success"
|
||||
plain
|
||||
icon="el-icon-edit"
|
||||
size="mini"
|
||||
:disabled="single"
|
||||
@click="handleUpdate"
|
||||
v-hasPermi="['queue:tsj:edit']"
|
||||
>修改</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="danger"
|
||||
plain
|
||||
icon="el-icon-delete"
|
||||
size="mini"
|
||||
:disabled="multiple"
|
||||
@click="handleDelete"
|
||||
v-hasPermi="['queue:tsj:remove']"
|
||||
>删除</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="warning"
|
||||
plain
|
||||
icon="el-icon-download"
|
||||
size="mini"
|
||||
@click="handleExport"
|
||||
v-hasPermi="['queue:tsj:export']"
|
||||
>导出</el-button>
|
||||
</el-col>
|
||||
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="tsjList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="GUID" align="center" prop="guid" />
|
||||
<el-table-column label="设备编号" align="center" prop="deviceId" />
|
||||
<el-table-column label="设备名称" align="center" prop="deviceName" />
|
||||
<el-table-column label="任务号" align="center" prop="taskNo" />
|
||||
<el-table-column label="原排" align="center" prop="srcRow" />
|
||||
<el-table-column label="原列" align="center" prop="srcColumn" />
|
||||
<el-table-column label="原层" align="center" prop="srcLayer" />
|
||||
<el-table-column label="目标排" align="center" prop="tarRow" />
|
||||
<el-table-column label="目标列" align="center" prop="tarColumn" />
|
||||
<el-table-column label="目标层" align="center" prop="tarLayer" />
|
||||
<el-table-column label="原地址" align="center" prop="srcSite" />
|
||||
<el-table-column label="目标地址" align="center" prop="tarSite" />
|
||||
<el-table-column label="下发" align="center" prop="sendFlag" />
|
||||
<el-table-column label="下发类型" align="center" prop="sendType" />
|
||||
<el-table-column label="任务类型" align="center" prop="taskType" />
|
||||
<el-table-column label="创建时间" align="center" prop="createDate" />
|
||||
<el-table-column label="开始时间" align="center" prop="startDate" />
|
||||
<el-table-column label="完成时间" align="center" prop="finishDate" />
|
||||
<el-table-column label="备用1" align="center" prop="spare1" />
|
||||
<el-table-column label="备用2" align="center" prop="spare2" />
|
||||
<el-table-column label="备用3" align="center" prop="spare3" />
|
||||
<el-table-column label="任务类型" align="center" prop="rwlx">
|
||||
<template slot-scope="scope">
|
||||
<dict-tag :options="dict.type.tsj_rwlx" :value="scope.row.rwlx"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-edit"
|
||||
@click="handleUpdate(scope.row)"
|
||||
v-hasPermi="['queue:tsj:edit']"
|
||||
>修改</el-button>
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@click="handleDelete(scope.row)"
|
||||
v-hasPermi="['queue:tsj:remove']"
|
||||
>删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<pagination
|
||||
v-show="total>0"
|
||||
:total="total"
|
||||
:page.sync="queryParams.pageNum"
|
||||
:limit.sync="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
|
||||
<!-- 添加或修改提升机执行队列对话框 -->
|
||||
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||
<el-form-item label="设备编号" prop="deviceId">
|
||||
<el-input v-model="form.deviceId" placeholder="请输入设备编号" />
|
||||
</el-form-item>
|
||||
<el-form-item label="设备名称" prop="deviceName">
|
||||
<el-input v-model="form.deviceName" placeholder="请输入设备名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="任务号" prop="taskNo">
|
||||
<el-input v-model="form.taskNo" placeholder="请输入任务号" />
|
||||
</el-form-item>
|
||||
<el-form-item label="原排" prop="srcRow">
|
||||
<el-input v-model="form.srcRow" placeholder="请输入原排" />
|
||||
</el-form-item>
|
||||
<el-form-item label="原列" prop="srcColumn">
|
||||
<el-input v-model="form.srcColumn" placeholder="请输入原列" />
|
||||
</el-form-item>
|
||||
<el-form-item label="原层" prop="srcLayer">
|
||||
<el-input v-model="form.srcLayer" placeholder="请输入原层" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目标排" prop="tarRow">
|
||||
<el-input v-model="form.tarRow" placeholder="请输入目标排" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目标列" prop="tarColumn">
|
||||
<el-input v-model="form.tarColumn" placeholder="请输入目标列" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目标层" prop="tarLayer">
|
||||
<el-input v-model="form.tarLayer" placeholder="请输入目标层" />
|
||||
</el-form-item>
|
||||
<el-form-item label="原地址" prop="srcSite">
|
||||
<el-input v-model="form.srcSite" placeholder="请输入原地址" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目标地址" prop="tarSite">
|
||||
<el-input v-model="form.tarSite" placeholder="请输入目标地址" />
|
||||
</el-form-item>
|
||||
<el-form-item label="下发" prop="sendFlag">
|
||||
<el-input v-model="form.sendFlag" placeholder="请输入下发" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备用1" prop="spare1">
|
||||
<el-input v-model="form.spare1" placeholder="请输入备用1" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备用2" prop="spare2">
|
||||
<el-input v-model="form.spare2" placeholder="请输入备用2" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备用3" prop="spare3">
|
||||
<el-input v-model="form.spare3" placeholder="请输入备用3" />
|
||||
</el-form-item>
|
||||
<el-form-item label="任务类型" prop="rwlx">
|
||||
<el-select v-model="form.rwlx" placeholder="请选择任务类型">
|
||||
<el-option
|
||||
v-for="dict in dict.type.tsj_rwlx"
|
||||
:key="dict.value"
|
||||
:label="dict.label"
|
||||
:value="dict.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||
<el-button @click="cancel">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { listTsj, getTsj, delTsj, addTsj, updateTsj } from "@/api/queue/tsj"
|
||||
|
||||
export default {
|
||||
name: "Tsj",
|
||||
dicts: ['tsj_rwlx'],
|
||||
data() {
|
||||
return {
|
||||
// 遮罩层
|
||||
loading: true,
|
||||
// 选中数组
|
||||
ids: [],
|
||||
// 非单个禁用
|
||||
single: true,
|
||||
// 非多个禁用
|
||||
multiple: true,
|
||||
// 显示搜索条件
|
||||
showSearch: true,
|
||||
// 总条数
|
||||
total: 0,
|
||||
// 提升机执行队列表格数据
|
||||
tsjList: [],
|
||||
// 弹出层标题
|
||||
title: "",
|
||||
// 是否显示弹出层
|
||||
open: false,
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
deviceId: null,
|
||||
deviceName: null,
|
||||
taskNo: null,
|
||||
srcRow: null,
|
||||
srcColumn: null,
|
||||
srcLayer: null,
|
||||
tarRow: null,
|
||||
tarColumn: null,
|
||||
tarLayer: null,
|
||||
srcSite: null,
|
||||
tarSite: null,
|
||||
sendFlag: null,
|
||||
sendType: null,
|
||||
taskType: null,
|
||||
createDate: null,
|
||||
startDate: null,
|
||||
finishDate: null,
|
||||
spare1: null,
|
||||
spare2: null,
|
||||
spare3: null,
|
||||
rwlx: null
|
||||
},
|
||||
// 表单参数
|
||||
form: {},
|
||||
// 表单校验
|
||||
rules: {
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
/** 查询提升机执行队列列表 */
|
||||
getList() {
|
||||
this.loading = true
|
||||
listTsj(this.queryParams).then(response => {
|
||||
this.tsjList = response.rows
|
||||
this.total = response.total
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
// 取消按钮
|
||||
cancel() {
|
||||
this.open = false
|
||||
this.reset()
|
||||
},
|
||||
// 表单重置
|
||||
reset() {
|
||||
this.form = {
|
||||
guid: null,
|
||||
deviceId: null,
|
||||
deviceName: null,
|
||||
taskNo: null,
|
||||
srcRow: null,
|
||||
srcColumn: null,
|
||||
srcLayer: null,
|
||||
tarRow: null,
|
||||
tarColumn: null,
|
||||
tarLayer: null,
|
||||
srcSite: null,
|
||||
tarSite: null,
|
||||
sendFlag: null,
|
||||
sendType: null,
|
||||
taskType: null,
|
||||
createDate: null,
|
||||
startDate: null,
|
||||
finishDate: null,
|
||||
spare1: null,
|
||||
spare2: null,
|
||||
spare3: null,
|
||||
rwlx: null
|
||||
}
|
||||
this.resetForm("form")
|
||||
},
|
||||
/** 搜索按钮操作 */
|
||||
handleQuery() {
|
||||
this.queryParams.pageNum = 1
|
||||
this.getList()
|
||||
},
|
||||
/** 重置按钮操作 */
|
||||
resetQuery() {
|
||||
this.resetForm("queryForm")
|
||||
this.handleQuery()
|
||||
},
|
||||
// 多选框选中数据
|
||||
handleSelectionChange(selection) {
|
||||
this.ids = selection.map(item => item.guid)
|
||||
this.single = selection.length!==1
|
||||
this.multiple = !selection.length
|
||||
},
|
||||
/** 新增按钮操作 */
|
||||
handleAdd() {
|
||||
this.reset()
|
||||
this.open = true
|
||||
this.title = "添加提升机执行队列"
|
||||
},
|
||||
/** 修改按钮操作 */
|
||||
handleUpdate(row) {
|
||||
this.reset()
|
||||
const guid = row.guid || this.ids
|
||||
getTsj(guid).then(response => {
|
||||
this.form = response.data
|
||||
this.open = true
|
||||
this.title = "修改提升机执行队列"
|
||||
})
|
||||
},
|
||||
/** 提交按钮 */
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (valid) {
|
||||
if (this.form.guid != null) {
|
||||
updateTsj(this.form).then(response => {
|
||||
this.$modal.msgSuccess("修改成功")
|
||||
this.open = false
|
||||
this.getList()
|
||||
})
|
||||
} else {
|
||||
addTsj(this.form).then(response => {
|
||||
this.$modal.msgSuccess("新增成功")
|
||||
this.open = false
|
||||
this.getList()
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
/** 删除按钮操作 */
|
||||
handleDelete(row) {
|
||||
const guids = row.guid || this.ids
|
||||
this.$modal.confirm('是否确认删除提升机执行队列编号为"' + guids + '"的数据项?').then(function() {
|
||||
return delTsj(guids)
|
||||
}).then(() => {
|
||||
this.getList()
|
||||
this.$modal.msgSuccess("删除成功")
|
||||
}).catch(() => {})
|
||||
},
|
||||
/** 导出按钮操作 */
|
||||
handleExport() {
|
||||
this.download('queue/tsj/export', {
|
||||
...this.queryParams
|
||||
}, `tsj_${new Date().getTime()}.xlsx`)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
506
ruoyi-ui/src/views/queue/tsjFinish/index.vue
Normal file
506
ruoyi-ui/src/views/queue/tsjFinish/index.vue
Normal file
@@ -0,0 +1,506 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||
<el-form-item label="设备编号" prop="deviceId">
|
||||
<el-input
|
||||
v-model="queryParams.deviceId"
|
||||
placeholder="请输入设备编号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="设备名称" prop="deviceName">
|
||||
<el-input
|
||||
v-model="queryParams.deviceName"
|
||||
placeholder="请输入设备名称"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="任务号" prop="taskNo">
|
||||
<el-input
|
||||
v-model="queryParams.taskNo"
|
||||
placeholder="请输入任务号"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="原排" prop="srcRow">
|
||||
<el-input
|
||||
v-model="queryParams.srcRow"
|
||||
placeholder="请输入原排"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="原列" prop="srcColumn">
|
||||
<el-input
|
||||
v-model="queryParams.srcColumn"
|
||||
placeholder="请输入原列"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="原层" prop="srcLayer">
|
||||
<el-input
|
||||
v-model="queryParams.srcLayer"
|
||||
placeholder="请输入原层"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="目标排" prop="tarRow">
|
||||
<el-input
|
||||
v-model="queryParams.tarRow"
|
||||
placeholder="请输入目标排"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="目标列" prop="tarColumn">
|
||||
<el-input
|
||||
v-model="queryParams.tarColumn"
|
||||
placeholder="请输入目标列"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="目标层" prop="tarLayer">
|
||||
<el-input
|
||||
v-model="queryParams.tarLayer"
|
||||
placeholder="请输入目标层"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="原地址" prop="srcSite">
|
||||
<el-input
|
||||
v-model="queryParams.srcSite"
|
||||
placeholder="请输入原地址"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="目标地址" prop="tarSite">
|
||||
<el-input
|
||||
v-model="queryParams.tarSite"
|
||||
placeholder="请输入目标地址"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="下发" prop="sendFlag">
|
||||
<el-input
|
||||
v-model="queryParams.sendFlag"
|
||||
placeholder="请输入下发"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="下发类型" prop="sendType">
|
||||
<el-input
|
||||
v-model="queryParams.sendType"
|
||||
placeholder="请输入下发类型"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="任务类型" prop="taskType">
|
||||
<el-input
|
||||
v-model="queryParams.taskType"
|
||||
placeholder="请输入任务类型"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备用1" prop="spare1">
|
||||
<el-input
|
||||
v-model="queryParams.spare1"
|
||||
placeholder="请输入备用1"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备用2" prop="spare2">
|
||||
<el-input
|
||||
v-model="queryParams.spare2"
|
||||
placeholder="请输入备用2"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="备用3" prop="spare3">
|
||||
<el-input
|
||||
v-model="queryParams.spare3"
|
||||
placeholder="请输入备用3"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="1-空车任务 2-载车任务" prop="rwlx">
|
||||
<el-select v-model="queryParams.rwlx" placeholder="请选择1-空车任务 2-载车任务" clearable>
|
||||
<el-option
|
||||
v-for="dict in dict.type.tsj_rwlx"
|
||||
:key="dict.value"
|
||||
:label="dict.label"
|
||||
:value="dict.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="primary"
|
||||
plain
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="handleAdd"
|
||||
v-hasPermi="['queue:tsjFinish:add']"
|
||||
>新增</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="success"
|
||||
plain
|
||||
icon="el-icon-edit"
|
||||
size="mini"
|
||||
:disabled="single"
|
||||
@click="handleUpdate"
|
||||
v-hasPermi="['queue:tsjFinish:edit']"
|
||||
>修改</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="danger"
|
||||
plain
|
||||
icon="el-icon-delete"
|
||||
size="mini"
|
||||
:disabled="multiple"
|
||||
@click="handleDelete"
|
||||
v-hasPermi="['queue:tsjFinish:remove']"
|
||||
>删除</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="warning"
|
||||
plain
|
||||
icon="el-icon-download"
|
||||
size="mini"
|
||||
@click="handleExport"
|
||||
v-hasPermi="['queue:tsjFinish:export']"
|
||||
>导出</el-button>
|
||||
</el-col>
|
||||
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="tsjFinishList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="GUID" align="center" prop="guid" />
|
||||
<el-table-column label="设备编号" align="center" prop="deviceId" />
|
||||
<el-table-column label="设备名称" align="center" prop="deviceName" />
|
||||
<el-table-column label="任务号" align="center" prop="taskNo" />
|
||||
<el-table-column label="原排" align="center" prop="srcRow" />
|
||||
<el-table-column label="原列" align="center" prop="srcColumn" />
|
||||
<el-table-column label="原层" align="center" prop="srcLayer" />
|
||||
<el-table-column label="目标排" align="center" prop="tarRow" />
|
||||
<el-table-column label="目标列" align="center" prop="tarColumn" />
|
||||
<el-table-column label="目标层" align="center" prop="tarLayer" />
|
||||
<el-table-column label="原地址" align="center" prop="srcSite" />
|
||||
<el-table-column label="目标地址" align="center" prop="tarSite" />
|
||||
<el-table-column label="下发" align="center" prop="sendFlag" />
|
||||
<el-table-column label="下发类型" align="center" prop="sendType" />
|
||||
<el-table-column label="任务类型" align="center" prop="taskType" />
|
||||
<el-table-column label="创建时间" align="center" prop="createDate" />
|
||||
<el-table-column label="开始时间" align="center" prop="startDate" />
|
||||
<el-table-column label="完成时间" align="center" prop="finishDate" />
|
||||
<el-table-column label="备用1" align="center" prop="spare1" />
|
||||
<el-table-column label="备用2" align="center" prop="spare2" />
|
||||
<el-table-column label="备用3" align="center" prop="spare3" />
|
||||
<el-table-column label="1-空车任务 2-载车任务" align="center" prop="rwlx">
|
||||
<template slot-scope="scope">
|
||||
<dict-tag :options="dict.type.tsj_rwlx" :value="scope.row.rwlx"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-edit"
|
||||
@click="handleUpdate(scope.row)"
|
||||
v-hasPermi="['queue:tsjFinish:edit']"
|
||||
>修改</el-button>
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@click="handleDelete(scope.row)"
|
||||
v-hasPermi="['queue:tsjFinish:remove']"
|
||||
>删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<pagination
|
||||
v-show="total>0"
|
||||
:total="total"
|
||||
:page.sync="queryParams.pageNum"
|
||||
:limit.sync="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
|
||||
<!-- 添加或修改提升机执行队列对话框 -->
|
||||
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||
<el-form-item label="设备编号" prop="deviceId">
|
||||
<el-input v-model="form.deviceId" placeholder="请输入设备编号" />
|
||||
</el-form-item>
|
||||
<el-form-item label="设备名称" prop="deviceName">
|
||||
<el-input v-model="form.deviceName" placeholder="请输入设备名称" />
|
||||
</el-form-item>
|
||||
<el-form-item label="任务号" prop="taskNo">
|
||||
<el-input v-model="form.taskNo" placeholder="请输入任务号" />
|
||||
</el-form-item>
|
||||
<el-form-item label="原排" prop="srcRow">
|
||||
<el-input v-model="form.srcRow" placeholder="请输入原排" />
|
||||
</el-form-item>
|
||||
<el-form-item label="原列" prop="srcColumn">
|
||||
<el-input v-model="form.srcColumn" placeholder="请输入原列" />
|
||||
</el-form-item>
|
||||
<el-form-item label="原层" prop="srcLayer">
|
||||
<el-input v-model="form.srcLayer" placeholder="请输入原层" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目标排" prop="tarRow">
|
||||
<el-input v-model="form.tarRow" placeholder="请输入目标排" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目标列" prop="tarColumn">
|
||||
<el-input v-model="form.tarColumn" placeholder="请输入目标列" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目标层" prop="tarLayer">
|
||||
<el-input v-model="form.tarLayer" placeholder="请输入目标层" />
|
||||
</el-form-item>
|
||||
<el-form-item label="原地址" prop="srcSite">
|
||||
<el-input v-model="form.srcSite" placeholder="请输入原地址" />
|
||||
</el-form-item>
|
||||
<el-form-item label="目标地址" prop="tarSite">
|
||||
<el-input v-model="form.tarSite" placeholder="请输入目标地址" />
|
||||
</el-form-item>
|
||||
<el-form-item label="下发" prop="sendFlag">
|
||||
<el-input v-model="form.sendFlag" placeholder="请输入下发" />
|
||||
</el-form-item>
|
||||
<el-form-item label="下发类型" prop="sendType">
|
||||
<el-input v-model="form.sendType" placeholder="请输入下发类型" />
|
||||
</el-form-item>
|
||||
<el-form-item label="任务类型" prop="taskType">
|
||||
<el-input v-model="form.taskType" placeholder="请输入任务类型" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备用1" prop="spare1">
|
||||
<el-input v-model="form.spare1" placeholder="请输入备用1" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备用2" prop="spare2">
|
||||
<el-input v-model="form.spare2" placeholder="请输入备用2" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备用3" prop="spare3">
|
||||
<el-input v-model="form.spare3" placeholder="请输入备用3" />
|
||||
</el-form-item>
|
||||
<el-form-item label="1-空车任务 2-载车任务" prop="rwlx">
|
||||
<el-select v-model="form.rwlx" placeholder="请选择1-空车任务 2-载车任务">
|
||||
<el-option
|
||||
v-for="dict in dict.type.tsj_rwlx"
|
||||
:key="dict.value"
|
||||
:label="dict.label"
|
||||
:value="dict.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||
<el-button @click="cancel">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { listTsjFinish, getTsjFinish, delTsjFinish, addTsjFinish, updateTsjFinish } from "@/api/queue/tsjFinish"
|
||||
|
||||
export default {
|
||||
name: "TsjFinish",
|
||||
dicts: ['tsj_rwlx'],
|
||||
data() {
|
||||
return {
|
||||
// 遮罩层
|
||||
loading: true,
|
||||
// 选中数组
|
||||
ids: [],
|
||||
// 非单个禁用
|
||||
single: true,
|
||||
// 非多个禁用
|
||||
multiple: true,
|
||||
// 显示搜索条件
|
||||
showSearch: true,
|
||||
// 总条数
|
||||
total: 0,
|
||||
// 提升机执行队列表格数据
|
||||
tsjFinishList: [],
|
||||
// 弹出层标题
|
||||
title: "",
|
||||
// 是否显示弹出层
|
||||
open: false,
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
deviceId: null,
|
||||
deviceName: null,
|
||||
taskNo: null,
|
||||
srcRow: null,
|
||||
srcColumn: null,
|
||||
srcLayer: null,
|
||||
tarRow: null,
|
||||
tarColumn: null,
|
||||
tarLayer: null,
|
||||
srcSite: null,
|
||||
tarSite: null,
|
||||
sendFlag: null,
|
||||
sendType: null,
|
||||
taskType: null,
|
||||
createDate: null,
|
||||
startDate: null,
|
||||
finishDate: null,
|
||||
spare1: null,
|
||||
spare2: null,
|
||||
spare3: null,
|
||||
rwlx: null
|
||||
},
|
||||
// 表单参数
|
||||
form: {},
|
||||
// 表单校验
|
||||
rules: {
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getList()
|
||||
},
|
||||
methods: {
|
||||
/** 查询提升机执行队列列表 */
|
||||
getList() {
|
||||
this.loading = true
|
||||
listTsjFinish(this.queryParams).then(response => {
|
||||
this.tsjFinishList = response.rows
|
||||
this.total = response.total
|
||||
this.loading = false
|
||||
})
|
||||
},
|
||||
// 取消按钮
|
||||
cancel() {
|
||||
this.open = false
|
||||
this.reset()
|
||||
},
|
||||
// 表单重置
|
||||
reset() {
|
||||
this.form = {
|
||||
guid: null,
|
||||
deviceId: null,
|
||||
deviceName: null,
|
||||
taskNo: null,
|
||||
srcRow: null,
|
||||
srcColumn: null,
|
||||
srcLayer: null,
|
||||
tarRow: null,
|
||||
tarColumn: null,
|
||||
tarLayer: null,
|
||||
srcSite: null,
|
||||
tarSite: null,
|
||||
sendFlag: null,
|
||||
sendType: null,
|
||||
taskType: null,
|
||||
createDate: null,
|
||||
startDate: null,
|
||||
finishDate: null,
|
||||
spare1: null,
|
||||
spare2: null,
|
||||
spare3: null,
|
||||
rwlx: null
|
||||
}
|
||||
this.resetForm("form")
|
||||
},
|
||||
/** 搜索按钮操作 */
|
||||
handleQuery() {
|
||||
this.queryParams.pageNum = 1
|
||||
this.getList()
|
||||
},
|
||||
/** 重置按钮操作 */
|
||||
resetQuery() {
|
||||
this.resetForm("queryForm")
|
||||
this.handleQuery()
|
||||
},
|
||||
// 多选框选中数据
|
||||
handleSelectionChange(selection) {
|
||||
this.ids = selection.map(item => item.guid)
|
||||
this.single = selection.length!==1
|
||||
this.multiple = !selection.length
|
||||
},
|
||||
/** 新增按钮操作 */
|
||||
handleAdd() {
|
||||
this.reset()
|
||||
this.open = true
|
||||
this.title = "添加提升机执行队列"
|
||||
},
|
||||
/** 修改按钮操作 */
|
||||
handleUpdate(row) {
|
||||
this.reset()
|
||||
const guid = row.guid || this.ids
|
||||
getTsjFinish(guid).then(response => {
|
||||
this.form = response.data
|
||||
this.open = true
|
||||
this.title = "修改提升机执行队列"
|
||||
})
|
||||
},
|
||||
/** 提交按钮 */
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (valid) {
|
||||
if (this.form.guid != null) {
|
||||
updateTsjFinish(this.form).then(response => {
|
||||
this.$modal.msgSuccess("修改成功")
|
||||
this.open = false
|
||||
this.getList()
|
||||
})
|
||||
} else {
|
||||
addTsjFinish(this.form).then(response => {
|
||||
this.$modal.msgSuccess("新增成功")
|
||||
this.open = false
|
||||
this.getList()
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
/** 删除按钮操作 */
|
||||
handleDelete(row) {
|
||||
const guids = row.guid || this.ids
|
||||
this.$modal.confirm('是否确认删除提升机执行队列编号为"' + guids + '"的数据项?').then(function() {
|
||||
return delTsjFinish(guids)
|
||||
}).then(() => {
|
||||
this.getList()
|
||||
this.$modal.msgSuccess("删除成功")
|
||||
}).catch(() => {})
|
||||
},
|
||||
/** 导出按钮操作 */
|
||||
handleExport() {
|
||||
this.download('queue/tsjFinish/export', {
|
||||
...this.queryParams
|
||||
}, `tsjFinish_${new Date().getTime()}.xlsx`)
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
Reference in New Issue
Block a user