完成 巡检

master
wangh 7 months ago
parent bb6ec4c7ef
commit d8db57ef15

@ -11,10 +11,7 @@ import static com.ruoyi.common.core.domain.AjaxResult.*;
import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.manage.domain.*;
import com.ruoyi.manage.service.IBaseLocationService;
import com.ruoyi.manage.service.IBaseManufacturerService;
import com.ruoyi.manage.service.IRecordInvalidatedService;
import com.ruoyi.manage.service.IRecordStoreCheckService;
import com.ruoyi.manage.service.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.unit.DataUnit;
@ -139,13 +136,28 @@ public class ApiController {
@PostMapping("/xj/select")
public AjaxResult xjSelect(String user) {
List<LedgerRfid> list = apiService.xjSelect(user);
List<StockDto> list = apiService.xjSelect(user);
if (list == null) {
return error("没有维护巡检区域");
}
return success(list);
}
@Autowired
private IRecordInspectionService inspectionService;
@PostMapping("/xj/submit")
public AjaxResult inspectionSubmit(String json, String user) {
RecordInspection recordInspection = new RecordInspection();
recordInspection.setInspectionUser(user);
int insertNumber = inspectionService.insertRecordInspection(recordInspection);
if (insertNumber == 1) {
List<StockDto> list = JSONObject.parseArray(json, StockDto.class);
apiService.insertInspectionInfo(list,recordInspection.getInspectionId());
}
return success();
}
@PostMapping("/fpin/select")
public AjaxResult fpInSelect(String epc) {
@ -162,9 +174,9 @@ public class ApiController {
}
@PostMapping("/fpin/submit")
public AjaxResult fpInSubmit(String epc,String localtionCode,String user,String bf,String subCode) {
int i=apiService.fpInSubmit(epc,localtionCode,user,bf,subCode);
apiService.updataLedgerIn(epc,subCode);
public AjaxResult fpInSubmit(String epc, String localtionCode, String user, String bf, String subCode) {
int i = apiService.fpInSubmit(epc, localtionCode, user, bf, subCode);
apiService.updataLedgerIn(epc, subCode);
return success();
}
}

@ -10,7 +10,7 @@ public class StockDto {
private String locationCode;
private String state;
private String createTime;
private String remark;
public String getCreateTime() {
return createTime;
}
@ -51,6 +51,14 @@ public class StockDto {
this.locationCode = locationCode;
}
public String getRemark() {
return remark;
}
public void setRemark(String remark) {
this.remark = remark;
}
@Override
public String toString() {
return "StockDto{" + "index=" + index + ", epcCode='" + epcCode + '\'' + ", locationCode='" + locationCode + '\'' + ", state='" + state + '\'' + '}';

@ -27,7 +27,7 @@ public interface ApiMapper {
void insertCheckInfo(@Param("list") List<StockDto> list, @Param("id") Long checkId);
List<LedgerRfid> xjSelect(String user);
List<StockDto> xjSelect(String user);
LedgerRfid bfSelect(String epc);
@ -39,4 +39,6 @@ public interface ApiMapper {
@Param("user") String user, @Param("bf") String bf, @Param("subCode") String subCode);
void updataLedgerIn(@Param("epc") String epc,@Param("code") String locationCode);
void insertInspectionInfo(@Param("list") List<StockDto> list,@Param("id") Long inspectionId);
}

@ -43,7 +43,7 @@ public class ApiService {
mapper.insertCheckInfo(list,checkId);
}
public List<LedgerRfid> xjSelect(String user) {
public List<StockDto> xjSelect(String user) {
return mapper.xjSelect(user);
}
@ -66,4 +66,8 @@ public class ApiService {
public void updataLedgerIn(String epc, String locationCode) {
mapper.updataLedgerIn(epc,locationCode);
}
public void insertInspectionInfo(List<StockDto> list, Long inspectionId) {
mapper.insertInspectionInfo(list,inspectionId);
}
}

@ -115,4 +115,15 @@
update_time = now()
WHERE rifd_code =#{epc}
</update>
<insert id="insertInspectionInfo" >
INSERT INTO record_inspection_info (inspection_id, epc_code, location_code, inspection_state,
inspection_remark)
VALUES
<foreach collection="list" item="item" separator=",">
(#{id}, #{item.epcCode},#{item.locationCode},#{item.state}, #{item.remark})
</foreach>
</insert>
</mapper>

@ -0,0 +1,127 @@
package com.ruoyi.manage.controller;
import java.util.List;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.manage.domain.RecordInspection;
import com.ruoyi.manage.service.IRecordInspectionService;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.common.core.page.TableDataInfo;
/**
* Controller
*
* @author wangh
* @date 2024-02-18
*/
@Controller
@RequestMapping("/manage/record_inspection")
public class RecordInspectionController extends BaseController
{
private String prefix = "manage/record_inspection";
@Autowired
private IRecordInspectionService recordInspectionService;
@RequiresPermissions("manage:record_inspection:view")
@GetMapping()
public String record_inspection()
{
return prefix + "/record_inspection";
}
/**
*
*/
@RequiresPermissions("manage:record_inspection:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(RecordInspection recordInspection)
{
startPage();
List<RecordInspection> list = recordInspectionService.selectRecordInspectionList(recordInspection);
return getDataTable(list);
}
/**
*
*/
@RequiresPermissions("manage:record_inspection:export")
@Log(title = "巡检记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(RecordInspection recordInspection)
{
List<RecordInspection> list = recordInspectionService.selectRecordInspectionList(recordInspection);
ExcelUtil<RecordInspection> util = new ExcelUtil<RecordInspection>(RecordInspection.class);
return util.exportExcel(list, "巡检记录数据");
}
/**
*
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("manage:record_inspection:add")
@Log(title = "巡检记录", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(RecordInspection recordInspection)
{
return toAjax(recordInspectionService.insertRecordInspection(recordInspection));
}
/**
*
*/
@RequiresPermissions("manage:record_inspection:edit")
@GetMapping("/edit/{inspectionId}")
public String edit(@PathVariable("inspectionId") Long inspectionId, ModelMap mmap)
{
RecordInspection recordInspection = recordInspectionService.selectRecordInspectionByInspectionId(inspectionId);
mmap.put("recordInspection", recordInspection);
return prefix + "/edit";
}
/**
*
*/
@RequiresPermissions("manage:record_inspection:edit")
@Log(title = "巡检记录", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(RecordInspection recordInspection)
{
return toAjax(recordInspectionService.updateRecordInspection(recordInspection));
}
/**
*
*/
@RequiresPermissions("manage:record_inspection:remove")
@Log(title = "巡检记录", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(recordInspectionService.deleteRecordInspectionByInspectionIds(ids));
}
}

@ -0,0 +1,127 @@
package com.ruoyi.manage.controller;
import java.util.List;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.ruoyi.common.annotation.Log;
import com.ruoyi.common.enums.BusinessType;
import com.ruoyi.manage.domain.RecordInspectionInfo;
import com.ruoyi.manage.service.IRecordInspectionInfoService;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.utils.poi.ExcelUtil;
import com.ruoyi.common.core.page.TableDataInfo;
/**
* Controller
*
* @author wangh
* @date 2024-02-18
*/
@Controller
@RequestMapping("/manage/record_inspection_info")
public class RecordInspectionInfoController extends BaseController
{
private String prefix = "manage/record_inspection_info";
@Autowired
private IRecordInspectionInfoService recordInspectionInfoService;
@RequiresPermissions("manage:record_inspection_info:view")
@GetMapping()
public String record_inspection_info()
{
return prefix + "/record_inspection_info";
}
/**
*
*/
@RequiresPermissions("manage:record_inspection_info:list")
@PostMapping("/list")
@ResponseBody
public TableDataInfo list(RecordInspectionInfo recordInspectionInfo)
{
startPage();
List<RecordInspectionInfo> list = recordInspectionInfoService.selectRecordInspectionInfoList(recordInspectionInfo);
return getDataTable(list);
}
/**
*
*/
@RequiresPermissions("manage:record_inspection_info:export")
@Log(title = "盘点数据记录", businessType = BusinessType.EXPORT)
@PostMapping("/export")
@ResponseBody
public AjaxResult export(RecordInspectionInfo recordInspectionInfo)
{
List<RecordInspectionInfo> list = recordInspectionInfoService.selectRecordInspectionInfoList(recordInspectionInfo);
ExcelUtil<RecordInspectionInfo> util = new ExcelUtil<RecordInspectionInfo>(RecordInspectionInfo.class);
return util.exportExcel(list, "盘点数据记录数据");
}
/**
*
*/
@GetMapping("/add")
public String add()
{
return prefix + "/add";
}
/**
*
*/
@RequiresPermissions("manage:record_inspection_info:add")
@Log(title = "盘点数据记录", businessType = BusinessType.INSERT)
@PostMapping("/add")
@ResponseBody
public AjaxResult addSave(RecordInspectionInfo recordInspectionInfo)
{
return toAjax(recordInspectionInfoService.insertRecordInspectionInfo(recordInspectionInfo));
}
/**
*
*/
@RequiresPermissions("manage:record_inspection_info:edit")
@GetMapping("/edit/{inspectionId}")
public String edit(@PathVariable("inspectionId") Long inspectionId, ModelMap mmap)
{
RecordInspectionInfo recordInspectionInfo = recordInspectionInfoService.selectRecordInspectionInfoByInspectionId(inspectionId);
mmap.put("recordInspectionInfo", recordInspectionInfo);
return prefix + "/edit";
}
/**
*
*/
@RequiresPermissions("manage:record_inspection_info:edit")
@Log(title = "盘点数据记录", businessType = BusinessType.UPDATE)
@PostMapping("/edit")
@ResponseBody
public AjaxResult editSave(RecordInspectionInfo recordInspectionInfo)
{
return toAjax(recordInspectionInfoService.updateRecordInspectionInfo(recordInspectionInfo));
}
/**
*
*/
@RequiresPermissions("manage:record_inspection_info:remove")
@Log(title = "盘点数据记录", businessType = BusinessType.DELETE)
@PostMapping( "/remove")
@ResponseBody
public AjaxResult remove(String ids)
{
return toAjax(recordInspectionInfoService.deleteRecordInspectionInfoByInspectionIds(ids));
}
}

@ -0,0 +1,105 @@
package com.ruoyi.manage.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_inspection
*
* @author wangh
* @date 2024-02-18
*/
public class RecordInspection extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** 主键 */
private Long inspectionId;
/** 巡检时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Excel(name = "巡检时间", width = 30, dateFormat = "yyyy-MM-dd")
private Date inspectionTime;
/** 巡检人 */
@Excel(name = "巡检人")
private String inspectionUser;
private int totalNumber;
private int normalNumber;
private int abnormalNumber;
private int skipNumber;
public void setInspectionId(Long inspectionId)
{
this.inspectionId = inspectionId;
}
public Long getInspectionId()
{
return inspectionId;
}
public void setInspectionTime(Date inspectionTime)
{
this.inspectionTime = inspectionTime;
}
public Date getInspectionTime()
{
return inspectionTime;
}
public void setInspectionUser(String inspectionUser)
{
this.inspectionUser = inspectionUser;
}
public String getInspectionUser()
{
return inspectionUser;
}
public int getTotalNumber() {
return totalNumber;
}
public void setTotalNumber(int totalNumber) {
this.totalNumber = totalNumber;
}
public int getNormalNumber() {
return normalNumber;
}
public void setNormalNumber(int normalNumber) {
this.normalNumber = normalNumber;
}
public int getAbnormalNumber() {
return abnormalNumber;
}
public void setAbnormalNumber(int abnormalNumber) {
this.abnormalNumber = abnormalNumber;
}
public int getSkipNumber() {
return skipNumber;
}
public void setSkipNumber(int skipNumber) {
this.skipNumber = skipNumber;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("inspectionId", getInspectionId())
.append("inspectionTime", getInspectionTime())
.append("inspectionUser", getInspectionUser())
.toString();
}
}

@ -0,0 +1,94 @@
package com.ruoyi.manage.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;
/**
* record_inspection_info
*
* @author wangh
* @date 2024-02-18
*/
public class RecordInspectionInfo extends BaseEntity
{
private static final long serialVersionUID = 1L;
/** 外键 */
@Excel(name = "外键")
private Long inspectionId;
/** RFID */
@Excel(name = "RFID")
private String epcCode;
/** 机位码 */
@Excel(name = "机位码")
private String locationCode;
/** 巡检结果 */
@Excel(name = "巡检结果")
private String inspectionState;
/** 异常原因 */
@Excel(name = "异常原因")
private String inspectionRemark;
public void setInspectionId(Long inspectionId)
{
this.inspectionId = inspectionId;
}
public Long getInspectionId()
{
return inspectionId;
}
public void setEpcCode(String epcCode)
{
this.epcCode = epcCode;
}
public String getEpcCode()
{
return epcCode;
}
public void setLocationCode(String locationCode)
{
this.locationCode = locationCode;
}
public String getLocationCode()
{
return locationCode;
}
public void setInspectionState(String inspectionState)
{
this.inspectionState = inspectionState;
}
public String getInspectionState()
{
return inspectionState;
}
public void setInspectionRemark(String inspectionRemark)
{
this.inspectionRemark = inspectionRemark;
}
public String getInspectionRemark()
{
return inspectionRemark;
}
@Override
public String toString() {
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
.append("inspectionId", getInspectionId())
.append("epcCode", getEpcCode())
.append("locationCode", getLocationCode())
.append("inspectionState", getInspectionState())
.append("inspectionRemark", getInspectionRemark())
.toString();
}
}

@ -0,0 +1,62 @@
package com.ruoyi.manage.mapper;
import java.util.List;
import com.ruoyi.manage.domain.RecordInspectionInfo;
import org.springframework.stereotype.Repository;
/**
* Mapper
*
* @author wangh
* @date 2024-02-18
*/
@Repository
public interface RecordInspectionInfoMapper
{
/**
*
*
* @param inspectionId
* @return
*/
public RecordInspectionInfo selectRecordInspectionInfoByInspectionId(Long inspectionId);
/**
*
*
* @param recordInspectionInfo
* @return
*/
public List<RecordInspectionInfo> selectRecordInspectionInfoList(RecordInspectionInfo recordInspectionInfo);
/**
*
*
* @param recordInspectionInfo
* @return
*/
public int insertRecordInspectionInfo(RecordInspectionInfo recordInspectionInfo);
/**
*
*
* @param recordInspectionInfo
* @return
*/
public int updateRecordInspectionInfo(RecordInspectionInfo recordInspectionInfo);
/**
*
*
* @param inspectionId
* @return
*/
public int deleteRecordInspectionInfoByInspectionId(Long inspectionId);
/**
*
*
* @param inspectionIds
* @return
*/
public int deleteRecordInspectionInfoByInspectionIds(String[] inspectionIds);
}

@ -0,0 +1,62 @@
package com.ruoyi.manage.mapper;
import java.util.List;
import com.ruoyi.manage.domain.RecordInspection;
import org.springframework.stereotype.Repository;
/**
* Mapper
*
* @author wangh
* @date 2024-02-18
*/
@Repository
public interface RecordInspectionMapper
{
/**
*
*
* @param inspectionId
* @return
*/
public RecordInspection selectRecordInspectionByInspectionId(Long inspectionId);
/**
*
*
* @param recordInspection
* @return
*/
public List<RecordInspection> selectRecordInspectionList(RecordInspection recordInspection);
/**
*
*
* @param recordInspection
* @return
*/
public int insertRecordInspection(RecordInspection recordInspection);
/**
*
*
* @param recordInspection
* @return
*/
public int updateRecordInspection(RecordInspection recordInspection);
/**
*
*
* @param inspectionId
* @return
*/
public int deleteRecordInspectionByInspectionId(Long inspectionId);
/**
*
*
* @param inspectionIds
* @return
*/
public int deleteRecordInspectionByInspectionIds(String[] inspectionIds);
}

@ -0,0 +1,61 @@
package com.ruoyi.manage.service;
import java.util.List;
import com.ruoyi.manage.domain.RecordInspectionInfo;
/**
* Service
*
* @author wangh
* @date 2024-02-18
*/
public interface IRecordInspectionInfoService
{
/**
*
*
* @param inspectionId
* @return
*/
public RecordInspectionInfo selectRecordInspectionInfoByInspectionId(Long inspectionId);
/**
*
*
* @param recordInspectionInfo
* @return
*/
public List<RecordInspectionInfo> selectRecordInspectionInfoList(RecordInspectionInfo recordInspectionInfo);
/**
*
*
* @param recordInspectionInfo
* @return
*/
public int insertRecordInspectionInfo(RecordInspectionInfo recordInspectionInfo);
/**
*
*
* @param recordInspectionInfo
* @return
*/
public int updateRecordInspectionInfo(RecordInspectionInfo recordInspectionInfo);
/**
*
*
* @param inspectionIds
* @return
*/
public int deleteRecordInspectionInfoByInspectionIds(String inspectionIds);
/**
*
*
* @param inspectionId
* @return
*/
public int deleteRecordInspectionInfoByInspectionId(Long inspectionId);
}

@ -0,0 +1,61 @@
package com.ruoyi.manage.service;
import java.util.List;
import com.ruoyi.manage.domain.RecordInspection;
/**
* Service
*
* @author wangh
* @date 2024-02-18
*/
public interface IRecordInspectionService
{
/**
*
*
* @param inspectionId
* @return
*/
public RecordInspection selectRecordInspectionByInspectionId(Long inspectionId);
/**
*
*
* @param recordInspection
* @return
*/
public List<RecordInspection> selectRecordInspectionList(RecordInspection recordInspection);
/**
*
*
* @param recordInspection
* @return
*/
public int insertRecordInspection(RecordInspection recordInspection);
/**
*
*
* @param recordInspection
* @return
*/
public int updateRecordInspection(RecordInspection recordInspection);
/**
*
*
* @param inspectionIds
* @return
*/
public int deleteRecordInspectionByInspectionIds(String inspectionIds);
/**
*
*
* @param inspectionId
* @return
*/
public int deleteRecordInspectionByInspectionId(Long inspectionId);
}

@ -0,0 +1,112 @@
package com.ruoyi.manage.service.impl;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.manage.mapper.RecordInspectionInfoMapper;
import com.ruoyi.manage.domain.RecordInspectionInfo;
import com.ruoyi.manage.service.IRecordInspectionInfoService;
import com.ruoyi.common.core.text.Convert;
/**
* Service
*
* @author wangh
* @date 2024-02-18
*/
@Service
public class RecordInspectionInfoServiceImpl implements IRecordInspectionInfoService {
@Autowired
private RecordInspectionInfoMapper recordInspectionInfoMapper;
/**
*
*
* @param inspectionId
* @return
*/
@Override
public RecordInspectionInfo selectRecordInspectionInfoByInspectionId(Long inspectionId) {
return recordInspectionInfoMapper.selectRecordInspectionInfoByInspectionId(inspectionId);
}
/**
*
*
* @param recordInspectionInfo
* @return
*/
@Override
public List<RecordInspectionInfo> selectRecordInspectionInfoList(RecordInspectionInfo recordInspectionInfo) {
return recordInspectionInfoMapper.selectRecordInspectionInfoList(recordInspectionInfo);
}
/**
*
*
* @param recordInspectionInfo
* @return
*/
@Override
public int insertRecordInspectionInfo(RecordInspectionInfo recordInspectionInfo) {
return recordInspectionInfoMapper.insertRecordInspectionInfo(recordInspectionInfo);
}
/**
*
*
* @param recordInspectionInfo
* @return
*/
@Override
public int updateRecordInspectionInfo(RecordInspectionInfo recordInspectionInfo) {
return recordInspectionInfoMapper.updateRecordInspectionInfo(recordInspectionInfo);
}
/**
*
*
* @param inspectionIds
* @return
*/
@Override
public int deleteRecordInspectionInfoByInspectionIds(String inspectionIds) {
return recordInspectionInfoMapper.deleteRecordInspectionInfoByInspectionIds(Convert.toStrArray(inspectionIds));
}
/**
*
*
* @param inspectionId
* @return
*/
@Override
public int deleteRecordInspectionInfoByInspectionId(Long inspectionId) {
return recordInspectionInfoMapper.deleteRecordInspectionInfoByInspectionId(inspectionId);
}
}

@ -0,0 +1,95 @@
package com.ruoyi.manage.service.impl;
import java.util.List;
import com.ruoyi.manage.mapper.RecordInspectionInfoMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.manage.mapper.RecordInspectionMapper;
import com.ruoyi.manage.domain.RecordInspection;
import com.ruoyi.manage.service.IRecordInspectionService;
import com.ruoyi.common.core.text.Convert;
/**
* Service
*
* @author wangh
* @date 2024-02-18
*/
@Service
public class RecordInspectionServiceImpl implements IRecordInspectionService {
@Autowired
private RecordInspectionMapper recordInspectionMapper;
/**
*
*
* @param inspectionId
* @return
*/
@Override
public RecordInspection selectRecordInspectionByInspectionId(Long inspectionId) {
return recordInspectionMapper.selectRecordInspectionByInspectionId(inspectionId);
}
/**
*
*
* @param recordInspection
* @return
*/
@Override
public List<RecordInspection> selectRecordInspectionList(RecordInspection recordInspection) {
return recordInspectionMapper.selectRecordInspectionList(recordInspection);
}
/**
*
*
* @param recordInspection
* @return
*/
@Override
public int insertRecordInspection(RecordInspection recordInspection) {
return recordInspectionMapper.insertRecordInspection(recordInspection);
}
/**
*
*
* @param recordInspection
* @return
*/
@Override
public int updateRecordInspection(RecordInspection recordInspection) {
return recordInspectionMapper.updateRecordInspection(recordInspection);
}
/**
*
*
* @param inspectionIds
* @return
*/
@Autowired
private RecordInspectionInfoMapper infoMapper;
@Override
public int deleteRecordInspectionByInspectionIds(String inspectionIds) {
String[] inspectionIds1 = Convert.toStrArray(inspectionIds);
infoMapper.deleteRecordInspectionInfoByInspectionIds(inspectionIds1);
return recordInspectionMapper.deleteRecordInspectionByInspectionIds(inspectionIds1);
}
/**
*
*
* @param inspectionId
* @return
*/
@Override
public int deleteRecordInspectionByInspectionId(Long inspectionId) {
infoMapper.deleteRecordInspectionInfoByInspectionId(inspectionId);
return recordInspectionMapper.deleteRecordInspectionByInspectionId(inspectionId);
}
}

@ -0,0 +1,22 @@
-- 菜单 SQL
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('巡检记录', '2026', '6', '/manage/record_inspection', 'C', '0', 'manage:record_inspection:view', '#', 'admin', sysdate(), '', null, '巡检记录菜单');
-- 按钮父菜单ID
SELECT @parentId := LAST_INSERT_ID();
-- 按钮 SQL
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('巡检记录查询', @parentId, '1', '#', 'F', '0', 'manage:record_inspection:list', '#', 'admin', sysdate(), '', null, '');
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('巡检记录新增', @parentId, '2', '#', 'F', '0', 'manage:record_inspection:add', '#', 'admin', sysdate(), '', null, '');
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('巡检记录修改', @parentId, '3', '#', 'F', '0', 'manage:record_inspection:edit', '#', 'admin', sysdate(), '', null, '');
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('巡检记录删除', @parentId, '4', '#', 'F', '0', 'manage:record_inspection:remove', '#', 'admin', sysdate(), '', null, '');
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('巡检记录导出', @parentId, '5', '#', 'F', '0', 'manage:record_inspection:export', '#', 'admin', sysdate(), '', null, '');

@ -0,0 +1,22 @@
-- 菜单 SQL
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('盘点数据记录', '2026', '1', '/manage/record_inspection_info', 'C', '0', 'manage:record_inspection_info:view', '#', 'admin', sysdate(), '', null, '盘点数据记录菜单');
-- 按钮父菜单ID
SELECT @parentId := LAST_INSERT_ID();
-- 按钮 SQL
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('盘点数据记录查询', @parentId, '1', '#', 'F', '0', 'manage:record_inspection_info:list', '#', 'admin', sysdate(), '', null, '');
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('盘点数据记录新增', @parentId, '2', '#', 'F', '0', 'manage:record_inspection_info:add', '#', 'admin', sysdate(), '', null, '');
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('盘点数据记录修改', @parentId, '3', '#', 'F', '0', 'manage:record_inspection_info:edit', '#', 'admin', sysdate(), '', null, '');
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('盘点数据记录删除', @parentId, '4', '#', 'F', '0', 'manage:record_inspection_info:remove', '#', 'admin', sysdate(), '', null, '');
insert into sys_menu (menu_name, parent_id, order_num, url, menu_type, visible, perms, icon, create_by, create_time, update_by, update_time, remark)
values('盘点数据记录导出', @parentId, '5', '#', 'F', '0', 'manage:record_inspection_info:export', '#', 'admin', sysdate(), '', null, '');

@ -0,0 +1,75 @@
<?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.manage.mapper.RecordInspectionInfoMapper">
<resultMap type="RecordInspectionInfo" id="RecordInspectionInfoResult">
<result property="inspectionId" column="inspection_id" />
<result property="epcCode" column="epc_code" />
<result property="locationCode" column="location_code" />
<result property="inspectionState" column="inspection_state" />
<result property="inspectionRemark" column="inspection_remark" />
</resultMap>
<sql id="selectRecordInspectionInfoVo">
select inspection_id, epc_code, location_code, inspection_state, inspection_remark from record_inspection_info
</sql>
<select id="selectRecordInspectionInfoList" parameterType="RecordInspectionInfo" resultMap="RecordInspectionInfoResult">
<include refid="selectRecordInspectionInfoVo"/>
<where>
<if test="inspectionId != null "> and inspection_id = #{inspectionId}</if>
<if test="epcCode != null and epcCode != ''"> and epc_code = #{epcCode}</if>
<if test="locationCode != null and locationCode != ''"> and location_code = #{locationCode}</if>
<if test="inspectionState != null and inspectionState != ''"> and inspection_state = #{inspectionState}</if>
<if test="inspectionRemark != null and inspectionRemark != ''"> and inspection_remark = #{inspectionRemark}</if>
</where>
</select>
<select id="selectRecordInspectionInfoByInspectionId" parameterType="Long" resultMap="RecordInspectionInfoResult">
<include refid="selectRecordInspectionInfoVo"/>
where inspection_id = #{inspectionId}
</select>
<insert id="insertRecordInspectionInfo" parameterType="RecordInspectionInfo">
insert into record_inspection_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="inspectionId != null">inspection_id,</if>
<if test="epcCode != null">epc_code,</if>
<if test="locationCode != null">location_code,</if>
<if test="inspectionState != null">inspection_state,</if>
<if test="inspectionRemark != null">inspection_remark,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="inspectionId != null">#{inspectionId},</if>
<if test="epcCode != null">#{epcCode},</if>
<if test="locationCode != null">#{locationCode},</if>
<if test="inspectionState != null">#{inspectionState},</if>
<if test="inspectionRemark != null">#{inspectionRemark},</if>
</trim>
</insert>
<update id="updateRecordInspectionInfo" parameterType="RecordInspectionInfo">
update record_inspection_info
<trim prefix="SET" suffixOverrides=",">
<if test="epcCode != null">epc_code = #{epcCode},</if>
<if test="locationCode != null">location_code = #{locationCode},</if>
<if test="inspectionState != null">inspection_state = #{inspectionState},</if>
<if test="inspectionRemark != null">inspection_remark = #{inspectionRemark},</if>
</trim>
where inspection_id = #{inspectionId}
</update>
<delete id="deleteRecordInspectionInfoByInspectionId" parameterType="Long">
delete from record_inspection_info where inspection_id = #{inspectionId}
</delete>
<delete id="deleteRecordInspectionInfoByInspectionIds" parameterType="String">
delete from record_inspection_info where inspection_id in
<foreach item="inspectionId" collection="array" open="(" separator="," close=")">
#{inspectionId}
</foreach>
</delete>
</mapper>

@ -0,0 +1,81 @@
<?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.manage.mapper.RecordInspectionMapper">
<resultMap type="com.ruoyi.manage.domain.RecordInspection" id="RecordInspectionResult">
<result property="inspectionId" column="inspection_id"/>
<result property="inspectionTime" column="inspection_time"/>
<result property="inspectionUser" column="inspection_user"/>
<result property="totalNumber" column="total_number"/>
<result property="normalNumber" column="normal_number"/>
<result property="abnormalNumber" column="abnormal_number"/>
<result property="skipNumber" column="skip_number"/>
</resultMap>
<sql id="selectRecordInspectionVo">
select inspection_id, inspection_time, inspection_user
from record_inspection
</sql>
<select id="selectRecordInspectionList" parameterType="RecordInspection" resultMap="RecordInspectionResult">
select ri.inspection_id,
inspection_time,
inspection_user,
count(rii.inspection_id) as total_number,
count(if(inspection_state = '正常', true, null)) as normal_number,
count(if(inspection_state = '异常', true, null)) as abnormal_number,
count(if(inspection_state = '跳过', true, null)) as skip_number
from record_inspection ri
left join record_inspection_info rii on ri.inspection_id = rii.inspection_id
<where>
<if test="params.beginInspectionTime != null and params.beginInspectionTime != '' and params.endInspectionTime != null and params.endInspectionTime != ''">
and inspection_time between #{params.beginInspectionTime} and #{params.endInspectionTime}
</if>
<if test="inspectionUser != null ">and inspection_user = #{inspectionUser}</if>
</where>
group by ri.inspection_id
</select>
<select id="selectRecordInspectionByInspectionId" parameterType="Long" resultMap="RecordInspectionResult">
<include refid="selectRecordInspectionVo"/>
where inspection_id = #{inspectionId}
</select>
<insert id="insertRecordInspection" parameterType="RecordInspection" useGeneratedKeys="true"
keyProperty="inspectionId">
insert into record_inspection
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="inspectionTime != null">inspection_time,</if>
<if test="inspectionUser != null">inspection_user,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="inspectionTime != null">#{inspectionTime},</if>
<if test="inspectionUser != null">#{inspectionUser},</if>
</trim>
</insert>
<update id="updateRecordInspection" parameterType="RecordInspection">
update record_inspection
<trim prefix="SET" suffixOverrides=",">
<if test="inspectionTime != null">inspection_time = #{inspectionTime},</if>
<if test="inspectionUser != null">inspection_user = #{inspectionUser},</if>
</trim>
where inspection_id = #{inspectionId}
</update>
<delete id="deleteRecordInspectionByInspectionId" parameterType="Long">
delete
from record_inspection
where inspection_id = #{inspectionId}
</delete>
<delete id="deleteRecordInspectionByInspectionIds" parameterType="String">
delete from record_inspection where inspection_id in
<foreach item="inspectionId" collection="array" open="(" separator="," close=")">
#{inspectionId}
</foreach>
</delete>
</mapper>

@ -0,0 +1,48 @@
<!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-record_inspection-add">
<div class="form-group">
<label class="col-sm-3 control-label">巡检时间:</label>
<div class="col-sm-8">
<div class="input-group date">
<input name="inspectionTime" 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">
<input name="inspectionUser" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "manage/record_inspection"
$("#form-record_inspection-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-record_inspection-add').serialize());
}
}
$("input[name='inspectionTime']").datetimepicker({
format: "yyyy-mm-dd",
minView: "month",
autoclose: true
});
</script>
</body>
</html>

@ -0,0 +1,49 @@
<!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-record_inspection-edit" th:object="${recordInspection}">
<input name="inspectionId" th:field="*{inspectionId}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">巡检时间:</label>
<div class="col-sm-8">
<div class="input-group date">
<input name="inspectionTime" th:value="${#dates.format(recordInspection.inspectionTime, '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">
<input name="inspectionUser" th:field="*{inspectionUser}" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<th:block th:include="include :: datetimepicker-js" />
<script th:inline="javascript">
var prefix = ctx + "manage/record_inspection";
$("#form-record_inspection-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-record_inspection-edit').serialize());
}
}
$("input[name='inspectionTime']").datetimepicker({
format: "yyyy-mm-dd",
minView: "month",
autoclose: true
});
</script>
</body>
</html>

@ -0,0 +1,154 @@
<!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 class="select-time">
<label>巡检时间:</label>
<input type="text" class="time-input" id="startTime" placeholder="开始时间" name="params[beginInspectionTime]"/>
<span>-</span>
<input type="text" class="time-input" id="endTime" placeholder="结束时间" name="params[endInspectionTime]"/>
</li>
<li>
<label>巡检人:</label>
<input type="text" name="inspectionUser"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</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="manage:record_inspection:add">-->
<!-- <i class="fa fa-plus"></i> 添加-->
<!-- </a>-->
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="manage:record_inspection:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="manage:record_inspection:remove">
<i class="fa fa-remove"></i> 删除
</a>
<!-- <a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="manage:record_inspection: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('manage:record_inspection:edit')}]];
var removeFlag = [[${@permission.hasPermi('manage:record_inspection:remove')}]];
var prefix = ctx + "manage/record_inspection";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
exportUrl: prefix + "/export",
modalName: "巡检记录",
detailView: true,
onExpandRow: function (index, row, $detail) {
initinspectionTable(index, row, $detail);
},
columns: [{
checkbox: true
},
{
field: 'inspectionId',
title: '主键',
visible: false
},
{
field: 'inspectionTime',
title: '巡检时间'
},
{
field: 'inspectionUser',
title: '巡检人'
},
{
field: 'totalNumber',
title: '巡检数量'
},
{
field: 'normalNumber',
title: '正常数量'
},
{
field: 'abnormalNumber',
title: '异常数量'
},
{
field: 'skipNumber',
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.inspectionId + '\')"><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.inspectionId + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join('');
}
}*/]
};
$.table.init(options);
});
initinspectionTable = function (index, row, $detail) {
var childTable = $detail.html('<table style="table-layout:fixed"></table>').find('table');
$(childTable).bootstrapTable({
url: ctx + "manage/record_inspection_info/list",
method: 'post',
sidePagination: "server",
contentType: "application/x-www-form-urlencoded",
queryParams: {
inspectionId: row.inspectionId
},
columns: [
{
title: '序号',
formatter: function (value, row, index) {
return index+1
}
},
{
field: 'epcCode',
title: 'RFID'
},
{
field: 'locationCode',
title: '机位码'
},
{
field: 'inspectionState',
title: '巡检结果'
},
{
field: 'inspectionRemark',
title: '异常原因'
}]
});
};
</script>
</body>
</html>

@ -0,0 +1,55 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('新增盘点数据记录')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-record_inspection_info-add">
<div class="form-group">
<label class="col-sm-3 control-label">外键:</label>
<div class="col-sm-8">
<input name="inspectionId" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">RFID</label>
<div class="col-sm-8">
<input name="epcCode" 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="inspectionState" 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="inspectionRemark" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "manage/record_inspection_info"
$("#form-record_inspection_info-add").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/add", $('#form-record_inspection_info-add').serialize());
}
}
</script>
</body>
</html>

@ -0,0 +1,56 @@
<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
<th:block th:include="include :: header('修改盘点数据记录')" />
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-record_inspection_info-edit" th:object="${recordInspectionInfo}">
<input name="inspectionId" th:field="*{inspectionId}" type="hidden">
<div class="form-group">
<label class="col-sm-3 control-label">外键:</label>
<div class="col-sm-8">
<input name="inspectionId" th:field="*{inspectionId}" class="form-control" type="text">
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label">RFID</label>
<div class="col-sm-8">
<input name="epcCode" th:field="*{epcCode}" 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="inspectionState" th:field="*{inspectionState}" 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="inspectionRemark" th:field="*{inspectionRemark}" class="form-control" type="text">
</div>
</div>
</form>
</div>
<th:block th:include="include :: footer" />
<script th:inline="javascript">
var prefix = ctx + "manage/record_inspection_info";
$("#form-record_inspection_info-edit").validate({
focusCleanup: true
});
function submitHandler() {
if ($.validate.form()) {
$.operate.save(prefix + "/edit", $('#form-record_inspection_info-edit').serialize());
}
}
</script>
</body>
</html>

@ -0,0 +1,113 @@
<!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="inspectionId"/>
</li>
<li>
<label>RFID</label>
<input type="text" name="epcCode"/>
</li>
<li>
<label>机位码:</label>
<input type="text" name="locationCode"/>
</li>
<li>
<label>巡检结果:</label>
<input type="text" name="inspectionState"/>
</li>
<li>
<label>异常原因:</label>
<input type="text" name="inspectionRemark"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</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="manage:record_inspection_info:add">
<i class="fa fa-plus"></i> 添加
</a>
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="manage:record_inspection_info:edit">
<i class="fa fa-edit"></i> 修改
</a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="manage:record_inspection_info:remove">
<i class="fa fa-remove"></i> 删除
</a>
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="manage:record_inspection_info: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('manage:record_inspection_info:edit')}]];
var removeFlag = [[${@permission.hasPermi('manage:record_inspection_info:remove')}]];
var prefix = ctx + "manage/record_inspection_info";
$(function() {
var options = {
url: prefix + "/list",
createUrl: prefix + "/add",
updateUrl: prefix + "/edit/{id}",
removeUrl: prefix + "/remove",
exportUrl: prefix + "/export",
modalName: "盘点数据记录",
columns: [{
checkbox: true
},
{
field: 'inspectionId',
title: '外键'
},
{
field: 'epcCode',
title: 'RFID'
},
{
field: 'locationCode',
title: '机位码'
},
{
field: 'inspectionState',
title: '巡检结果'
},
{
field: 'inspectionRemark',
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.inspectionId + '\')"><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.inspectionId + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join('');
}
}]
};
$.table.init(options);
});
</script>
</body>
</html>

@ -11,7 +11,7 @@
<div class="select-list">
<ul>
<li>
<label>RFID编码</label>
<label>RFID</label>
<input type="text" name="epcCode"/>
</li>
<li>

Loading…
Cancel
Save