入库
This commit is contained in:
parent
af51ca8da4
commit
a5a6325bd5
|
|
@ -5,6 +5,7 @@ import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import com.ruoyi.app.domain.AppGoods;
|
import com.ruoyi.app.domain.AppGoods;
|
||||||
import com.ruoyi.app.service.IAppGoodsService;
|
import com.ruoyi.app.service.IAppGoodsService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -40,6 +41,7 @@ public class AppGoodsController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:goods:list')")
|
@PreAuthorize("@ss.hasPermi('system:goods:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppGoods.class)
|
||||||
public TableDataInfo list(AppGoods appGoods)
|
public TableDataInfo list(AppGoods appGoods)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppGoods;
|
||||||
import com.ruoyi.app.domain.AppGoodsPair;
|
import com.ruoyi.app.domain.AppGoodsPair;
|
||||||
import com.ruoyi.app.service.IAppGoodsPairService;
|
import com.ruoyi.app.service.IAppGoodsPairService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -29,7 +31,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
* @date 2025-01-15
|
* @date 2025-01-15
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/app/goodsPair")
|
@RequestMapping("/app/pair")
|
||||||
public class AppGoodsPairController extends BaseController
|
public class AppGoodsPairController extends BaseController
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppGoodsPairController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:pair:list')")
|
@PreAuthorize("@ss.hasPermi('system:pair:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppGoodsPair.class)
|
||||||
public TableDataInfo list(AppGoodsPair appGoodsPair)
|
public TableDataInfo list(AppGoodsPair appGoodsPair)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppGoodsPair;
|
||||||
import com.ruoyi.app.domain.AppLedConfig;
|
import com.ruoyi.app.domain.AppLedConfig;
|
||||||
import com.ruoyi.app.service.IAppLedConfigService;
|
import com.ruoyi.app.service.IAppLedConfigService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -29,7 +31,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
* @date 2025-01-15
|
* @date 2025-01-15
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/app/ledConfig")
|
@RequestMapping("/app/led")
|
||||||
public class AppLedConfigController extends BaseController
|
public class AppLedConfigController extends BaseController
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppLedConfigController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:config:list')")
|
@PreAuthorize("@ss.hasPermi('system:config:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppLedConfig.class)
|
||||||
public TableDataInfo list(AppLedConfig appLedConfig)
|
public TableDataInfo list(AppLedConfig appLedConfig)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -4,10 +4,12 @@ import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppLedConfig;
|
||||||
import com.ruoyi.app.domain.AppLocation;
|
import com.ruoyi.app.domain.AppLocation;
|
||||||
import com.ruoyi.app.service.IAppLocationService;
|
import com.ruoyi.app.service.IAppLocationService;
|
||||||
import com.ruoyi.common.annotation.Anonymous;
|
import com.ruoyi.common.annotation.Anonymous;
|
||||||
import com.ruoyi.common.utils.StringUtils;
|
import com.ruoyi.common.utils.StringUtils;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
|
@ -46,6 +48,7 @@ public class AppLocationController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:location:list')")
|
@PreAuthorize("@ss.hasPermi('system:location:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppLocation.class)
|
||||||
public TableDataInfo list(AppLocation appLocation)
|
public TableDataInfo list(AppLocation appLocation)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,106 @@
|
||||||
|
package com.ruoyi.web.controller.app;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppPendingStorage;
|
||||||
|
import com.ruoyi.app.service.IAppPendingStorageService;
|
||||||
|
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.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 入库码盘Controller
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2025-02-22
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/system/storage")
|
||||||
|
public class AppPendingStorageController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private IAppPendingStorageService appPendingStorageService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询入库码盘列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:storage:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(AppPendingStorage appPendingStorage)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<AppPendingStorage> list = appPendingStorageService.selectAppPendingStorageList(appPendingStorage);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出入库码盘列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:storage:export')")
|
||||||
|
@Log(title = "入库码盘", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
public void export(HttpServletResponse response, AppPendingStorage appPendingStorage)
|
||||||
|
{
|
||||||
|
List<AppPendingStorage> list = appPendingStorageService.selectAppPendingStorageList(appPendingStorage);
|
||||||
|
ExcelUtil<AppPendingStorage> util = new ExcelUtil<AppPendingStorage>(AppPendingStorage.class);
|
||||||
|
util.exportExcel(response, list, "入库码盘数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取入库码盘详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:storage:query')")
|
||||||
|
@GetMapping(value = "/{recordId}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("recordId") String recordId)
|
||||||
|
{
|
||||||
|
return success(appPendingStorageService.selectAppPendingStorageByRecordId(recordId));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增入库码盘
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:storage:add')")
|
||||||
|
@Log(title = "入库码盘", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody AppPendingStorage appPendingStorage)
|
||||||
|
{
|
||||||
|
return toAjax(appPendingStorageService.insertAppPendingStorage(appPendingStorage));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改入库码盘
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:storage:edit')")
|
||||||
|
@Log(title = "入库码盘", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody AppPendingStorage appPendingStorage)
|
||||||
|
{
|
||||||
|
return toAjax(appPendingStorageService.updateAppPendingStorage(appPendingStorage));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除入库码盘
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:storage:remove')")
|
||||||
|
@Log(title = "入库码盘", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{recordIds}")
|
||||||
|
public AjaxResult remove(@PathVariable String[] recordIds)
|
||||||
|
{
|
||||||
|
return toAjax(appPendingStorageService.deleteAppPendingStorageByRecordIds(recordIds));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,14 +1,17 @@
|
||||||
package com.ruoyi.web.controller.app;
|
package com.ruoyi.web.controller.app;
|
||||||
|
|
||||||
import com.ruoyi.app.domain.AppLocation;
|
import com.ruoyi.app.domain.AppLocation;
|
||||||
|
import com.ruoyi.app.domain.AppPendingStorage;
|
||||||
import com.ruoyi.app.domain.AppPmsOrderIn;
|
import com.ruoyi.app.domain.AppPmsOrderIn;
|
||||||
import com.ruoyi.app.domain.AppTask;
|
import com.ruoyi.app.domain.AppTask;
|
||||||
|
import com.ruoyi.app.service.IAppPendingStorageService;
|
||||||
import com.ruoyi.app.service.IAppPmsOrderInService;
|
import com.ruoyi.app.service.IAppPmsOrderInService;
|
||||||
import com.ruoyi.app.service.IAppPmsOrderOutService;
|
import com.ruoyi.app.service.IAppPmsOrderOutService;
|
||||||
import com.ruoyi.common.annotation.Anonymous;
|
import com.ruoyi.common.annotation.Anonymous;
|
||||||
import com.ruoyi.common.annotation.Log;
|
import com.ruoyi.common.annotation.Log;
|
||||||
import com.ruoyi.common.core.controller.BaseController;
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
import com.ruoyi.common.core.page.TableDataInfo;
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
import com.ruoyi.common.enums.BusinessType;
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
import com.ruoyi.common.enums.OperatorType;
|
import com.ruoyi.common.enums.OperatorType;
|
||||||
|
|
@ -17,14 +20,14 @@ import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
import com.ruoyi.web.domain.PmsOrderInRequest;
|
import com.ruoyi.web.domain.PmsOrderInRequest;
|
||||||
import com.ruoyi.web.domain.PmsOrderOutRequest;
|
import com.ruoyi.web.domain.PmsOrderOutRequest;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.web.bind.annotation.*;
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
import java.util.ArrayList;
|
import java.math.BigDecimal;
|
||||||
import java.util.Arrays;
|
import java.util.*;
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 【请填写功能名称】Controller
|
* 【请填写功能名称】Controller
|
||||||
|
|
@ -41,6 +44,9 @@ public class AppPmsController extends BaseController
|
||||||
@Autowired
|
@Autowired
|
||||||
private IAppPmsOrderOutService appPmsOrderOutService;// 出库单
|
private IAppPmsOrderOutService appPmsOrderOutService;// 出库单
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IAppPendingStorageService appPendingStorageService;
|
||||||
|
|
||||||
private final List<Integer> orderInTypeList = Arrays.asList(1, 2, 3, 4, 5, 6);
|
private final List<Integer> orderInTypeList = Arrays.asList(1, 2, 3, 4, 5, 6);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -54,8 +60,9 @@ public class AppPmsController extends BaseController
|
||||||
{
|
{
|
||||||
// TODO
|
// TODO
|
||||||
// 判断数据是否缺失
|
// 判断数据是否缺失
|
||||||
|
Integer orderType = orderInRequest.getOrderType();
|
||||||
if (StringUtils.isEmpty(orderInRequest.getListId())
|
if (StringUtils.isEmpty(orderInRequest.getListId())
|
||||||
|| orderInTypeList.contains(orderInRequest.getOrderType())
|
|| !orderInTypeList.contains(orderInRequest.getOrderType())
|
||||||
|| StringUtils.isEmpty(orderInRequest.getCustomerId())
|
|| StringUtils.isEmpty(orderInRequest.getCustomerId())
|
||||||
|| StringUtils.isEmpty(orderInRequest.getOrderId())
|
|| StringUtils.isEmpty(orderInRequest.getOrderId())
|
||||||
|| StringUtils.isEmpty(orderInRequest.getGoodsId())
|
|| StringUtils.isEmpty(orderInRequest.getGoodsId())
|
||||||
|
|
@ -69,10 +76,24 @@ public class AppPmsController extends BaseController
|
||||||
if (existAppPmsOrderIn != null) {
|
if (existAppPmsOrderIn != null) {
|
||||||
return error("入库单号重复。");
|
return error("入库单号重复。");
|
||||||
}
|
}
|
||||||
|
AppPmsOrderIn appPmsOrderIn = new AppPmsOrderIn();
|
||||||
|
BeanUtils.copyProperties(orderInRequest,appPmsOrderIn);
|
||||||
|
appPmsOrderIn.setOrderType(Long.valueOf(orderInRequest.getOrderType()));
|
||||||
|
appPmsOrderIn.setGoodsNum(BigDecimal.valueOf(orderInRequest.getGoodsNum()));
|
||||||
|
appPmsOrderIn.setUsedNum(BigDecimal.valueOf(0));
|
||||||
|
appPmsOrderIn.setRemainingNum(BigDecimal.valueOf(orderInRequest.getGoodsNum()));
|
||||||
|
appPmsOrderIn.setOrderStatus(Long.valueOf(0));
|
||||||
|
appPmsOrderIn.setCreateTime(new Date());
|
||||||
|
appPmsOrderIn.setUpdateTime(new Date());
|
||||||
|
|
||||||
|
AppPendingStorage appPendingStorage = new AppPendingStorage();
|
||||||
|
appPendingStorage.setRecordId(UUID.randomUUID().toString());
|
||||||
return success();
|
BeanUtils.copyProperties(appPmsOrderIn, appPendingStorage);
|
||||||
|
int i = appPendingStorageService.insertAppPendingStorage(appPendingStorage);
|
||||||
|
if (i == 0) {
|
||||||
|
return error("存入入库码盘信息失败");
|
||||||
|
}
|
||||||
|
return toAjax(appPmsOrderInService.insertAppPmsOrderIn(appPmsOrderIn));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppLocation;
|
||||||
import com.ruoyi.app.domain.AppPmsOrderIn;
|
import com.ruoyi.app.domain.AppPmsOrderIn;
|
||||||
import com.ruoyi.app.service.IAppPmsOrderInService;
|
import com.ruoyi.app.service.IAppPmsOrderInService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -29,7 +31,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
* @date 2025-01-15
|
* @date 2025-01-15
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/app/pmwOrderIn")
|
@RequestMapping("/app/pmsOrderIn")
|
||||||
public class AppPmsOrderInController extends BaseController
|
public class AppPmsOrderInController extends BaseController
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppPmsOrderInController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:in:list')")
|
@PreAuthorize("@ss.hasPermi('system:in:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppPmsOrderIn.class)
|
||||||
public TableDataInfo list(AppPmsOrderIn appPmsOrderIn)
|
public TableDataInfo list(AppPmsOrderIn appPmsOrderIn)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppPmsOrderIn;
|
||||||
import com.ruoyi.app.domain.AppPmsOrderOut;
|
import com.ruoyi.app.domain.AppPmsOrderOut;
|
||||||
import com.ruoyi.app.service.IAppPmsOrderOutService;
|
import com.ruoyi.app.service.IAppPmsOrderOutService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppPmsOrderOutController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:out:list')")
|
@PreAuthorize("@ss.hasPermi('system:out:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppPmsOrderOut.class)
|
||||||
public TableDataInfo list(AppPmsOrderOut appPmsOrderOut)
|
public TableDataInfo list(AppPmsOrderOut appPmsOrderOut)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppPmsOrderOut;
|
||||||
import com.ruoyi.app.domain.AppProvider;
|
import com.ruoyi.app.domain.AppProvider;
|
||||||
import com.ruoyi.app.service.IAppProviderService;
|
import com.ruoyi.app.service.IAppProviderService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppProviderController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:provider:list')")
|
@PreAuthorize("@ss.hasPermi('system:provider:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppProvider.class)
|
||||||
public TableDataInfo list(AppProvider appProvider)
|
public TableDataInfo list(AppProvider appProvider)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppProvider;
|
||||||
import com.ruoyi.app.domain.AppStand;
|
import com.ruoyi.app.domain.AppStand;
|
||||||
import com.ruoyi.app.service.IAppStandService;
|
import com.ruoyi.app.service.IAppStandService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppStandController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:stand:list')")
|
@PreAuthorize("@ss.hasPermi('system:stand:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppStand.class)
|
||||||
public TableDataInfo list(AppStand appStand)
|
public TableDataInfo list(AppStand appStand)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,9 @@ import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import com.ruoyi.app.domain.AppStock;
|
import com.ruoyi.app.domain.AppStock;
|
||||||
|
import com.ruoyi.app.domain.AppTaskBak;
|
||||||
import com.ruoyi.app.service.IAppStockService;
|
import com.ruoyi.app.service.IAppStockService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -29,7 +31,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
* @date 2025-01-15
|
* @date 2025-01-15
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/system/stock")
|
@RequestMapping("/app/stock")
|
||||||
public class AppStockController extends BaseController
|
public class AppStockController extends BaseController
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|
@ -38,8 +40,9 @@ public class AppStockController extends BaseController
|
||||||
/**
|
/**
|
||||||
* 查询【请填写功能名称】列表
|
* 查询【请填写功能名称】列表
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:stock:list')")
|
@PreAuthorize("@ss.hasPermi('app:stock:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppStock.class)
|
||||||
public TableDataInfo list(AppStock appStock)
|
public TableDataInfo list(AppStock appStock)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
@ -50,7 +53,7 @@ public class AppStockController extends BaseController
|
||||||
/**
|
/**
|
||||||
* 导出【请填写功能名称】列表
|
* 导出【请填写功能名称】列表
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:stock:export')")
|
@PreAuthorize("@ss.hasPermi('app:stock:export')")
|
||||||
@Log(title = "【请填写功能名称】", businessType = BusinessType.EXPORT)
|
@Log(title = "【请填写功能名称】", businessType = BusinessType.EXPORT)
|
||||||
@PostMapping("/export")
|
@PostMapping("/export")
|
||||||
public void export(HttpServletResponse response, AppStock appStock)
|
public void export(HttpServletResponse response, AppStock appStock)
|
||||||
|
|
@ -63,7 +66,7 @@ public class AppStockController extends BaseController
|
||||||
/**
|
/**
|
||||||
* 获取【请填写功能名称】详细信息
|
* 获取【请填写功能名称】详细信息
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:stock:query')")
|
@PreAuthorize("@ss.hasPermi('app:stock:query')")
|
||||||
@GetMapping(value = "/{stockId}")
|
@GetMapping(value = "/{stockId}")
|
||||||
public AjaxResult getInfo(@PathVariable("stockId") String stockId)
|
public AjaxResult getInfo(@PathVariable("stockId") String stockId)
|
||||||
{
|
{
|
||||||
|
|
@ -73,7 +76,7 @@ public class AppStockController extends BaseController
|
||||||
/**
|
/**
|
||||||
* 新增【请填写功能名称】
|
* 新增【请填写功能名称】
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:stock:add')")
|
@PreAuthorize("@ss.hasPermi('app:stock:add')")
|
||||||
@Log(title = "【请填写功能名称】", businessType = BusinessType.INSERT)
|
@Log(title = "【请填写功能名称】", businessType = BusinessType.INSERT)
|
||||||
@PostMapping
|
@PostMapping
|
||||||
public AjaxResult add(@RequestBody AppStock appStock)
|
public AjaxResult add(@RequestBody AppStock appStock)
|
||||||
|
|
@ -84,7 +87,7 @@ public class AppStockController extends BaseController
|
||||||
/**
|
/**
|
||||||
* 修改【请填写功能名称】
|
* 修改【请填写功能名称】
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:stock:edit')")
|
@PreAuthorize("@ss.hasPermi('app:stock:edit')")
|
||||||
@Log(title = "【请填写功能名称】", businessType = BusinessType.UPDATE)
|
@Log(title = "【请填写功能名称】", businessType = BusinessType.UPDATE)
|
||||||
@PutMapping
|
@PutMapping
|
||||||
public AjaxResult edit(@RequestBody AppStock appStock)
|
public AjaxResult edit(@RequestBody AppStock appStock)
|
||||||
|
|
@ -95,7 +98,7 @@ public class AppStockController extends BaseController
|
||||||
/**
|
/**
|
||||||
* 删除【请填写功能名称】
|
* 删除【请填写功能名称】
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:stock:remove')")
|
@PreAuthorize("@ss.hasPermi('app:stock:remove')")
|
||||||
@Log(title = "【请填写功能名称】", businessType = BusinessType.DELETE)
|
@Log(title = "【请填写功能名称】", businessType = BusinessType.DELETE)
|
||||||
@DeleteMapping("/{stockIds}")
|
@DeleteMapping("/{stockIds}")
|
||||||
public AjaxResult remove(@PathVariable String[] stockIds)
|
public AjaxResult remove(@PathVariable String[] stockIds)
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppStand;
|
||||||
import com.ruoyi.app.domain.AppTaskBak;
|
import com.ruoyi.app.domain.AppTaskBak;
|
||||||
import com.ruoyi.app.service.IAppTaskBakService;
|
import com.ruoyi.app.service.IAppTaskBakService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -29,7 +31,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
* @date 2025-01-15
|
* @date 2025-01-15
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/app/taskBak")
|
@RequestMapping("/app/taskbak")
|
||||||
public class AppTaskBakController extends BaseController
|
public class AppTaskBakController extends BaseController
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppTaskBakController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:bak:list')")
|
@PreAuthorize("@ss.hasPermi('system:bak:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppTaskBak.class)
|
||||||
public TableDataInfo list(AppTaskBak appTaskBak)
|
public TableDataInfo list(AppTaskBak appTaskBak)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -1,20 +1,26 @@
|
||||||
package com.ruoyi.web.controller.app;
|
package com.ruoyi.web.controller.app;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
import com.ruoyi.app.domain.AppLocation;
|
|
||||||
import com.ruoyi.app.domain.AppTask;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import com.ruoyi.app.domain.AppWcsTask;
|
import com.ruoyi.app.domain.*;
|
||||||
import com.ruoyi.app.service.IAppLocationService;
|
import com.ruoyi.app.service.*;
|
||||||
import com.ruoyi.app.service.IAppTaskService;
|
import com.ruoyi.app.service.impl.AppPendingStorageServiceImpl;
|
||||||
import com.ruoyi.app.service.IAppWcsTaskBakService;
|
|
||||||
import com.ruoyi.app.service.IAppWcsTaskService;
|
|
||||||
import com.ruoyi.common.annotation.Anonymous;
|
import com.ruoyi.common.annotation.Anonymous;
|
||||||
import com.ruoyi.common.utils.StringUtils;
|
import com.ruoyi.common.utils.StringUtils;
|
||||||
import com.ruoyi.web.domain.TaskResultFeedRequest;
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
|
import com.ruoyi.web.domain.*;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
|
import org.springframework.http.HttpEntity;
|
||||||
|
import org.springframework.http.HttpHeaders;
|
||||||
|
import org.springframework.http.MediaType;
|
||||||
|
import org.springframework.http.client.SimpleClientHttpRequestFactory;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
import org.springframework.web.bind.annotation.PostMapping;
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
import org.springframework.web.bind.annotation.PutMapping;
|
import org.springframework.web.bind.annotation.PutMapping;
|
||||||
|
|
@ -29,6 +35,7 @@ import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
import com.ruoyi.common.enums.BusinessType;
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
import com.ruoyi.common.core.page.TableDataInfo;
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
import org.springframework.web.client.RestTemplate;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 【请填写功能名称】Controller
|
* 【请填写功能名称】Controller
|
||||||
|
|
@ -48,14 +55,23 @@ public class AppTaskController extends BaseController
|
||||||
private IAppWcsTaskService appWcsTaskService;
|
private IAppWcsTaskService appWcsTaskService;
|
||||||
@Autowired
|
@Autowired
|
||||||
private IAppWcsTaskBakService appWcsTaskBakService;
|
private IAppWcsTaskBakService appWcsTaskBakService;
|
||||||
|
@Autowired
|
||||||
|
private IAppPmsOrderInService appPmsOrderInService;
|
||||||
|
@Autowired
|
||||||
|
private IAppTaskBakService appTaskBakService;
|
||||||
|
@Autowired
|
||||||
|
private IAppStockService appStockService;
|
||||||
|
|
||||||
private final List<Integer> wcsTaskStatusList = Arrays.asList(1, 2, 3, 4, 5, 100, 998, 999);
|
private final List<Integer> wcsTaskStatusList = Arrays.asList(1, 2, 3, 4, 5, 100, 998, 999);
|
||||||
|
@Autowired
|
||||||
|
private AppPendingStorageServiceImpl appPendingStorageServiceImpl;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询【请填写功能名称】列表
|
* 查询【请填写功能名称】列表
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:task:list')")
|
@PreAuthorize("@ss.hasPermi('system:task:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppTask.class)
|
||||||
public TableDataInfo list(AppTask appTask)
|
public TableDataInfo list(AppTask appTask)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
@ -229,4 +245,232 @@ public class AppTaskController extends BaseController
|
||||||
|
|
||||||
return error("处理任务反馈错误。");
|
return error("处理任务反馈错误。");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation("生成库位")
|
||||||
|
@PostMapping("/sendLocation")
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
@Anonymous
|
||||||
|
public AjaxResult sendLocation(@RequestBody WcsLocationRequest wcsStackerTask)
|
||||||
|
{
|
||||||
|
if(ObjectUtil.isEmpty(wcsStackerTask.getPoint())||
|
||||||
|
ObjectUtil.isEmpty(wcsStackerTask.getVehicleNo())){
|
||||||
|
return error("缺少请求数据");
|
||||||
|
}
|
||||||
|
AppTask appTask = new AppTask();
|
||||||
|
appTask.setVehicleId(wcsStackerTask.getVehicleNo());
|
||||||
|
List<AppTask> appTasks = appTaskService.selectAppTaskList(appTask);
|
||||||
|
if(appTasks.size()>0){
|
||||||
|
return error("此托盘任务已存在");
|
||||||
|
}
|
||||||
|
|
||||||
|
AppTask appTask2 = new AppTask();
|
||||||
|
BeanUtils.copyProperties(wcsStackerTask, appTask2);
|
||||||
|
appTask2.setTaskId("RK"+System.currentTimeMillis());
|
||||||
|
appTask2.setWcsTaskId("RK"+System.currentTimeMillis());
|
||||||
|
appTask2.setTaskStatus(1);
|
||||||
|
appTask2.setTaskType(1);
|
||||||
|
appTask2.setOrigin(wcsStackerTask.getPoint());
|
||||||
|
appTask2.setTaskPriority(1);
|
||||||
|
String location = appLocationService.sendLocation();
|
||||||
|
appTask2.setDestination(location);
|
||||||
|
appTask2.setVehicleId(wcsStackerTask.getVehicleNo());
|
||||||
|
int i1 = appTaskService.insertAppTask(appTask2);
|
||||||
|
if(i1 == 0 ){
|
||||||
|
return error("wms生成入库任务异常");
|
||||||
|
}
|
||||||
|
AppWcsTask appTask1 = new AppWcsTask();
|
||||||
|
BeanUtils.copyProperties(wcsStackerTask, appTask);
|
||||||
|
appTask1.setWcsTaskId(appTask2.getTaskId());
|
||||||
|
appTask1.setWcsTaskStatus(1);
|
||||||
|
appTask1.setWcsTaskType(appTask2.getTaskType());
|
||||||
|
appTask1.setOrigin("101");
|
||||||
|
appTask1.setTaskPriority(appTask2.getTaskPriority());
|
||||||
|
appTask1.setDestination(location);
|
||||||
|
appTask1.setSendTime(new Date());
|
||||||
|
appTask1.setVehicleId(appTask2.getVehicleId());
|
||||||
|
int i = appWcsTaskService.insertAppWcsTask(appTask1);
|
||||||
|
if(i == 0 ){
|
||||||
|
return error("wcs生成入库任务异常");
|
||||||
|
}
|
||||||
|
|
||||||
|
WcsDate wcsDate = new WcsDate();
|
||||||
|
wcsDate.setTaskId(appTask2.getTaskId());
|
||||||
|
wcsDate.setUser("WMS");
|
||||||
|
wcsDate.setVehicleNo(wcsStackerTask.getVehicleNo());
|
||||||
|
wcsDate.setDestination(location);
|
||||||
|
return success(wcsDate);
|
||||||
|
}
|
||||||
|
|
||||||
|
@ApiOperation("任务反馈")
|
||||||
|
@PostMapping("/taskResult")
|
||||||
|
@Anonymous
|
||||||
|
@Transactional
|
||||||
|
public AjaxResult taskResult(@RequestBody TaskResultFeedRequest taskResultFeedRequest)
|
||||||
|
{
|
||||||
|
if(ObjectUtil.isEmpty(taskResultFeedRequest.getTaskId()) ||
|
||||||
|
ObjectUtil.isEmpty(taskResultFeedRequest.getVehicleNo())){
|
||||||
|
return error("缺少请求数据");
|
||||||
|
}
|
||||||
|
AppTask appTask1 = appTaskService.selectAppTaskByTaskId(taskResultFeedRequest.getTaskId());
|
||||||
|
if(ObjectUtil.isEmpty(appTask1)){
|
||||||
|
return error("wms任务不存在");
|
||||||
|
}
|
||||||
|
AppWcsTask appWcsTask = appWcsTaskService.selectAppWcsTaskByWcsTaskId(taskResultFeedRequest.getTaskId());
|
||||||
|
if(ObjectUtil.isEmpty(appWcsTask)){
|
||||||
|
return error("wcs任务不存在");
|
||||||
|
}
|
||||||
|
if(ObjectUtil.isNotEmpty(taskResultFeedRequest.getTaskStatus())){
|
||||||
|
if(!wcsTaskStatusList.contains(taskResultFeedRequest.getTaskStatus())){
|
||||||
|
return error("缺少请求数据");
|
||||||
|
}
|
||||||
|
AppTask appTask = new AppTask();
|
||||||
|
appTask.setTaskId(taskResultFeedRequest.getTaskId());
|
||||||
|
appTask.setTaskStatus(taskResultFeedRequest.getTaskStatus());
|
||||||
|
int i = appTaskService.updateAppTask(appTask);
|
||||||
|
if (i == 0 ){
|
||||||
|
return error("wms更新任务信息失败");
|
||||||
|
}
|
||||||
|
AppWcsTask appWcsTask1 = new AppWcsTask();
|
||||||
|
appWcsTask1.setWcsTaskId(taskResultFeedRequest.getTaskId());
|
||||||
|
appWcsTask1.setWcsTaskStatus(taskResultFeedRequest.getTaskStatus());
|
||||||
|
int i1 = appWcsTaskService.updateAppWcsTask(appWcsTask1);
|
||||||
|
if (i1 == 0 ){
|
||||||
|
return error("wcs更新任务信息失败");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//wcs反馈
|
||||||
|
if(taskResultFeedRequest.getTaskStatus() == 100){
|
||||||
|
AppTask appTask = new AppTask();
|
||||||
|
appTask.setVehicleId(taskResultFeedRequest.getVehicleNo());
|
||||||
|
List<AppTask> appTasks = appTaskService.selectAppTaskList(appTask);
|
||||||
|
AppWcsTask appWcsTask1 = new AppWcsTask();
|
||||||
|
appWcsTask1.setVehicleId(taskResultFeedRequest.getVehicleNo());
|
||||||
|
List<AppWcsTask> appWcsTasks = appWcsTaskService.selectAppWcsTaskList(appWcsTask1);
|
||||||
|
|
||||||
|
if(ObjectUtil.isEmpty(appTasks)){
|
||||||
|
return error("该托盘不存在wms任务");
|
||||||
|
}
|
||||||
|
if(ObjectUtil.isEmpty(appWcsTasks)){
|
||||||
|
return error("该托盘不存在wcs任务");
|
||||||
|
}
|
||||||
|
for (AppWcsTask appWcsTask3 : appWcsTasks) {
|
||||||
|
//wcs移存到历史表中
|
||||||
|
AppWcsTask appWcsTask2 = appWcsTaskService.selectAppWcsTaskByWcsTaskId(appWcsTask3.getWcsTaskId());
|
||||||
|
AppWcsTaskBak appWcsTask4 = new AppWcsTaskBak();
|
||||||
|
BeanUtils.copyProperties(appWcsTask2, appWcsTask4);
|
||||||
|
appWcsTask4.setFinishTime(new Date());
|
||||||
|
appWcsTaskBakService.insertAppWcsTaskBak(appWcsTask4);
|
||||||
|
appWcsTaskService.deleteAppWcsTaskByWcsTaskId(appWcsTask2.getWcsTaskId());
|
||||||
|
}
|
||||||
|
for(AppTask appTask2 : appTasks){
|
||||||
|
if(ObjectUtil.isEmpty(appTask2.getGoodsId())){
|
||||||
|
return error("此托盘未绑定物料");
|
||||||
|
}
|
||||||
|
AppPmsOrderIn appPmsOrderIn = new AppPmsOrderIn();
|
||||||
|
appPmsOrderIn.setGoodsId(appTask2.getGoodsId());
|
||||||
|
List<AppPmsOrderIn> appPmsOrderIns = appPmsOrderInService.selectAppPmsOrderInList(appPmsOrderIn);
|
||||||
|
if(ObjectUtil.isEmpty(appPmsOrderIns)){
|
||||||
|
return error("该物料任务单不存在");
|
||||||
|
}
|
||||||
|
|
||||||
|
//物料操作数量
|
||||||
|
BigDecimal opNum = appTask2.getOpNum();
|
||||||
|
|
||||||
|
String url = "http://localhost:9430/app/task/kk";
|
||||||
|
RestTemplate restTemplate = new RestTemplate();
|
||||||
|
SimpleClientHttpRequestFactory factory = new SimpleClientHttpRequestFactory();
|
||||||
|
//连接超时时间
|
||||||
|
factory.setConnectTimeout(5000);
|
||||||
|
// 读取超时时间
|
||||||
|
factory.setReadTimeout(10000);
|
||||||
|
restTemplate.setRequestFactory(factory);
|
||||||
|
HttpHeaders headers = new HttpHeaders();
|
||||||
|
headers.setContentType(MediaType.APPLICATION_JSON);
|
||||||
|
|
||||||
|
PmsOrderInRequest orderInRequest = new PmsOrderInRequest();
|
||||||
|
orderInRequest.setOrderId(appPmsOrderIns.get(0).getOrderId());
|
||||||
|
orderInRequest.setGoodsId(appPmsOrderIns.get(0).getGoodsId());
|
||||||
|
if(ObjectUtil.isNotEmpty(appTask2.getOpNum())){
|
||||||
|
orderInRequest.setGoodsNum(appTask2.getOpNum().intValue());
|
||||||
|
}else{
|
||||||
|
orderInRequest.setGoodsNum(appPmsOrderIns.get(0).getGoodsNum().intValue());
|
||||||
|
}
|
||||||
|
orderInRequest.setGoodsCode(appPmsOrderIns.get(0).getGoodsCode());
|
||||||
|
orderInRequest.setSpare1(appPmsOrderIns.get(0).getSpare1());
|
||||||
|
orderInRequest.setSpare2(appPmsOrderIns.get(0).getSpare2());
|
||||||
|
|
||||||
|
|
||||||
|
//修改库位状态
|
||||||
|
AppLocation appLocation = new AppLocation();
|
||||||
|
appLocation.setLocationId(appTask2.getDestination());
|
||||||
|
appLocation.setLocationStatus(2);
|
||||||
|
appLocationService.updateAppLocation(appLocation);
|
||||||
|
//更新库存
|
||||||
|
AppStock appStock = new AppStock();
|
||||||
|
appStock.setStockId(appTask2.getGoodsId());
|
||||||
|
appStock.setGoodsId(appTask2.getGoodsId());
|
||||||
|
appStock.setVehicleId(appTask2.getVehicleId());
|
||||||
|
appStock.setLocationId(appTask2.getDestination());
|
||||||
|
appStock.setOriginNum(BigDecimal.valueOf(orderInRequest.getGoodsNum()));
|
||||||
|
appStock.setGoodsUnit(appPmsOrderIns.get(0).getUnit());
|
||||||
|
appStockService.insertAppStock(appStock);
|
||||||
|
//wms移存到历史表
|
||||||
|
AppTaskBak appTaskBak = new AppTaskBak();
|
||||||
|
BeanUtils.copyProperties(appTask2, appTaskBak);
|
||||||
|
appTaskBak.setCreateTime(new Date());
|
||||||
|
appTaskBak.setOpNum(BigDecimal.valueOf(orderInRequest.getGoodsNum()));
|
||||||
|
appTaskBak.setFinishTime(new Date());
|
||||||
|
appTaskBakService.insertAppTaskBak(appTaskBak);
|
||||||
|
appTaskService.deleteAppTaskByTaskId(appTask2.getTaskId());
|
||||||
|
//更新pms任务表
|
||||||
|
AppPmsOrderIn appPmsOrderIn1 = new AppPmsOrderIn();
|
||||||
|
appPmsOrderIn1.setGoodsId(appTask2.getGoodsId());
|
||||||
|
appPmsOrderIn1.setOrderStatus(Long.valueOf(0));
|
||||||
|
List<AppPmsOrderIn> appPmsOrderIns1 = appPmsOrderInService.selectAppPmsOrderInList(appPmsOrderIn1);
|
||||||
|
if(ObjectUtil.isEmpty(appPmsOrderIns1)){
|
||||||
|
return error("物料未绑定托盘");
|
||||||
|
}
|
||||||
|
AppPmsOrderIn appPmsOrderIn2 = appPmsOrderIns1.get(0);
|
||||||
|
appPmsOrderIn2.setOrderStatus(2L);
|
||||||
|
appPmsOrderIn2.setUsedNum(BigDecimal.valueOf(orderInRequest.getGoodsNum()));
|
||||||
|
appPmsOrderIn2.setRemainingNum(appPmsOrderIn2.getGoodsNum().subtract(BigDecimal.valueOf(orderInRequest.getGoodsNum())));
|
||||||
|
int i1 = appPmsOrderInService.updateAppPmsOrderIn(appPmsOrderIn2);
|
||||||
|
if(i1 == 0 ){
|
||||||
|
return error("pms任务表更新失败");
|
||||||
|
}
|
||||||
|
//更新码盘表
|
||||||
|
AppPendingStorage appPendingStorage = new AppPendingStorage();
|
||||||
|
appPendingStorage.setGoodsId(appTask2.getGoodsId());
|
||||||
|
appPendingStorage.setStatus(Long.valueOf(1));
|
||||||
|
List<AppPendingStorage> appPendingStorages = appPendingStorageServiceImpl.selectAppPendingStorageList(appPendingStorage);
|
||||||
|
if(ObjectUtil.isEmpty(appPendingStorages)){
|
||||||
|
return error("未查询到码盘信息");
|
||||||
|
}
|
||||||
|
AppPendingStorage appPendingStorage1 = appPendingStorages.get(0);
|
||||||
|
appPendingStorage1.setStatus(Long.valueOf(3));
|
||||||
|
appPendingStorage1.setGoodsNum(BigDecimal.valueOf(orderInRequest.getGoodsNum()));
|
||||||
|
appPendingStorage1.setUpdateTime(new Date());
|
||||||
|
int i = appPendingStorageServiceImpl.updateAppPendingStorage(appPendingStorage1);
|
||||||
|
if(i == 0){
|
||||||
|
return error("码盘表信息更新失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
HttpEntity<PmsOrderInRequest> requestEntity = new HttpEntity<>(orderInRequest, headers);
|
||||||
|
String response = restTemplate.postForObject(url, requestEntity, String.class);
|
||||||
|
boolean contains = response.contains("200");
|
||||||
|
if(!contains){
|
||||||
|
return error("上报pms失败");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
return success();
|
||||||
|
}
|
||||||
|
@PostMapping("/kk")
|
||||||
|
@Anonymous
|
||||||
|
public AjaxResult kk(@RequestBody PmsOrderInRequest orderInRequest)
|
||||||
|
{
|
||||||
|
return success();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppTask;
|
||||||
import com.ruoyi.app.domain.AppVehicle;
|
import com.ruoyi.app.domain.AppVehicle;
|
||||||
import com.ruoyi.app.service.IAppVehicleService;
|
import com.ruoyi.app.service.IAppVehicleService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppVehicleController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:vehicle:list')")
|
@PreAuthorize("@ss.hasPermi('system:vehicle:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppVehicle.class)
|
||||||
public TableDataInfo list(AppVehicle appVehicle)
|
public TableDataInfo list(AppVehicle appVehicle)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -3,9 +3,11 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppVehicle;
|
||||||
import com.ruoyi.app.domain.AppWave;
|
import com.ruoyi.app.domain.AppWave;
|
||||||
import com.ruoyi.app.service.IAppWaveService;
|
import com.ruoyi.app.service.IAppWaveService;
|
||||||
import com.ruoyi.common.annotation.Anonymous;
|
import com.ruoyi.common.annotation.Anonymous;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -41,6 +43,7 @@ public class AppWaveController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:wave:list')")
|
@PreAuthorize("@ss.hasPermi('system:wave:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppWave.class)
|
||||||
public TableDataInfo list(AppWave appWave)
|
public TableDataInfo list(AppWave appWave)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -3,8 +3,10 @@ package com.ruoyi.web.controller.app;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppWave;
|
||||||
import com.ruoyi.app.domain.AppWcsTaskBak;
|
import com.ruoyi.app.domain.AppWcsTaskBak;
|
||||||
import com.ruoyi.app.service.IAppWcsTaskBakService;
|
import com.ruoyi.app.service.IAppWcsTaskBakService;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -29,7 +31,7 @@ import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
* @date 2025-01-15
|
* @date 2025-01-15
|
||||||
*/
|
*/
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/app/WcsTaskBak")
|
@RequestMapping("/app/wcsTaskBak")
|
||||||
public class AppWcsTaskBakController extends BaseController
|
public class AppWcsTaskBakController extends BaseController
|
||||||
{
|
{
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|
@ -40,6 +42,7 @@ public class AppWcsTaskBakController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:bak:list')")
|
@PreAuthorize("@ss.hasPermi('system:bak:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppWcsTaskBak.class)
|
||||||
public TableDataInfo list(AppWcsTaskBak appWcsTaskBak)
|
public TableDataInfo list(AppWcsTaskBak appWcsTaskBak)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,12 @@ import java.util.List;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import com.ruoyi.app.domain.AppWcsTask;
|
import com.ruoyi.app.domain.AppWcsTask;
|
||||||
|
import com.ruoyi.app.domain.AppWcsTaskBak;
|
||||||
import com.ruoyi.app.service.IAppWcsTaskService;
|
import com.ruoyi.app.service.IAppWcsTaskService;
|
||||||
|
import com.ruoyi.common.annotation.Anonymous;
|
||||||
|
import com.ruoyi.web.controller.section.EnhanceDataList;
|
||||||
|
import com.ruoyi.web.domain.PmsOrderInRequest;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
import org.springframework.security.access.prepost.PreAuthorize;
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
|
@ -40,6 +45,7 @@ public class AppWcsTaskController extends BaseController
|
||||||
*/
|
*/
|
||||||
@PreAuthorize("@ss.hasPermi('system:task:list')")
|
@PreAuthorize("@ss.hasPermi('system:task:list')")
|
||||||
@GetMapping("/list")
|
@GetMapping("/list")
|
||||||
|
@EnhanceDataList(entityType = AppWcsTask.class)
|
||||||
public TableDataInfo list(AppWcsTask appWcsTask)
|
public TableDataInfo list(AppWcsTask appWcsTask)
|
||||||
{
|
{
|
||||||
startPage();
|
startPage();
|
||||||
|
|
@ -102,4 +108,6 @@ public class AppWcsTaskController extends BaseController
|
||||||
{
|
{
|
||||||
return toAjax(appWcsTaskService.deleteAppWcsTaskByWcsTaskIds(wcsTaskIds));
|
return toAjax(appWcsTaskService.deleteAppWcsTaskByWcsTaskIds(wcsTaskIds));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,72 @@
|
||||||
|
package com.ruoyi.web.controller.section;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
import com.ruoyi.generator.util.ColumnUtils;
|
||||||
|
import org.aspectj.lang.ProceedingJoinPoint;
|
||||||
|
import org.aspectj.lang.annotation.Around;
|
||||||
|
import org.aspectj.lang.annotation.Aspect;
|
||||||
|
import org.aspectj.lang.annotation.Pointcut;
|
||||||
|
import org.aspectj.lang.reflect.MethodSignature;
|
||||||
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@Aspect
|
||||||
|
@Component
|
||||||
|
public class DataListAspect {
|
||||||
|
|
||||||
|
@Pointcut("@annotation(EnhanceDataList)")
|
||||||
|
public void dataListPointcut() {}
|
||||||
|
|
||||||
|
//分页不处理
|
||||||
|
@Around(value = "dataListPointcut()")
|
||||||
|
public Object around(ProceedingJoinPoint joinPoint) throws Throwable {
|
||||||
|
// 先执行目标方法
|
||||||
|
Object result = joinPoint.proceed();
|
||||||
|
|
||||||
|
// 检查结果是否为 TableDataInfo 实例
|
||||||
|
if (result instanceof TableDataInfo) {
|
||||||
|
TableDataInfo dataTable = (TableDataInfo) result;
|
||||||
|
MethodSignature signature = (MethodSignature) joinPoint.getSignature();
|
||||||
|
EnhanceDataList enhanceDataList = signature.getMethod().getAnnotation(EnhanceDataList.class);
|
||||||
|
|
||||||
|
// 设置列信息
|
||||||
|
dataTable.setColumns(ColumnUtils.getColumnsJson(enhanceDataList.entityType()));
|
||||||
|
|
||||||
|
// 在这里添加其他逻辑来修改 dataTable
|
||||||
|
// 例如重新计算 total 或修改 rows
|
||||||
|
// dataTable.setTotal(newTotal);
|
||||||
|
// dataTable.setRows(newRows);
|
||||||
|
|
||||||
|
return dataTable; // 返回修改后的 dataTable
|
||||||
|
}
|
||||||
|
|
||||||
|
return result; // 如果结果不是 TableDataInfo 实例,直接返回原结果
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//集合类
|
||||||
|
@Pointcut("@annotation(ListColumns)")
|
||||||
|
public void list() {}
|
||||||
|
|
||||||
|
@Around("list()")
|
||||||
|
public Object lists(ProceedingJoinPoint joinPoint) throws Throwable {
|
||||||
|
Object result = joinPoint.proceed();
|
||||||
|
MethodSignature signature = (MethodSignature) joinPoint.getSignature();
|
||||||
|
ListColumns columns = signature.getMethod().getAnnotation(ListColumns.class);
|
||||||
|
if (result instanceof Map) {
|
||||||
|
Map<String, Object> map = (Map<String, Object>) result;
|
||||||
|
// 确保list也被放入map中
|
||||||
|
if (joinPoint.getArgs().length > 0 && joinPoint.getArgs()[0] instanceof List) {
|
||||||
|
map.put("list", joinPoint.getArgs()[0]);
|
||||||
|
}
|
||||||
|
map.put("columns", ColumnUtils.getColumnsJson(columns.value()));
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,12 @@
|
||||||
|
package com.ruoyi.web.controller.section;
|
||||||
|
|
||||||
|
import java.lang.annotation.ElementType;
|
||||||
|
import java.lang.annotation.Retention;
|
||||||
|
import java.lang.annotation.RetentionPolicy;
|
||||||
|
import java.lang.annotation.Target;
|
||||||
|
|
||||||
|
@Target(ElementType.METHOD)
|
||||||
|
@Retention(RetentionPolicy.RUNTIME)
|
||||||
|
public @interface EnhanceDataList {
|
||||||
|
Class<?> entityType();
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
package com.ruoyi.web.controller.section;
|
||||||
|
|
||||||
|
import java.lang.annotation.ElementType;
|
||||||
|
import java.lang.annotation.Retention;
|
||||||
|
import java.lang.annotation.RetentionPolicy;
|
||||||
|
import java.lang.annotation.Target;
|
||||||
|
|
||||||
|
|
||||||
|
@Target(ElementType.METHOD)
|
||||||
|
@Retention(RetentionPolicy.RUNTIME)
|
||||||
|
public @interface ListColumns {
|
||||||
|
Class<?> value();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
72
ruoyi-admin/src/main/java/com/ruoyi/web/domain/WcsDate.java
Normal file
72
ruoyi-admin/src/main/java/com/ruoyi/web/domain/WcsDate.java
Normal file
|
|
@ -0,0 +1,72 @@
|
||||||
|
package com.ruoyi.web.domain;
|
||||||
|
|
||||||
|
public class WcsDate {
|
||||||
|
/**
|
||||||
|
* 任务号
|
||||||
|
*/
|
||||||
|
private String taskId;
|
||||||
|
/**
|
||||||
|
* 用户
|
||||||
|
*/
|
||||||
|
private String user;
|
||||||
|
/**
|
||||||
|
* 载具号
|
||||||
|
*/
|
||||||
|
private String vehicleNo ;
|
||||||
|
/**
|
||||||
|
* 终点位置
|
||||||
|
*/
|
||||||
|
private String destination;
|
||||||
|
|
||||||
|
private String spare1;
|
||||||
|
|
||||||
|
private String spare2;
|
||||||
|
|
||||||
|
public String getUser() {
|
||||||
|
return user;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setUser(String user) {
|
||||||
|
this.user = user;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getVehicleNo() {
|
||||||
|
return vehicleNo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setVehicleNo(String vehicleNo) {
|
||||||
|
this.vehicleNo = vehicleNo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getDestination() {
|
||||||
|
return destination;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDestination(String destination) {
|
||||||
|
this.destination = destination;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSpare1() {
|
||||||
|
return spare1;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSpare1(String spare1) {
|
||||||
|
this.spare1 = spare1;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSpare2() {
|
||||||
|
return spare2;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSpare2(String spare2) {
|
||||||
|
this.spare2 = spare2;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTaskId() {
|
||||||
|
return taskId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setTaskId(String taskId) {
|
||||||
|
this.taskId = taskId;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package com.ruoyi.web.domain;
|
||||||
|
|
||||||
|
public class WcsLocationRequest {
|
||||||
|
/**
|
||||||
|
* 点位
|
||||||
|
*/
|
||||||
|
private String point;
|
||||||
|
/**
|
||||||
|
* 载具编号
|
||||||
|
*/
|
||||||
|
private String vehicleNo;
|
||||||
|
/**
|
||||||
|
* 条码信息
|
||||||
|
*/
|
||||||
|
private String codeMessage ;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
public String getPoint() {
|
||||||
|
return point;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setPoint(String point) {
|
||||||
|
this.point = point;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getRemark() {
|
||||||
|
return remark;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRemark(String remark) {
|
||||||
|
this.remark = remark;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCodeMessage() {
|
||||||
|
return codeMessage;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setCodeMessage(String codeMessage) {
|
||||||
|
this.codeMessage = codeMessage;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getVehicleNo() {
|
||||||
|
return vehicleNo;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setVehicleNo(String vehicleNo) {
|
||||||
|
this.vehicleNo = vehicleNo;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,5 +1,7 @@
|
||||||
package com.ruoyi.common.core.page;
|
package com.ruoyi.common.core.page;
|
||||||
|
|
||||||
|
import cn.hutool.json.JSONArray;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
|
@ -30,6 +32,15 @@ public class TableDataInfo implements Serializable
|
||||||
public TableDataInfo()
|
public TableDataInfo()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
private JSONArray columns;
|
||||||
|
|
||||||
|
public JSONArray getColumns() {
|
||||||
|
return columns;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setColumns(JSONArray columns) {
|
||||||
|
this.columns = columns;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 分页
|
* 分页
|
||||||
|
|
|
||||||
|
|
@ -114,7 +114,7 @@ public class SecurityConfig
|
||||||
requests.antMatchers("/login", "/register", "/captchaImage").permitAll()
|
requests.antMatchers("/login", "/register", "/captchaImage").permitAll()
|
||||||
// 静态资源,可匿名访问
|
// 静态资源,可匿名访问
|
||||||
.antMatchers(HttpMethod.GET, "/", "/*.html", "/**/*.html", "/**/*.css", "/**/*.js", "/profile/**").permitAll()
|
.antMatchers(HttpMethod.GET, "/", "/*.html", "/**/*.html", "/**/*.css", "/**/*.js", "/profile/**").permitAll()
|
||||||
.antMatchers("/swagger-ui.html", "/swagger-resources/**", "/webjars/**", "/*/api-docs", "/druid/**").permitAll()
|
.antMatchers("/swagger-ui.html", "/swagger-resources/**", "/webjars/**", "/*/api-docs", "/druid/**","/app/pms/orderIn","/app/task/sendLocation", "/app/task/taskResult","/app/task/kk").permitAll()
|
||||||
// 除上面外的所有请求全部需要鉴权认证
|
// 除上面外的所有请求全部需要鉴权认证
|
||||||
.anyRequest().authenticated();
|
.anyRequest().authenticated();
|
||||||
})
|
})
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,73 @@
|
||||||
|
package com.ruoyi.generator.util;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
import cn.hutool.json.JSONArray;
|
||||||
|
import cn.hutool.json.JSONObject;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
|
||||||
|
import java.lang.reflect.Field;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 动态加载列表和中文名称
|
||||||
|
*/
|
||||||
|
public class ColumnUtils {
|
||||||
|
|
||||||
|
public static JSONArray getColumnsJson(Class<?> clazz) {
|
||||||
|
JSONArray columns = new JSONArray();
|
||||||
|
Field[] fields = clazz.getDeclaredFields();
|
||||||
|
int key = 0;
|
||||||
|
|
||||||
|
for (Field field : fields) {
|
||||||
|
Excel excelAnnotation = field.getAnnotation(Excel.class);
|
||||||
|
if (excelAnnotation != null) {
|
||||||
|
JSONObject column = new JSONObject();
|
||||||
|
// column.put("seq", key++);
|
||||||
|
if(!String.class.isAssignableFrom(field.getType())){
|
||||||
|
column.put("type", "number");
|
||||||
|
column.put("sortable", "custom");
|
||||||
|
}
|
||||||
|
if (field.getName().equals("createTime")) {
|
||||||
|
column.put("prop", field.getName());
|
||||||
|
column.put("label", excelAnnotation.name());
|
||||||
|
column.put("sortable", true);
|
||||||
|
column.put("width", 180);
|
||||||
|
}
|
||||||
|
column.put("prop", field.getName());
|
||||||
|
column.put("label", excelAnnotation.name());
|
||||||
|
// column.put("visible", true); // 假设所有列默认都是可见的
|
||||||
|
// column.put("columnName", field.getName()); // 设置列ID
|
||||||
|
columns.put(column);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Class<?> superclass = clazz.getSuperclass();
|
||||||
|
Field[] declaredFields = superclass.getDeclaredFields();
|
||||||
|
for (Field declaredField : declaredFields) {
|
||||||
|
Excel excelAnnotation = declaredField.getAnnotation(Excel.class);
|
||||||
|
if (excelAnnotation != null) {
|
||||||
|
JSONObject column = new JSONObject();
|
||||||
|
// column.put("seq", key++);
|
||||||
|
if(!String.class.isAssignableFrom(declaredField.getType())){
|
||||||
|
column.put("type", "number");
|
||||||
|
column.put("sortable", "custom");
|
||||||
|
}
|
||||||
|
if (declaredField.getName().equals("createTime")) {
|
||||||
|
column.put("prop", declaredField.getName());
|
||||||
|
column.put("label", excelAnnotation.name());
|
||||||
|
column.put("sortable", true);
|
||||||
|
column.put("width", 180);
|
||||||
|
}
|
||||||
|
column.put("prop", declaredField.getName());
|
||||||
|
column.put("label", excelAnnotation.name());
|
||||||
|
// column.put("visible", true); // 假设所有列默认都是可见的
|
||||||
|
// column.put("columnName", declaredField.getName()); // 设置列ID
|
||||||
|
columns.put(column);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return columns;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
package com.ruoyi.app.domain;
|
package com.ruoyi.app.domain;
|
||||||
|
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
import com.ruoyi.common.core.domain.BaseEntity;
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
|
@ -15,6 +16,7 @@ public class AppLedConfig extends BaseEntity
|
||||||
private static final long serialVersionUID = 1L;
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
/** 主键 */
|
/** 主键 */
|
||||||
|
@Excel(name = "主键")
|
||||||
private String ledId;
|
private String ledId;
|
||||||
|
|
||||||
public void setLedId(String ledId)
|
public void setLedId(String ledId)
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,7 @@ public class AppLocation extends BaseEntity
|
||||||
private static final Long serialVersionUID = 1L;
|
private static final Long serialVersionUID = 1L;
|
||||||
|
|
||||||
/** 库位号 */
|
/** 库位号 */
|
||||||
|
@Excel(name = "库位号")
|
||||||
private String locationId;
|
private String locationId;
|
||||||
|
|
||||||
/** 库位类型 */
|
/** 库位类型 */
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,237 @@
|
||||||
|
package com.ruoyi.app.domain;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
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;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 入库码盘对象 app_pending_storage
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2025-02-22
|
||||||
|
*/
|
||||||
|
public class AppPendingStorage extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 记录号,主键 */
|
||||||
|
private String recordId;
|
||||||
|
|
||||||
|
/** 入库单号 */
|
||||||
|
@Excel(name = "入库单号")
|
||||||
|
private String listId;
|
||||||
|
|
||||||
|
/** 订单类型 */
|
||||||
|
@Excel(name = "订单类型")
|
||||||
|
private Long orderType;
|
||||||
|
|
||||||
|
/** 客户ID */
|
||||||
|
@Excel(name = "客户ID")
|
||||||
|
private String customerId;
|
||||||
|
|
||||||
|
/** 订单号 */
|
||||||
|
@Excel(name = "订单号")
|
||||||
|
private String orderId;
|
||||||
|
|
||||||
|
/** 物料号 */
|
||||||
|
@Excel(name = "物料号")
|
||||||
|
private String goodsId;
|
||||||
|
|
||||||
|
/** 物料数量 */
|
||||||
|
@Excel(name = "物料数量")
|
||||||
|
private BigDecimal goodsNum;
|
||||||
|
|
||||||
|
/** 物料条码 */
|
||||||
|
@Excel(name = "物料条码")
|
||||||
|
private String goodsCode;
|
||||||
|
|
||||||
|
/** 物料描述 */
|
||||||
|
@Excel(name = "物料描述")
|
||||||
|
private String goodsDesc;
|
||||||
|
|
||||||
|
/** 单位 */
|
||||||
|
@Excel(name = "单位")
|
||||||
|
private String unit;
|
||||||
|
|
||||||
|
/** */
|
||||||
|
@Excel(name = "")
|
||||||
|
private String spare1;
|
||||||
|
|
||||||
|
/** */
|
||||||
|
@Excel(name = "")
|
||||||
|
private String spare2;
|
||||||
|
|
||||||
|
/** 状态:1-码盘成功;2-正在入库;3-入库完成;4-异常 */
|
||||||
|
@Excel(name = "状态:1-码盘成功;2-正在入库;3-入库完成;4-异常")
|
||||||
|
private Long status;
|
||||||
|
|
||||||
|
/** 码盘类型:1-其他物料入库;2-pms入库 */
|
||||||
|
@Excel(name = "码盘类型:1-其他物料入库;2-pms入库")
|
||||||
|
private Long storageType;
|
||||||
|
|
||||||
|
/** 创建人 */
|
||||||
|
@Excel(name = "创建人")
|
||||||
|
private String createPerson;
|
||||||
|
|
||||||
|
public void setRecordId(String recordId)
|
||||||
|
{
|
||||||
|
this.recordId = recordId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getRecordId()
|
||||||
|
{
|
||||||
|
return recordId;
|
||||||
|
}
|
||||||
|
public void setListId(String listId)
|
||||||
|
{
|
||||||
|
this.listId = listId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getListId()
|
||||||
|
{
|
||||||
|
return listId;
|
||||||
|
}
|
||||||
|
public void setOrderType(Long orderType)
|
||||||
|
{
|
||||||
|
this.orderType = orderType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getOrderType()
|
||||||
|
{
|
||||||
|
return orderType;
|
||||||
|
}
|
||||||
|
public void setCustomerId(String customerId)
|
||||||
|
{
|
||||||
|
this.customerId = customerId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCustomerId()
|
||||||
|
{
|
||||||
|
return customerId;
|
||||||
|
}
|
||||||
|
public void setOrderId(String orderId)
|
||||||
|
{
|
||||||
|
this.orderId = orderId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getOrderId()
|
||||||
|
{
|
||||||
|
return orderId;
|
||||||
|
}
|
||||||
|
public void setGoodsId(String goodsId)
|
||||||
|
{
|
||||||
|
this.goodsId = goodsId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGoodsId()
|
||||||
|
{
|
||||||
|
return goodsId;
|
||||||
|
}
|
||||||
|
public void setGoodsNum(BigDecimal goodsNum)
|
||||||
|
{
|
||||||
|
this.goodsNum = goodsNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public BigDecimal getGoodsNum()
|
||||||
|
{
|
||||||
|
return goodsNum;
|
||||||
|
}
|
||||||
|
public void setGoodsCode(String goodsCode)
|
||||||
|
{
|
||||||
|
this.goodsCode = goodsCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGoodsCode()
|
||||||
|
{
|
||||||
|
return goodsCode;
|
||||||
|
}
|
||||||
|
public void setGoodsDesc(String goodsDesc)
|
||||||
|
{
|
||||||
|
this.goodsDesc = goodsDesc;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGoodsDesc()
|
||||||
|
{
|
||||||
|
return goodsDesc;
|
||||||
|
}
|
||||||
|
public void setUnit(String unit)
|
||||||
|
{
|
||||||
|
this.unit = unit;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getUnit()
|
||||||
|
{
|
||||||
|
return unit;
|
||||||
|
}
|
||||||
|
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 setStatus(Long status)
|
||||||
|
{
|
||||||
|
this.status = status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getStatus()
|
||||||
|
{
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
public void setStorageType(Long storageType)
|
||||||
|
{
|
||||||
|
this.storageType = storageType;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getStorageType()
|
||||||
|
{
|
||||||
|
return storageType;
|
||||||
|
}
|
||||||
|
public void setCreatePerson(String createPerson)
|
||||||
|
{
|
||||||
|
this.createPerson = createPerson;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCreatePerson()
|
||||||
|
{
|
||||||
|
return createPerson;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("recordId", getRecordId())
|
||||||
|
.append("listId", getListId())
|
||||||
|
.append("orderType", getOrderType())
|
||||||
|
.append("customerId", getCustomerId())
|
||||||
|
.append("orderId", getOrderId())
|
||||||
|
.append("goodsId", getGoodsId())
|
||||||
|
.append("goodsNum", getGoodsNum())
|
||||||
|
.append("goodsCode", getGoodsCode())
|
||||||
|
.append("goodsDesc", getGoodsDesc())
|
||||||
|
.append("unit", getUnit())
|
||||||
|
.append("spare1", getSpare1())
|
||||||
|
.append("spare2", getSpare2())
|
||||||
|
.append("status", getStatus())
|
||||||
|
.append("storageType", getStorageType())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("createPerson", getCreatePerson())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.append("remark", getRemark())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -10,7 +10,7 @@ import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
* 【请填写功能名称】对象 app_pms_order_in
|
* 【请填写功能名称】对象 app_pms_order_in
|
||||||
*
|
*
|
||||||
* @author ruoyi
|
* @author ruoyi
|
||||||
* @date 2025-01-14
|
* @date 2025-02-22
|
||||||
*/
|
*/
|
||||||
public class AppPmsOrderIn extends BaseEntity
|
public class AppPmsOrderIn extends BaseEntity
|
||||||
{
|
{
|
||||||
|
|
@ -39,6 +39,14 @@ public class AppPmsOrderIn extends BaseEntity
|
||||||
@Excel(name = "数量")
|
@Excel(name = "数量")
|
||||||
private BigDecimal goodsNum;
|
private BigDecimal goodsNum;
|
||||||
|
|
||||||
|
/** 使用数量(已入库数量) */
|
||||||
|
@Excel(name = "使用数量", readConverterExp = "已=入库数量")
|
||||||
|
private BigDecimal usedNum;
|
||||||
|
|
||||||
|
/** 剩余数量 */
|
||||||
|
@Excel(name = "剩余数量")
|
||||||
|
private BigDecimal remainingNum;
|
||||||
|
|
||||||
/** 物料条码 */
|
/** 物料条码 */
|
||||||
@Excel(name = "物料条码")
|
@Excel(name = "物料条码")
|
||||||
private String goodsCode;
|
private String goodsCode;
|
||||||
|
|
@ -59,6 +67,10 @@ public class AppPmsOrderIn extends BaseEntity
|
||||||
@Excel(name = "预留2")
|
@Excel(name = "预留2")
|
||||||
private String spare2;
|
private String spare2;
|
||||||
|
|
||||||
|
/** 订单状态 */
|
||||||
|
@Excel(name = "订单状态")
|
||||||
|
private Long orderStatus;
|
||||||
|
|
||||||
public void setListId(String listId)
|
public void setListId(String listId)
|
||||||
{
|
{
|
||||||
this.listId = listId;
|
this.listId = listId;
|
||||||
|
|
@ -113,6 +125,24 @@ public class AppPmsOrderIn extends BaseEntity
|
||||||
{
|
{
|
||||||
return goodsNum;
|
return goodsNum;
|
||||||
}
|
}
|
||||||
|
public void setUsedNum(BigDecimal usedNum)
|
||||||
|
{
|
||||||
|
this.usedNum = usedNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public BigDecimal getUsedNum()
|
||||||
|
{
|
||||||
|
return usedNum;
|
||||||
|
}
|
||||||
|
public void setRemainingNum(BigDecimal remainingNum)
|
||||||
|
{
|
||||||
|
this.remainingNum = remainingNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public BigDecimal getRemainingNum()
|
||||||
|
{
|
||||||
|
return remainingNum;
|
||||||
|
}
|
||||||
public void setGoodsCode(String goodsCode)
|
public void setGoodsCode(String goodsCode)
|
||||||
{
|
{
|
||||||
this.goodsCode = goodsCode;
|
this.goodsCode = goodsCode;
|
||||||
|
|
@ -158,6 +188,15 @@ public class AppPmsOrderIn extends BaseEntity
|
||||||
{
|
{
|
||||||
return spare2;
|
return spare2;
|
||||||
}
|
}
|
||||||
|
public void setOrderStatus(Long orderStatus)
|
||||||
|
{
|
||||||
|
this.orderStatus = orderStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getOrderStatus()
|
||||||
|
{
|
||||||
|
return orderStatus;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
|
|
@ -168,11 +207,17 @@ public class AppPmsOrderIn extends BaseEntity
|
||||||
.append("orderId", getOrderId())
|
.append("orderId", getOrderId())
|
||||||
.append("goodsId", getGoodsId())
|
.append("goodsId", getGoodsId())
|
||||||
.append("goodsNum", getGoodsNum())
|
.append("goodsNum", getGoodsNum())
|
||||||
|
.append("usedNum", getUsedNum())
|
||||||
|
.append("remainingNum", getRemainingNum())
|
||||||
.append("goodsCode", getGoodsCode())
|
.append("goodsCode", getGoodsCode())
|
||||||
.append("goodsDesc", getGoodsDesc())
|
.append("goodsDesc", getGoodsDesc())
|
||||||
.append("unit", getUnit())
|
.append("unit", getUnit())
|
||||||
.append("spare1", getSpare1())
|
.append("spare1", getSpare1())
|
||||||
.append("spare2", getSpare2())
|
.append("spare2", getSpare2())
|
||||||
|
.append("orderStatus", getOrderStatus())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.append("remark", getRemark())
|
||||||
.toString();
|
.toString();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,63 @@
|
||||||
|
package com.ruoyi.app.mapper;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppPendingStorage;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 入库码盘Mapper接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2025-02-22
|
||||||
|
*/
|
||||||
|
public interface AppPendingStorageMapper
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询入库码盘
|
||||||
|
*
|
||||||
|
* @param recordId 入库码盘主键
|
||||||
|
* @return 入库码盘
|
||||||
|
*/
|
||||||
|
public AppPendingStorage selectAppPendingStorageByRecordId(String recordId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询入库码盘列表
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 入库码盘集合
|
||||||
|
*/
|
||||||
|
public List<AppPendingStorage> selectAppPendingStorageList(AppPendingStorage appPendingStorage);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增入库码盘
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertAppPendingStorage(AppPendingStorage appPendingStorage);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改入库码盘
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateAppPendingStorage(AppPendingStorage appPendingStorage);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除入库码盘
|
||||||
|
*
|
||||||
|
* @param recordId 入库码盘主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAppPendingStorageByRecordId(String recordId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除入库码盘
|
||||||
|
*
|
||||||
|
* @param recordIds 需要删除的数据主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAppPendingStorageByRecordIds(String[] recordIds);
|
||||||
|
}
|
||||||
|
|
@ -73,4 +73,6 @@ public interface IAppLocationService
|
||||||
* @return 库位
|
* @return 库位
|
||||||
*/
|
*/
|
||||||
AppLocation requestLocation(int equipmentId);
|
AppLocation requestLocation(int equipmentId);
|
||||||
|
|
||||||
|
String sendLocation();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,63 @@
|
||||||
|
package com.ruoyi.app.service;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppPendingStorage;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 入库码盘Service接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2025-02-22
|
||||||
|
*/
|
||||||
|
public interface IAppPendingStorageService
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询入库码盘
|
||||||
|
*
|
||||||
|
* @param recordId 入库码盘主键
|
||||||
|
* @return 入库码盘
|
||||||
|
*/
|
||||||
|
public AppPendingStorage selectAppPendingStorageByRecordId(String recordId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询入库码盘列表
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 入库码盘集合
|
||||||
|
*/
|
||||||
|
public List<AppPendingStorage> selectAppPendingStorageList(AppPendingStorage appPendingStorage);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增入库码盘
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertAppPendingStorage(AppPendingStorage appPendingStorage);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改入库码盘
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateAppPendingStorage(AppPendingStorage appPendingStorage);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除入库码盘
|
||||||
|
*
|
||||||
|
* @param recordIds 需要删除的入库码盘主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAppPendingStorageByRecordIds(String[] recordIds);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除入库码盘信息
|
||||||
|
*
|
||||||
|
* @param recordId 入库码盘主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteAppPendingStorageByRecordId(String recordId);
|
||||||
|
}
|
||||||
|
|
@ -2,6 +2,7 @@ package com.ruoyi.app.service;
|
||||||
|
|
||||||
import com.ruoyi.app.domain.AppPmsOrderIn;
|
import com.ruoyi.app.domain.AppPmsOrderIn;
|
||||||
|
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -59,4 +60,5 @@ public interface IAppPmsOrderInService
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
public int deleteAppPmsOrderInByListId(String listId);
|
public int deleteAppPmsOrderInByListId(String listId);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,11 +5,13 @@ import java.util.List;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import com.ruoyi.app.domain.AppLocation;
|
import com.ruoyi.app.domain.AppLocation;
|
||||||
import com.ruoyi.app.mapper.AppLocationMapper;
|
import com.ruoyi.app.mapper.AppLocationMapper;
|
||||||
import com.ruoyi.app.service.IAppLocationService;
|
import com.ruoyi.app.service.IAppLocationService;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 【请填写功能名称】Service业务层处理
|
* 【请填写功能名称】Service业务层处理
|
||||||
|
|
@ -136,6 +138,39 @@ public class AppLocationServiceImpl implements IAppLocationService {
|
||||||
return resultLocation;
|
return resultLocation;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional
|
||||||
|
public String sendLocation() {
|
||||||
|
AppLocation appLocation = new AppLocation();
|
||||||
|
appLocation.setLocationStatus(0);
|
||||||
|
appLocation.setIsLock(0);
|
||||||
|
//查询可用库位
|
||||||
|
List<AppLocation> appLocations = appLocationMapper.selectAppLocationList(appLocation);
|
||||||
|
if (appLocations == null || appLocations.isEmpty()) {
|
||||||
|
throw new RuntimeException("库位已满");
|
||||||
|
}
|
||||||
|
//筛选深度
|
||||||
|
List<AppLocation> collect = appLocations.stream().filter(l -> l.getwDepth().equals(2)).collect(Collectors.toList());
|
||||||
|
List<AppLocation> collect1 = appLocations.stream().filter(l -> l.getwDepth().equals(1)).collect(Collectors.toList());
|
||||||
|
//定义库位
|
||||||
|
String locationId = null;
|
||||||
|
if(ObjectUtil.isNotEmpty(collect)){
|
||||||
|
locationId = collect.get(0).getLocationId();
|
||||||
|
}else{
|
||||||
|
locationId =collect1.get(0).getLocationId();
|
||||||
|
}
|
||||||
|
AppLocation location = new AppLocation();
|
||||||
|
location.setLocationId(locationId);
|
||||||
|
location.setLocationStatus(1);
|
||||||
|
//更新库位为任务中
|
||||||
|
int i = appLocationMapper.updateAppLocation(location);
|
||||||
|
if(i == 0 ){
|
||||||
|
throw new RuntimeException("库位更新失败");
|
||||||
|
}
|
||||||
|
return locationId;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 是否是最内层可用库位
|
* 是否是最内层可用库位
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,98 @@
|
||||||
|
package com.ruoyi.app.service.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.ruoyi.app.domain.AppPendingStorage;
|
||||||
|
import com.ruoyi.app.mapper.AppPendingStorageMapper;
|
||||||
|
import com.ruoyi.app.service.IAppPendingStorageService;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 入库码盘Service业务层处理
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2025-02-22
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class AppPendingStorageServiceImpl implements IAppPendingStorageService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private AppPendingStorageMapper appPendingStorageMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询入库码盘
|
||||||
|
*
|
||||||
|
* @param recordId 入库码盘主键
|
||||||
|
* @return 入库码盘
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public AppPendingStorage selectAppPendingStorageByRecordId(String recordId)
|
||||||
|
{
|
||||||
|
return appPendingStorageMapper.selectAppPendingStorageByRecordId(recordId);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询入库码盘列表
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 入库码盘
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<AppPendingStorage> selectAppPendingStorageList(AppPendingStorage appPendingStorage)
|
||||||
|
{
|
||||||
|
return appPendingStorageMapper.selectAppPendingStorageList(appPendingStorage);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增入库码盘
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertAppPendingStorage(AppPendingStorage appPendingStorage)
|
||||||
|
{
|
||||||
|
appPendingStorage.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return appPendingStorageMapper.insertAppPendingStorage(appPendingStorage);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改入库码盘
|
||||||
|
*
|
||||||
|
* @param appPendingStorage 入库码盘
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateAppPendingStorage(AppPendingStorage appPendingStorage)
|
||||||
|
{
|
||||||
|
appPendingStorage.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return appPendingStorageMapper.updateAppPendingStorage(appPendingStorage);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除入库码盘
|
||||||
|
*
|
||||||
|
* @param recordIds 需要删除的入库码盘主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteAppPendingStorageByRecordIds(String[] recordIds)
|
||||||
|
{
|
||||||
|
return appPendingStorageMapper.deleteAppPendingStorageByRecordIds(recordIds);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除入库码盘信息
|
||||||
|
*
|
||||||
|
* @param recordId 入库码盘主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteAppPendingStorageByRecordId(String recordId)
|
||||||
|
{
|
||||||
|
return appPendingStorageMapper.deleteAppPendingStorageByRecordId(recordId);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -5,6 +5,7 @@ import java.util.List;
|
||||||
import com.ruoyi.app.domain.AppPmsOrderIn;
|
import com.ruoyi.app.domain.AppPmsOrderIn;
|
||||||
import com.ruoyi.app.mapper.AppPmsOrderInMapper;
|
import com.ruoyi.app.mapper.AppPmsOrderInMapper;
|
||||||
import com.ruoyi.app.service.IAppPmsOrderInService;
|
import com.ruoyi.app.service.IAppPmsOrderInService;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
|
@ -91,4 +92,5 @@ public class AppPmsOrderInServiceImpl implements IAppPmsOrderInService
|
||||||
{
|
{
|
||||||
return appPmsOrderInMapper.deleteAppPmsOrderInByListId(listId);
|
return appPmsOrderInMapper.deleteAppPmsOrderInByListId(listId);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,135 @@
|
||||||
|
<?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.app.mapper.AppPendingStorageMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppPendingStorage" id="AppPendingStorageResult">
|
||||||
|
<result property="recordId" column="record_id" />
|
||||||
|
<result property="listId" column="list_id" />
|
||||||
|
<result property="orderType" column="order_type" />
|
||||||
|
<result property="customerId" column="customer_id" />
|
||||||
|
<result property="orderId" column="order_id" />
|
||||||
|
<result property="goodsId" column="goods_id" />
|
||||||
|
<result property="goodsNum" column="goods_num" />
|
||||||
|
<result property="goodsCode" column="goods_code" />
|
||||||
|
<result property="goodsDesc" column="goods_desc" />
|
||||||
|
<result property="unit" column="unit" />
|
||||||
|
<result property="spare1" column="spare1" />
|
||||||
|
<result property="spare2" column="spare2" />
|
||||||
|
<result property="status" column="status" />
|
||||||
|
<result property="storageType" column="storage_type" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="createPerson" column="create_person" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppPendingStorageVo">
|
||||||
|
select record_id, list_id, order_type, customer_id, order_id, goods_id, goods_num, goods_code, goods_desc, unit, spare1, spare2, status, storage_type, create_time, create_person, update_time, remark from app_pending_storage
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppPendingStorageList" parameterType="AppPendingStorage" resultMap="AppPendingStorageResult">
|
||||||
|
<include refid="selectAppPendingStorageVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="listId != null and listId != ''"> and list_id = #{listId}</if>
|
||||||
|
<if test="orderType != null "> and order_type = #{orderType}</if>
|
||||||
|
<if test="customerId != null and customerId != ''"> and customer_id = #{customerId}</if>
|
||||||
|
<if test="orderId != null and orderId != ''"> and order_id = #{orderId}</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
||||||
|
<if test="goodsNum != null "> and goods_num = #{goodsNum}</if>
|
||||||
|
<if test="goodsCode != null and goodsCode != ''"> and goods_code = #{goodsCode}</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''"> and goods_desc = #{goodsDesc}</if>
|
||||||
|
<if test="unit != null and unit != ''"> and unit = #{unit}</if>
|
||||||
|
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if>
|
||||||
|
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
|
||||||
|
<if test="status != null "> and status = #{status}</if>
|
||||||
|
<if test="storageType != null "> and storage_type = #{storageType}</if>
|
||||||
|
<if test="createPerson != null and createPerson != ''"> and create_person = #{createPerson}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppPendingStorageByRecordId" parameterType="String" resultMap="AppPendingStorageResult">
|
||||||
|
<include refid="selectAppPendingStorageVo"/>
|
||||||
|
where record_id = #{recordId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppPendingStorage" parameterType="AppPendingStorage">
|
||||||
|
insert into app_pending_storage
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="recordId != null">record_id,</if>
|
||||||
|
<if test="listId != null and listId != ''">list_id,</if>
|
||||||
|
<if test="orderType != null">order_type,</if>
|
||||||
|
<if test="customerId != null and customerId != ''">customer_id,</if>
|
||||||
|
<if test="orderId != null and orderId != ''">order_id,</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id,</if>
|
||||||
|
<if test="goodsNum != null">goods_num,</if>
|
||||||
|
<if test="goodsCode != null">goods_code,</if>
|
||||||
|
<if test="goodsDesc != null">goods_desc,</if>
|
||||||
|
<if test="unit != null and unit != ''">unit,</if>
|
||||||
|
<if test="spare1 != null">spare1,</if>
|
||||||
|
<if test="spare2 != null">spare2,</if>
|
||||||
|
<if test="status != null">status,</if>
|
||||||
|
<if test="storageType != null">storage_type,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="createPerson != null and createPerson != ''">create_person,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="recordId != null">#{recordId},</if>
|
||||||
|
<if test="listId != null and listId != ''">#{listId},</if>
|
||||||
|
<if test="orderType != null">#{orderType},</if>
|
||||||
|
<if test="customerId != null and customerId != ''">#{customerId},</if>
|
||||||
|
<if test="orderId != null and orderId != ''">#{orderId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">#{goodsId},</if>
|
||||||
|
<if test="goodsNum != null">#{goodsNum},</if>
|
||||||
|
<if test="goodsCode != null">#{goodsCode},</if>
|
||||||
|
<if test="goodsDesc != null">#{goodsDesc},</if>
|
||||||
|
<if test="unit != null and unit != ''">#{unit},</if>
|
||||||
|
<if test="spare1 != null">#{spare1},</if>
|
||||||
|
<if test="spare2 != null">#{spare2},</if>
|
||||||
|
<if test="status != null">#{status},</if>
|
||||||
|
<if test="storageType != null">#{storageType},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="createPerson != null and createPerson != ''">#{createPerson},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppPendingStorage" parameterType="AppPendingStorage">
|
||||||
|
update app_pending_storage
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="listId != null and listId != ''">list_id = #{listId},</if>
|
||||||
|
<if test="orderType != null">order_type = #{orderType},</if>
|
||||||
|
<if test="customerId != null and customerId != ''">customer_id = #{customerId},</if>
|
||||||
|
<if test="orderId != null and orderId != ''">order_id = #{orderId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
||||||
|
<if test="goodsNum != null">goods_num = #{goodsNum},</if>
|
||||||
|
<if test="goodsCode != null">goods_code = #{goodsCode},</if>
|
||||||
|
<if test="goodsDesc != null">goods_desc = #{goodsDesc},</if>
|
||||||
|
<if test="unit != null and unit != ''">unit = #{unit},</if>
|
||||||
|
<if test="spare1 != null">spare1 = #{spare1},</if>
|
||||||
|
<if test="spare2 != null">spare2 = #{spare2},</if>
|
||||||
|
<if test="status != null">status = #{status},</if>
|
||||||
|
<if test="storageType != null">storage_type = #{storageType},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="createPerson != null and createPerson != ''">create_person = #{createPerson},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where record_id = #{recordId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppPendingStorageByRecordId" parameterType="String">
|
||||||
|
delete from app_pending_storage where record_id = #{recordId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppPendingStorageByRecordIds" parameterType="String">
|
||||||
|
delete from app_pending_storage where record_id in
|
||||||
|
<foreach item="recordId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{recordId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -11,15 +11,21 @@
|
||||||
<result property="orderId" column="order_id" />
|
<result property="orderId" column="order_id" />
|
||||||
<result property="goodsId" column="goods_id" />
|
<result property="goodsId" column="goods_id" />
|
||||||
<result property="goodsNum" column="goods_num" />
|
<result property="goodsNum" column="goods_num" />
|
||||||
|
<result property="usedNum" column="used_num" />
|
||||||
|
<result property="remainingNum" column="remaining_num" />
|
||||||
<result property="goodsCode" column="goods_code" />
|
<result property="goodsCode" column="goods_code" />
|
||||||
<result property="goodsDesc" column="goods_desc" />
|
<result property="goodsDesc" column="goods_desc" />
|
||||||
<result property="unit" column="unit" />
|
<result property="unit" column="unit" />
|
||||||
<result property="spare1" column="spare1" />
|
<result property="spare1" column="spare1" />
|
||||||
<result property="spare2" column="spare2" />
|
<result property="spare2" column="spare2" />
|
||||||
|
<result property="orderStatus" column="order_status" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectAppPmsOrderInVo">
|
<sql id="selectAppPmsOrderInVo">
|
||||||
select list_id, order_type, customer_id, order_id, goods_id, goods_num, goods_code, goods_desc, unit, spare1, spare2 from app_pms_order_in
|
select list_id, order_type, customer_id, order_id, goods_id, goods_num, used_num, remaining_num, goods_code, goods_desc, unit, spare1, spare2, order_status, create_time, update_time, remark from app_pms_order_in
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectAppPmsOrderInList" parameterType="AppPmsOrderIn" resultMap="AppPmsOrderInResult">
|
<select id="selectAppPmsOrderInList" parameterType="AppPmsOrderIn" resultMap="AppPmsOrderInResult">
|
||||||
|
|
@ -30,11 +36,14 @@
|
||||||
<if test="orderId != null and orderId != ''"> and order_id = #{orderId}</if>
|
<if test="orderId != null and orderId != ''"> and order_id = #{orderId}</if>
|
||||||
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
||||||
<if test="goodsNum != null "> and goods_num = #{goodsNum}</if>
|
<if test="goodsNum != null "> and goods_num = #{goodsNum}</if>
|
||||||
|
<if test="usedNum != null "> and used_num = #{usedNum}</if>
|
||||||
|
<if test="remainingNum != null "> and remaining_num = #{remainingNum}</if>
|
||||||
<if test="goodsCode != null and goodsCode != ''"> and goods_code = #{goodsCode}</if>
|
<if test="goodsCode != null and goodsCode != ''"> and goods_code = #{goodsCode}</if>
|
||||||
<if test="goodsDesc != null and goodsDesc != ''"> and goods_desc = #{goodsDesc}</if>
|
<if test="goodsDesc != null and goodsDesc != ''"> and goods_desc = #{goodsDesc}</if>
|
||||||
<if test="unit != null and unit != ''"> and unit = #{unit}</if>
|
<if test="unit != null and unit != ''"> and unit = #{unit}</if>
|
||||||
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if>
|
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if>
|
||||||
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
|
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
|
||||||
|
<if test="orderStatus != null "> and order_status = #{orderStatus}</if>
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
@ -52,11 +61,17 @@
|
||||||
<if test="orderId != null and orderId != ''">order_id,</if>
|
<if test="orderId != null and orderId != ''">order_id,</if>
|
||||||
<if test="goodsId != null and goodsId != ''">goods_id,</if>
|
<if test="goodsId != null and goodsId != ''">goods_id,</if>
|
||||||
<if test="goodsNum != null">goods_num,</if>
|
<if test="goodsNum != null">goods_num,</if>
|
||||||
|
<if test="usedNum != null">used_num,</if>
|
||||||
|
<if test="remainingNum != null">remaining_num,</if>
|
||||||
<if test="goodsCode != null and goodsCode != ''">goods_code,</if>
|
<if test="goodsCode != null and goodsCode != ''">goods_code,</if>
|
||||||
<if test="goodsDesc != null and goodsDesc != ''">goods_desc,</if>
|
<if test="goodsDesc != null and goodsDesc != ''">goods_desc,</if>
|
||||||
<if test="unit != null and unit != ''">unit,</if>
|
<if test="unit != null and unit != ''">unit,</if>
|
||||||
<if test="spare1 != null">spare1,</if>
|
<if test="spare1 != null">spare1,</if>
|
||||||
<if test="spare2 != null">spare2,</if>
|
<if test="spare2 != null">spare2,</if>
|
||||||
|
<if test="orderStatus != null">order_status,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
</trim>
|
</trim>
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
<if test="listId != null">#{listId},</if>
|
<if test="listId != null">#{listId},</if>
|
||||||
|
|
@ -65,11 +80,17 @@
|
||||||
<if test="orderId != null and orderId != ''">#{orderId},</if>
|
<if test="orderId != null and orderId != ''">#{orderId},</if>
|
||||||
<if test="goodsId != null and goodsId != ''">#{goodsId},</if>
|
<if test="goodsId != null and goodsId != ''">#{goodsId},</if>
|
||||||
<if test="goodsNum != null">#{goodsNum},</if>
|
<if test="goodsNum != null">#{goodsNum},</if>
|
||||||
|
<if test="usedNum != null">#{usedNum},</if>
|
||||||
|
<if test="remainingNum != null">#{remainingNum},</if>
|
||||||
<if test="goodsCode != null and goodsCode != ''">#{goodsCode},</if>
|
<if test="goodsCode != null and goodsCode != ''">#{goodsCode},</if>
|
||||||
<if test="goodsDesc != null and goodsDesc != ''">#{goodsDesc},</if>
|
<if test="goodsDesc != null and goodsDesc != ''">#{goodsDesc},</if>
|
||||||
<if test="unit != null and unit != ''">#{unit},</if>
|
<if test="unit != null and unit != ''">#{unit},</if>
|
||||||
<if test="spare1 != null">#{spare1},</if>
|
<if test="spare1 != null">#{spare1},</if>
|
||||||
<if test="spare2 != null">#{spare2},</if>
|
<if test="spare2 != null">#{spare2},</if>
|
||||||
|
<if test="orderStatus != null">#{orderStatus},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
</trim>
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
|
|
@ -81,11 +102,17 @@
|
||||||
<if test="orderId != null and orderId != ''">order_id = #{orderId},</if>
|
<if test="orderId != null and orderId != ''">order_id = #{orderId},</if>
|
||||||
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
||||||
<if test="goodsNum != null">goods_num = #{goodsNum},</if>
|
<if test="goodsNum != null">goods_num = #{goodsNum},</if>
|
||||||
|
<if test="usedNum != null">used_num = #{usedNum},</if>
|
||||||
|
<if test="remainingNum != null">remaining_num = #{remainingNum},</if>
|
||||||
<if test="goodsCode != null and goodsCode != ''">goods_code = #{goodsCode},</if>
|
<if test="goodsCode != null and goodsCode != ''">goods_code = #{goodsCode},</if>
|
||||||
<if test="goodsDesc != null and goodsDesc != ''">goods_desc = #{goodsDesc},</if>
|
<if test="goodsDesc != null and goodsDesc != ''">goods_desc = #{goodsDesc},</if>
|
||||||
<if test="unit != null and unit != ''">unit = #{unit},</if>
|
<if test="unit != null and unit != ''">unit = #{unit},</if>
|
||||||
<if test="spare1 != null">spare1 = #{spare1},</if>
|
<if test="spare1 != null">spare1 = #{spare1},</if>
|
||||||
<if test="spare2 != null">spare2 = #{spare2},</if>
|
<if test="spare2 != null">spare2 = #{spare2},</if>
|
||||||
|
<if test="orderStatus != null">order_status = #{orderStatus},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
</trim>
|
</trim>
|
||||||
where list_id = #{listId}
|
where list_id = #{listId}
|
||||||
</update>
|
</update>
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,92 @@
|
||||||
|
<?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.AppGoodsMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppGoods" id="AppGoodsResult">
|
||||||
|
<result property="goodsId" column="goods_id" />
|
||||||
|
<result property="goodsName" column="goods_name" />
|
||||||
|
<result property="goodsUnit" column="goods_unit" />
|
||||||
|
<result property="goodsType" column="goods_type" />
|
||||||
|
<result property="normalVehicleType" column="normal_vehicle_type" />
|
||||||
|
<result property="goodsStatus" column="goods_status" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
<result property="lastUpdateUser" column="last_update_user" />
|
||||||
|
<result property="lastUpdateTime" column="last_update_time" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppGoodsVo">
|
||||||
|
select goods_id, goods_name, goods_unit, goods_type, normal_vehicle_type, goods_status, remark, last_update_user, last_update_time from app_goods
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppGoodsList" parameterType="AppGoods" resultMap="AppGoodsResult">
|
||||||
|
<include refid="selectAppGoodsVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="goodsName != null and goodsName != ''"> and goods_name like concat('%', #{goodsName}, '%')</if>
|
||||||
|
<if test="goodsUnit != null and goodsUnit != ''"> and goods_unit = #{goodsUnit}</if>
|
||||||
|
<if test="goodsType != null and goodsType != ''"> and goods_type = #{goodsType}</if>
|
||||||
|
<if test="normalVehicleType != null and normalVehicleType != ''"> and normal_vehicle_type = #{normalVehicleType}</if>
|
||||||
|
<if test="goodsStatus != null "> and goods_status = #{goodsStatus}</if>
|
||||||
|
<if test="lastUpdateUser != null and lastUpdateUser != ''"> and last_update_user = #{lastUpdateUser}</if>
|
||||||
|
<if test="lastUpdateTime != null "> and last_update_time = #{lastUpdateTime}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppGoodsByGoodsId" parameterType="String" resultMap="AppGoodsResult">
|
||||||
|
<include refid="selectAppGoodsVo"/>
|
||||||
|
where goods_id = #{goodsId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppGoods" parameterType="AppGoods">
|
||||||
|
insert into app_goods
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="goodsId != null">goods_id,</if>
|
||||||
|
<if test="goodsName != null">goods_name,</if>
|
||||||
|
<if test="goodsUnit != null and goodsUnit != ''">goods_unit,</if>
|
||||||
|
<if test="goodsType != null">goods_type,</if>
|
||||||
|
<if test="normalVehicleType != null">normal_vehicle_type,</if>
|
||||||
|
<if test="goodsStatus != null">goods_status,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
<if test="lastUpdateUser != null">last_update_user,</if>
|
||||||
|
<if test="lastUpdateTime != null">last_update_time,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="goodsId != null">#{goodsId},</if>
|
||||||
|
<if test="goodsName != null">#{goodsName},</if>
|
||||||
|
<if test="goodsUnit != null and goodsUnit != ''">#{goodsUnit},</if>
|
||||||
|
<if test="goodsType != null">#{goodsType},</if>
|
||||||
|
<if test="normalVehicleType != null">#{normalVehicleType},</if>
|
||||||
|
<if test="goodsStatus != null">#{goodsStatus},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
<if test="lastUpdateUser != null">#{lastUpdateUser},</if>
|
||||||
|
<if test="lastUpdateTime != null">#{lastUpdateTime},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppGoods" parameterType="AppGoods">
|
||||||
|
update app_goods
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="goodsName != null">goods_name = #{goodsName},</if>
|
||||||
|
<if test="goodsUnit != null and goodsUnit != ''">goods_unit = #{goodsUnit},</if>
|
||||||
|
<if test="goodsType != null">goods_type = #{goodsType},</if>
|
||||||
|
<if test="normalVehicleType != null">normal_vehicle_type = #{normalVehicleType},</if>
|
||||||
|
<if test="goodsStatus != null">goods_status = #{goodsStatus},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
<if test="lastUpdateUser != null">last_update_user = #{lastUpdateUser},</if>
|
||||||
|
<if test="lastUpdateTime != null">last_update_time = #{lastUpdateTime},</if>
|
||||||
|
</trim>
|
||||||
|
where goods_id = #{goodsId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppGoodsByGoodsId" parameterType="String">
|
||||||
|
delete from app_goods where goods_id = #{goodsId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppGoodsByGoodsIds" parameterType="String">
|
||||||
|
delete from app_goods where goods_id in
|
||||||
|
<foreach item="goodsId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{goodsId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,58 @@
|
||||||
|
<?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.AppGoodsPairMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppGoodsPair" id="AppGoodsPairResult">
|
||||||
|
<result property="pairId" column="pair_id" />
|
||||||
|
<result property="goodsId" column="goods_id" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppGoodsPairVo">
|
||||||
|
select pair_id, goods_id from app_goods_pair
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppGoodsPairList" parameterType="AppGoodsPair" resultMap="AppGoodsPairResult">
|
||||||
|
<include refid="selectAppGoodsPairVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppGoodsPairByPairId" parameterType="String" resultMap="AppGoodsPairResult">
|
||||||
|
<include refid="selectAppGoodsPairVo"/>
|
||||||
|
where pair_id = #{pairId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppGoodsPair" parameterType="AppGoodsPair">
|
||||||
|
insert into app_goods_pair
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="pairId != null">pair_id,</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="pairId != null">#{pairId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">#{goodsId},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppGoodsPair" parameterType="AppGoodsPair">
|
||||||
|
update app_goods_pair
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
||||||
|
</trim>
|
||||||
|
where pair_id = #{pairId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppGoodsPairByPairId" parameterType="String">
|
||||||
|
delete from app_goods_pair where pair_id = #{pairId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppGoodsPairByPairIds" parameterType="String">
|
||||||
|
delete from app_goods_pair where pair_id in
|
||||||
|
<foreach item="pairId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{pairId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,53 @@
|
||||||
|
<?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.AppLedConfigMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppLedConfig" id="AppLedConfigResult">
|
||||||
|
<result property="ledId" column="led_id" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppLedConfigVo">
|
||||||
|
select led_id from app_led_config
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppLedConfigList" parameterType="AppLedConfig" resultMap="AppLedConfigResult">
|
||||||
|
<include refid="selectAppLedConfigVo"/>
|
||||||
|
<where>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppLedConfigByLedId" parameterType="String" resultMap="AppLedConfigResult">
|
||||||
|
<include refid="selectAppLedConfigVo"/>
|
||||||
|
where led_id = #{ledId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppLedConfig" parameterType="AppLedConfig">
|
||||||
|
insert into app_led_config
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="ledId != null">led_id,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="ledId != null">#{ledId},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppLedConfig" parameterType="AppLedConfig">
|
||||||
|
update app_led_config
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
</trim>
|
||||||
|
where led_id = #{ledId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppLedConfigByLedId" parameterType="String">
|
||||||
|
delete from app_led_config where led_id = #{ledId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppLedConfigByLedIds" parameterType="String">
|
||||||
|
delete from app_led_config where led_id in
|
||||||
|
<foreach item="ledId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{ledId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,122 @@
|
||||||
|
<?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.AppLocationMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppLocation" id="AppLocationResult">
|
||||||
|
<result property="locationId" column="location_id" />
|
||||||
|
<result property="locationType" column="location_type" />
|
||||||
|
<result property="locationStatus" column="location_status" />
|
||||||
|
<result property="outerId" column="outer_id" />
|
||||||
|
<result property="areaId" column="area_id" />
|
||||||
|
<result property="tunnelId" column="tunnel_id" />
|
||||||
|
<result property="equipmentId" column="equipment_id" />
|
||||||
|
<result property="wRow" column="w_row" />
|
||||||
|
<result property="wCol" column="w_col" />
|
||||||
|
<result property="wLayer" column="w_layer" />
|
||||||
|
<result property="wDepth" column="w_depth" />
|
||||||
|
<result property="isLock" column="is_lock" />
|
||||||
|
<result property="vehicleId" column="vehicle_id" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
<result property="isWorking" column="is_working" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppLocationVo">
|
||||||
|
select location_id, location_type, location_status, outer_id, area_id, tunnel_id, equipment_id, w_row, w_col, w_layer, w_depth, is_lock, vehicle_id, remark, is_working from app_location
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppLocationList" parameterType="AppLocation" resultMap="AppLocationResult">
|
||||||
|
<include refid="selectAppLocationVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="locationType != null "> and location_type = #{locationType}</if>
|
||||||
|
<if test="locationStatus != null "> and location_status = #{locationStatus}</if>
|
||||||
|
<if test="outerId != null and outerId != ''"> and outer_id = #{outerId}</if>
|
||||||
|
<if test="areaId != null "> and area_id = #{areaId}</if>
|
||||||
|
<if test="tunnelId != null "> and tunnel_id = #{tunnelId}</if>
|
||||||
|
<if test="equipmentId != null "> and equipment_id = #{equipmentId}</if>
|
||||||
|
<if test="wRow != null "> and w_row = #{wRow}</if>
|
||||||
|
<if test="wCol != null "> and w_col = #{wCol}</if>
|
||||||
|
<if test="wLayer != null "> and w_layer = #{wLayer}</if>
|
||||||
|
<if test="wDepth != null "> and w_depth = #{wDepth}</if>
|
||||||
|
<if test="isLock != null "> and is_lock = #{isLock}</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''"> and vehicle_id = #{vehicleId}</if>
|
||||||
|
<if test="isWorking != null "> and is_working = #{isWorking}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppLocationByLocationId" parameterType="String" resultMap="AppLocationResult">
|
||||||
|
<include refid="selectAppLocationVo"/>
|
||||||
|
where location_id = #{locationId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppLocation" parameterType="AppLocation">
|
||||||
|
insert into app_location
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="locationId != null">location_id,</if>
|
||||||
|
<if test="locationType != null">location_type,</if>
|
||||||
|
<if test="locationStatus != null">location_status,</if>
|
||||||
|
<if test="outerId != null">outer_id,</if>
|
||||||
|
<if test="areaId != null">area_id,</if>
|
||||||
|
<if test="tunnelId != null">tunnel_id,</if>
|
||||||
|
<if test="equipmentId != null">equipment_id,</if>
|
||||||
|
<if test="wRow != null">w_row,</if>
|
||||||
|
<if test="wCol != null">w_col,</if>
|
||||||
|
<if test="wLayer != null">w_layer,</if>
|
||||||
|
<if test="wDepth != null">w_depth,</if>
|
||||||
|
<if test="isLock != null">is_lock,</if>
|
||||||
|
<if test="vehicleId != null">vehicle_id,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
<if test="isWorking != null">is_working,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="locationId != null">#{locationId},</if>
|
||||||
|
<if test="locationType != null">#{locationType},</if>
|
||||||
|
<if test="locationStatus != null">#{locationStatus},</if>
|
||||||
|
<if test="outerId != null">#{outerId},</if>
|
||||||
|
<if test="areaId != null">#{areaId},</if>
|
||||||
|
<if test="tunnelId != null">#{tunnelId},</if>
|
||||||
|
<if test="equipmentId != null">#{equipmentId},</if>
|
||||||
|
<if test="wRow != null">#{wRow},</if>
|
||||||
|
<if test="wCol != null">#{wCol},</if>
|
||||||
|
<if test="wLayer != null">#{wLayer},</if>
|
||||||
|
<if test="wDepth != null">#{wDepth},</if>
|
||||||
|
<if test="isLock != null">#{isLock},</if>
|
||||||
|
<if test="vehicleId != null">#{vehicleId},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
<if test="isWorking != null">#{isWorking},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppLocation" parameterType="AppLocation">
|
||||||
|
update app_location
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="locationType != null">location_type = #{locationType},</if>
|
||||||
|
<if test="locationStatus != null">location_status = #{locationStatus},</if>
|
||||||
|
<if test="outerId != null">outer_id = #{outerId},</if>
|
||||||
|
<if test="areaId != null">area_id = #{areaId},</if>
|
||||||
|
<if test="tunnelId != null">tunnel_id = #{tunnelId},</if>
|
||||||
|
<if test="equipmentId != null">equipment_id = #{equipmentId},</if>
|
||||||
|
<if test="wRow != null">w_row = #{wRow},</if>
|
||||||
|
<if test="wCol != null">w_col = #{wCol},</if>
|
||||||
|
<if test="wLayer != null">w_layer = #{wLayer},</if>
|
||||||
|
<if test="wDepth != null">w_depth = #{wDepth},</if>
|
||||||
|
<if test="isLock != null">is_lock = #{isLock},</if>
|
||||||
|
<if test="vehicleId != null">vehicle_id = #{vehicleId},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
<if test="isWorking != null">is_working = #{isWorking},</if>
|
||||||
|
</trim>
|
||||||
|
where location_id = #{locationId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppLocationByLocationId" parameterType="String">
|
||||||
|
delete from app_location where location_id = #{locationId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppLocationByLocationIds" parameterType="String">
|
||||||
|
delete from app_location where location_id in
|
||||||
|
<foreach item="locationId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{locationId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,108 @@
|
||||||
|
<?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.AppPmsOrderInMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppPmsOrderIn" id="AppPmsOrderInResult">
|
||||||
|
<result property="listId" column="list_id" />
|
||||||
|
<result property="orderType" column="order_type" />
|
||||||
|
<result property="customerId" column="customer_id" />
|
||||||
|
<result property="orderId" column="order_id" />
|
||||||
|
<result property="goodsId" column="goods_id" />
|
||||||
|
<result property="goodsNum" column="goods_num" />
|
||||||
|
<result property="goodsCode" column="goods_code" />
|
||||||
|
<result property="goodsDesc" column="goods_desc" />
|
||||||
|
<result property="unit" column="unit" />
|
||||||
|
<result property="spare1" column="spare1" />
|
||||||
|
<result property="spare2" column="spare2" />
|
||||||
|
<result property="orderStatus" column="order_status" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppPmsOrderInVo">
|
||||||
|
select list_id, order_type, customer_id, order_id, goods_id, goods_num, goods_code, goods_desc, unit, spare1, spare2, order_status from app_pms_order_in
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppPmsOrderInList" parameterType="AppPmsOrderIn" resultMap="AppPmsOrderInResult">
|
||||||
|
<include refid="selectAppPmsOrderInVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="orderType != null "> and order_type = #{orderType}</if>
|
||||||
|
<if test="customerId != null and customerId != ''"> and customer_id = #{customerId}</if>
|
||||||
|
<if test="orderId != null and orderId != ''"> and order_id = #{orderId}</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
||||||
|
<if test="goodsNum != null "> and goods_num = #{goodsNum}</if>
|
||||||
|
<if test="goodsCode != null and goodsCode != ''"> and goods_code = #{goodsCode}</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''"> and goods_desc = #{goodsDesc}</if>
|
||||||
|
<if test="unit != null and unit != ''"> and unit = #{unit}</if>
|
||||||
|
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if>
|
||||||
|
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
|
||||||
|
<if test="orderStatus != null "> and order_status = #{orderStatus}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppPmsOrderInByListId" parameterType="String" resultMap="AppPmsOrderInResult">
|
||||||
|
<include refid="selectAppPmsOrderInVo"/>
|
||||||
|
where list_id = #{listId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppPmsOrderIn" parameterType="AppPmsOrderIn">
|
||||||
|
insert into app_pms_order_in
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="listId != null">list_id,</if>
|
||||||
|
<if test="orderType != null">order_type,</if>
|
||||||
|
<if test="customerId != null and customerId != ''">customer_id,</if>
|
||||||
|
<if test="orderId != null and orderId != ''">order_id,</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id,</if>
|
||||||
|
<if test="goodsNum != null">goods_num,</if>
|
||||||
|
<if test="goodsCode != null and goodsCode != ''">goods_code,</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''">goods_desc,</if>
|
||||||
|
<if test="unit != null and unit != ''">unit,</if>
|
||||||
|
<if test="spare1 != null">spare1,</if>
|
||||||
|
<if test="spare2 != null">spare2,</if>
|
||||||
|
<if test="orderStatus != null">order_status,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="listId != null">#{listId},</if>
|
||||||
|
<if test="orderType != null">#{orderType},</if>
|
||||||
|
<if test="customerId != null and customerId != ''">#{customerId},</if>
|
||||||
|
<if test="orderId != null and orderId != ''">#{orderId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">#{goodsId},</if>
|
||||||
|
<if test="goodsNum != null">#{goodsNum},</if>
|
||||||
|
<if test="goodsCode != null and goodsCode != ''">#{goodsCode},</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''">#{goodsDesc},</if>
|
||||||
|
<if test="unit != null and unit != ''">#{unit},</if>
|
||||||
|
<if test="spare1 != null">#{spare1},</if>
|
||||||
|
<if test="spare2 != null">#{spare2},</if>
|
||||||
|
<if test="orderStatus != null">#{orderStatus},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppPmsOrderIn" parameterType="AppPmsOrderIn">
|
||||||
|
update app_pms_order_in
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="orderType != null">order_type = #{orderType},</if>
|
||||||
|
<if test="customerId != null and customerId != ''">customer_id = #{customerId},</if>
|
||||||
|
<if test="orderId != null and orderId != ''">order_id = #{orderId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
||||||
|
<if test="goodsNum != null">goods_num = #{goodsNum},</if>
|
||||||
|
<if test="goodsCode != null and goodsCode != ''">goods_code = #{goodsCode},</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''">goods_desc = #{goodsDesc},</if>
|
||||||
|
<if test="unit != null and unit != ''">unit = #{unit},</if>
|
||||||
|
<if test="spare1 != null">spare1 = #{spare1},</if>
|
||||||
|
<if test="spare2 != null">spare2 = #{spare2},</if>
|
||||||
|
<if test="orderStatus != null">order_status = #{orderStatus},</if>
|
||||||
|
</trim>
|
||||||
|
where list_id = #{listId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppPmsOrderInByListId" parameterType="String">
|
||||||
|
delete from app_pms_order_in where list_id = #{listId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppPmsOrderInByListIds" parameterType="String">
|
||||||
|
delete from app_pms_order_in where list_id in
|
||||||
|
<foreach item="listId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{listId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,93 @@
|
||||||
|
<?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.AppPmsOrderOutMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppPmsOrderOut" id="AppPmsOrderOutResult">
|
||||||
|
<result property="listId" column="list_id" />
|
||||||
|
<result property="orderType" column="order_type" />
|
||||||
|
<result property="customerId" column="customer_id" />
|
||||||
|
<result property="goodsId" column="goods_id" />
|
||||||
|
<result property="goodsNum" column="goods_num" />
|
||||||
|
<result property="goodsDesc" column="goods_desc" />
|
||||||
|
<result property="spare1" column="spare1" />
|
||||||
|
<result property="spare2" column="spare2" />
|
||||||
|
<result property="orderStatus" column="order_status" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppPmsOrderOutVo">
|
||||||
|
select list_id, order_type, customer_id, goods_id, goods_num, goods_desc, spare1, spare2, order_status from app_pms_order_out
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppPmsOrderOutList" parameterType="AppPmsOrderOut" resultMap="AppPmsOrderOutResult">
|
||||||
|
<include refid="selectAppPmsOrderOutVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="orderType != null "> and order_type = #{orderType}</if>
|
||||||
|
<if test="customerId != null and customerId != ''"> and customer_id = #{customerId}</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
||||||
|
<if test="goodsNum != null "> and goods_num = #{goodsNum}</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''"> and goods_desc = #{goodsDesc}</if>
|
||||||
|
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if>
|
||||||
|
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
|
||||||
|
<if test="orderStatus != null "> and order_status = #{orderStatus}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppPmsOrderOutByListId" parameterType="String" resultMap="AppPmsOrderOutResult">
|
||||||
|
<include refid="selectAppPmsOrderOutVo"/>
|
||||||
|
where list_id = #{listId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppPmsOrderOut" parameterType="AppPmsOrderOut">
|
||||||
|
insert into app_pms_order_out
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="listId != null">list_id,</if>
|
||||||
|
<if test="orderType != null">order_type,</if>
|
||||||
|
<if test="customerId != null and customerId != ''">customer_id,</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id,</if>
|
||||||
|
<if test="goodsNum != null">goods_num,</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''">goods_desc,</if>
|
||||||
|
<if test="spare1 != null and spare1 != ''">spare1,</if>
|
||||||
|
<if test="spare2 != null">spare2,</if>
|
||||||
|
<if test="orderStatus != null">order_status,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="listId != null">#{listId},</if>
|
||||||
|
<if test="orderType != null">#{orderType},</if>
|
||||||
|
<if test="customerId != null and customerId != ''">#{customerId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">#{goodsId},</if>
|
||||||
|
<if test="goodsNum != null">#{goodsNum},</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''">#{goodsDesc},</if>
|
||||||
|
<if test="spare1 != null and spare1 != ''">#{spare1},</if>
|
||||||
|
<if test="spare2 != null">#{spare2},</if>
|
||||||
|
<if test="orderStatus != null">#{orderStatus},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppPmsOrderOut" parameterType="AppPmsOrderOut">
|
||||||
|
update app_pms_order_out
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="orderType != null">order_type = #{orderType},</if>
|
||||||
|
<if test="customerId != null and customerId != ''">customer_id = #{customerId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
||||||
|
<if test="goodsNum != null">goods_num = #{goodsNum},</if>
|
||||||
|
<if test="goodsDesc != null and goodsDesc != ''">goods_desc = #{goodsDesc},</if>
|
||||||
|
<if test="spare1 != null and spare1 != ''">spare1 = #{spare1},</if>
|
||||||
|
<if test="spare2 != null">spare2 = #{spare2},</if>
|
||||||
|
<if test="orderStatus != null">order_status = #{orderStatus},</if>
|
||||||
|
</trim>
|
||||||
|
where list_id = #{listId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppPmsOrderOutByListId" parameterType="String">
|
||||||
|
delete from app_pms_order_out where list_id = #{listId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppPmsOrderOutByListIds" parameterType="String">
|
||||||
|
delete from app_pms_order_out where list_id in
|
||||||
|
<foreach item="listId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{listId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,83 @@
|
||||||
|
<?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.AppProviderMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppProvider" id="AppProviderResult">
|
||||||
|
<result property="providerId" column="provider_id" />
|
||||||
|
<result property="providerName" column="provider_name" />
|
||||||
|
<result property="providerContact" column="provider_contact" />
|
||||||
|
<result property="providerAddress" column="provider_address" />
|
||||||
|
<result property="providerStatus" column="provider_status" />
|
||||||
|
<result property="lastUpdateUser" column="last_update_user" />
|
||||||
|
<result property="lastUpdateTime" column="last_update_time" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppProviderVo">
|
||||||
|
select provider_id, provider_name, provider_contact, provider_address, provider_status, last_update_user, last_update_time from app_provider
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppProviderList" parameterType="AppProvider" resultMap="AppProviderResult">
|
||||||
|
<include refid="selectAppProviderVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="providerName != null and providerName != ''"> and provider_name like concat('%', #{providerName}, '%')</if>
|
||||||
|
<if test="providerContact != null "> and provider_contact = #{providerContact}</if>
|
||||||
|
<if test="providerAddress != null and providerAddress != ''"> and provider_address = #{providerAddress}</if>
|
||||||
|
<if test="providerStatus != null "> and provider_status = #{providerStatus}</if>
|
||||||
|
<if test="lastUpdateUser != null and lastUpdateUser != ''"> and last_update_user = #{lastUpdateUser}</if>
|
||||||
|
<if test="lastUpdateTime != null "> and last_update_time = #{lastUpdateTime}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppProviderByProviderId" parameterType="String" resultMap="AppProviderResult">
|
||||||
|
<include refid="selectAppProviderVo"/>
|
||||||
|
where provider_id = #{providerId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppProvider" parameterType="AppProvider">
|
||||||
|
insert into app_provider
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="providerId != null">provider_id,</if>
|
||||||
|
<if test="providerName != null">provider_name,</if>
|
||||||
|
<if test="providerContact != null">provider_contact,</if>
|
||||||
|
<if test="providerAddress != null">provider_address,</if>
|
||||||
|
<if test="providerStatus != null">provider_status,</if>
|
||||||
|
<if test="lastUpdateUser != null">last_update_user,</if>
|
||||||
|
<if test="lastUpdateTime != null">last_update_time,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="providerId != null">#{providerId},</if>
|
||||||
|
<if test="providerName != null">#{providerName},</if>
|
||||||
|
<if test="providerContact != null">#{providerContact},</if>
|
||||||
|
<if test="providerAddress != null">#{providerAddress},</if>
|
||||||
|
<if test="providerStatus != null">#{providerStatus},</if>
|
||||||
|
<if test="lastUpdateUser != null">#{lastUpdateUser},</if>
|
||||||
|
<if test="lastUpdateTime != null">#{lastUpdateTime},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppProvider" parameterType="AppProvider">
|
||||||
|
update app_provider
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="providerName != null">provider_name = #{providerName},</if>
|
||||||
|
<if test="providerContact != null">provider_contact = #{providerContact},</if>
|
||||||
|
<if test="providerAddress != null">provider_address = #{providerAddress},</if>
|
||||||
|
<if test="providerStatus != null">provider_status = #{providerStatus},</if>
|
||||||
|
<if test="lastUpdateUser != null">last_update_user = #{lastUpdateUser},</if>
|
||||||
|
<if test="lastUpdateTime != null">last_update_time = #{lastUpdateTime},</if>
|
||||||
|
</trim>
|
||||||
|
where provider_id = #{providerId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppProviderByProviderId" parameterType="String">
|
||||||
|
delete from app_provider where provider_id = #{providerId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppProviderByProviderIds" parameterType="String">
|
||||||
|
delete from app_provider where provider_id in
|
||||||
|
<foreach item="providerId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{providerId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,87 @@
|
||||||
|
<?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.AppStandMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppStand" id="AppStandResult">
|
||||||
|
<result property="standId" column="stand_id" />
|
||||||
|
<result property="standName" column="stand_name" />
|
||||||
|
<result property="standType" column="stand_type" />
|
||||||
|
<result property="standArea" column="stand_area" />
|
||||||
|
<result property="standProperty" column="stand_property" />
|
||||||
|
<result property="standStatus" column="stand_status" />
|
||||||
|
<result property="isLock" column="is_lock" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppStandVo">
|
||||||
|
select stand_id, stand_name, stand_type, stand_area, stand_property, stand_status, is_lock, remark from app_stand
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppStandList" parameterType="AppStand" resultMap="AppStandResult">
|
||||||
|
<include refid="selectAppStandVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="standName != null and standName != ''"> and stand_name like concat('%', #{standName}, '%')</if>
|
||||||
|
<if test="standType != null and standType != ''"> and stand_type = #{standType}</if>
|
||||||
|
<if test="standArea != null and standArea != ''"> and stand_area = #{standArea}</if>
|
||||||
|
<if test="standProperty != null and standProperty != ''"> and stand_property = #{standProperty}</if>
|
||||||
|
<if test="standStatus != null "> and stand_status = #{standStatus}</if>
|
||||||
|
<if test="isLock != null "> and is_lock = #{isLock}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppStandByStandId" parameterType="String" resultMap="AppStandResult">
|
||||||
|
<include refid="selectAppStandVo"/>
|
||||||
|
where stand_id = #{standId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppStand" parameterType="AppStand">
|
||||||
|
insert into app_stand
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="standId != null">stand_id,</if>
|
||||||
|
<if test="standName != null and standName != ''">stand_name,</if>
|
||||||
|
<if test="standType != null and standType != ''">stand_type,</if>
|
||||||
|
<if test="standArea != null and standArea != ''">stand_area,</if>
|
||||||
|
<if test="standProperty != null and standProperty != ''">stand_property,</if>
|
||||||
|
<if test="standStatus != null">stand_status,</if>
|
||||||
|
<if test="isLock != null">is_lock,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="standId != null">#{standId},</if>
|
||||||
|
<if test="standName != null and standName != ''">#{standName},</if>
|
||||||
|
<if test="standType != null and standType != ''">#{standType},</if>
|
||||||
|
<if test="standArea != null and standArea != ''">#{standArea},</if>
|
||||||
|
<if test="standProperty != null and standProperty != ''">#{standProperty},</if>
|
||||||
|
<if test="standStatus != null">#{standStatus},</if>
|
||||||
|
<if test="isLock != null">#{isLock},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppStand" parameterType="AppStand">
|
||||||
|
update app_stand
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="standName != null and standName != ''">stand_name = #{standName},</if>
|
||||||
|
<if test="standType != null and standType != ''">stand_type = #{standType},</if>
|
||||||
|
<if test="standArea != null and standArea != ''">stand_area = #{standArea},</if>
|
||||||
|
<if test="standProperty != null and standProperty != ''">stand_property = #{standProperty},</if>
|
||||||
|
<if test="standStatus != null">stand_status = #{standStatus},</if>
|
||||||
|
<if test="isLock != null">is_lock = #{isLock},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where stand_id = #{standId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppStandByStandId" parameterType="String">
|
||||||
|
delete from app_stand where stand_id = #{standId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppStandByStandIds" parameterType="String">
|
||||||
|
delete from app_stand where stand_id in
|
||||||
|
<foreach item="standId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{standId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
141
ruoyi-system/src/main/resources/mapper/system/AppStockMapper.xml
Normal file
141
ruoyi-system/src/main/resources/mapper/system/AppStockMapper.xml
Normal file
|
|
@ -0,0 +1,141 @@
|
||||||
|
<?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.AppStockMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppStock" id="AppStockResult">
|
||||||
|
<result property="stockId" column="stock_id" />
|
||||||
|
<result property="vehicleId" column="vehicle_id" />
|
||||||
|
<result property="locationId" column="location_id" />
|
||||||
|
<result property="goodsId" column="goods_id" />
|
||||||
|
<result property="goodsName" column="goods_name" />
|
||||||
|
<result property="goodsUnit" column="goods_unit" />
|
||||||
|
<result property="providerId" column="provider_id" />
|
||||||
|
<result property="providerName" column="provider_name" />
|
||||||
|
<result property="remainNum" column="remain_num" />
|
||||||
|
<result property="originNum" column="origin_num" />
|
||||||
|
<result property="batchNo" column="batch_no" />
|
||||||
|
<result property="invAge" column="inv_age" />
|
||||||
|
<result property="goodsStatus" column="goods_status" />
|
||||||
|
<result property="stockStatus" column="stock_status" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="createUser" column="create_user" />
|
||||||
|
<result property="lastUpdateTime" column="last_update_time" />
|
||||||
|
<result property="lastUpdateUser" column="last_update_user" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppStockVo">
|
||||||
|
select stock_id, vehicle_id, location_id, goods_id, goods_name, goods_unit, provider_id, provider_name, remain_num, origin_num, batch_no, inv_age, goods_status, stock_status, create_time, create_user, last_update_time, last_update_user, remark from app_stock
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppStockList" parameterType="AppStock" resultMap="AppStockResult">
|
||||||
|
<include refid="selectAppStockVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''"> and vehicle_id = #{vehicleId}</if>
|
||||||
|
<if test="locationId != null and locationId != ''"> and location_id = #{locationId}</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
||||||
|
<if test="goodsName != null and goodsName != ''"> and goods_name like concat('%', #{goodsName}, '%')</if>
|
||||||
|
<if test="goodsUnit != null and goodsUnit != ''"> and goods_unit = #{goodsUnit}</if>
|
||||||
|
<if test="providerId != null and providerId != ''"> and provider_id = #{providerId}</if>
|
||||||
|
<if test="providerName != null and providerName != ''"> and provider_name like concat('%', #{providerName}, '%')</if>
|
||||||
|
<if test="remainNum != null "> and remain_num = #{remainNum}</if>
|
||||||
|
<if test="originNum != null "> and origin_num = #{originNum}</if>
|
||||||
|
<if test="batchNo != null and batchNo != ''"> and batch_no = #{batchNo}</if>
|
||||||
|
<if test="invAge != null "> and inv_age = #{invAge}</if>
|
||||||
|
<if test="goodsStatus != null "> and goods_status = #{goodsStatus}</if>
|
||||||
|
<if test="stockStatus != null "> and stock_status = #{stockStatus}</if>
|
||||||
|
<if test="createUser != null and createUser != ''"> and create_user = #{createUser}</if>
|
||||||
|
<if test="lastUpdateTime != null "> and last_update_time = #{lastUpdateTime}</if>
|
||||||
|
<if test="lastUpdateUser != null and lastUpdateUser != ''"> and last_update_user = #{lastUpdateUser}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppStockByStockId" parameterType="String" resultMap="AppStockResult">
|
||||||
|
<include refid="selectAppStockVo"/>
|
||||||
|
where stock_id = #{stockId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppStock" parameterType="AppStock">
|
||||||
|
insert into app_stock
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="stockId != null">stock_id,</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id,</if>
|
||||||
|
<if test="locationId != null and locationId != ''">location_id,</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id,</if>
|
||||||
|
<if test="goodsName != null">goods_name,</if>
|
||||||
|
<if test="goodsUnit != null">goods_unit,</if>
|
||||||
|
<if test="providerId != null and providerId != ''">provider_id,</if>
|
||||||
|
<if test="providerName != null">provider_name,</if>
|
||||||
|
<if test="remainNum != null">remain_num,</if>
|
||||||
|
<if test="originNum != null">origin_num,</if>
|
||||||
|
<if test="batchNo != null">batch_no,</if>
|
||||||
|
<if test="invAge != null">inv_age,</if>
|
||||||
|
<if test="goodsStatus != null">goods_status,</if>
|
||||||
|
<if test="stockStatus != null">stock_status,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="createUser != null">create_user,</if>
|
||||||
|
<if test="lastUpdateTime != null">last_update_time,</if>
|
||||||
|
<if test="lastUpdateUser != null">last_update_user,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="stockId != null">#{stockId},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">#{vehicleId},</if>
|
||||||
|
<if test="locationId != null and locationId != ''">#{locationId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">#{goodsId},</if>
|
||||||
|
<if test="goodsName != null">#{goodsName},</if>
|
||||||
|
<if test="goodsUnit != null">#{goodsUnit},</if>
|
||||||
|
<if test="providerId != null and providerId != ''">#{providerId},</if>
|
||||||
|
<if test="providerName != null">#{providerName},</if>
|
||||||
|
<if test="remainNum != null">#{remainNum},</if>
|
||||||
|
<if test="originNum != null">#{originNum},</if>
|
||||||
|
<if test="batchNo != null">#{batchNo},</if>
|
||||||
|
<if test="invAge != null">#{invAge},</if>
|
||||||
|
<if test="goodsStatus != null">#{goodsStatus},</if>
|
||||||
|
<if test="stockStatus != null">#{stockStatus},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="createUser != null">#{createUser},</if>
|
||||||
|
<if test="lastUpdateTime != null">#{lastUpdateTime},</if>
|
||||||
|
<if test="lastUpdateUser != null">#{lastUpdateUser},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppStock" parameterType="AppStock">
|
||||||
|
update app_stock
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id = #{vehicleId},</if>
|
||||||
|
<if test="locationId != null and locationId != ''">location_id = #{locationId},</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
||||||
|
<if test="goodsName != null">goods_name = #{goodsName},</if>
|
||||||
|
<if test="goodsUnit != null">goods_unit = #{goodsUnit},</if>
|
||||||
|
<if test="providerId != null and providerId != ''">provider_id = #{providerId},</if>
|
||||||
|
<if test="providerName != null">provider_name = #{providerName},</if>
|
||||||
|
<if test="remainNum != null">remain_num = #{remainNum},</if>
|
||||||
|
<if test="originNum != null">origin_num = #{originNum},</if>
|
||||||
|
<if test="batchNo != null">batch_no = #{batchNo},</if>
|
||||||
|
<if test="invAge != null">inv_age = #{invAge},</if>
|
||||||
|
<if test="goodsStatus != null">goods_status = #{goodsStatus},</if>
|
||||||
|
<if test="stockStatus != null">stock_status = #{stockStatus},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="createUser != null">create_user = #{createUser},</if>
|
||||||
|
<if test="lastUpdateTime != null">last_update_time = #{lastUpdateTime},</if>
|
||||||
|
<if test="lastUpdateUser != null">last_update_user = #{lastUpdateUser},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where stock_id = #{stockId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppStockByStockId" parameterType="String">
|
||||||
|
delete from app_stock where stock_id = #{stockId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppStockByStockIds" parameterType="String">
|
||||||
|
delete from app_stock where stock_id in
|
||||||
|
<foreach item="stockId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{stockId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,122 @@
|
||||||
|
<?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.AppTaskBakMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppTaskBak" id="AppTaskBakResult">
|
||||||
|
<result property="taskId" column="task_id" />
|
||||||
|
<result property="taskType" column="task_type" />
|
||||||
|
<result property="taskStatus" column="task_status" />
|
||||||
|
<result property="taskPriority" column="task_priority" />
|
||||||
|
<result property="vehicleId" column="vehicle_id" />
|
||||||
|
<result property="origin" column="origin" />
|
||||||
|
<result property="destination" column="destination" />
|
||||||
|
<result property="wcsTaskId" column="wcs_task_id" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="finishTime" column="finish_time" />
|
||||||
|
<result property="goodsId" column="goods_id" />
|
||||||
|
<result property="opNum" column="op_num" />
|
||||||
|
<result property="stockNum" column="stock_num" />
|
||||||
|
<result property="opUser" column="op_user" />
|
||||||
|
<result property="preTask" column="pre_task" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppTaskBakVo">
|
||||||
|
select task_id, task_type, task_status, task_priority, vehicle_id, origin, destination, wcs_task_id, create_time, finish_time, goods_id, op_num, stock_num, op_user, pre_task from app_task_bak
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppTaskBakList" parameterType="AppTaskBak" resultMap="AppTaskBakResult">
|
||||||
|
<include refid="selectAppTaskBakVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="taskType != null "> and task_type = #{taskType}</if>
|
||||||
|
<if test="taskStatus != null "> and task_status = #{taskStatus}</if>
|
||||||
|
<if test="taskPriority != null "> and task_priority = #{taskPriority}</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''"> and vehicle_id = #{vehicleId}</if>
|
||||||
|
<if test="origin != null and origin != ''"> and origin = #{origin}</if>
|
||||||
|
<if test="destination != null and destination != ''"> and destination = #{destination}</if>
|
||||||
|
<if test="wcsTaskId != null and wcsTaskId != ''"> and wcs_task_id = #{wcsTaskId}</if>
|
||||||
|
<if test="finishTime != null "> and finish_time = #{finishTime}</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
||||||
|
<if test="opNum != null "> and op_num = #{opNum}</if>
|
||||||
|
<if test="stockNum != null "> and stock_num = #{stockNum}</if>
|
||||||
|
<if test="opUser != null and opUser != ''"> and op_user = #{opUser}</if>
|
||||||
|
<if test="preTask != null and preTask != ''"> and pre_task = #{preTask}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppTaskBakByTaskId" parameterType="String" resultMap="AppTaskBakResult">
|
||||||
|
<include refid="selectAppTaskBakVo"/>
|
||||||
|
where task_id = #{taskId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppTaskBak" parameterType="AppTaskBak">
|
||||||
|
insert into app_task_bak
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="taskId != null">task_id,</if>
|
||||||
|
<if test="taskType != null">task_type,</if>
|
||||||
|
<if test="taskStatus != null">task_status,</if>
|
||||||
|
<if test="taskPriority != null">task_priority,</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id,</if>
|
||||||
|
<if test="origin != null">origin,</if>
|
||||||
|
<if test="destination != null">destination,</if>
|
||||||
|
<if test="wcsTaskId != null">wcs_task_id,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="finishTime != null">finish_time,</if>
|
||||||
|
<if test="goodsId != null">goods_id,</if>
|
||||||
|
<if test="opNum != null">op_num,</if>
|
||||||
|
<if test="stockNum != null">stock_num,</if>
|
||||||
|
<if test="opUser != null">op_user,</if>
|
||||||
|
<if test="preTask != null">pre_task,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="taskId != null">#{taskId},</if>
|
||||||
|
<if test="taskType != null">#{taskType},</if>
|
||||||
|
<if test="taskStatus != null">#{taskStatus},</if>
|
||||||
|
<if test="taskPriority != null">#{taskPriority},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">#{vehicleId},</if>
|
||||||
|
<if test="origin != null">#{origin},</if>
|
||||||
|
<if test="destination != null">#{destination},</if>
|
||||||
|
<if test="wcsTaskId != null">#{wcsTaskId},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="finishTime != null">#{finishTime},</if>
|
||||||
|
<if test="goodsId != null">#{goodsId},</if>
|
||||||
|
<if test="opNum != null">#{opNum},</if>
|
||||||
|
<if test="stockNum != null">#{stockNum},</if>
|
||||||
|
<if test="opUser != null">#{opUser},</if>
|
||||||
|
<if test="preTask != null">#{preTask},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppTaskBak" parameterType="AppTaskBak">
|
||||||
|
update app_task_bak
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="taskType != null">task_type = #{taskType},</if>
|
||||||
|
<if test="taskStatus != null">task_status = #{taskStatus},</if>
|
||||||
|
<if test="taskPriority != null">task_priority = #{taskPriority},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id = #{vehicleId},</if>
|
||||||
|
<if test="origin != null">origin = #{origin},</if>
|
||||||
|
<if test="destination != null">destination = #{destination},</if>
|
||||||
|
<if test="wcsTaskId != null">wcs_task_id = #{wcsTaskId},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="finishTime != null">finish_time = #{finishTime},</if>
|
||||||
|
<if test="goodsId != null">goods_id = #{goodsId},</if>
|
||||||
|
<if test="opNum != null">op_num = #{opNum},</if>
|
||||||
|
<if test="stockNum != null">stock_num = #{stockNum},</if>
|
||||||
|
<if test="opUser != null">op_user = #{opUser},</if>
|
||||||
|
<if test="preTask != null">pre_task = #{preTask},</if>
|
||||||
|
</trim>
|
||||||
|
where task_id = #{taskId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppTaskBakByTaskId" parameterType="String">
|
||||||
|
delete from app_task_bak where task_id = #{taskId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppTaskBakByTaskIds" parameterType="String">
|
||||||
|
delete from app_task_bak where task_id in
|
||||||
|
<foreach item="taskId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{taskId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
122
ruoyi-system/src/main/resources/mapper/system/AppTaskMapper.xml
Normal file
122
ruoyi-system/src/main/resources/mapper/system/AppTaskMapper.xml
Normal file
|
|
@ -0,0 +1,122 @@
|
||||||
|
<?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.AppTaskMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppTask" id="AppTaskResult">
|
||||||
|
<result property="taskId" column="task_id" />
|
||||||
|
<result property="taskType" column="task_type" />
|
||||||
|
<result property="taskStatus" column="task_status" />
|
||||||
|
<result property="taskPriority" column="task_priority" />
|
||||||
|
<result property="vehicleId" column="vehicle_id" />
|
||||||
|
<result property="origin" column="origin" />
|
||||||
|
<result property="destination" column="destination" />
|
||||||
|
<result property="wcsTaskId" column="wcs_task_id" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="finishTime" column="finish_time" />
|
||||||
|
<result property="goodsId" column="goods_id" />
|
||||||
|
<result property="opNum" column="op_num" />
|
||||||
|
<result property="stockNum" column="stock_num" />
|
||||||
|
<result property="opUser" column="op_user" />
|
||||||
|
<result property="preTask" column="pre_task" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppTaskVo">
|
||||||
|
select task_id, task_type, task_status, task_priority, vehicle_id, origin, destination, wcs_task_id, create_time, finish_time, goods_id, op_num, stock_num, op_user, pre_task from app_task
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppTaskList" parameterType="AppTask" resultMap="AppTaskResult">
|
||||||
|
<include refid="selectAppTaskVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="taskType != null "> and task_type = #{taskType}</if>
|
||||||
|
<if test="taskStatus != null "> and task_status = #{taskStatus}</if>
|
||||||
|
<if test="taskPriority != null "> and task_priority = #{taskPriority}</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''"> and vehicle_id = #{vehicleId}</if>
|
||||||
|
<if test="origin != null and origin != ''"> and origin = #{origin}</if>
|
||||||
|
<if test="destination != null and destination != ''"> and destination = #{destination}</if>
|
||||||
|
<if test="wcsTaskId != null and wcsTaskId != ''"> and wcs_task_id = #{wcsTaskId}</if>
|
||||||
|
<if test="finishTime != null "> and finish_time = #{finishTime}</if>
|
||||||
|
<if test="goodsId != null and goodsId != ''"> and goods_id = #{goodsId}</if>
|
||||||
|
<if test="opNum != null "> and op_num = #{opNum}</if>
|
||||||
|
<if test="stockNum != null "> and stock_num = #{stockNum}</if>
|
||||||
|
<if test="opUser != null and opUser != ''"> and op_user = #{opUser}</if>
|
||||||
|
<if test="preTask != null and preTask != ''"> and pre_task = #{preTask}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppTaskByTaskId" parameterType="String" resultMap="AppTaskResult">
|
||||||
|
<include refid="selectAppTaskVo"/>
|
||||||
|
where task_id = #{taskId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppTask" parameterType="AppTask">
|
||||||
|
insert into app_task
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="taskId != null">task_id,</if>
|
||||||
|
<if test="taskType != null">task_type,</if>
|
||||||
|
<if test="taskStatus != null">task_status,</if>
|
||||||
|
<if test="taskPriority != null">task_priority,</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id,</if>
|
||||||
|
<if test="origin != null">origin,</if>
|
||||||
|
<if test="destination != null">destination,</if>
|
||||||
|
<if test="wcsTaskId != null">wcs_task_id,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="finishTime != null">finish_time,</if>
|
||||||
|
<if test="goodsId != null">goods_id,</if>
|
||||||
|
<if test="opNum != null">op_num,</if>
|
||||||
|
<if test="stockNum != null">stock_num,</if>
|
||||||
|
<if test="opUser != null">op_user,</if>
|
||||||
|
<if test="preTask != null">pre_task,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="taskId != null">#{taskId},</if>
|
||||||
|
<if test="taskType != null">#{taskType},</if>
|
||||||
|
<if test="taskStatus != null">#{taskStatus},</if>
|
||||||
|
<if test="taskPriority != null">#{taskPriority},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">#{vehicleId},</if>
|
||||||
|
<if test="origin != null">#{origin},</if>
|
||||||
|
<if test="destination != null">#{destination},</if>
|
||||||
|
<if test="wcsTaskId != null">#{wcsTaskId},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="finishTime != null">#{finishTime},</if>
|
||||||
|
<if test="goodsId != null">#{goodsId},</if>
|
||||||
|
<if test="opNum != null">#{opNum},</if>
|
||||||
|
<if test="stockNum != null">#{stockNum},</if>
|
||||||
|
<if test="opUser != null">#{opUser},</if>
|
||||||
|
<if test="preTask != null">#{preTask},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppTask" parameterType="AppTask">
|
||||||
|
update app_task
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="taskType != null">task_type = #{taskType},</if>
|
||||||
|
<if test="taskStatus != null">task_status = #{taskStatus},</if>
|
||||||
|
<if test="taskPriority != null">task_priority = #{taskPriority},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id = #{vehicleId},</if>
|
||||||
|
<if test="origin != null">origin = #{origin},</if>
|
||||||
|
<if test="destination != null">destination = #{destination},</if>
|
||||||
|
<if test="wcsTaskId != null">wcs_task_id = #{wcsTaskId},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="finishTime != null">finish_time = #{finishTime},</if>
|
||||||
|
<if test="goodsId != null">goods_id = #{goodsId},</if>
|
||||||
|
<if test="opNum != null">op_num = #{opNum},</if>
|
||||||
|
<if test="stockNum != null">stock_num = #{stockNum},</if>
|
||||||
|
<if test="opUser != null">op_user = #{opUser},</if>
|
||||||
|
<if test="preTask != null">pre_task = #{preTask},</if>
|
||||||
|
</trim>
|
||||||
|
where task_id = #{taskId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppTaskByTaskId" parameterType="String">
|
||||||
|
delete from app_task where task_id = #{taskId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppTaskByTaskIds" parameterType="String">
|
||||||
|
delete from app_task where task_id in
|
||||||
|
<foreach item="taskId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{taskId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,92 @@
|
||||||
|
<?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.AppVehicleMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppVehicle" id="AppVehicleResult">
|
||||||
|
<result property="vehicleId" column="vehicle_id" />
|
||||||
|
<result property="vehicleType" column="vehicle_type" />
|
||||||
|
<result property="vehicleStatus" column="vehicle_status" />
|
||||||
|
<result property="locationId" column="location_id" />
|
||||||
|
<result property="isEmpty" column="is_empty" />
|
||||||
|
<result property="isLock" column="is_lock" />
|
||||||
|
<result property="lastInTime" column="last_in_time" />
|
||||||
|
<result property="lastInUser" column="last_in_user" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppVehicleVo">
|
||||||
|
select vehicle_id, vehicle_type, vehicle_status, location_id, is_empty, is_lock, last_in_time, last_in_user, remark from app_vehicle
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppVehicleList" parameterType="AppVehicle" resultMap="AppVehicleResult">
|
||||||
|
<include refid="selectAppVehicleVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="vehicleType != null and vehicleType != ''"> and vehicle_type = #{vehicleType}</if>
|
||||||
|
<if test="vehicleStatus != null "> and vehicle_status = #{vehicleStatus}</if>
|
||||||
|
<if test="locationId != null and locationId != ''"> and location_id = #{locationId}</if>
|
||||||
|
<if test="isEmpty != null "> and is_empty = #{isEmpty}</if>
|
||||||
|
<if test="isLock != null "> and is_lock = #{isLock}</if>
|
||||||
|
<if test="lastInTime != null "> and last_in_time = #{lastInTime}</if>
|
||||||
|
<if test="lastInUser != null and lastInUser != ''"> and last_in_user = #{lastInUser}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppVehicleByVehicleId" parameterType="String" resultMap="AppVehicleResult">
|
||||||
|
<include refid="selectAppVehicleVo"/>
|
||||||
|
where vehicle_id = #{vehicleId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppVehicle" parameterType="AppVehicle">
|
||||||
|
insert into app_vehicle
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="vehicleId != null">vehicle_id,</if>
|
||||||
|
<if test="vehicleType != null and vehicleType != ''">vehicle_type,</if>
|
||||||
|
<if test="vehicleStatus != null">vehicle_status,</if>
|
||||||
|
<if test="locationId != null">location_id,</if>
|
||||||
|
<if test="isEmpty != null">is_empty,</if>
|
||||||
|
<if test="isLock != null">is_lock,</if>
|
||||||
|
<if test="lastInTime != null">last_in_time,</if>
|
||||||
|
<if test="lastInUser != null">last_in_user,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="vehicleId != null">#{vehicleId},</if>
|
||||||
|
<if test="vehicleType != null and vehicleType != ''">#{vehicleType},</if>
|
||||||
|
<if test="vehicleStatus != null">#{vehicleStatus},</if>
|
||||||
|
<if test="locationId != null">#{locationId},</if>
|
||||||
|
<if test="isEmpty != null">#{isEmpty},</if>
|
||||||
|
<if test="isLock != null">#{isLock},</if>
|
||||||
|
<if test="lastInTime != null">#{lastInTime},</if>
|
||||||
|
<if test="lastInUser != null">#{lastInUser},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppVehicle" parameterType="AppVehicle">
|
||||||
|
update app_vehicle
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="vehicleType != null and vehicleType != ''">vehicle_type = #{vehicleType},</if>
|
||||||
|
<if test="vehicleStatus != null">vehicle_status = #{vehicleStatus},</if>
|
||||||
|
<if test="locationId != null">location_id = #{locationId},</if>
|
||||||
|
<if test="isEmpty != null">is_empty = #{isEmpty},</if>
|
||||||
|
<if test="isLock != null">is_lock = #{isLock},</if>
|
||||||
|
<if test="lastInTime != null">last_in_time = #{lastInTime},</if>
|
||||||
|
<if test="lastInUser != null">last_in_user = #{lastInUser},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where vehicle_id = #{vehicleId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppVehicleByVehicleId" parameterType="String">
|
||||||
|
delete from app_vehicle where vehicle_id = #{vehicleId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppVehicleByVehicleIds" parameterType="String">
|
||||||
|
delete from app_vehicle where vehicle_id in
|
||||||
|
<foreach item="vehicleId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{vehicleId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,82 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.ruoyi.system.mapper.AppWaveMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppWave" id="AppWaveResult">
|
||||||
|
<result property="waveId" column="wave_id" />
|
||||||
|
<result property="outRule" column="out_rule" />
|
||||||
|
<result property="isChad" column="is_chad" />
|
||||||
|
<result property="waveStatus" column="wave_status" />
|
||||||
|
<result property="orderWbs" column="order_wbs" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
<result property="waveDestination" column="wave_destination" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppWaveVo">
|
||||||
|
select wave_id, out_rule, is_chad, wave_status, order_wbs, remark, wave_destination from app_wave
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppWaveList" parameterType="AppWave" resultMap="AppWaveResult">
|
||||||
|
<include refid="selectAppWaveVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="outRule != null "> and out_rule = #{outRule}</if>
|
||||||
|
<if test="isChad != null "> and is_chad = #{isChad}</if>
|
||||||
|
<if test="waveStatus != null "> and wave_status = #{waveStatus}</if>
|
||||||
|
<if test="orderWbs != null and orderWbs != ''"> and order_wbs = #{orderWbs}</if>
|
||||||
|
<if test="waveDestination != null and waveDestination != ''"> and wave_destination = #{waveDestination}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppWaveByWaveId" parameterType="String" resultMap="AppWaveResult">
|
||||||
|
<include refid="selectAppWaveVo"/>
|
||||||
|
where wave_id = #{waveId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppWave" parameterType="AppWave">
|
||||||
|
insert into app_wave
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="waveId != null">wave_id,</if>
|
||||||
|
<if test="outRule != null">out_rule,</if>
|
||||||
|
<if test="isChad != null">is_chad,</if>
|
||||||
|
<if test="waveStatus != null">wave_status,</if>
|
||||||
|
<if test="orderWbs != null">order_wbs,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
<if test="waveDestination != null and waveDestination != ''">wave_destination,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="waveId != null">#{waveId},</if>
|
||||||
|
<if test="outRule != null">#{outRule},</if>
|
||||||
|
<if test="isChad != null">#{isChad},</if>
|
||||||
|
<if test="waveStatus != null">#{waveStatus},</if>
|
||||||
|
<if test="orderWbs != null">#{orderWbs},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
<if test="waveDestination != null and waveDestination != ''">#{waveDestination},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppWave" parameterType="AppWave">
|
||||||
|
update app_wave
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="outRule != null">out_rule = #{outRule},</if>
|
||||||
|
<if test="isChad != null">is_chad = #{isChad},</if>
|
||||||
|
<if test="waveStatus != null">wave_status = #{waveStatus},</if>
|
||||||
|
<if test="orderWbs != null">order_wbs = #{orderWbs},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
<if test="waveDestination != null and waveDestination != ''">wave_destination = #{waveDestination},</if>
|
||||||
|
</trim>
|
||||||
|
where wave_id = #{waveId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppWaveByWaveId" parameterType="String">
|
||||||
|
delete from app_wave where wave_id = #{waveId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppWaveByWaveIds" parameterType="String">
|
||||||
|
delete from app_wave where wave_id in
|
||||||
|
<foreach item="waveId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{waveId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,101 @@
|
||||||
|
<?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.AppWcsTaskBakMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppWcsTaskBak" id="AppWcsTaskBakResult">
|
||||||
|
<result property="wcsTaskId" column="wcs_task_id" />
|
||||||
|
<result property="wcsTaskStatus" column="wcs_task_status" />
|
||||||
|
<result property="wcsTaskType" column="wcs_task_type" />
|
||||||
|
<result property="taskPriority" column="task_priority" />
|
||||||
|
<result property="vehicleId" column="vehicle_id" />
|
||||||
|
<result property="origin" column="origin" />
|
||||||
|
<result property="destination" column="destination" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="sendTime" column="send_time" />
|
||||||
|
<result property="finishTime" column="finish_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppWcsTaskBakVo">
|
||||||
|
select wcs_task_id, wcs_task_status, wcs_task_type, task_priority, vehicle_id, origin, destination, create_time, send_time, finish_time, remark from app_wcs_task_bak
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppWcsTaskBakList" parameterType="AppWcsTaskBak" resultMap="AppWcsTaskBakResult">
|
||||||
|
<include refid="selectAppWcsTaskBakVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="wcsTaskStatus != null "> and wcs_task_status = #{wcsTaskStatus}</if>
|
||||||
|
<if test="wcsTaskType != null "> and wcs_task_type = #{wcsTaskType}</if>
|
||||||
|
<if test="taskPriority != null "> and task_priority = #{taskPriority}</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''"> and vehicle_id = #{vehicleId}</if>
|
||||||
|
<if test="origin != null and origin != ''"> and origin = #{origin}</if>
|
||||||
|
<if test="destination != null and destination != ''"> and destination = #{destination}</if>
|
||||||
|
<if test="sendTime != null "> and send_time = #{sendTime}</if>
|
||||||
|
<if test="finishTime != null "> and finish_time = #{finishTime}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppWcsTaskBakByWcsTaskId" parameterType="String" resultMap="AppWcsTaskBakResult">
|
||||||
|
<include refid="selectAppWcsTaskBakVo"/>
|
||||||
|
where wcs_task_id = #{wcsTaskId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppWcsTaskBak" parameterType="AppWcsTaskBak">
|
||||||
|
insert into app_wcs_task_bak
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="wcsTaskId != null">wcs_task_id,</if>
|
||||||
|
<if test="wcsTaskStatus != null">wcs_task_status,</if>
|
||||||
|
<if test="wcsTaskType != null">wcs_task_type,</if>
|
||||||
|
<if test="taskPriority != null">task_priority,</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id,</if>
|
||||||
|
<if test="origin != null and origin != ''">origin,</if>
|
||||||
|
<if test="destination != null and destination != ''">destination,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="sendTime != null">send_time,</if>
|
||||||
|
<if test="finishTime != null">finish_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="wcsTaskId != null">#{wcsTaskId},</if>
|
||||||
|
<if test="wcsTaskStatus != null">#{wcsTaskStatus},</if>
|
||||||
|
<if test="wcsTaskType != null">#{wcsTaskType},</if>
|
||||||
|
<if test="taskPriority != null">#{taskPriority},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">#{vehicleId},</if>
|
||||||
|
<if test="origin != null and origin != ''">#{origin},</if>
|
||||||
|
<if test="destination != null and destination != ''">#{destination},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="sendTime != null">#{sendTime},</if>
|
||||||
|
<if test="finishTime != null">#{finishTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppWcsTaskBak" parameterType="AppWcsTaskBak">
|
||||||
|
update app_wcs_task_bak
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="wcsTaskStatus != null">wcs_task_status = #{wcsTaskStatus},</if>
|
||||||
|
<if test="wcsTaskType != null">wcs_task_type = #{wcsTaskType},</if>
|
||||||
|
<if test="taskPriority != null">task_priority = #{taskPriority},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id = #{vehicleId},</if>
|
||||||
|
<if test="origin != null and origin != ''">origin = #{origin},</if>
|
||||||
|
<if test="destination != null and destination != ''">destination = #{destination},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="sendTime != null">send_time = #{sendTime},</if>
|
||||||
|
<if test="finishTime != null">finish_time = #{finishTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where wcs_task_id = #{wcsTaskId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppWcsTaskBakByWcsTaskId" parameterType="String">
|
||||||
|
delete from app_wcs_task_bak where wcs_task_id = #{wcsTaskId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppWcsTaskBakByWcsTaskIds" parameterType="String">
|
||||||
|
delete from app_wcs_task_bak where wcs_task_id in
|
||||||
|
<foreach item="wcsTaskId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{wcsTaskId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,101 @@
|
||||||
|
<?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.AppWcsTaskMapper">
|
||||||
|
|
||||||
|
<resultMap type="AppWcsTask" id="AppWcsTaskResult">
|
||||||
|
<result property="wcsTaskId" column="wcs_task_id" />
|
||||||
|
<result property="wcsTaskStatus" column="wcs_task_status" />
|
||||||
|
<result property="wcsTaskType" column="wcs_task_type" />
|
||||||
|
<result property="taskPriority" column="task_priority" />
|
||||||
|
<result property="vehicleId" column="vehicle_id" />
|
||||||
|
<result property="origin" column="origin" />
|
||||||
|
<result property="destination" column="destination" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="sendTime" column="send_time" />
|
||||||
|
<result property="finishTime" column="finish_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectAppWcsTaskVo">
|
||||||
|
select wcs_task_id, wcs_task_status, wcs_task_type, task_priority, vehicle_id, origin, destination, create_time, send_time, finish_time, remark from app_wcs_task
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectAppWcsTaskList" parameterType="AppWcsTask" resultMap="AppWcsTaskResult">
|
||||||
|
<include refid="selectAppWcsTaskVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="wcsTaskStatus != null "> and wcs_task_status = #{wcsTaskStatus}</if>
|
||||||
|
<if test="wcsTaskType != null "> and wcs_task_type = #{wcsTaskType}</if>
|
||||||
|
<if test="taskPriority != null "> and task_priority = #{taskPriority}</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''"> and vehicle_id = #{vehicleId}</if>
|
||||||
|
<if test="origin != null and origin != ''"> and origin = #{origin}</if>
|
||||||
|
<if test="destination != null and destination != ''"> and destination = #{destination}</if>
|
||||||
|
<if test="sendTime != null "> and send_time = #{sendTime}</if>
|
||||||
|
<if test="finishTime != null "> and finish_time = #{finishTime}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectAppWcsTaskByWcsTaskId" parameterType="String" resultMap="AppWcsTaskResult">
|
||||||
|
<include refid="selectAppWcsTaskVo"/>
|
||||||
|
where wcs_task_id = #{wcsTaskId}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertAppWcsTask" parameterType="AppWcsTask">
|
||||||
|
insert into app_wcs_task
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="wcsTaskId != null">wcs_task_id,</if>
|
||||||
|
<if test="wcsTaskStatus != null">wcs_task_status,</if>
|
||||||
|
<if test="wcsTaskType != null">wcs_task_type,</if>
|
||||||
|
<if test="taskPriority != null">task_priority,</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id,</if>
|
||||||
|
<if test="origin != null and origin != ''">origin,</if>
|
||||||
|
<if test="destination != null and destination != ''">destination,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="sendTime != null">send_time,</if>
|
||||||
|
<if test="finishTime != null">finish_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="wcsTaskId != null">#{wcsTaskId},</if>
|
||||||
|
<if test="wcsTaskStatus != null">#{wcsTaskStatus},</if>
|
||||||
|
<if test="wcsTaskType != null">#{wcsTaskType},</if>
|
||||||
|
<if test="taskPriority != null">#{taskPriority},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">#{vehicleId},</if>
|
||||||
|
<if test="origin != null and origin != ''">#{origin},</if>
|
||||||
|
<if test="destination != null and destination != ''">#{destination},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="sendTime != null">#{sendTime},</if>
|
||||||
|
<if test="finishTime != null">#{finishTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateAppWcsTask" parameterType="AppWcsTask">
|
||||||
|
update app_wcs_task
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="wcsTaskStatus != null">wcs_task_status = #{wcsTaskStatus},</if>
|
||||||
|
<if test="wcsTaskType != null">wcs_task_type = #{wcsTaskType},</if>
|
||||||
|
<if test="taskPriority != null">task_priority = #{taskPriority},</if>
|
||||||
|
<if test="vehicleId != null and vehicleId != ''">vehicle_id = #{vehicleId},</if>
|
||||||
|
<if test="origin != null and origin != ''">origin = #{origin},</if>
|
||||||
|
<if test="destination != null and destination != ''">destination = #{destination},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="sendTime != null">send_time = #{sendTime},</if>
|
||||||
|
<if test="finishTime != null">finish_time = #{finishTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where wcs_task_id = #{wcsTaskId}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteAppWcsTaskByWcsTaskId" parameterType="String">
|
||||||
|
delete from app_wcs_task where wcs_task_id = #{wcsTaskId}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteAppWcsTaskByWcsTaskIds" parameterType="String">
|
||||||
|
delete from app_wcs_task where wcs_task_id in
|
||||||
|
<foreach item="wcsTaskId" collection="array" open="(" separator="," close=")">
|
||||||
|
#{wcsTaskId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
Loading…
Reference in New Issue
Block a user