parent
0a254d39a4
commit
83fbf6edc8
@ -0,0 +1,127 @@
|
|||||||
|
package com.ruoyi.web.controller.basic;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.ui.ModelMap;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.system.domain.RecordError;
|
||||||
|
import com.ruoyi.system.service.IRecordErrorService;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 异常记录Controller
|
||||||
|
*
|
||||||
|
* @author Frank zhou
|
||||||
|
* @date 2021-09-16
|
||||||
|
*/
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/system/recorderror")
|
||||||
|
public class RecordErrorController extends BaseController
|
||||||
|
{
|
||||||
|
private String prefix = "system/recorderror";
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IRecordErrorService recordErrorService;
|
||||||
|
|
||||||
|
@RequiresPermissions("system:recorderror:view")
|
||||||
|
@GetMapping()
|
||||||
|
public String recorderror()
|
||||||
|
{
|
||||||
|
return prefix + "/recorderror";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询异常记录列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("system:recorderror:list")
|
||||||
|
@PostMapping("/list")
|
||||||
|
@ResponseBody
|
||||||
|
public TableDataInfo list(RecordError recordError)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
recordError.setTaskStatus(Long.valueOf(4));
|
||||||
|
List<RecordError> list = recordErrorService.selectRecordErrorList(recordError);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出异常记录列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("system:recorderror:export")
|
||||||
|
@Log(title = "异常记录", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult export(RecordError recordError)
|
||||||
|
{
|
||||||
|
List<RecordError> list = recordErrorService.selectRecordErrorList(recordError);
|
||||||
|
ExcelUtil<RecordError> util = new ExcelUtil<RecordError>(RecordError.class);
|
||||||
|
return util.exportExcel(list, "异常记录数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增异常记录
|
||||||
|
*/
|
||||||
|
@GetMapping("/add")
|
||||||
|
public String add()
|
||||||
|
{
|
||||||
|
return prefix + "/add";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增保存异常记录
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("system:recorderror:add")
|
||||||
|
@Log(title = "异常记录", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping("/add")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult addSave(RecordError recordError)
|
||||||
|
{
|
||||||
|
return toAjax(recordErrorService.insertRecordError(recordError));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改异常记录
|
||||||
|
*/
|
||||||
|
@GetMapping("/edit/{objid}")
|
||||||
|
public String edit(@PathVariable("objid") String objid, ModelMap mmap)
|
||||||
|
{
|
||||||
|
RecordError recordError = recordErrorService.selectRecordErrorByObjid(objid);
|
||||||
|
mmap.put("recordError", recordError);
|
||||||
|
return prefix + "/edit";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改保存异常记录
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("system:recorderror:edit")
|
||||||
|
@Log(title = "异常记录", businessType = BusinessType.UPDATE)
|
||||||
|
@PostMapping("/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult editSave(RecordError recordError)
|
||||||
|
{
|
||||||
|
return toAjax(recordErrorService.updateRecordError(recordError));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除异常记录
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("system:recorderror:remove")
|
||||||
|
@Log(title = "异常记录", businessType = BusinessType.DELETE)
|
||||||
|
@PostMapping( "/remove")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult remove(String ids)
|
||||||
|
{
|
||||||
|
return toAjax(recordErrorService.deleteRecordErrorByObjids(ids));
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,140 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('新增异常记录')" />
|
||||||
|
<th:block th:include="include :: datetimepicker-css" />
|
||||||
|
</head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-recorderror-add">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">任务编号:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="taskCode" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">箱体编码:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="boxCode" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">门体/物料编码:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="materialCode" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">物料类型:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="materialType" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">仓库编码:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="storeCode" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">库位编码:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="locationCode" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">库位区域:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="locationArea" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">操作类型:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="operationType" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">任务类型:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="taskType" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">任务状态:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<select name="taskStatus" class="form-control m-b" th:with="type=${@dict.getType('location_status')}">
|
||||||
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">返回标识:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="returnFlag" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">开始时间:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<div class="input-group date">
|
||||||
|
<input name="beginTime" class="form-control" placeholder="yyyy-MM-dd" type="text">
|
||||||
|
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">结束时间:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<div class="input-group date">
|
||||||
|
<input name="endTime" class="form-control" placeholder="yyyy-MM-dd" type="text">
|
||||||
|
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">记录时间:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<div class="input-group date">
|
||||||
|
<input name="recordTime" class="form-control" placeholder="yyyy-MM-dd" type="text">
|
||||||
|
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<th:block th:include="include :: footer" />
|
||||||
|
<th:block th:include="include :: datetimepicker-js" />
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var prefix = ctx + "system/recorderror"
|
||||||
|
$("#form-recorderror-add").validate({
|
||||||
|
focusCleanup: true
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/add", $('#form-recorderror-add').serialize());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$("input[name='beginTime']").datetimepicker({
|
||||||
|
format: "yyyy-mm-dd",
|
||||||
|
minView: "month",
|
||||||
|
autoclose: true
|
||||||
|
});
|
||||||
|
|
||||||
|
$("input[name='endTime']").datetimepicker({
|
||||||
|
format: "yyyy-mm-dd",
|
||||||
|
minView: "month",
|
||||||
|
autoclose: true
|
||||||
|
});
|
||||||
|
|
||||||
|
$("input[name='recordTime']").datetimepicker({
|
||||||
|
format: "yyyy-mm-dd",
|
||||||
|
minView: "month",
|
||||||
|
autoclose: true
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
@ -0,0 +1,141 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('修改异常记录')" />
|
||||||
|
<th:block th:include="include :: datetimepicker-css" />
|
||||||
|
</head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-recorderror-edit" th:object="${recordError}">
|
||||||
|
<input name="objid" th:field="*{objid}" type="hidden">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">任务编号:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="taskCode" th:field="*{taskCode}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">箱体编码:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="boxCode" th:field="*{boxCode}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">门体/物料编码:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="materialCode" th:field="*{materialCode}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">物料类型:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="materialType" th:field="*{materialType}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">仓库编码:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="storeCode" th:field="*{storeCode}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">库位编码:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="locationCode" th:field="*{locationCode}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">库位区域:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="locationArea" th:field="*{locationArea}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">操作类型:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="operationType" th:field="*{operationType}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">任务类型:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="taskType" th:field="*{taskType}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">任务状态:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<select name="taskStatus" class="form-control m-b" th:with="type=${@dict.getType('location_status')}">
|
||||||
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{taskStatus}"></option>
|
||||||
|
</select>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">返回标识:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="returnFlag" th:field="*{returnFlag}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">开始时间:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<div class="input-group date">
|
||||||
|
<input name="beginTime" th:value="${#dates.format(recordError.beginTime, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text">
|
||||||
|
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">结束时间:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<div class="input-group date">
|
||||||
|
<input name="endTime" th:value="${#dates.format(recordError.endTime, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text">
|
||||||
|
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">记录时间:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<div class="input-group date">
|
||||||
|
<input name="recordTime" th:value="${#dates.format(recordError.recordTime, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text">
|
||||||
|
<span class="input-group-addon"><i class="fa fa-calendar"></i></span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<th:block th:include="include :: footer" />
|
||||||
|
<th:block th:include="include :: datetimepicker-js" />
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var prefix = ctx + "system/recorderror";
|
||||||
|
$("#form-recorderror-edit").validate({
|
||||||
|
focusCleanup: true
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/edit", $('#form-recorderror-edit').serialize());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$("input[name='beginTime']").datetimepicker({
|
||||||
|
format: "yyyy-mm-dd",
|
||||||
|
minView: "month",
|
||||||
|
autoclose: true
|
||||||
|
});
|
||||||
|
|
||||||
|
$("input[name='endTime']").datetimepicker({
|
||||||
|
format: "yyyy-mm-dd",
|
||||||
|
minView: "month",
|
||||||
|
autoclose: true
|
||||||
|
});
|
||||||
|
|
||||||
|
$("input[name='recordTime']").datetimepicker({
|
||||||
|
format: "yyyy-mm-dd",
|
||||||
|
minView: "month",
|
||||||
|
autoclose: true
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
@ -0,0 +1,197 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('异常记录列表')" />
|
||||||
|
</head>
|
||||||
|
<body class="gray-bg">
|
||||||
|
<div class="container-div">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12 search-collapse">
|
||||||
|
<form id="formId">
|
||||||
|
<div class="select-list">
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
<label>任务编号:</label>
|
||||||
|
<input type="text" name="taskCode"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>箱体编码:</label>
|
||||||
|
<input type="text" name="boxCode"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>门体/物料编码:</label>
|
||||||
|
<input type="text" name="materialCode"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>物料类型:</label>
|
||||||
|
<input type="text" name="materialType"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>仓库编码:</label>
|
||||||
|
<input type="text" name="storeCode"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>库位编码:</label>
|
||||||
|
<input type="text" name="locationCode"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>库位区域:</label>
|
||||||
|
<input type="text" name="locationArea"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>操作类型:</label>
|
||||||
|
<input type="text" name="operationType"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>任务类型:</label>
|
||||||
|
<input type="text" name="taskType"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>任务状态:</label>
|
||||||
|
<select name="taskStatus" th:with="type=${@dict.getType('location_status')}">
|
||||||
|
<option value="">所有</option>
|
||||||
|
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
|
||||||
|
</select>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>返回标识:</label>
|
||||||
|
<input type="text" name="returnFlag"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>开始时间:</label>
|
||||||
|
<input type="text" class="time-input" placeholder="请选择开始时间" name="beginTime"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>结束时间:</label>
|
||||||
|
<input type="text" class="time-input" placeholder="请选择结束时间" name="endTime"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>记录时间:</label>
|
||||||
|
<input type="text" class="time-input" placeholder="请选择记录时间" name="recordTime"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||||
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="btn-group-sm" id="toolbar" role="group">
|
||||||
|
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="system:recorderror:add">
|
||||||
|
<i class="fa fa-plus"></i> 添加
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="system:recorderror:edit">
|
||||||
|
<i class="fa fa-edit"></i> 修改
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="system:recorderror:remove">
|
||||||
|
<i class="fa fa-remove"></i> 删除
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="system:recorderror:export">
|
||||||
|
<i class="fa fa-download"></i> 导出
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-12 select-table table-striped">
|
||||||
|
<table id="bootstrap-table"></table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<th:block th:include="include :: footer" />
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var editFlag = [[${@permission.hasPermi('system:recorderror:edit')}]];
|
||||||
|
var removeFlag = [[${@permission.hasPermi('system:recorderror:remove')}]];
|
||||||
|
var taskStatusDatas = [[${@dict.getType('location_status')}]];
|
||||||
|
var prefix = ctx + "system/recorderror";
|
||||||
|
|
||||||
|
$(function() {
|
||||||
|
var options = {
|
||||||
|
url: prefix + "/list",
|
||||||
|
createUrl: prefix + "/add",
|
||||||
|
updateUrl: prefix + "/edit/{id}",
|
||||||
|
removeUrl: prefix + "/remove",
|
||||||
|
exportUrl: prefix + "/export",
|
||||||
|
modalName: "异常记录",
|
||||||
|
columns: [{
|
||||||
|
checkbox: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'objid',
|
||||||
|
title: '主键',
|
||||||
|
visible: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'taskCode',
|
||||||
|
title: '任务编号'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'boxCode',
|
||||||
|
title: '箱体编码'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'materialCode',
|
||||||
|
title: '门体/物料编码'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'materialType',
|
||||||
|
title: '物料类型'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'storeCode',
|
||||||
|
title: '仓库编码'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'locationCode',
|
||||||
|
title: '库位编码'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'locationArea',
|
||||||
|
title: '库位区域'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'operationType',
|
||||||
|
title: '操作类型'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'taskType',
|
||||||
|
title: '任务类型'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'taskStatus',
|
||||||
|
title: '任务状态',
|
||||||
|
formatter: function(value, row, index) {
|
||||||
|
return $.table.selectDictLabel(taskStatusDatas, value);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'returnFlag',
|
||||||
|
title: '返回标识'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'beginTime',
|
||||||
|
title: '开始时间'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'endTime',
|
||||||
|
title: '结束时间'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'recordTime',
|
||||||
|
title: '记录时间'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '操作',
|
||||||
|
align: 'center',
|
||||||
|
formatter: function(value, row, index) {
|
||||||
|
var actions = [];
|
||||||
|
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.objid + '\')"><i class="fa fa-edit"></i>编辑</a> ');
|
||||||
|
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.objid + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||||
|
return actions.join('');
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
};
|
||||||
|
$.table.init(options);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
@ -0,0 +1,238 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
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;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 异常记录对象 record_task
|
||||||
|
*
|
||||||
|
* @author Frank zhou
|
||||||
|
* @date 2021-09-16
|
||||||
|
*/
|
||||||
|
public class RecordError extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private String objid;
|
||||||
|
|
||||||
|
/** 任务编号 */
|
||||||
|
@Excel(name = "任务编号")
|
||||||
|
private String taskCode;
|
||||||
|
|
||||||
|
/** 箱体编码 */
|
||||||
|
@Excel(name = "箱体编码")
|
||||||
|
private String boxCode;
|
||||||
|
|
||||||
|
/** 门体/物料编码 */
|
||||||
|
@Excel(name = "门体/物料编码")
|
||||||
|
private String materialCode;
|
||||||
|
|
||||||
|
/** 物料类型 */
|
||||||
|
@Excel(name = "物料类型")
|
||||||
|
private Long materialType;
|
||||||
|
|
||||||
|
/** 仓库编码 */
|
||||||
|
@Excel(name = "仓库编码")
|
||||||
|
private String storeCode;
|
||||||
|
|
||||||
|
/** 库位编码 */
|
||||||
|
@Excel(name = "库位编码")
|
||||||
|
private String locationCode;
|
||||||
|
|
||||||
|
/** 库位区域 */
|
||||||
|
@Excel(name = "库位区域")
|
||||||
|
private String locationArea;
|
||||||
|
|
||||||
|
/** 操作类型 */
|
||||||
|
@Excel(name = "操作类型")
|
||||||
|
private Long operationType;
|
||||||
|
|
||||||
|
/** 任务类型 */
|
||||||
|
@Excel(name = "任务类型")
|
||||||
|
private Long taskType;
|
||||||
|
|
||||||
|
/** 任务状态 */
|
||||||
|
@Excel(name = "任务状态")
|
||||||
|
private Long taskStatus;
|
||||||
|
|
||||||
|
/** 返回标识 */
|
||||||
|
@Excel(name = "返回标识")
|
||||||
|
private String returnFlag;
|
||||||
|
|
||||||
|
/** 开始时间 */
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||||
|
private Date beginTime;
|
||||||
|
|
||||||
|
/** 结束时间 */
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||||
|
private Date endTime;
|
||||||
|
|
||||||
|
/** 记录时间 */
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Excel(name = "记录时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||||
|
private Date recordTime;
|
||||||
|
|
||||||
|
public void setObjid(String objid)
|
||||||
|
{
|
||||||
|
this.objid = objid;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getObjid()
|
||||||
|
{
|
||||||
|
return objid;
|
||||||
|
}
|
||||||
|
public void setTaskCode(String taskCode)
|
||||||
|
{
|
||||||
|
this.taskCode = taskCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTaskCode()
|
||||||
|
{
|
||||||
|
return taskCode;
|
||||||
|
}
|
||||||
|
public void setBoxCode(String boxCode)
|
||||||
|
{
|
||||||
|
this.boxCode = boxCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getBoxCode()
|
||||||
|
{
|
||||||
|
return boxCode;
|
||||||
|
}
|
||||||
|
public void setMaterialCode(String materialCode)
|
||||||
|
{
|
||||||
|
this.materialCode = materialCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMaterialCode()
|
||||||
|
{
|
||||||
|
return materialCode;
|
||||||
|
}
|
||||||
|
public void setMaterialType(Long materialType)
|
||||||
|
{
|
||||||
|
this.materialType = materialType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getMaterialType()
|
||||||
|
{
|
||||||
|
return materialType;
|
||||||
|
}
|
||||||
|
public void setStoreCode(String storeCode)
|
||||||
|
{
|
||||||
|
this.storeCode = storeCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getStoreCode()
|
||||||
|
{
|
||||||
|
return storeCode;
|
||||||
|
}
|
||||||
|
public void setLocationCode(String locationCode)
|
||||||
|
{
|
||||||
|
this.locationCode = locationCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLocationCode()
|
||||||
|
{
|
||||||
|
return locationCode;
|
||||||
|
}
|
||||||
|
public void setLocationArea(String locationArea)
|
||||||
|
{
|
||||||
|
this.locationArea = locationArea;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getLocationArea()
|
||||||
|
{
|
||||||
|
return locationArea;
|
||||||
|
}
|
||||||
|
public void setOperationType(Long operationType)
|
||||||
|
{
|
||||||
|
this.operationType = operationType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getOperationType()
|
||||||
|
{
|
||||||
|
return operationType;
|
||||||
|
}
|
||||||
|
public void setTaskType(Long taskType)
|
||||||
|
{
|
||||||
|
this.taskType = taskType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getTaskType()
|
||||||
|
{
|
||||||
|
return taskType;
|
||||||
|
}
|
||||||
|
public void setTaskStatus(Long taskStatus)
|
||||||
|
{
|
||||||
|
this.taskStatus = taskStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getTaskStatus()
|
||||||
|
{
|
||||||
|
return taskStatus;
|
||||||
|
}
|
||||||
|
public void setReturnFlag(String returnFlag)
|
||||||
|
{
|
||||||
|
this.returnFlag = returnFlag;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getReturnFlag()
|
||||||
|
{
|
||||||
|
return returnFlag;
|
||||||
|
}
|
||||||
|
public void setBeginTime(Date beginTime)
|
||||||
|
{
|
||||||
|
this.beginTime = beginTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getBeginTime()
|
||||||
|
{
|
||||||
|
return beginTime;
|
||||||
|
}
|
||||||
|
public void setEndTime(Date endTime)
|
||||||
|
{
|
||||||
|
this.endTime = endTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getEndTime()
|
||||||
|
{
|
||||||
|
return endTime;
|
||||||
|
}
|
||||||
|
public void setRecordTime(Date recordTime)
|
||||||
|
{
|
||||||
|
this.recordTime = recordTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getRecordTime()
|
||||||
|
{
|
||||||
|
return recordTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("objid", getObjid())
|
||||||
|
.append("taskCode", getTaskCode())
|
||||||
|
.append("boxCode", getBoxCode())
|
||||||
|
.append("materialCode", getMaterialCode())
|
||||||
|
.append("materialType", getMaterialType())
|
||||||
|
.append("storeCode", getStoreCode())
|
||||||
|
.append("locationCode", getLocationCode())
|
||||||
|
.append("locationArea", getLocationArea())
|
||||||
|
.append("operationType", getOperationType())
|
||||||
|
.append("taskType", getTaskType())
|
||||||
|
.append("taskStatus", getTaskStatus())
|
||||||
|
.append("returnFlag", getReturnFlag())
|
||||||
|
.append("beginTime", getBeginTime())
|
||||||
|
.append("endTime", getEndTime())
|
||||||
|
.append("recordTime", getRecordTime())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,61 @@
|
|||||||
|
package com.ruoyi.system.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.system.domain.RecordError;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 异常记录Mapper接口
|
||||||
|
*
|
||||||
|
* @author Frank zhou
|
||||||
|
* @date 2021-09-16
|
||||||
|
*/
|
||||||
|
public interface RecordErrorMapper
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询异常记录
|
||||||
|
*
|
||||||
|
* @param objid 异常记录主键
|
||||||
|
* @return 异常记录
|
||||||
|
*/
|
||||||
|
public RecordError selectRecordErrorByObjid(String objid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询异常记录列表
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 异常记录集合
|
||||||
|
*/
|
||||||
|
public List<RecordError> selectRecordErrorList(RecordError recordError);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增异常记录
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertRecordError(RecordError recordError);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改异常记录
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateRecordError(RecordError recordError);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除异常记录
|
||||||
|
*
|
||||||
|
* @param objid 异常记录主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteRecordErrorByObjid(String objid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除异常记录
|
||||||
|
*
|
||||||
|
* @param objids 需要删除的数据主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteRecordErrorByObjids(String[] objids);
|
||||||
|
}
|
@ -0,0 +1,61 @@
|
|||||||
|
package com.ruoyi.system.service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.system.domain.RecordError;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 异常记录Service接口
|
||||||
|
*
|
||||||
|
* @author Frank zhou
|
||||||
|
* @date 2021-09-16
|
||||||
|
*/
|
||||||
|
public interface IRecordErrorService
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询异常记录
|
||||||
|
*
|
||||||
|
* @param objid 异常记录主键
|
||||||
|
* @return 异常记录
|
||||||
|
*/
|
||||||
|
public RecordError selectRecordErrorByObjid(String objid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询异常记录列表
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 异常记录集合
|
||||||
|
*/
|
||||||
|
public List<RecordError> selectRecordErrorList(RecordError recordError);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增异常记录
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertRecordError(RecordError recordError);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改异常记录
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateRecordError(RecordError recordError);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除异常记录
|
||||||
|
*
|
||||||
|
* @param objids 需要删除的异常记录主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteRecordErrorByObjids(String objids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除异常记录信息
|
||||||
|
*
|
||||||
|
* @param objid 异常记录主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteRecordErrorByObjid(String objid);
|
||||||
|
}
|
@ -0,0 +1,94 @@
|
|||||||
|
package com.ruoyi.system.service.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import com.ruoyi.system.mapper.RecordErrorMapper;
|
||||||
|
import com.ruoyi.system.domain.RecordError;
|
||||||
|
import com.ruoyi.system.service.IRecordErrorService;
|
||||||
|
import com.ruoyi.common.core.text.Convert;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 异常记录Service业务层处理
|
||||||
|
*
|
||||||
|
* @author Frank zhou
|
||||||
|
* @date 2021-09-16
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class RecordErrorServiceImpl implements IRecordErrorService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private RecordErrorMapper recordErrorMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询异常记录
|
||||||
|
*
|
||||||
|
* @param objid 异常记录主键
|
||||||
|
* @return 异常记录
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public RecordError selectRecordErrorByObjid(String objid)
|
||||||
|
{
|
||||||
|
return recordErrorMapper.selectRecordErrorByObjid(objid);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询异常记录列表
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 异常记录
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<RecordError> selectRecordErrorList(RecordError recordError)
|
||||||
|
{
|
||||||
|
return recordErrorMapper.selectRecordErrorList(recordError);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增异常记录
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertRecordError(RecordError recordError)
|
||||||
|
{
|
||||||
|
return recordErrorMapper.insertRecordError(recordError);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改异常记录
|
||||||
|
*
|
||||||
|
* @param recordError 异常记录
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateRecordError(RecordError recordError)
|
||||||
|
{
|
||||||
|
return recordErrorMapper.updateRecordError(recordError);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除异常记录
|
||||||
|
*
|
||||||
|
* @param objids 需要删除的异常记录主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteRecordErrorByObjids(String objids)
|
||||||
|
{
|
||||||
|
return recordErrorMapper.deleteRecordErrorByObjids(Convert.toStrArray(objids));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除异常记录信息
|
||||||
|
*
|
||||||
|
* @param objid 异常记录主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteRecordErrorByObjid(String objid)
|
||||||
|
{
|
||||||
|
return recordErrorMapper.deleteRecordErrorByObjid(objid);
|
||||||
|
}
|
||||||
|
}
|
@ -0,0 +1,126 @@
|
|||||||
|
<?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.system.mapper.RecordErrorMapper">
|
||||||
|
|
||||||
|
<resultMap type="RecordError" id="RecordErrorResult">
|
||||||
|
<result property="objid" column="objid" />
|
||||||
|
<result property="taskCode" column="task_code" />
|
||||||
|
<result property="boxCode" column="box_code" />
|
||||||
|
<result property="materialCode" column="material_code" />
|
||||||
|
<result property="materialType" column="material_type" />
|
||||||
|
<result property="storeCode" column="store_code" />
|
||||||
|
<result property="locationCode" column="location_code" />
|
||||||
|
<result property="locationArea" column="location_area" />
|
||||||
|
<result property="operationType" column="operation_type" />
|
||||||
|
<result property="taskType" column="task_type" />
|
||||||
|
<result property="taskStatus" column="task_status" />
|
||||||
|
<result property="returnFlag" column="return_flag" />
|
||||||
|
<result property="beginTime" column="begin_time" />
|
||||||
|
<result property="endTime" column="end_time" />
|
||||||
|
<result property="recordTime" column="record_time" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectRecordErrorVo">
|
||||||
|
select objid, task_code, box_code, material_code, material_type, store_code, location_code, location_area, operation_type, task_type, task_status, return_flag, begin_time, end_time, record_time from record_task
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectRecordErrorList" parameterType="RecordError" resultMap="RecordErrorResult">
|
||||||
|
<include refid="selectRecordErrorVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="taskCode != null and taskCode != ''"> and task_code like concat(concat('%', #{taskCode}), '%')</if>
|
||||||
|
<if test="boxCode != null and boxCode != ''"> and box_code like concat(concat('%', #{boxCode}), '%')</if>
|
||||||
|
<if test="materialCode != null and materialCode != ''"> and material_code = #{materialCode}</if>
|
||||||
|
<if test="materialType != null "> and material_type = #{materialType}</if>
|
||||||
|
<if test="storeCode != null and storeCode != ''"> and store_code = #{storeCode}</if>
|
||||||
|
<if test="locationCode != null and locationCode != ''"> and location_code = #{locationCode}</if>
|
||||||
|
<if test="locationArea != null and locationArea != ''"> and location_area = #{locationArea}</if>
|
||||||
|
<if test="operationType != null "> and operation_type = #{operationType}</if>
|
||||||
|
<if test="taskType != null "> and task_type = #{taskType}</if>
|
||||||
|
<if test="taskStatus != null "> and task_status = #{taskStatus}</if>
|
||||||
|
<if test="returnFlag != null and returnFlag != ''"> and return_flag = #{returnFlag}</if>
|
||||||
|
<if test="beginTime != null "> and begin_time = #{beginTime}</if>
|
||||||
|
<if test="endTime != null "> and end_time = #{endTime}</if>
|
||||||
|
<if test="recordTime != null "> and record_time = #{recordTime}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectRecordErrorByObjid" parameterType="String" resultMap="RecordErrorResult">
|
||||||
|
<include refid="selectRecordErrorVo"/>
|
||||||
|
where objid = #{objid}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertRecordError" parameterType="RecordError">
|
||||||
|
<selectKey keyProperty="objid" resultType="long" order="BEFORE">
|
||||||
|
SELECT seq_record_task.NEXTVAL as objid FROM DUAL
|
||||||
|
</selectKey>
|
||||||
|
insert into record_task
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="objid != null">objid,</if>
|
||||||
|
<if test="taskCode != null">task_code,</if>
|
||||||
|
<if test="boxCode != null">box_code,</if>
|
||||||
|
<if test="materialCode != null">material_code,</if>
|
||||||
|
<if test="materialType != null">material_type,</if>
|
||||||
|
<if test="storeCode != null">store_code,</if>
|
||||||
|
<if test="locationCode != null">location_code,</if>
|
||||||
|
<if test="locationArea != null">location_area,</if>
|
||||||
|
<if test="operationType != null">operation_type,</if>
|
||||||
|
<if test="taskType != null">task_type,</if>
|
||||||
|
<if test="taskStatus != null">task_status,</if>
|
||||||
|
<if test="returnFlag != null">return_flag,</if>
|
||||||
|
<if test="beginTime != null">begin_time,</if>
|
||||||
|
<if test="endTime != null">end_time,</if>
|
||||||
|
<if test="recordTime != null">record_time,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="objid != null">#{objid},</if>
|
||||||
|
<if test="taskCode != null">#{taskCode},</if>
|
||||||
|
<if test="boxCode != null">#{boxCode},</if>
|
||||||
|
<if test="materialCode != null">#{materialCode},</if>
|
||||||
|
<if test="materialType != null">#{materialType},</if>
|
||||||
|
<if test="storeCode != null">#{storeCode},</if>
|
||||||
|
<if test="locationCode != null">#{locationCode},</if>
|
||||||
|
<if test="locationArea != null">#{locationArea},</if>
|
||||||
|
<if test="operationType != null">#{operationType},</if>
|
||||||
|
<if test="taskType != null">#{taskType},</if>
|
||||||
|
<if test="taskStatus != null">#{taskStatus},</if>
|
||||||
|
<if test="returnFlag != null">#{returnFlag},</if>
|
||||||
|
<if test="beginTime != null">#{beginTime},</if>
|
||||||
|
<if test="endTime != null">#{endTime},</if>
|
||||||
|
<if test="recordTime != null">#{recordTime},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateRecordError" parameterType="RecordError">
|
||||||
|
update record_task
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="taskCode != null">task_code = #{taskCode},</if>
|
||||||
|
<if test="boxCode != null">box_code = #{boxCode},</if>
|
||||||
|
<if test="materialCode != null">material_code = #{materialCode},</if>
|
||||||
|
<if test="materialType != null">material_type = #{materialType},</if>
|
||||||
|
<if test="storeCode != null">store_code = #{storeCode},</if>
|
||||||
|
<if test="locationCode != null">location_code = #{locationCode},</if>
|
||||||
|
<if test="locationArea != null">location_area = #{locationArea},</if>
|
||||||
|
<if test="operationType != null">operation_type = #{operationType},</if>
|
||||||
|
<if test="taskType != null">task_type = #{taskType},</if>
|
||||||
|
<if test="taskStatus != null">task_status = #{taskStatus},</if>
|
||||||
|
<if test="returnFlag != null">return_flag = #{returnFlag},</if>
|
||||||
|
<if test="beginTime != null">begin_time = #{beginTime},</if>
|
||||||
|
<if test="endTime != null">end_time = #{endTime},</if>
|
||||||
|
<if test="recordTime != null">record_time = #{recordTime},</if>
|
||||||
|
</trim>
|
||||||
|
where objid = #{objid}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteRecordErrorByObjid" parameterType="String">
|
||||||
|
delete from record_task where objid = #{objid}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteRecordErrorByObjids" parameterType="String">
|
||||||
|
delete from record_task where objid in
|
||||||
|
<foreach item="objid" collection="array" open="(" separator="," close=")">
|
||||||
|
#{objid}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
Loading…
Reference in New Issue