Merge remote-tracking branch 'origin/master'
commit
1471d4672c
@ -0,0 +1,42 @@
|
||||
package com.foreverwin.mesnac.common.controller;
|
||||
|
||||
import com.foreverwin.mesnac.common.enums.HandleEnum;
|
||||
import com.foreverwin.mesnac.common.model.MobileWorkStationData;
|
||||
import com.foreverwin.mesnac.common.service.MobileWorkStationService;
|
||||
import com.foreverwin.modular.core.util.CommonMethods;
|
||||
import com.foreverwin.modular.core.util.R;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author Syngna
|
||||
* @since 2020-01-04
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/mobileWorkStations")
|
||||
public class MobileWorkStationController {
|
||||
|
||||
@Autowired
|
||||
public MobileWorkStationService mobileWorkStationService;
|
||||
|
||||
@GetMapping("listMobileWorkStationApplication")
|
||||
public R listMobileWorkStationApplication(String workStation) {
|
||||
|
||||
List<MobileWorkStationData> result;
|
||||
try {
|
||||
String site = CommonMethods.getSite();
|
||||
String user = CommonMethods.getUser();
|
||||
String userBo = HandleEnum.USER.getHandle(site, user);
|
||||
result = mobileWorkStationService.listMobileWorkStationApplication(site, userBo, workStation);
|
||||
}
|
||||
catch (Exception e) {
|
||||
return R.failed(e.getMessage());
|
||||
}
|
||||
return R.ok(result);
|
||||
}
|
||||
}
|
@ -0,0 +1,16 @@
|
||||
package com.foreverwin.mesnac.common.mapper;
|
||||
|
||||
import com.foreverwin.mesnac.common.model.ActivityOption;
|
||||
import com.foreverwin.mesnac.common.model.MobileWorkStationData;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@Repository
|
||||
public interface MobileWorkStationMapper {
|
||||
|
||||
List<ActivityOption> selectActivityOptionList(@Param("activityBoList") List<String> activityBoList);
|
||||
|
||||
List<MobileWorkStationData> selectMobileWorkStationList(@Param("site") String site, @Param("userBo") String userBo, @Param("workStation") String workStation);
|
||||
}
|
@ -0,0 +1,34 @@
|
||||
package com.foreverwin.mesnac.common.model;
|
||||
|
||||
public class ActivityOption {
|
||||
|
||||
private String activity;
|
||||
|
||||
private String key;
|
||||
|
||||
private String value;
|
||||
|
||||
public String getActivity() {
|
||||
return activity;
|
||||
}
|
||||
|
||||
public void setActivity(String activity) {
|
||||
this.activity = activity;
|
||||
}
|
||||
|
||||
public String getKey() {
|
||||
return key;
|
||||
}
|
||||
|
||||
public void setKey(String key) {
|
||||
this.key = key;
|
||||
}
|
||||
|
||||
public String getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
public void setValue(String value) {
|
||||
this.value = value;
|
||||
}
|
||||
}
|
@ -0,0 +1,156 @@
|
||||
package com.foreverwin.mesnac.common.model;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class MobileWorkStationData {
|
||||
|
||||
private String workStationBo;
|
||||
|
||||
private String canChangeOperation;
|
||||
|
||||
private String canChangeResource;
|
||||
|
||||
private String defaultOperationBo;
|
||||
|
||||
private String defaultResourceBo;
|
||||
|
||||
private String mainInputPrompt;
|
||||
|
||||
private String sequence;
|
||||
|
||||
private String buttonId;
|
||||
|
||||
private String buttonSize;
|
||||
|
||||
private String label;
|
||||
|
||||
private String imageIcon;
|
||||
|
||||
private String activityBo;
|
||||
|
||||
private String activity;
|
||||
|
||||
private String classOrProgram;
|
||||
|
||||
private List<ActivityOption> activityOptionList;
|
||||
|
||||
public String getWorkStationBo() {
|
||||
return workStationBo;
|
||||
}
|
||||
|
||||
public void setWorkStationBo(String workStationBo) {
|
||||
this.workStationBo = workStationBo;
|
||||
}
|
||||
|
||||
public String getCanChangeOperation() {
|
||||
return canChangeOperation;
|
||||
}
|
||||
|
||||
public void setCanChangeOperation(String canChangeOperation) {
|
||||
this.canChangeOperation = canChangeOperation;
|
||||
}
|
||||
|
||||
public String getCanChangeResource() {
|
||||
return canChangeResource;
|
||||
}
|
||||
|
||||
public void setCanChangeResource(String canChangeResource) {
|
||||
this.canChangeResource = canChangeResource;
|
||||
}
|
||||
|
||||
public String getDefaultOperationBo() {
|
||||
return defaultOperationBo;
|
||||
}
|
||||
|
||||
public void setDefaultOperationBo(String defaultOperationBo) {
|
||||
this.defaultOperationBo = defaultOperationBo;
|
||||
}
|
||||
|
||||
public String getDefaultResourceBo() {
|
||||
return defaultResourceBo;
|
||||
}
|
||||
|
||||
public void setDefaultResourceBo(String defaultResourceBo) {
|
||||
this.defaultResourceBo = defaultResourceBo;
|
||||
}
|
||||
|
||||
public String getMainInputPrompt() {
|
||||
return mainInputPrompt;
|
||||
}
|
||||
|
||||
public void setMainInputPrompt(String mainInputPrompt) {
|
||||
this.mainInputPrompt = mainInputPrompt;
|
||||
}
|
||||
|
||||
public String getSequence() {
|
||||
return sequence;
|
||||
}
|
||||
|
||||
public void setSequence(String sequence) {
|
||||
this.sequence = sequence;
|
||||
}
|
||||
|
||||
public String getButtonId() {
|
||||
return buttonId;
|
||||
}
|
||||
|
||||
public void setButtonId(String buttonId) {
|
||||
this.buttonId = buttonId;
|
||||
}
|
||||
|
||||
public String getButtonSize() {
|
||||
return buttonSize;
|
||||
}
|
||||
|
||||
public void setButtonSize(String buttonSize) {
|
||||
this.buttonSize = buttonSize;
|
||||
}
|
||||
|
||||
public String getLabel() {
|
||||
return label;
|
||||
}
|
||||
|
||||
public void setLabel(String label) {
|
||||
this.label = label;
|
||||
}
|
||||
|
||||
public String getImageIcon() {
|
||||
return imageIcon;
|
||||
}
|
||||
|
||||
public void setImageIcon(String imageIcon) {
|
||||
this.imageIcon = imageIcon;
|
||||
}
|
||||
|
||||
public String getActivityBo() {
|
||||
return activityBo;
|
||||
}
|
||||
|
||||
public void setActivityBo(String activityBo) {
|
||||
this.activityBo = activityBo;
|
||||
}
|
||||
|
||||
public String getActivity() {
|
||||
return activity;
|
||||
}
|
||||
|
||||
public void setActivity(String activity) {
|
||||
this.activity = activity;
|
||||
}
|
||||
|
||||
public String getClassOrProgram() {
|
||||
return classOrProgram;
|
||||
}
|
||||
|
||||
public void setClassOrProgram(String classOrProgram) {
|
||||
this.classOrProgram = classOrProgram;
|
||||
}
|
||||
|
||||
public List<ActivityOption> getActivityOptionList() {
|
||||
return activityOptionList;
|
||||
}
|
||||
|
||||
public void setActivityOptionList(List<ActivityOption> activityOptionList) {
|
||||
this.activityOptionList = activityOptionList;
|
||||
}
|
||||
}
|
@ -0,0 +1,20 @@
|
||||
package com.foreverwin.mesnac.common.service;
|
||||
|
||||
|
||||
|
||||
import com.foreverwin.mesnac.common.model.MobileWorkStationData;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author Syngna
|
||||
* @since 2019-05-30
|
||||
*/
|
||||
public interface MobileWorkStationService {
|
||||
|
||||
List<MobileWorkStationData> listMobileWorkStationApplication(String site, String userBo, String workStation);
|
||||
}
|
@ -0,0 +1,48 @@
|
||||
package com.foreverwin.mesnac.common.service.impl;
|
||||
|
||||
import com.foreverwin.mesnac.common.mapper.MobileWorkStationMapper;
|
||||
import com.foreverwin.mesnac.common.model.ActivityOption;
|
||||
import com.foreverwin.mesnac.common.model.MobileWorkStationData;
|
||||
import com.foreverwin.mesnac.common.service.MobileWorkStationService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 移动维护服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author Syngna
|
||||
* @since 2020-01-04
|
||||
*/
|
||||
@Service
|
||||
public class MobileWorkStationServiceImpl implements MobileWorkStationService {
|
||||
|
||||
@Autowired
|
||||
private MobileWorkStationMapper mobileWorkStationMapper;
|
||||
|
||||
@Override
|
||||
public List<MobileWorkStationData> listMobileWorkStationApplication(String site, String userBo, String workStation) {
|
||||
List<MobileWorkStationData> workStationDataList = mobileWorkStationMapper.selectMobileWorkStationList(site, userBo, workStation);
|
||||
if(workStationDataList == null || workStationDataList.size() == 0) {
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<String> activityList = workStationDataList.stream().map(MobileWorkStationData::getActivityBo).collect(Collectors.toList());
|
||||
List<ActivityOption> activityOptionList = mobileWorkStationMapper.selectActivityOptionList(activityList);
|
||||
for(MobileWorkStationData mobileWorkStationData : workStationDataList) {
|
||||
if(mobileWorkStationData.getActivityOptionList() == null) {
|
||||
mobileWorkStationData.setActivityOptionList(new ArrayList<>());
|
||||
}
|
||||
for(ActivityOption activityOption: activityOptionList) {
|
||||
if(activityOption.getActivity().equals(mobileWorkStationData.getActivity())) {
|
||||
mobileWorkStationData.getActivityOptionList().add(activityOption);
|
||||
}
|
||||
}
|
||||
}
|
||||
return workStationDataList;
|
||||
}
|
||||
}
|
@ -0,0 +1,56 @@
|
||||
<?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.foreverwin.mesnac.common.mapper.MobileWorkStationMapper">
|
||||
<resultMap id="BaseResultMap" type="com.foreverwin.mesnac.common.model.MobileWorkStationData">
|
||||
<result column="WORKSTATION_BO" property="workStationBo" />
|
||||
<result column="CAN_CHANGE_OPERATION" property="canChangeOperation" />
|
||||
<result column="CAN_CHANGE_RESOURCE" property="canChangeResource" />
|
||||
<result column="DEFAULT_OPERATION_BO" property="defaultOperationBo" />
|
||||
<result column="DEFAULT_RESOURCE_BO" property="defaultResourceBo" />
|
||||
<result column="MAIN_INPUT_PROMPT" property="mainInputPrompt" />
|
||||
<result column="SEQUENCE" property="sequence" />
|
||||
<result column="BUTTON_ID" property="buttonId" />
|
||||
<result column="BUTTON_SIZE" property="buttonSize" />
|
||||
<result column="LABEL" property="label" />
|
||||
<result column="IMAGE_ICON" property="imageIcon" />
|
||||
<result column="ACTIVITY_BO" property="activityBo" />
|
||||
<result column="ACTIVITY" property="activity" />
|
||||
<result column="CLASS_OR_PROGRAM" property="classOrProgram" />
|
||||
</resultMap>
|
||||
|
||||
<resultMap id="ActivityOptionMap" type="com.foreverwin.mesnac.common.model.ActivityOption">
|
||||
<result column="ACTIVITY" property="activity" />
|
||||
<result column="KEY" property="key" />
|
||||
<result column="VALUE" property="value" />
|
||||
</resultMap>
|
||||
|
||||
<select id="selectActivityOptionList" resultMap="ActivityOptionMap">
|
||||
SELECT AC.ACTIVITY, AO.EXEC_UNIT_OPTION AS KEY, SETTING AS VALUE
|
||||
FROM ACTIVITY_OPTION AO
|
||||
INNER JOIN ACTIVITY AC ON AC.HANDLE = AO.ACTIVITY_BO
|
||||
WHERE AC.HANDLE IN
|
||||
<foreach collection="activityBoList" item="item" separator="," close=")" open="(">
|
||||
#{item}
|
||||
</foreach>
|
||||
</select>
|
||||
|
||||
<select id="selectMobileWorkStationList" resultMap="BaseResultMap">
|
||||
SELECT PC.WORKSTATION_BO, PC.CAN_CHANGE_OPERATION, PC.CAN_CHANGE_RESOURCE, PC.DEFAULT_OPERATION_BO, PC.DEFAULT_RESOURCE_BO, PC.MAIN_INPUT_PROMPT,
|
||||
PB.SEQUENCE, PB.BUTTON_ID, PB.BUTTON_SIZE, PB.LABEL, PB.IMAGE_ICON, PA.ACTIVITY_BO, AC.ACTIVITY, AC.CLASS_OR_PROGRAM
|
||||
FROM WORKSTATION WC
|
||||
INNER JOIN POD_CONFIG PC ON WC.HANDLE = PC.WORKSTATION_BO
|
||||
INNER JOIN POD_BUTTON PB ON PB.POD_CONFIG_BO = PC.HANDLE
|
||||
INNER JOIN POD_ACTIVITY PA ON PA.POD_BUTTON_BO = PB.HANDLE
|
||||
INNER JOIN ACTIVITY AC ON AC.HANDLE = PA.ACTIVITY_BO AND AC.ENABLED = 'true'
|
||||
INNER JOIN(
|
||||
SELECT AP.ACTIVITY_OR_GROUP_GBO AS ACTIVITY_BO
|
||||
FROM USER_GROUP_MEMBER UGM
|
||||
INNER JOIN ACTIVITY_PERM AP ON UGM.USER_GROUP_BO = AP.USER_OR_GROUP_GBO
|
||||
WHERE UGM.USER_OR_GROUP_GBO = #{userBo}
|
||||
GROUP BY AP.ACTIVITY_OR_GROUP_GBO
|
||||
)AP ON AP.ACTIVITY_BO = PA.ACTIVITY_BO
|
||||
WHERE WC.SITE = #{site}
|
||||
AND WC.WORKSTATION = #{workStation}
|
||||
AND WC.WORKSTATION_TYPE = 'C'
|
||||
</select>
|
||||
</mapper>
|
@ -0,0 +1,146 @@
|
||||
package com.foreverwin.mesnac.production.controller;
|
||||
|
||||
import com.foreverwin.mesnac.meapi.util.StringUtils;
|
||||
import com.foreverwin.modular.core.exception.BusinessException;
|
||||
import com.foreverwin.modular.core.util.R;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
import com.foreverwin.modular.core.util.CommonMethods;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import com.foreverwin.mesnac.production.service.SfcDataService;
|
||||
import com.foreverwin.mesnac.production.model.SfcData;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author Leon.L
|
||||
* @since 2021-06-29
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/SFC-DATA")
|
||||
public class SfcDataController {
|
||||
|
||||
@Autowired
|
||||
public SfcDataService sfcDataService;
|
||||
|
||||
/**
|
||||
* 根据id查询
|
||||
*
|
||||
* @param id 主键
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/{id:.+}")
|
||||
public R getSfcDataById(@PathVariable String id) {
|
||||
return R.ok( sfcDataService.getById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有数据
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("")
|
||||
public R getSfcDataList(SfcData sfcData){
|
||||
List<SfcData> result;
|
||||
QueryWrapper<SfcData> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(sfcData);
|
||||
result = sfcDataService.list(queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询数据
|
||||
*
|
||||
* @param frontPage 分页信息
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/page")
|
||||
public R page(FrontPage<SfcData> frontPage, SfcData sfcData){
|
||||
IPage result;
|
||||
QueryWrapper<SfcData> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(sfcData);
|
||||
if (frontPage.getGlobalQuery() != null && !"".equals(frontPage.getGlobalQuery().trim())) {
|
||||
//TODO modify global query
|
||||
queryWrapper.lambda().and(wrapper -> wrapper
|
||||
.like(SfcData::getHandle, frontPage.getGlobalQuery())
|
||||
.or().like(SfcData::getSfcBo, frontPage.getGlobalQuery())
|
||||
.or().like(SfcData::getDataField, frontPage.getGlobalQuery())
|
||||
.or().like(SfcData::getDataAttr, frontPage.getGlobalQuery())
|
||||
.or().like(SfcData::getUserBo, frontPage.getGlobalQuery())
|
||||
);
|
||||
}
|
||||
result = sfcDataService.page(frontPage.getPagePlus(), queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增
|
||||
* @param sfcData 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PostMapping
|
||||
public R save(@RequestBody SfcData sfcData) {
|
||||
return R.ok(sfcDataService.save(sfcData));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
* @param sfcData 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PutMapping
|
||||
public R updateById(@RequestBody SfcData sfcData) {
|
||||
return R.ok(sfcDataService.updateById(sfcData));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据id删除对象
|
||||
* @param id 实体ID
|
||||
* @return 0 失败 1 成功
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(method = RequestMethod.DELETE, value = "/{id:.+}")
|
||||
public R removeById(@PathVariable("id") String id){
|
||||
return R.ok(sfcDataService.removeById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除对象
|
||||
* @param ids 实体集合ID
|
||||
* @return 0 失败 1 成功
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(method = RequestMethod.POST, value = "/delete-batch")
|
||||
public R removeByIds(List<String> ids){
|
||||
return R.ok(sfcDataService.removeByIds(ids));
|
||||
}
|
||||
|
||||
|
||||
@ResponseBody
|
||||
@GetMapping("/saveSfcLocation")
|
||||
public R saveSfcLocation(String sfc, String location) {
|
||||
try {
|
||||
if (StringUtils.isBlank(sfc)) {
|
||||
throw BusinessException.build("SFC不能为空");
|
||||
}
|
||||
if (StringUtils.isBlank(location)) {
|
||||
throw BusinessException.build("位置不能为空");
|
||||
}
|
||||
|
||||
String site = CommonMethods.getSite();
|
||||
String user = CommonMethods.getUser();
|
||||
sfcDataService.saveSfcLocation(site, user, sfc, location);
|
||||
} catch (Exception e) {
|
||||
return R.failed(e.getMessage());
|
||||
}
|
||||
|
||||
return R.ok();
|
||||
}
|
||||
}
|
@ -0,0 +1,97 @@
|
||||
package com.foreverwin.mesnac.production.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.meapi.dto.SfcDto;
|
||||
import com.foreverwin.mesnac.meapi.model.Sfc;
|
||||
import com.foreverwin.mesnac.meapi.model.ShopOrder;
|
||||
import com.foreverwin.mesnac.production.model.StepOperation;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 描述: sfc过站
|
||||
* 作者: philip
|
||||
* 时间: 2021-6-29 15:56
|
||||
*/
|
||||
@Repository
|
||||
public interface SfcCrossMapper extends BaseMapper {
|
||||
|
||||
/**
|
||||
* 查找绑定的物料条码的SFC数量
|
||||
* @param dataField
|
||||
* @param dataAttr
|
||||
* @return
|
||||
*/
|
||||
List<Sfc> findBindingBarcode(@Param("dataField") String dataField,
|
||||
@Param("dataAttr") String dataAttr,
|
||||
@Param("site") String site,
|
||||
@Param("statusBoList") List<String> statusBoList);
|
||||
|
||||
|
||||
/**
|
||||
* 根据工艺路线查找下面所有的工序, 按照Sequence进行排序
|
||||
* @param routerBo
|
||||
* @return
|
||||
*/
|
||||
List<StepOperation> findRouterOperationByRouterBo(@Param("site") String site, @Param("routerBo") String routerBo, @Param("locale") String locale);
|
||||
|
||||
// String getDoneSfcItemBo(IPage page, @Param("dataAttr") String dataAttr,
|
||||
// @Param("site") String site, @Param("statusBo") String statusBo);
|
||||
|
||||
|
||||
/**
|
||||
* 根据工单查找未完成的SFC关联的SN信息
|
||||
* @param site
|
||||
* @param shopOrderRef
|
||||
* @return
|
||||
*/
|
||||
List<Sfc> findOpenStatusSnByShopOrder(@Param("site") String site, @Param("shopOrderRef") String shopOrderRef);
|
||||
|
||||
/**
|
||||
* 查询某条产线和给定状态的工单列表
|
||||
* @param plannedWorkCenterBo
|
||||
* @param customStatus
|
||||
* @return
|
||||
*/
|
||||
List<ShopOrder> findShopOrderListByStatus(@Param("plannedWorkCenterBo") String plannedWorkCenterBo,
|
||||
@Param("status") String customStatus);
|
||||
|
||||
//List<Map<String, Object>> findSfcListBySnList(@Param("site") String site, @Param("snList") List<String> snList);
|
||||
|
||||
/**
|
||||
* 查找工艺路线的最后一道工序
|
||||
* @param page
|
||||
* @param routerBo
|
||||
* @return
|
||||
*/
|
||||
StepOperation findRouterLastOperationByRouterBo(IPage page, @Param("routerBo") String routerBo);
|
||||
|
||||
/**
|
||||
* 根据SN查找最后一个有效的SFC信息
|
||||
* @param page
|
||||
* @param site
|
||||
* @param sn
|
||||
* @return
|
||||
*/
|
||||
Sfc findSfcBySn(IPage page, @Param("site") String site, @Param("sn") String sn);
|
||||
|
||||
/**
|
||||
* 根据SN查找最后一个有效的SFC信息包含完工状态
|
||||
* @param page
|
||||
* @param site
|
||||
* @param sn
|
||||
* @return
|
||||
*/
|
||||
Sfc findSfcBySnContainComplete(IPage page, @Param("site") String site, @Param("sn") String sn);
|
||||
|
||||
|
||||
List<StepOperation> getResourceBySfc(@Param("site") String site, @Param("sfc") String sfc);
|
||||
|
||||
Map<String, Object> querySfcData(@Param("site")String site, @Param("locale")String locale, @Param("dto")SfcDto sfcDto);
|
||||
|
||||
List<Map<String, Object>> querySfcStep(@Param("site")String site, @Param("sfc")String sfc, @Param("operation")String operation);
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
package com.foreverwin.mesnac.production.mapper;
|
||||
|
||||
import com.foreverwin.mesnac.production.model.SfcData;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author Leon.L
|
||||
* @since 2021-06-29
|
||||
*/
|
||||
@Repository
|
||||
public interface SfcDataMapper extends BaseMapper<SfcData> {
|
||||
|
||||
}
|
@ -0,0 +1,141 @@
|
||||
package com.foreverwin.mesnac.production.model;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.baomidou.mybatisplus.extension.activerecord.Model;
|
||||
import java.time.LocalDateTime;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author Leon.L
|
||||
* @since 2021-06-29
|
||||
*/
|
||||
|
||||
@TableName("SFC_DATA")
|
||||
public class SfcData extends Model<SfcData> {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@TableField("HANDLE")
|
||||
private String handle;
|
||||
@TableField("SFC_BO")
|
||||
private String sfcBo;
|
||||
@TableField("DATE_TIME")
|
||||
private LocalDateTime dateTime;
|
||||
@TableField("DATA_FIELD")
|
||||
private String dataField;
|
||||
@TableField("DATA_ATTR")
|
||||
private String dataAttr;
|
||||
@TableField("USER_BO")
|
||||
private String userBo;
|
||||
@TableField("CREATED_DATE_TIME")
|
||||
private LocalDateTime createdDateTime;
|
||||
@TableField("MODIFIED_DATE_TIME")
|
||||
private LocalDateTime modifiedDateTime;
|
||||
|
||||
|
||||
public String getHandle() {
|
||||
return handle;
|
||||
}
|
||||
|
||||
public void setHandle(String handle) {
|
||||
this.handle = handle;
|
||||
}
|
||||
|
||||
public String getSfcBo() {
|
||||
return sfcBo;
|
||||
}
|
||||
|
||||
public void setSfcBo(String sfcBo) {
|
||||
this.sfcBo = sfcBo;
|
||||
}
|
||||
|
||||
public LocalDateTime getDateTime() {
|
||||
return dateTime;
|
||||
}
|
||||
|
||||
public void setDateTime(LocalDateTime dateTime) {
|
||||
this.dateTime = dateTime;
|
||||
}
|
||||
|
||||
public String getDataField() {
|
||||
return dataField;
|
||||
}
|
||||
|
||||
public void setDataField(String dataField) {
|
||||
this.dataField = dataField;
|
||||
}
|
||||
|
||||
public String getDataAttr() {
|
||||
return dataAttr;
|
||||
}
|
||||
|
||||
public void setDataAttr(String dataAttr) {
|
||||
this.dataAttr = dataAttr;
|
||||
}
|
||||
|
||||
public String getUserBo() {
|
||||
return userBo;
|
||||
}
|
||||
|
||||
public void setUserBo(String userBo) {
|
||||
this.userBo = userBo;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreatedDateTime() {
|
||||
return createdDateTime;
|
||||
}
|
||||
|
||||
public void setCreatedDateTime(LocalDateTime createdDateTime) {
|
||||
this.createdDateTime = createdDateTime;
|
||||
}
|
||||
|
||||
public LocalDateTime getModifiedDateTime() {
|
||||
return modifiedDateTime;
|
||||
}
|
||||
|
||||
public void setModifiedDateTime(LocalDateTime modifiedDateTime) {
|
||||
this.modifiedDateTime = modifiedDateTime;
|
||||
}
|
||||
|
||||
public static final String HANDLE = "HANDLE";
|
||||
|
||||
public static final String SFC_BO = "SFC_BO";
|
||||
|
||||
public static final String DATE_TIME = "DATE_TIME";
|
||||
|
||||
public static final String DATA_FIELD = "DATA_FIELD";
|
||||
|
||||
public static final String DATA_ATTR = "DATA_ATTR";
|
||||
|
||||
public static final String USER_BO = "USER_BO";
|
||||
|
||||
public static final String CREATED_DATE_TIME = "CREATED_DATE_TIME";
|
||||
|
||||
public static final String MODIFIED_DATE_TIME = "MODIFIED_DATE_TIME";
|
||||
|
||||
|
||||
@Override
|
||||
protected Serializable pkVal() {
|
||||
return this.handle;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "SfcData{" +
|
||||
"handle = " + handle +
|
||||
", sfcBo = " + sfcBo +
|
||||
", dateTime = " + dateTime +
|
||||
", dataField = " + dataField +
|
||||
", dataAttr = " + dataAttr +
|
||||
", userBo = " + userBo +
|
||||
", createdDateTime = " + createdDateTime +
|
||||
", modifiedDateTime = " + modifiedDateTime +
|
||||
"}";
|
||||
}
|
||||
}
|
@ -0,0 +1,113 @@
|
||||
package com.foreverwin.mesnac.production.model;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 描述: 工序步骤
|
||||
* 作者: philip
|
||||
* 时间: 2021-6-29 08:48
|
||||
*/
|
||||
public class StepOperation {
|
||||
|
||||
private String operationBo;
|
||||
|
||||
private String operation;
|
||||
|
||||
private String description;
|
||||
|
||||
private String stepId;
|
||||
|
||||
private String erpOperation;
|
||||
|
||||
private BigDecimal sequence;
|
||||
|
||||
/** 步骤排队数量 **/
|
||||
private BigDecimal qtyInQueue;
|
||||
|
||||
/** 步骤在制数量 **/
|
||||
private BigDecimal qtyInWork;
|
||||
|
||||
private String reportingCenterBo;
|
||||
|
||||
private String resourceBo;
|
||||
|
||||
public String getResourceBo() {
|
||||
return resourceBo;
|
||||
}
|
||||
|
||||
public void setResourceBo(String resourceBo) {
|
||||
this.resourceBo = resourceBo;
|
||||
}
|
||||
|
||||
public String getOperationBo() {
|
||||
return operationBo;
|
||||
}
|
||||
|
||||
public void setOperationBo(String operationBo) {
|
||||
this.operationBo = operationBo;
|
||||
}
|
||||
|
||||
public String getOperation() {
|
||||
return operation;
|
||||
}
|
||||
|
||||
public void setOperation(String operation) {
|
||||
this.operation = operation;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public String getStepId() {
|
||||
return stepId;
|
||||
}
|
||||
|
||||
public void setStepId(String stepId) {
|
||||
this.stepId = stepId;
|
||||
}
|
||||
|
||||
public BigDecimal getSequence() {
|
||||
return sequence;
|
||||
}
|
||||
|
||||
public void setSequence(BigDecimal sequence) {
|
||||
this.sequence = sequence;
|
||||
}
|
||||
|
||||
public String getReportingCenterBo() {
|
||||
return reportingCenterBo;
|
||||
}
|
||||
|
||||
public void setReportingCenterBo(String reportingCenterBo) {
|
||||
this.reportingCenterBo = reportingCenterBo;
|
||||
}
|
||||
|
||||
public BigDecimal getQtyInQueue() {
|
||||
return qtyInQueue;
|
||||
}
|
||||
|
||||
public void setQtyInQueue(BigDecimal qtyInQueue) {
|
||||
this.qtyInQueue = qtyInQueue;
|
||||
}
|
||||
|
||||
public BigDecimal getQtyInWork() {
|
||||
return qtyInWork;
|
||||
}
|
||||
|
||||
public void setQtyInWork(BigDecimal qtyInWork) {
|
||||
this.qtyInWork = qtyInWork;
|
||||
}
|
||||
|
||||
public String getErpOperation() {
|
||||
return erpOperation;
|
||||
}
|
||||
|
||||
public void setErpOperation(String erpOperation) {
|
||||
this.erpOperation = erpOperation;
|
||||
}
|
||||
}
|
@ -0,0 +1,37 @@
|
||||
package com.foreverwin.mesnac.production.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.production.model.SfcData;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author Leon.L
|
||||
* @since 2021-06-29
|
||||
*/
|
||||
public interface SfcDataService extends IService<SfcData> {
|
||||
|
||||
/**
|
||||
* 分页查询
|
||||
* @param frontPage
|
||||
* @return
|
||||
*/
|
||||
IPage<SfcData> selectPage(FrontPage<SfcData> frontPage, SfcData sfcData);
|
||||
|
||||
List<SfcData> selectList(SfcData sfcData);
|
||||
|
||||
/**
|
||||
* 保存SFC的跟追位置
|
||||
*
|
||||
* @param site
|
||||
* @param sfc
|
||||
* @param location
|
||||
*/
|
||||
void saveSfcLocation(String site, String user, String sfc, String location);
|
||||
}
|
@ -0,0 +1,211 @@
|
||||
<?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.foreverwin.mesnac.production.mapper.SfcCrossMapper">
|
||||
|
||||
<resultMap id="StepOperationMap" type="com.foreverwin.mesnac.production.model.StepOperation">
|
||||
<result property="operationBo" column="OPERATION_BO" />
|
||||
<result property="stepId" column="STEP_ID" />
|
||||
<result property="sequence" column="SEQUENCE" javaType="java.math.BigDecimal" />
|
||||
<result property="reportingCenterBo" column="REPORTING_CENTER_BO" />
|
||||
<result property="operation" column="OPERATION" />
|
||||
<result property="description" column="DESCRIPTION" />
|
||||
<result property="resourceBo" column="RESOURCE_BO" />
|
||||
</resultMap>
|
||||
|
||||
<select id="findBindingBarcode" resultMap="com.foreverwin.mesnac.meapi.mapper.SfcMapper.BaseResultMap">
|
||||
SELECT
|
||||
SFC.HANDLE,
|
||||
SFC.SFC,
|
||||
SFC.SHOP_ORDER_BO,
|
||||
SFC.STATUS_BO
|
||||
FROM SFC SFC
|
||||
JOIN SFC_DATA DT ON DT.SFC_BO = SFC.HANDLE AND DT.DATA_FIELD = #{dataField}
|
||||
WHERE DT.DATA_ATTR = #{dataAttr}
|
||||
AND SFC.SITE = #{site}
|
||||
|
||||
<if test="statusBoList != null and statusBoList.size() > 0">
|
||||
AND SFC.STATUS_BO IN
|
||||
<foreach collection="statusBoList" item="item" index="index" open="(" close=")" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
|
||||
ORDER BY DT.DATE_TIME DESC
|
||||
</select>
|
||||
|
||||
<select id="findRouterOperationByRouterBo" resultMap="StepOperationMap">
|
||||
SELECT
|
||||
STEP.STEP_ID ,
|
||||
STEP."SEQUENCE",
|
||||
STEP.REPORTING_CENTER_BO,
|
||||
STEP.ERP_OPERATION ,
|
||||
OP.HANDLE AS OPERATION_BO,
|
||||
OP.OPERATION ,
|
||||
OPT.DESCRIPTION
|
||||
FROM ROUTER R
|
||||
JOIN ROUTER_STEP STEP ON R.HANDLE = STEP.ROUTER_BO
|
||||
JOIN ROUTER_OPERATION RO ON STEP.HANDLE = RO.ROUTER_STEP_BO
|
||||
JOIN OPERATION OP ON 'OperationBO:' || #{site} || ',' || OP.OPERATION || ',#' = RO.OPERATION_BO AND OP.CURRENT_REVISION = 'true'
|
||||
JOIN OPERATION_T OPT ON OP.HANDLE = OPT.OPERATION_BO AND OPT.LOCALE='zh'
|
||||
WHERE R.HANDLE = #{routerBo}
|
||||
AND OP.SITE = #{site}
|
||||
AND OPT.LOCALE = #{locale}
|
||||
ORDER BY STEP."SEQUENCE"
|
||||
</select>
|
||||
|
||||
<select id="findRouterLastOperationByRouterBo" resultMap="StepOperationMap">
|
||||
SELECT
|
||||
STEP.STEP_ID ,
|
||||
STEP."SEQUENCE",
|
||||
RO.OPERATION_BO
|
||||
FROM ROUTER R
|
||||
JOIN ROUTER_STEP STEP ON R.HANDLE = STEP.ROUTER_BO
|
||||
JOIN ROUTER_OPERATION RO ON STEP.HANDLE = RO.ROUTER_STEP_BO
|
||||
WHERE R.HANDLE = #{routerBo}
|
||||
ORDER BY STEP."SEQUENCE" DESC
|
||||
</select>
|
||||
|
||||
<select id="findShopOrderListByStatus" resultMap="com.foreverwin.mesnac.meapi.mapper.ShopOrderMapper.BaseResultMap">
|
||||
SELECT
|
||||
ORD.HANDLE,
|
||||
ORD.SHOP_ORDER,
|
||||
ORD.PLANNED_ITEM_BO,
|
||||
ORD.ITEM_BO
|
||||
FROM SHOP_ORDER ORD
|
||||
JOIN CUSTOM_FIELDS CF ON ORD.HANDLE = CF.HANDLE AND CF.ATTRIBUTE = 'WORK_ORDER_STATUS'
|
||||
WHERE ORD.PLANNED_WORK_CENTER_BO = #{plannedWorkCenterBo}
|
||||
AND CF.VALUE = #{status}
|
||||
</select>
|
||||
|
||||
<select id="findOpenStatusSnByShopOrder" resultMap="com.foreverwin.mesnac.meapi.mapper.SfcMapper.BaseResultMap">
|
||||
SELECT
|
||||
SFC.SFC,
|
||||
SFC.QTY ,
|
||||
SFC.CREATED_DATE_TIME
|
||||
FROM SFC SFC
|
||||
WHERE SFC.SHOP_ORDER_BO = #{shopOrderRef}
|
||||
AND SFC.SITE = #{site}
|
||||
AND SFC.STATUS_BO IN ('StatusBO:' || #{site} || ',403', 'StatusBO:' || #{site} || ',402')
|
||||
ORDER BY SFC.CREATED_DATE_TIME DESC
|
||||
</select>
|
||||
|
||||
<select id="findSfcBySn" resultMap="com.foreverwin.mesnac.meapi.mapper.SfcMapper.BaseResultMap">
|
||||
SELECT
|
||||
SFC.HANDLE,
|
||||
SFC.SFC,
|
||||
SFC.STATUS_BO,
|
||||
SFC.SHOP_ORDER_BO,
|
||||
SFC.QTY,
|
||||
SFC.ITEM_BO
|
||||
FROM SFC SFC
|
||||
JOIN SFC_DATA SD ON SFC.HANDLE = SD.SFC_BO AND SD.DATA_FIELD = 'SN'
|
||||
WHERE SFC.SITE = #{site}
|
||||
AND SD.DATA_ATTR = #{sn}
|
||||
AND SFC.STATUS_BO IN ('StatusBO:' || #{site} || ',403', 'StatusBO:' || #{site} || ',402' , 'StatusBO:'|| #{site} || ',401')
|
||||
ORDER BY SFC.CREATED_DATE_TIME DESC
|
||||
</select>
|
||||
|
||||
|
||||
<select id="findSfcBySnContainComplete" resultMap="com.foreverwin.mesnac.meapi.mapper.SfcMapper.BaseResultMap">
|
||||
SELECT
|
||||
SFC.HANDLE,
|
||||
SFC.SFC,
|
||||
SFC.STATUS_BO,
|
||||
SFC.SHOP_ORDER_BO,
|
||||
SFC.QTY,
|
||||
SFC.ITEM_BO
|
||||
FROM SFC SFC
|
||||
JOIN SFC_DATA SD ON SFC.HANDLE = SD.SFC_BO AND SD.DATA_FIELD = 'SN'
|
||||
WHERE SFC.SITE = #{site}
|
||||
AND SD.DATA_ATTR = #{sn}
|
||||
AND SFC.STATUS_BO IN ('StatusBO:' || #{site} || ',403', 'StatusBO:' || #{site} || ',402','StatusBO:' || #{site} || ',405')
|
||||
ORDER BY SFC.CREATED_DATE_TIME DESC
|
||||
</select>
|
||||
|
||||
<select id="getResourceBySfc" resultMap="StepOperationMap">
|
||||
select siw.RESOURCE_BO
|
||||
from sfc as sfc
|
||||
inner join sfc_routing as sri on sfc.handle = sri.sfc_bo
|
||||
inner join sfc_router as srt on sri.handle = srt.sfc_routing_bo
|
||||
inner join sfc_step as sep on srt.handle = sep.sfc_router_bo
|
||||
INNER JOIN SFC_IN_WORK siw ON sep.HANDLE = siw.SFC_STEP_BO
|
||||
WHERE sfc.site = #{site} and
|
||||
sfc.SFC = #{sfc}
|
||||
</select>
|
||||
<select id="querySfcData" resultType="map">
|
||||
SELECT SO.SHOP_ORDER, SO_CF.VALUE ITEM_NUMBER, I.ITEM, IT.DESCRIPTION ITEM_DESC,
|
||||
CASE WHEN ST.STATUS='403' AND SS.QTY_IN_QUEUE > 0 THEN N'402' ELSE ST.STATUS END STATUS,
|
||||
OP.OPERATION, OT.DESCRIPTION OPERATION_DESC,OP.OPERATION||'/'||RS.STEP_ID OPERATION_STEP,
|
||||
RO_CF2.VALUE TOOL ,SOD.HANDLE SFC_DISPATCH_DETAIL_BO,
|
||||
S.SFC,S.QTY SFC_QTY,RS.STEP_ID, SOD.DISPATCH_NO ,
|
||||
TO_CHAR( SOD.PLANNED_START_DATE + INTERVAL '8' HOUR,'yyyy-mm-dd hh24:mi:ss')START_DATE,
|
||||
TO_CHAR(SOD.PLANNED_COMPLETE_DATE + INTERVAL '8' HOUR ,'yyyy-mm-dd hh24:mi:ss')COMP_DATE,
|
||||
TO_CHAR((SOD.PLANNED_COMPLETE_DATE - SOD.PLANNED_START_DATE )*24,'fm9999999990.00')||'H' ADD_DATE,
|
||||
CASE WHEN OT.DESCRIPTION LIKE 'CH%' THEN SUBSTR(OT.DESCRIPTION, 0, 3) ELSE N'' END SLOT
|
||||
FROM SFC S
|
||||
INNER JOIN STATUS ST ON ST.HANDLE = S.STATUS_BO
|
||||
INNER JOIN SFC_ROUTING SR ON SR.SFC_BO = S.HANDLE
|
||||
INNER JOIN SFC_ROUTER SRO ON SRO.SFC_ROUTING_BO = SR.HANDLE AND SRO.IN_USE = 'true'
|
||||
INNER JOIN SFC_STEP SS ON SS.SFC_ROUTER_BO = SRO.HANDLE AND (SS.QTY_IN_QUEUE > 0 OR SS.QTY_IN_WORK > 0)
|
||||
INNER JOIN ROUTER RO ON SRO.ROUTER_BO = RO.HANDLE
|
||||
INNER JOIN ROUTER_STEP RS ON RS.ROUTER_BO = RO.HANDLE AND RS.STEP_ID = SS.STEP_ID
|
||||
INNER JOIN ROUTER_OPERATION ROP ON ROP.HANDLE = RS.ROUTER_COMP_GBO AND SS.OPERATION_BO = ROP.OPERATION_BO
|
||||
LEFT JOIN CUSTOM_FIELDS RO_CF2 ON RO_CF2.HANDLE = ROP.HANDLE AND RO_CF2."ATTRIBUTE" = 'TOOL_NUMBER'
|
||||
INNER JOIN OPERATION OP ON 'OperationBO:'||OP.SITE||','||OP.OPERATION||',#' = SS.OPERATION_BO AND OP.CURRENT_REVISION='true'
|
||||
AND (#{dto.operation} IS NULL OR OP.OPERATION = #{dto.operation})
|
||||
LEFT JOIN OPERATION_T OT ON OT.OPERATION_BO = OP.HANDLE AND OT.LOCALE =#{locale}
|
||||
INNER JOIN SHOP_ORDER SO ON SO.HANDLE = S.SHOP_ORDER_BO
|
||||
LEFT JOIN CUSTOM_FIELDS SO_CF ON SO_CF.HANDLE = SO.HANDLE AND SO_CF."ATTRIBUTE" = 'ITEM_NUMBER'
|
||||
INNER JOIN ITEM I ON I.HANDLE = S.ITEM_BO
|
||||
LEFT JOIN ITEM_T IT ON IT.ITEM_BO = I.HANDLE AND IT.LOCALE =#{locale}
|
||||
INNER JOIN (
|
||||
SELECT SD.HANDLE, SD.SFC,SD.RESRCE,SD.OPERATION,SD.STEP_ID,SD.PLANNED_COMPLETE_DATE, SD.PLANNED_START_DATE,SD.DISPATCH_NO
|
||||
FROM Z_PROD_READY_TASK RB
|
||||
INNER JOIN Z_SFC_DISPATCH SD ON SD.HANDLE = RB.SFC_DISPATCH_BO
|
||||
WHERE RB.SITE =#{site} AND RB.STATUS = 'F'
|
||||
) SOD ON SOD.RESRCE =#{dto.resrce} AND SOD.SFC= S.SFC AND SOD.OPERATION = OP.OPERATION
|
||||
WHERE S.SITE = #{site} AND S.SFC = #{dto.sfc} AND ROWNUM=1
|
||||
GROUP BY SO.SHOP_ORDER, SO_CF.VALUE , I.ITEM, IT.DESCRIPTION ,
|
||||
CASE WHEN ST.STATUS='403' AND SS.QTY_IN_QUEUE > 0 THEN N'402' ELSE ST.STATUS END,
|
||||
OP.OPERATION, OT.DESCRIPTION ,OP.OPERATION||'/'||RS.STEP_ID ,RO_CF2.VALUE,
|
||||
S.SFC,S.QTY ,RS.STEP_ID,SOD.DISPATCH_NO , SOD.HANDLE ,
|
||||
TO_CHAR( SOD.PLANNED_START_DATE + INTERVAL '8' HOUR,'yyyy-mm-dd hh24:mi:ss'),
|
||||
TO_CHAR(SOD.PLANNED_COMPLETE_DATE + INTERVAL '8' HOUR,'yyyy-mm-dd hh24:mi:ss'),
|
||||
TO_CHAR((SOD.PLANNED_COMPLETE_DATE - SOD.PLANNED_START_DATE )*24,'fm9999999990.00')||'H',
|
||||
CASE WHEN OT.DESCRIPTION LIKE 'CH%' THEN SUBSTR(OT.DESCRIPTION, 0, 3) ELSE N'' END
|
||||
</select>
|
||||
<select id="querySfcStep" resultType="map">
|
||||
SELECT B1.OPERATION,B1.STEP_ID,B1.DESCRIPTION STEP_DESC,B1.STATE,
|
||||
B1.HANDLE,B1."SEQUENCE",
|
||||
CASE WHEN B1."SEQUENCE"=B1.MAXSEQ THEN 'true'
|
||||
ELSE 'false' END IS_SEQTRUE,B1.LONG_DESCRIPTION,
|
||||
CASE WHEN B1.STATE ='FINISHED' THEN N'已完工'
|
||||
WHEN B1."SEQUENCE"=B1.MAXSEQ AND B1.STATE ='READY' AND B1.STATUS ='403' THEN N'加工中'
|
||||
ELSE N'未加工'
|
||||
END STEP_STATUS
|
||||
FROM (
|
||||
SELECT A1.*,MAX(A1.SELECTSEQ) OVER(PARTITION BY OPERATION) MAXSEQ
|
||||
FROM (
|
||||
SELECT O.OPERATION,SST.SUBSTEP STEP_ID,SS.STATE,
|
||||
NVL(SST.DESCRIPTION,SU.DESCRIPTION) DESCRIPTION,
|
||||
CASE WHEN SS.STATE ='FINISHED' THEN N'已完工' ELSE N'加工中' END STEP_STATUS,
|
||||
SS.HANDLE,SS."SEQUENCE",
|
||||
CASE WHEN SS.STATE='FINISHED' THEN SST."SEQUENCE"+1 ELSE 0 END SELECTSEQ,ST.STATUS,
|
||||
NVL(SST.LONG_DESCRIPTION,SU.LONG_DESCRIPTION) LONG_DESCRIPTION
|
||||
FROM SFC_SUBSTEP SS
|
||||
INNER JOIN SFC_STEP SSTEP ON SS.SFC_STEP_BO=SSTEP.HANDLE AND SSTEP.DONE='false'
|
||||
AND (SSTEP.QTY_IN_QUEUE > 0 OR SSTEP.QTY_IN_WORK > 0)
|
||||
INNER JOIN SFC_ROUTER SR ON SR.HANDLE=SSTEP.SFC_ROUTER_BO
|
||||
INNER JOIN SFC_ROUTING SRI ON SRI.HANDLE=SR.SFC_ROUTING_BO
|
||||
INNER JOIN ROUTER_SUBSTEP SST ON SS.ROUTER_SUBSTEP_BO = SST.HANDLE
|
||||
LEFT JOIN SUBSTEP SU ON SU.SUBSTEP = SST.SUBSTEP AND SU.CURRENT_REVISION = 'true' AND SU.SITE = #{site}
|
||||
INNER JOIN SFC S ON S.HANDLE=SRI.SFC_BO
|
||||
INNER JOIN STATUS ST ON ST.HANDLE = S.STATUS_BO
|
||||
INNER JOIN OPERATION O ON O.OPERATION=SPLIT(SSTEP.OPERATION_BO,2) AND O.SITE=S.SITE AND O.CURRENT_REVISION = 'true'
|
||||
AND #{operation} IS NULL OR #{operation} = O.OPERATION)
|
||||
WHERE S.SFC=#{sfc} AND S.SITE= #{site} ORDER BY SST."SEQUENCE"
|
||||
) A1
|
||||
) B1 ORDER BY B1."SEQUENCE" ASC
|
||||
|
||||
</select>
|
||||
</mapper>
|
@ -0,0 +1,332 @@
|
||||
<?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.foreverwin.mesnac.production.mapper.SfcDataMapper">
|
||||
|
||||
<!-- 通用查询映射结果 -->
|
||||
<resultMap id="BaseResultMap" type="com.foreverwin.mesnac.production.model.SfcData">
|
||||
<result column="HANDLE" property="handle" />
|
||||
<result column="SFC_BO" property="sfcBo" />
|
||||
<result column="DATE_TIME" property="dateTime" />
|
||||
<result column="DATA_FIELD" property="dataField" />
|
||||
<result column="DATA_ATTR" property="dataAttr" />
|
||||
<result column="USER_BO" property="userBo" />
|
||||
<result column="CREATED_DATE_TIME" property="createdDateTime" />
|
||||
<result column="MODIFIED_DATE_TIME" property="modifiedDateTime" />
|
||||
</resultMap>
|
||||
|
||||
<!-- 通用查询结果列 -->
|
||||
<sql id="Base_Column_List">
|
||||
HANDLE, SFC_BO, DATE_TIME, DATA_FIELD, DATA_ATTR, USER_BO, CREATED_DATE_TIME, MODIFIED_DATE_TIME
|
||||
</sql>
|
||||
|
||||
<!-- BaseMapper标准查询/修改/删除 -->
|
||||
|
||||
<select id="selectByMap" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include>
|
||||
FROM SFC_DATA
|
||||
<if test="cm!=null and !cm.isEmpty">
|
||||
<where>
|
||||
<foreach collection="cm.keys" item="k" separator="AND">
|
||||
<if test="cm[k] != null">
|
||||
${k} = #{cm[${k}]}
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</if>
|
||||
</select>
|
||||
|
||||
|
||||
<select id="selectOne" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include> FROM SFC_DATA
|
||||
<where>
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.handle}
|
||||
</if>
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectCount" resultType="Integer">
|
||||
SELECT COUNT(1) FROM SFC_DATA
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
</if>
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</if>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.nonEmptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<select id="selectList" resultMap="BaseResultMap">
|
||||
SELECT <choose><when test="ew != null and ew.sqlSelect != null">${ew.sqlSelect}</when><otherwise><include refid="Base_Column_List"></include></otherwise></choose> FROM SFC_DATA
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
</if>
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</if>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.nonEmptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<select id="selectMaps" resultType="HashMap">
|
||||
SELECT <choose><when test="ew != null and ew.sqlSelect != null">${ew.sqlSelect}</when><otherwise><include refid="Base_Column_List"></include></otherwise></choose> FROM SFC_DATA
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
</if>
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</if>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.nonEmptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<select id="selectObjs" resultType="Object">
|
||||
SELECT <choose><when test="ew != null and ew.sqlSelect != null">${ew.sqlSelect}</when><otherwise><include refid="Base_Column_List"></include></otherwise></choose> FROM SFC_DATA
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
</if>
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</if>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.nonEmptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<select id="selectPage" resultMap="BaseResultMap">
|
||||
SELECT <choose><when test="ew != null and ew.sqlSelect != null">${ew.sqlSelect}</when><otherwise><include refid="Base_Column_List"></include></otherwise></choose> FROM SFC_DATA
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
</if>
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</if>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.nonEmptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<select id="selectMapsPage" resultType="HashMap">
|
||||
SELECT <choose><when test="ew != null and ew.sqlSelect != null">${ew.sqlSelect}</when><otherwise><include refid="Base_Column_List"></include></otherwise></choose> FROM SFC_DATA
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
</if>
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</if>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.nonEmptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<insert id="insert" parameterType="com.foreverwin.mesnac.production.model.SfcData">
|
||||
INSERT INTO SFC_DATA
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
HANDLE,
|
||||
<if test="sfcBo!=null">SFC_BO,</if>
|
||||
<if test="dateTime!=null">DATE_TIME,</if>
|
||||
<if test="dataField!=null">DATA_FIELD,</if>
|
||||
<if test="dataAttr!=null">DATA_ATTR,</if>
|
||||
<if test="userBo!=null">USER_BO,</if>
|
||||
<if test="createdDateTime!=null">CREATED_DATE_TIME,</if>
|
||||
<if test="modifiedDateTime!=null">MODIFIED_DATE_TIME,</if>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
<if test="sfcBo!=null">#{sfcBo},</if>
|
||||
<if test="dateTime!=null">#{dateTime},</if>
|
||||
<if test="dataField!=null">#{dataField},</if>
|
||||
<if test="dataAttr!=null">#{dataAttr},</if>
|
||||
<if test="userBo!=null">#{userBo},</if>
|
||||
<if test="createdDateTime!=null">#{createdDateTime},</if>
|
||||
<if test="modifiedDateTime!=null">#{modifiedDateTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<insert id="insertAllColumn" parameterType="com.foreverwin.mesnac.production.model.SfcData">
|
||||
INSERT INTO SFC_DATA
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<include refid="Base_Column_List"></include>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
#{sfcBo},
|
||||
#{dateTime},
|
||||
#{dataField},
|
||||
#{dataAttr},
|
||||
#{userBo},
|
||||
#{createdDateTime},
|
||||
#{modifiedDateTime},
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<update id="update">
|
||||
UPDATE SFC_DATA <trim prefix="SET" suffixOverrides=",">
|
||||
<if test="et.handle!=null">HANDLE=#{et.handle},</if>
|
||||
<if test="et.sfcBo!=null">SFC_BO=#{et.sfcBo},</if>
|
||||
<if test="et.dateTime!=null">DATE_TIME=#{et.dateTime},</if>
|
||||
<if test="et.dataField!=null">DATA_FIELD=#{et.dataField},</if>
|
||||
<if test="et.dataAttr!=null">DATA_ATTR=#{et.dataAttr},</if>
|
||||
<if test="et.userBo!=null">USER_BO=#{et.userBo},</if>
|
||||
<if test="et.createdDateTime!=null">CREATED_DATE_TIME=#{et.createdDateTime},</if>
|
||||
<if test="et.modifiedDateTime!=null">MODIFIED_DATE_TIME=#{et.modifiedDateTime},</if>
|
||||
</trim>
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</if>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.nonEmptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</update>
|
||||
|
||||
|
||||
<delete id="deleteByMap">
|
||||
DELETE FROM SFC_DATA
|
||||
<if test="cm!=null and !cm.isEmpty">
|
||||
<where>
|
||||
<foreach collection="cm.keys" item="k" separator="AND">
|
||||
<if test="cm[k] != null">
|
||||
${k} = #{cm[${k}]}
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</if>
|
||||
</delete>
|
||||
|
||||
<delete id="delete">
|
||||
DELETE FROM SFC_DATA
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
</if>
|
||||
<if test="ew.entity.sfcBo!=null"> AND SFC_BO=#{ew.entity.sfcBo}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.dataField!=null"> AND DATA_FIELD=#{ew.entity.dataField}</if>
|
||||
<if test="ew.entity.dataAttr!=null"> AND DATA_ATTR=#{ew.entity.dataAttr}</if>
|
||||
<if test="ew.entity.userBo!=null"> AND USER_BO=#{ew.entity.userBo}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifiedDateTime!=null"> AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}</if>
|
||||
</if>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.nonEmptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</if>
|
||||
</where>
|
||||
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">
|
||||
${ew.sqlSegment}
|
||||
</if>
|
||||
</delete>
|
||||
|
||||
<!-- BaseMapper标准查询/修改/删除 -->
|
||||
|
||||
</mapper>
|
Loading…
Reference in New Issue