设备接口模块更新
parent
44d88c8fc6
commit
477da3d3a3
@ -0,0 +1,152 @@
|
||||
package com.foreverwin.mesnac.equip.controller;
|
||||
|
||||
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.equip.service.EdcDataResourceService;
|
||||
import com.foreverwin.mesnac.equip.model.EdcDataResource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/Z-EDC-DATA-RESOURCE")
|
||||
public class EdcDataResourceController {
|
||||
|
||||
@Autowired
|
||||
public EdcDataResourceService edcDataResourceService;
|
||||
|
||||
/**
|
||||
* 根据id查询
|
||||
*
|
||||
* @param id 主键
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/{id:.+}")
|
||||
public R getEdcDataResourceById(@PathVariable String id) {
|
||||
return R.ok( edcDataResourceService.getById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有数据
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("")
|
||||
public R getEdcDataResourceList(EdcDataResource edcDataResource){
|
||||
List<EdcDataResource> result;
|
||||
QueryWrapper<EdcDataResource> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(edcDataResource);
|
||||
result = edcDataResourceService.list(queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询数据
|
||||
*
|
||||
* @param frontPage 分页信息
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/page")
|
||||
public R page(FrontPage<EdcDataResource> frontPage, EdcDataResource edcDataResource){
|
||||
IPage result;
|
||||
QueryWrapper<EdcDataResource> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(edcDataResource);
|
||||
if (frontPage.getGlobalQuery() != null && !"".equals(frontPage.getGlobalQuery().trim())) {
|
||||
//TODO modify global query
|
||||
queryWrapper.lambda().and(wrapper -> wrapper
|
||||
.like(EdcDataResource::getHandle, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getSite, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getResrce, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getDcGroupBo, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getCreateUser, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS1, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS2, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS3, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS4, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS5, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS6, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS7, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS8, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS9, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS10, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS11, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS12, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS13, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS14, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS15, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS16, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS17, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS18, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS19, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS20, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS21, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS22, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS23, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS24, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS25, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS26, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS27, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS28, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS29, frontPage.getGlobalQuery())
|
||||
.or().like(EdcDataResource::getS30, frontPage.getGlobalQuery())
|
||||
);
|
||||
}
|
||||
result = edcDataResourceService.page(frontPage.getPagePlus(), queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增
|
||||
* @param edcDataResource 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PostMapping
|
||||
public R save(@RequestBody EdcDataResource edcDataResource) {
|
||||
return R.ok(edcDataResourceService.save(edcDataResource));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
* @param edcDataResource 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PutMapping
|
||||
public R updateById(@RequestBody EdcDataResource edcDataResource) {
|
||||
return R.ok(edcDataResourceService.updateById(edcDataResource));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据id删除对象
|
||||
* @param id 实体ID
|
||||
* @return 0 失败 1 成功
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(method = RequestMethod.DELETE, value = "/{id:.+}")
|
||||
public R removeById(@PathVariable("id") String id){
|
||||
return R.ok(edcDataResourceService.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(edcDataResourceService.removeByIds(ids));
|
||||
}
|
||||
}
|
@ -0,0 +1,123 @@
|
||||
package com.foreverwin.mesnac.equip.controller;
|
||||
|
||||
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.equip.service.ResourceFaultReceiveService;
|
||||
import com.foreverwin.mesnac.equip.model.ResourceFaultReceive;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/Z-RESOURCE-FAULT-RECEIVE")
|
||||
public class ResourceFaultReceiveController {
|
||||
|
||||
@Autowired
|
||||
public ResourceFaultReceiveService resourceFaultReceiveService;
|
||||
|
||||
/**
|
||||
* 根据id查询
|
||||
*
|
||||
* @param id 主键
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/{id:.+}")
|
||||
public R getResourceFaultReceiveById(@PathVariable String id) {
|
||||
return R.ok( resourceFaultReceiveService.getById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有数据
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("")
|
||||
public R getResourceFaultReceiveList(ResourceFaultReceive resourceFaultReceive){
|
||||
List<ResourceFaultReceive> result;
|
||||
QueryWrapper<ResourceFaultReceive> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(resourceFaultReceive);
|
||||
result = resourceFaultReceiveService.list(queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询数据
|
||||
*
|
||||
* @param frontPage 分页信息
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/page")
|
||||
public R page(FrontPage<ResourceFaultReceive> frontPage, ResourceFaultReceive resourceFaultReceive){
|
||||
IPage result;
|
||||
QueryWrapper<ResourceFaultReceive> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(resourceFaultReceive);
|
||||
if (frontPage.getGlobalQuery() != null && !"".equals(frontPage.getGlobalQuery().trim())) {
|
||||
//TODO modify global query
|
||||
queryWrapper.lambda().and(wrapper -> wrapper
|
||||
.like(ResourceFaultReceive::getHandle, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceFaultReceive::getSite, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceFaultReceive::getResrce, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceFaultReceive::getFaultCode, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceFaultReceive::getCreateUser, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceFaultReceive::getModifyUser, frontPage.getGlobalQuery())
|
||||
);
|
||||
}
|
||||
result = resourceFaultReceiveService.page(frontPage.getPagePlus(), queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增
|
||||
* @param resourceFaultReceive 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PostMapping
|
||||
public R save(@RequestBody ResourceFaultReceive resourceFaultReceive) {
|
||||
return R.ok(resourceFaultReceiveService.save(resourceFaultReceive));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
* @param resourceFaultReceive 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PutMapping
|
||||
public R updateById(@RequestBody ResourceFaultReceive resourceFaultReceive) {
|
||||
return R.ok(resourceFaultReceiveService.updateById(resourceFaultReceive));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据id删除对象
|
||||
* @param id 实体ID
|
||||
* @return 0 失败 1 成功
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(method = RequestMethod.DELETE, value = "/{id:.+}")
|
||||
public R removeById(@PathVariable("id") String id){
|
||||
return R.ok(resourceFaultReceiveService.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(resourceFaultReceiveService.removeByIds(ids));
|
||||
}
|
||||
}
|
@ -0,0 +1,124 @@
|
||||
package com.foreverwin.mesnac.equip.controller;
|
||||
|
||||
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.equip.service.ResourceStatusReceiveService;
|
||||
import com.foreverwin.mesnac.equip.model.ResourceStatusReceive;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/Z-RESOURCE-STATUS-RECEIVE")
|
||||
public class ResourceStatusReceiveController {
|
||||
|
||||
@Autowired
|
||||
public ResourceStatusReceiveService resourceStatusReceiveService;
|
||||
|
||||
/**
|
||||
* 根据id查询
|
||||
*
|
||||
* @param id 主键
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/{id:.+}")
|
||||
public R getResourceStatusReceiveById(@PathVariable String id) {
|
||||
return R.ok( resourceStatusReceiveService.getById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有数据
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("")
|
||||
public R getResourceStatusReceiveList(ResourceStatusReceive resourceStatusReceive){
|
||||
List<ResourceStatusReceive> result;
|
||||
QueryWrapper<ResourceStatusReceive> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(resourceStatusReceive);
|
||||
result = resourceStatusReceiveService.list(queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询数据
|
||||
*
|
||||
* @param frontPage 分页信息
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/page")
|
||||
public R page(FrontPage<ResourceStatusReceive> frontPage, ResourceStatusReceive resourceStatusReceive){
|
||||
IPage result;
|
||||
QueryWrapper<ResourceStatusReceive> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(resourceStatusReceive);
|
||||
if (frontPage.getGlobalQuery() != null && !"".equals(frontPage.getGlobalQuery().trim())) {
|
||||
//TODO modify global query
|
||||
queryWrapper.lambda().and(wrapper -> wrapper
|
||||
.like(ResourceStatusReceive::getHandle, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceStatusReceive::getSite, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceStatusReceive::getResrce, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceStatusReceive::getStatus, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceStatusReceive::getChangeStatus, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceStatusReceive::getCreateUser, frontPage.getGlobalQuery())
|
||||
.or().like(ResourceStatusReceive::getModifyUser, frontPage.getGlobalQuery())
|
||||
);
|
||||
}
|
||||
result = resourceStatusReceiveService.page(frontPage.getPagePlus(), queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增
|
||||
* @param resourceStatusReceive 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PostMapping
|
||||
public R save(@RequestBody ResourceStatusReceive resourceStatusReceive) {
|
||||
return R.ok(resourceStatusReceiveService.save(resourceStatusReceive));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
* @param resourceStatusReceive 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PutMapping
|
||||
public R updateById(@RequestBody ResourceStatusReceive resourceStatusReceive) {
|
||||
return R.ok(resourceStatusReceiveService.updateById(resourceStatusReceive));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据id删除对象
|
||||
* @param id 实体ID
|
||||
* @return 0 失败 1 成功
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(method = RequestMethod.DELETE, value = "/{id:.+}")
|
||||
public R removeById(@PathVariable("id") String id){
|
||||
return R.ok(resourceStatusReceiveService.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(resourceStatusReceiveService.removeByIds(ids));
|
||||
}
|
||||
}
|
@ -0,0 +1,22 @@
|
||||
package com.foreverwin.mesnac.equip.dto;
|
||||
|
||||
public class EdcDataResourceDto {
|
||||
private String param;
|
||||
private String paramVal;
|
||||
|
||||
public String getParam() {
|
||||
return param;
|
||||
}
|
||||
|
||||
public void setParam(String param) {
|
||||
this.param = param;
|
||||
}
|
||||
|
||||
public String getParamVal() {
|
||||
return paramVal;
|
||||
}
|
||||
|
||||
public void setParamVal(String paramVal) {
|
||||
this.paramVal = paramVal;
|
||||
}
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
package com.foreverwin.mesnac.equip.mapper;
|
||||
|
||||
import com.foreverwin.mesnac.equip.model.ResourceFaultReceive;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 设备故障信息接收表-接口 Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@Repository
|
||||
public interface ResourceFaultReceiveMapper extends BaseMapper<ResourceFaultReceive> {
|
||||
|
||||
}
|
@ -0,0 +1,22 @@
|
||||
package com.foreverwin.mesnac.equip.mapper;
|
||||
|
||||
import com.foreverwin.mesnac.equip.model.ResourceStatusReceive;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 设备状态表-接口 Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@Repository
|
||||
public interface ResourceStatusReceiveMapper extends BaseMapper<ResourceStatusReceive> {
|
||||
|
||||
// 获取最新的记录
|
||||
ResourceStatusReceive getOneByMaxCreateDateTime(@Param("site") String site);
|
||||
|
||||
}
|
@ -0,0 +1,912 @@
|
||||
package com.foreverwin.mesnac.equip.model;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.baomidou.mybatisplus.extension.activerecord.Model;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import java.time.LocalDateTime;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import java.io.Serializable;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
|
||||
@TableName("Z_EDC_DATA_RESOURCE")
|
||||
|
||||
public class EdcDataResource extends Model<EdcDataResource> {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@TableId(value = "HANDLE", type = IdType.INPUT)
|
||||
private String handle;
|
||||
@TableField("SITE")
|
||||
private String site;
|
||||
@TableField("RESRCE")
|
||||
private String resrce;
|
||||
@TableField("DC_GROUP_BO")
|
||||
private String dcGroupBo;
|
||||
@TableField("DATE_TIME")
|
||||
private LocalDateTime dateTime;
|
||||
@TableField("CREATED_DATE_TIME")
|
||||
private LocalDateTime createdDateTime;
|
||||
@TableField("CREATE_USER")
|
||||
private String createUser;
|
||||
@TableField("S1")
|
||||
private String s1;
|
||||
@TableField("S2")
|
||||
private String s2;
|
||||
@TableField("S3")
|
||||
private String s3;
|
||||
@TableField("S4")
|
||||
private String s4;
|
||||
@TableField("S5")
|
||||
private String s5;
|
||||
@TableField("S6")
|
||||
private String s6;
|
||||
@TableField("S7")
|
||||
private String s7;
|
||||
@TableField("S8")
|
||||
private String s8;
|
||||
@TableField("S9")
|
||||
private String s9;
|
||||
@TableField("S10")
|
||||
private String s10;
|
||||
@TableField("S11")
|
||||
private String s11;
|
||||
@TableField("S12")
|
||||
private String s12;
|
||||
@TableField("S13")
|
||||
private String s13;
|
||||
@TableField("S14")
|
||||
private String s14;
|
||||
@TableField("S15")
|
||||
private String s15;
|
||||
@TableField("S16")
|
||||
private String s16;
|
||||
@TableField("S17")
|
||||
private String s17;
|
||||
@TableField("S18")
|
||||
private String s18;
|
||||
@TableField("S19")
|
||||
private String s19;
|
||||
@TableField("S20")
|
||||
private String s20;
|
||||
@TableField("S21")
|
||||
private String s21;
|
||||
@TableField("S22")
|
||||
private String s22;
|
||||
@TableField("S23")
|
||||
private String s23;
|
||||
@TableField("S24")
|
||||
private String s24;
|
||||
@TableField("S25")
|
||||
private String s25;
|
||||
@TableField("S26")
|
||||
private String s26;
|
||||
@TableField("S27")
|
||||
private String s27;
|
||||
@TableField("S28")
|
||||
private String s28;
|
||||
@TableField("S29")
|
||||
private String s29;
|
||||
@TableField("S30")
|
||||
private String s30;
|
||||
@TableField("N1")
|
||||
private Double n1;
|
||||
@TableField("N2")
|
||||
private Double n2;
|
||||
@TableField("N3")
|
||||
private Double n3;
|
||||
@TableField("N4")
|
||||
private Double n4;
|
||||
@TableField("N5")
|
||||
private Double n5;
|
||||
@TableField("N6")
|
||||
private Double n6;
|
||||
@TableField("N7")
|
||||
private Double n7;
|
||||
@TableField("N8")
|
||||
private Double n8;
|
||||
@TableField("N9")
|
||||
private Double n9;
|
||||
@TableField("N10")
|
||||
private Double n10;
|
||||
@TableField("N11")
|
||||
private Double n11;
|
||||
@TableField("N12")
|
||||
private Double n12;
|
||||
@TableField("N13")
|
||||
private Double n13;
|
||||
@TableField("N14")
|
||||
private Double n14;
|
||||
@TableField("N15")
|
||||
private Double n15;
|
||||
@TableField("N16")
|
||||
private Double n16;
|
||||
@TableField("N17")
|
||||
private Double n17;
|
||||
@TableField("N18")
|
||||
private Double n18;
|
||||
@TableField("N19")
|
||||
private Double n19;
|
||||
@TableField("N20")
|
||||
private Double n20;
|
||||
@TableField("N21")
|
||||
private Double n21;
|
||||
@TableField("N22")
|
||||
private Double n22;
|
||||
@TableField("N23")
|
||||
private Double n23;
|
||||
@TableField("N24")
|
||||
private Double n24;
|
||||
@TableField("N25")
|
||||
private Double n25;
|
||||
@TableField("N26")
|
||||
private Double n26;
|
||||
@TableField("N27")
|
||||
private Double n27;
|
||||
@TableField("N28")
|
||||
private Double n28;
|
||||
@TableField("N29")
|
||||
private Double n29;
|
||||
@TableField("N30")
|
||||
private Double n30;
|
||||
|
||||
|
||||
public String getHandle() {
|
||||
return handle;
|
||||
}
|
||||
|
||||
public void setHandle(String handle) {
|
||||
this.handle = handle;
|
||||
}
|
||||
|
||||
public String getSite() {
|
||||
return site;
|
||||
}
|
||||
|
||||
public void setSite(String site) {
|
||||
this.site = site;
|
||||
}
|
||||
|
||||
public String getResrce() {
|
||||
return resrce;
|
||||
}
|
||||
|
||||
public void setResrce(String resrce) {
|
||||
this.resrce = resrce;
|
||||
}
|
||||
|
||||
public String getDcGroupBo() {
|
||||
return dcGroupBo;
|
||||
}
|
||||
|
||||
public void setDcGroupBo(String dcGroupBo) {
|
||||
this.dcGroupBo = dcGroupBo;
|
||||
}
|
||||
|
||||
public LocalDateTime getDateTime() {
|
||||
return dateTime;
|
||||
}
|
||||
|
||||
public void setDateTime(LocalDateTime dateTime) {
|
||||
this.dateTime = dateTime;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreatedDateTime() {
|
||||
return createdDateTime;
|
||||
}
|
||||
|
||||
public void setCreatedDateTime(LocalDateTime createdDateTime) {
|
||||
this.createdDateTime = createdDateTime;
|
||||
}
|
||||
|
||||
public String getCreateUser() {
|
||||
return createUser;
|
||||
}
|
||||
|
||||
public void setCreateUser(String createUser) {
|
||||
this.createUser = createUser;
|
||||
}
|
||||
|
||||
public String getS1() {
|
||||
return s1;
|
||||
}
|
||||
|
||||
public void setS1(String s1) {
|
||||
this.s1 = s1;
|
||||
}
|
||||
|
||||
public String getS2() {
|
||||
return s2;
|
||||
}
|
||||
|
||||
public void setS2(String s2) {
|
||||
this.s2 = s2;
|
||||
}
|
||||
|
||||
public String getS3() {
|
||||
return s3;
|
||||
}
|
||||
|
||||
public void setS3(String s3) {
|
||||
this.s3 = s3;
|
||||
}
|
||||
|
||||
public String getS4() {
|
||||
return s4;
|
||||
}
|
||||
|
||||
public void setS4(String s4) {
|
||||
this.s4 = s4;
|
||||
}
|
||||
|
||||
public String getS5() {
|
||||
return s5;
|
||||
}
|
||||
|
||||
public void setS5(String s5) {
|
||||
this.s5 = s5;
|
||||
}
|
||||
|
||||
public String getS6() {
|
||||
return s6;
|
||||
}
|
||||
|
||||
public void setS6(String s6) {
|
||||
this.s6 = s6;
|
||||
}
|
||||
|
||||
public String getS7() {
|
||||
return s7;
|
||||
}
|
||||
|
||||
public void setS7(String s7) {
|
||||
this.s7 = s7;
|
||||
}
|
||||
|
||||
public String getS8() {
|
||||
return s8;
|
||||
}
|
||||
|
||||
public void setS8(String s8) {
|
||||
this.s8 = s8;
|
||||
}
|
||||
|
||||
public String getS9() {
|
||||
return s9;
|
||||
}
|
||||
|
||||
public void setS9(String s9) {
|
||||
this.s9 = s9;
|
||||
}
|
||||
|
||||
public String getS10() {
|
||||
return s10;
|
||||
}
|
||||
|
||||
public void setS10(String s10) {
|
||||
this.s10 = s10;
|
||||
}
|
||||
|
||||
public String getS11() {
|
||||
return s11;
|
||||
}
|
||||
|
||||
public void setS11(String s11) {
|
||||
this.s11 = s11;
|
||||
}
|
||||
|
||||
public String getS12() {
|
||||
return s12;
|
||||
}
|
||||
|
||||
public void setS12(String s12) {
|
||||
this.s12 = s12;
|
||||
}
|
||||
|
||||
public String getS13() {
|
||||
return s13;
|
||||
}
|
||||
|
||||
public void setS13(String s13) {
|
||||
this.s13 = s13;
|
||||
}
|
||||
|
||||
public String getS14() {
|
||||
return s14;
|
||||
}
|
||||
|
||||
public void setS14(String s14) {
|
||||
this.s14 = s14;
|
||||
}
|
||||
|
||||
public String getS15() {
|
||||
return s15;
|
||||
}
|
||||
|
||||
public void setS15(String s15) {
|
||||
this.s15 = s15;
|
||||
}
|
||||
|
||||
public String getS16() {
|
||||
return s16;
|
||||
}
|
||||
|
||||
public void setS16(String s16) {
|
||||
this.s16 = s16;
|
||||
}
|
||||
|
||||
public String getS17() {
|
||||
return s17;
|
||||
}
|
||||
|
||||
public void setS17(String s17) {
|
||||
this.s17 = s17;
|
||||
}
|
||||
|
||||
public String getS18() {
|
||||
return s18;
|
||||
}
|
||||
|
||||
public void setS18(String s18) {
|
||||
this.s18 = s18;
|
||||
}
|
||||
|
||||
public String getS19() {
|
||||
return s19;
|
||||
}
|
||||
|
||||
public void setS19(String s19) {
|
||||
this.s19 = s19;
|
||||
}
|
||||
|
||||
public String getS20() {
|
||||
return s20;
|
||||
}
|
||||
|
||||
public void setS20(String s20) {
|
||||
this.s20 = s20;
|
||||
}
|
||||
|
||||
public String getS21() {
|
||||
return s21;
|
||||
}
|
||||
|
||||
public void setS21(String s21) {
|
||||
this.s21 = s21;
|
||||
}
|
||||
|
||||
public String getS22() {
|
||||
return s22;
|
||||
}
|
||||
|
||||
public void setS22(String s22) {
|
||||
this.s22 = s22;
|
||||
}
|
||||
|
||||
public String getS23() {
|
||||
return s23;
|
||||
}
|
||||
|
||||
public void setS23(String s23) {
|
||||
this.s23 = s23;
|
||||
}
|
||||
|
||||
public String getS24() {
|
||||
return s24;
|
||||
}
|
||||
|
||||
public void setS24(String s24) {
|
||||
this.s24 = s24;
|
||||
}
|
||||
|
||||
public String getS25() {
|
||||
return s25;
|
||||
}
|
||||
|
||||
public void setS25(String s25) {
|
||||
this.s25 = s25;
|
||||
}
|
||||
|
||||
public String getS26() {
|
||||
return s26;
|
||||
}
|
||||
|
||||
public void setS26(String s26) {
|
||||
this.s26 = s26;
|
||||
}
|
||||
|
||||
public String getS27() {
|
||||
return s27;
|
||||
}
|
||||
|
||||
public void setS27(String s27) {
|
||||
this.s27 = s27;
|
||||
}
|
||||
|
||||
public String getS28() {
|
||||
return s28;
|
||||
}
|
||||
|
||||
public void setS28(String s28) {
|
||||
this.s28 = s28;
|
||||
}
|
||||
|
||||
public String getS29() {
|
||||
return s29;
|
||||
}
|
||||
|
||||
public void setS29(String s29) {
|
||||
this.s29 = s29;
|
||||
}
|
||||
|
||||
public String getS30() {
|
||||
return s30;
|
||||
}
|
||||
|
||||
public void setS30(String s30) {
|
||||
this.s30 = s30;
|
||||
}
|
||||
|
||||
public Double getN1() {
|
||||
return n1;
|
||||
}
|
||||
|
||||
public void setN1(Double n1) {
|
||||
this.n1 = n1;
|
||||
}
|
||||
|
||||
public Double getN2() {
|
||||
return n2;
|
||||
}
|
||||
|
||||
public void setN2(Double n2) {
|
||||
this.n2 = n2;
|
||||
}
|
||||
|
||||
public Double getN3() {
|
||||
return n3;
|
||||
}
|
||||
|
||||
public void setN3(Double n3) {
|
||||
this.n3 = n3;
|
||||
}
|
||||
|
||||
public Double getN4() {
|
||||
return n4;
|
||||
}
|
||||
|
||||
public void setN4(Double n4) {
|
||||
this.n4 = n4;
|
||||
}
|
||||
|
||||
public Double getN5() {
|
||||
return n5;
|
||||
}
|
||||
|
||||
public void setN5(Double n5) {
|
||||
this.n5 = n5;
|
||||
}
|
||||
|
||||
public Double getN6() {
|
||||
return n6;
|
||||
}
|
||||
|
||||
public void setN6(Double n6) {
|
||||
this.n6 = n6;
|
||||
}
|
||||
|
||||
public Double getN7() {
|
||||
return n7;
|
||||
}
|
||||
|
||||
public void setN7(Double n7) {
|
||||
this.n7 = n7;
|
||||
}
|
||||
|
||||
public Double getN8() {
|
||||
return n8;
|
||||
}
|
||||
|
||||
public void setN8(Double n8) {
|
||||
this.n8 = n8;
|
||||
}
|
||||
|
||||
public Double getN9() {
|
||||
return n9;
|
||||
}
|
||||
|
||||
public void setN9(Double n9) {
|
||||
this.n9 = n9;
|
||||
}
|
||||
|
||||
public Double getN10() {
|
||||
return n10;
|
||||
}
|
||||
|
||||
public void setN10(Double n10) {
|
||||
this.n10 = n10;
|
||||
}
|
||||
|
||||
public Double getN11() {
|
||||
return n11;
|
||||
}
|
||||
|
||||
public void setN11(Double n11) {
|
||||
this.n11 = n11;
|
||||
}
|
||||
|
||||
public Double getN12() {
|
||||
return n12;
|
||||
}
|
||||
|
||||
public void setN12(Double n12) {
|
||||
this.n12 = n12;
|
||||
}
|
||||
|
||||
public Double getN13() {
|
||||
return n13;
|
||||
}
|
||||
|
||||
public void setN13(Double n13) {
|
||||
this.n13 = n13;
|
||||
}
|
||||
|
||||
public Double getN14() {
|
||||
return n14;
|
||||
}
|
||||
|
||||
public void setN14(Double n14) {
|
||||
this.n14 = n14;
|
||||
}
|
||||
|
||||
public Double getN15() {
|
||||
return n15;
|
||||
}
|
||||
|
||||
public void setN15(Double n15) {
|
||||
this.n15 = n15;
|
||||
}
|
||||
|
||||
public Double getN16() {
|
||||
return n16;
|
||||
}
|
||||
|
||||
public void setN16(Double n16) {
|
||||
this.n16 = n16;
|
||||
}
|
||||
|
||||
public Double getN17() {
|
||||
return n17;
|
||||
}
|
||||
|
||||
public void setN17(Double n17) {
|
||||
this.n17 = n17;
|
||||
}
|
||||
|
||||
public Double getN18() {
|
||||
return n18;
|
||||
}
|
||||
|
||||
public void setN18(Double n18) {
|
||||
this.n18 = n18;
|
||||
}
|
||||
|
||||
public Double getN19() {
|
||||
return n19;
|
||||
}
|
||||
|
||||
public void setN19(Double n19) {
|
||||
this.n19 = n19;
|
||||
}
|
||||
|
||||
public Double getN20() {
|
||||
return n20;
|
||||
}
|
||||
|
||||
public void setN20(Double n20) {
|
||||
this.n20 = n20;
|
||||
}
|
||||
|
||||
public Double getN21() {
|
||||
return n21;
|
||||
}
|
||||
|
||||
public void setN21(Double n21) {
|
||||
this.n21 = n21;
|
||||
}
|
||||
|
||||
public Double getN22() {
|
||||
return n22;
|
||||
}
|
||||
|
||||
public void setN22(Double n22) {
|
||||
this.n22 = n22;
|
||||
}
|
||||
|
||||
public Double getN23() {
|
||||
return n23;
|
||||
}
|
||||
|
||||
public void setN23(Double n23) {
|
||||
this.n23 = n23;
|
||||
}
|
||||
|
||||
public Double getN24() {
|
||||
return n24;
|
||||
}
|
||||
|
||||
public void setN24(Double n24) {
|
||||
this.n24 = n24;
|
||||
}
|
||||
|
||||
public Double getN25() {
|
||||
return n25;
|
||||
}
|
||||
|
||||
public void setN25(Double n25) {
|
||||
this.n25 = n25;
|
||||
}
|
||||
|
||||
public Double getN26() {
|
||||
return n26;
|
||||
}
|
||||
|
||||
public void setN26(Double n26) {
|
||||
this.n26 = n26;
|
||||
}
|
||||
|
||||
public Double getN27() {
|
||||
return n27;
|
||||
}
|
||||
|
||||
public void setN27(Double n27) {
|
||||
this.n27 = n27;
|
||||
}
|
||||
|
||||
public Double getN28() {
|
||||
return n28;
|
||||
}
|
||||
|
||||
public void setN28(Double n28) {
|
||||
this.n28 = n28;
|
||||
}
|
||||
|
||||
public Double getN29() {
|
||||
return n29;
|
||||
}
|
||||
|
||||
public void setN29(Double n29) {
|
||||
this.n29 = n29;
|
||||
}
|
||||
|
||||
public Double getN30() {
|
||||
return n30;
|
||||
}
|
||||
|
||||
public void setN30(Double n30) {
|
||||
this.n30 = n30;
|
||||
}
|
||||
|
||||
public static final String HANDLE = "HANDLE";
|
||||
|
||||
public static final String SITE = "SITE";
|
||||
|
||||
public static final String RESRCE = "RESRCE";
|
||||
|
||||
public static final String DC_GROUP_BO = "DC_GROUP_BO";
|
||||
|
||||
public static final String DATE_TIME = "DATE_TIME";
|
||||
|
||||
public static final String CREATED_DATE_TIME = "CREATED_DATE_TIME";
|
||||
|
||||
public static final String CREATE_USER = "CREATE_USER";
|
||||
|
||||
public static final String S1 = "S1";
|
||||
|
||||
public static final String S2 = "S2";
|
||||
|
||||
public static final String S3 = "S3";
|
||||
|
||||
public static final String S4 = "S4";
|
||||
|
||||
public static final String S5 = "S5";
|
||||
|
||||
public static final String S6 = "S6";
|
||||
|
||||
public static final String S7 = "S7";
|
||||
|
||||
public static final String S8 = "S8";
|
||||
|
||||
public static final String S9 = "S9";
|
||||
|
||||
public static final String S10 = "S10";
|
||||
|
||||
public static final String S11 = "S11";
|
||||
|
||||
public static final String S12 = "S12";
|
||||
|
||||
public static final String S13 = "S13";
|
||||
|
||||
public static final String S14 = "S14";
|
||||
|
||||
public static final String S15 = "S15";
|
||||
|
||||
public static final String S16 = "S16";
|
||||
|
||||
public static final String S17 = "S17";
|
||||
|
||||
public static final String S18 = "S18";
|
||||
|
||||
public static final String S19 = "S19";
|
||||
|
||||
public static final String S20 = "S20";
|
||||
|
||||
public static final String S21 = "S21";
|
||||
|
||||
public static final String S22 = "S22";
|
||||
|
||||
public static final String S23 = "S23";
|
||||
|
||||
public static final String S24 = "S24";
|
||||
|
||||
public static final String S25 = "S25";
|
||||
|
||||
public static final String S26 = "S26";
|
||||
|
||||
public static final String S27 = "S27";
|
||||
|
||||
public static final String S28 = "S28";
|
||||
|
||||
public static final String S29 = "S29";
|
||||
|
||||
public static final String S30 = "S30";
|
||||
|
||||
public static final String N1 = "N1";
|
||||
|
||||
public static final String N2 = "N2";
|
||||
|
||||
public static final String N3 = "N3";
|
||||
|
||||
public static final String N4 = "N4";
|
||||
|
||||
public static final String N5 = "N5";
|
||||
|
||||
public static final String N6 = "N6";
|
||||
|
||||
public static final String N7 = "N7";
|
||||
|
||||
public static final String N8 = "N8";
|
||||
|
||||
public static final String N9 = "N9";
|
||||
|
||||
public static final String N10 = "N10";
|
||||
|
||||
public static final String N11 = "N11";
|
||||
|
||||
public static final String N12 = "N12";
|
||||
|
||||
public static final String N13 = "N13";
|
||||
|
||||
public static final String N14 = "N14";
|
||||
|
||||
public static final String N15 = "N15";
|
||||
|
||||
public static final String N16 = "N16";
|
||||
|
||||
public static final String N17 = "N17";
|
||||
|
||||
public static final String N18 = "N18";
|
||||
|
||||
public static final String N19 = "N19";
|
||||
|
||||
public static final String N20 = "N20";
|
||||
|
||||
public static final String N21 = "N21";
|
||||
|
||||
public static final String N22 = "N22";
|
||||
|
||||
public static final String N23 = "N23";
|
||||
|
||||
public static final String N24 = "N24";
|
||||
|
||||
public static final String N25 = "N25";
|
||||
|
||||
public static final String N26 = "N26";
|
||||
|
||||
public static final String N27 = "N27";
|
||||
|
||||
public static final String N28 = "N28";
|
||||
|
||||
public static final String N29 = "N29";
|
||||
|
||||
public static final String N30 = "N30";
|
||||
|
||||
|
||||
@Override
|
||||
protected Serializable pkVal() {
|
||||
return this.handle;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "EdcDataResource{" +
|
||||
"handle = " + handle +
|
||||
", site = " + site +
|
||||
", resrce = " + resrce +
|
||||
", dcGroupBo = " + dcGroupBo +
|
||||
", dateTime = " + dateTime +
|
||||
", createdDateTime = " + createdDateTime +
|
||||
", createUser = " + createUser +
|
||||
", s1 = " + s1 +
|
||||
", s2 = " + s2 +
|
||||
", s3 = " + s3 +
|
||||
", s4 = " + s4 +
|
||||
", s5 = " + s5 +
|
||||
", s6 = " + s6 +
|
||||
", s7 = " + s7 +
|
||||
", s8 = " + s8 +
|
||||
", s9 = " + s9 +
|
||||
", s10 = " + s10 +
|
||||
", s11 = " + s11 +
|
||||
", s12 = " + s12 +
|
||||
", s13 = " + s13 +
|
||||
", s14 = " + s14 +
|
||||
", s15 = " + s15 +
|
||||
", s16 = " + s16 +
|
||||
", s17 = " + s17 +
|
||||
", s18 = " + s18 +
|
||||
", s19 = " + s19 +
|
||||
", s20 = " + s20 +
|
||||
", s21 = " + s21 +
|
||||
", s22 = " + s22 +
|
||||
", s23 = " + s23 +
|
||||
", s24 = " + s24 +
|
||||
", s25 = " + s25 +
|
||||
", s26 = " + s26 +
|
||||
", s27 = " + s27 +
|
||||
", s28 = " + s28 +
|
||||
", s29 = " + s29 +
|
||||
", s30 = " + s30 +
|
||||
", n1 = " + n1 +
|
||||
", n2 = " + n2 +
|
||||
", n3 = " + n3 +
|
||||
", n4 = " + n4 +
|
||||
", n5 = " + n5 +
|
||||
", n6 = " + n6 +
|
||||
", n7 = " + n7 +
|
||||
", n8 = " + n8 +
|
||||
", n9 = " + n9 +
|
||||
", n10 = " + n10 +
|
||||
", n11 = " + n11 +
|
||||
", n12 = " + n12 +
|
||||
", n13 = " + n13 +
|
||||
", n14 = " + n14 +
|
||||
", n15 = " + n15 +
|
||||
", n16 = " + n16 +
|
||||
", n17 = " + n17 +
|
||||
", n18 = " + n18 +
|
||||
", n19 = " + n19 +
|
||||
", n20 = " + n20 +
|
||||
", n21 = " + n21 +
|
||||
", n22 = " + n22 +
|
||||
", n23 = " + n23 +
|
||||
", n24 = " + n24 +
|
||||
", n25 = " + n25 +
|
||||
", n26 = " + n26 +
|
||||
", n27 = " + n27 +
|
||||
", n28 = " + n28 +
|
||||
", n29 = " + n29 +
|
||||
", n30 = " + n30 +
|
||||
"}";
|
||||
}
|
||||
}
|
@ -0,0 +1,185 @@
|
||||
package com.foreverwin.mesnac.equip.model;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.baomidou.mybatisplus.extension.activerecord.Model;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import java.time.LocalDateTime;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import java.io.Serializable;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 设备故障信息接收表-接口
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
|
||||
@TableName("Z_RESOURCE_FAULT_RECEIVE")
|
||||
|
||||
public class ResourceFaultReceive extends Model<ResourceFaultReceive> {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
@TableId(value = "HANDLE", type = IdType.INPUT)
|
||||
private String handle;
|
||||
/**
|
||||
* 站点
|
||||
*/
|
||||
@TableField("SITE")
|
||||
private String site;
|
||||
/**
|
||||
* 设备编号
|
||||
*/
|
||||
@TableField("RESRCE")
|
||||
private String resrce;
|
||||
/**
|
||||
* 设备故障编码
|
||||
*/
|
||||
@TableField("FAULT_CODE")
|
||||
private String faultCode;
|
||||
/**
|
||||
* 故障接收时间
|
||||
*/
|
||||
@TableField("FAULT_DATE")
|
||||
private LocalDateTime faultDate;
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
@TableField("CREATE_USER")
|
||||
private String createUser;
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@TableField("CREATED_DATE_TIME")
|
||||
private LocalDateTime createdDateTime;
|
||||
/**
|
||||
* 修改人
|
||||
*/
|
||||
@TableField("MODIFY_USER")
|
||||
private String modifyUser;
|
||||
/**
|
||||
* 修改时间
|
||||
*/
|
||||
@TableField("MODIFIED_DATE_TIME")
|
||||
private LocalDateTime modifiedDateTime;
|
||||
|
||||
|
||||
public String getHandle() {
|
||||
return handle;
|
||||
}
|
||||
|
||||
public void setHandle(String handle) {
|
||||
this.handle = handle;
|
||||
}
|
||||
|
||||
public String getSite() {
|
||||
return site;
|
||||
}
|
||||
|
||||
public void setSite(String site) {
|
||||
this.site = site;
|
||||
}
|
||||
|
||||
public String getResrce() {
|
||||
return resrce;
|
||||
}
|
||||
|
||||
public void setResrce(String resrce) {
|
||||
this.resrce = resrce;
|
||||
}
|
||||
|
||||
public String getFaultCode() {
|
||||
return faultCode;
|
||||
}
|
||||
|
||||
public void setFaultCode(String faultCode) {
|
||||
this.faultCode = faultCode;
|
||||
}
|
||||
|
||||
public LocalDateTime getFaultDate() {
|
||||
return faultDate;
|
||||
}
|
||||
|
||||
public void setFaultDate(LocalDateTime faultDate) {
|
||||
this.faultDate = faultDate;
|
||||
}
|
||||
|
||||
public String getCreateUser() {
|
||||
return createUser;
|
||||
}
|
||||
|
||||
public void setCreateUser(String createUser) {
|
||||
this.createUser = createUser;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreatedDateTime() {
|
||||
return createdDateTime;
|
||||
}
|
||||
|
||||
public void setCreatedDateTime(LocalDateTime createdDateTime) {
|
||||
this.createdDateTime = createdDateTime;
|
||||
}
|
||||
|
||||
public String getModifyUser() {
|
||||
return modifyUser;
|
||||
}
|
||||
|
||||
public void setModifyUser(String modifyUser) {
|
||||
this.modifyUser = modifyUser;
|
||||
}
|
||||
|
||||
public LocalDateTime getModifiedDateTime() {
|
||||
return modifiedDateTime;
|
||||
}
|
||||
|
||||
public void setModifiedDateTime(LocalDateTime modifiedDateTime) {
|
||||
this.modifiedDateTime = modifiedDateTime;
|
||||
}
|
||||
|
||||
public static final String HANDLE = "HANDLE";
|
||||
|
||||
public static final String SITE = "SITE";
|
||||
|
||||
public static final String RESRCE = "RESRCE";
|
||||
|
||||
public static final String FAULT_CODE = "FAULT_CODE";
|
||||
|
||||
public static final String FAULT_DATE = "FAULT_DATE";
|
||||
|
||||
public static final String CREATE_USER = "CREATE_USER";
|
||||
|
||||
public static final String CREATED_DATE_TIME = "CREATED_DATE_TIME";
|
||||
|
||||
public static final String MODIFY_USER = "MODIFY_USER";
|
||||
|
||||
public static final String MODIFIED_DATE_TIME = "MODIFIED_DATE_TIME";
|
||||
|
||||
|
||||
@Override
|
||||
protected Serializable pkVal() {
|
||||
return this.handle;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ResourceFaultReceive{" +
|
||||
"handle = " + handle +
|
||||
", site = " + site +
|
||||
", resrce = " + resrce +
|
||||
", faultCode = " + faultCode +
|
||||
", faultDate = " + faultDate +
|
||||
", createUser = " + createUser +
|
||||
", createdDateTime = " + createdDateTime +
|
||||
", modifyUser = " + modifyUser +
|
||||
", modifiedDateTime = " + modifiedDateTime +
|
||||
"}";
|
||||
}
|
||||
}
|
@ -0,0 +1,233 @@
|
||||
package com.foreverwin.mesnac.equip.model;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.baomidou.mybatisplus.extension.activerecord.Model;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import java.time.LocalDateTime;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import java.io.Serializable;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 设备状态表-接口
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
|
||||
@TableName("Z_RESOURCE_STATUS_RECEIVE")
|
||||
|
||||
public class ResourceStatusReceive extends Model<ResourceStatusReceive> {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键
|
||||
*/
|
||||
@TableId(value = "HANDLE", type = IdType.INPUT)
|
||||
private String handle;
|
||||
/**
|
||||
* 站点
|
||||
*/
|
||||
@TableField("SITE")
|
||||
private String site;
|
||||
/**
|
||||
* 设备编号
|
||||
*/
|
||||
@TableField("RESRCE")
|
||||
private String resrce;
|
||||
/**
|
||||
* 当前状态
|
||||
*/
|
||||
@TableField("STATUS")
|
||||
private String status;
|
||||
/**
|
||||
* 当前状态获取时间
|
||||
*/
|
||||
@TableField("DATE_TIME")
|
||||
private LocalDateTime dateTime;
|
||||
/**
|
||||
* 接收的状态
|
||||
*/
|
||||
@TableField("CHANGE_STATUS")
|
||||
private String changeStatus;
|
||||
/**
|
||||
* 接收时间
|
||||
*/
|
||||
@TableField("CHANGE_DATE_TIME")
|
||||
private LocalDateTime changeDateTime;
|
||||
/**
|
||||
* 间隔时间
|
||||
*/
|
||||
@TableField("INTERVAL_TIME")
|
||||
private Double intervalTime;
|
||||
/**
|
||||
* 创建人
|
||||
*/
|
||||
@TableField("CREATE_USER")
|
||||
private String createUser;
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@TableField("CREATED_DATE_TIME")
|
||||
private LocalDateTime createdDateTime;
|
||||
/**
|
||||
* 修改人
|
||||
*/
|
||||
@TableField("MODIFY_USER")
|
||||
private String modifyUser;
|
||||
/**
|
||||
* 修改时间
|
||||
*/
|
||||
@TableField("MODIFIED_DATE_TIME")
|
||||
private LocalDateTime modifiedDateTime;
|
||||
|
||||
|
||||
public String getHandle() {
|
||||
return handle;
|
||||
}
|
||||
|
||||
public void setHandle(String handle) {
|
||||
this.handle = handle;
|
||||
}
|
||||
|
||||
public String getSite() {
|
||||
return site;
|
||||
}
|
||||
|
||||
public void setSite(String site) {
|
||||
this.site = site;
|
||||
}
|
||||
|
||||
public String getResrce() {
|
||||
return resrce;
|
||||
}
|
||||
|
||||
public void setResrce(String resrce) {
|
||||
this.resrce = resrce;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public LocalDateTime getDateTime() {
|
||||
return dateTime;
|
||||
}
|
||||
|
||||
public void setDateTime(LocalDateTime dateTime) {
|
||||
this.dateTime = dateTime;
|
||||
}
|
||||
|
||||
public String getChangeStatus() {
|
||||
return changeStatus;
|
||||
}
|
||||
|
||||
public void setChangeStatus(String changeStatus) {
|
||||
this.changeStatus = changeStatus;
|
||||
}
|
||||
|
||||
public LocalDateTime getChangeDateTime() {
|
||||
return changeDateTime;
|
||||
}
|
||||
|
||||
public void setChangeDateTime(LocalDateTime changeDateTime) {
|
||||
this.changeDateTime = changeDateTime;
|
||||
}
|
||||
|
||||
public Double getIntervalTime() {
|
||||
return intervalTime;
|
||||
}
|
||||
|
||||
public void setIntervalTime(Double intervalTime) {
|
||||
this.intervalTime = intervalTime;
|
||||
}
|
||||
|
||||
public String getCreateUser() {
|
||||
return createUser;
|
||||
}
|
||||
|
||||
public void setCreateUser(String createUser) {
|
||||
this.createUser = createUser;
|
||||
}
|
||||
|
||||
public LocalDateTime getCreatedDateTime() {
|
||||
return createdDateTime;
|
||||
}
|
||||
|
||||
public void setCreatedDateTime(LocalDateTime createdDateTime) {
|
||||
this.createdDateTime = createdDateTime;
|
||||
}
|
||||
|
||||
public String getModifyUser() {
|
||||
return modifyUser;
|
||||
}
|
||||
|
||||
public void setModifyUser(String modifyUser) {
|
||||
this.modifyUser = modifyUser;
|
||||
}
|
||||
|
||||
public LocalDateTime getModifiedDateTime() {
|
||||
return modifiedDateTime;
|
||||
}
|
||||
|
||||
public void setModifiedDateTime(LocalDateTime modifiedDateTime) {
|
||||
this.modifiedDateTime = modifiedDateTime;
|
||||
}
|
||||
|
||||
public static final String HANDLE = "HANDLE";
|
||||
|
||||
public static final String SITE = "SITE";
|
||||
|
||||
public static final String RESRCE = "RESRCE";
|
||||
|
||||
public static final String STATUS = "STATUS";
|
||||
|
||||
public static final String DATE_TIME = "DATE_TIME";
|
||||
|
||||
public static final String CHANGE_STATUS = "CHANGE_STATUS";
|
||||
|
||||
public static final String CHANGE_DATE_TIME = "CHANGE_DATE_TIME";
|
||||
|
||||
public static final String INTERVAL_TIME = "INTERVAL_TIME";
|
||||
|
||||
public static final String CREATE_USER = "CREATE_USER";
|
||||
|
||||
public static final String CREATED_DATE_TIME = "CREATED_DATE_TIME";
|
||||
|
||||
public static final String MODIFY_USER = "MODIFY_USER";
|
||||
|
||||
public static final String MODIFIED_DATE_TIME = "MODIFIED_DATE_TIME";
|
||||
|
||||
|
||||
@Override
|
||||
protected Serializable pkVal() {
|
||||
return this.handle;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ResourceStatusReceive{" +
|
||||
"handle = " + handle +
|
||||
", site = " + site +
|
||||
", resrce = " + resrce +
|
||||
", status = " + status +
|
||||
", dateTime = " + dateTime +
|
||||
", changeStatus = " + changeStatus +
|
||||
", changeDateTime = " + changeDateTime +
|
||||
", intervalTime = " + intervalTime +
|
||||
", createUser = " + createUser +
|
||||
", createdDateTime = " + createdDateTime +
|
||||
", modifyUser = " + modifyUser +
|
||||
", modifiedDateTime = " + modifiedDateTime +
|
||||
"}";
|
||||
}
|
||||
}
|
@ -0,0 +1,31 @@
|
||||
package com.foreverwin.mesnac.equip.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.equip.model.EdcDataResource;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
public interface EdcDataResourceService extends IService<EdcDataResource> {
|
||||
|
||||
/**
|
||||
* 分页查询
|
||||
* @param frontPage
|
||||
* @return
|
||||
*/
|
||||
IPage<EdcDataResource> selectPage(FrontPage<EdcDataResource> frontPage, EdcDataResource edcDataResource);
|
||||
|
||||
List<EdcDataResource> selectList(EdcDataResource edcDataResource);
|
||||
|
||||
String saveResourceParamByMq(String text);
|
||||
|
||||
}
|
@ -0,0 +1,32 @@
|
||||
package com.foreverwin.mesnac.equip.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.equip.model.ResourceFaultReceive;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 设备故障信息接收表-接口 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
public interface ResourceFaultReceiveService extends IService<ResourceFaultReceive> {
|
||||
|
||||
/**
|
||||
* 分页查询
|
||||
* @param frontPage
|
||||
* @return
|
||||
*/
|
||||
IPage<ResourceFaultReceive> selectPage(FrontPage<ResourceFaultReceive> frontPage, ResourceFaultReceive resourceFaultReceive);
|
||||
|
||||
List<ResourceFaultReceive> selectList(ResourceFaultReceive resourceFaultReceive);
|
||||
|
||||
String parseResourceFaultInfo(String text);
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,37 @@
|
||||
package com.foreverwin.mesnac.equip.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.equip.model.ResourceStatusReceive;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 设备状态表-接口 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
public interface ResourceStatusReceiveService extends IService<ResourceStatusReceive> {
|
||||
|
||||
/**
|
||||
* 分页查询
|
||||
* @param frontPage
|
||||
* @return
|
||||
*/
|
||||
IPage<ResourceStatusReceive> selectPage(FrontPage<ResourceStatusReceive> frontPage, ResourceStatusReceive resourceStatusReceive);
|
||||
|
||||
List<ResourceStatusReceive> selectList(ResourceStatusReceive resourceStatusReceive);
|
||||
|
||||
/**
|
||||
* 插入新数据、更新数据、更新设备状态
|
||||
* @param text
|
||||
*/
|
||||
String updateResourceStatusByMq(String text);
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,135 @@
|
||||
package com.foreverwin.mesnac.equip.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.foreverwin.mesnac.common.enums.HandleEnum;
|
||||
import com.foreverwin.mesnac.equip.dto.EdcDataResourceDto;
|
||||
import com.foreverwin.mesnac.meapi.mapper.DcParameterMapper;
|
||||
import com.foreverwin.mesnac.meapi.model.DcParameter;
|
||||
import com.foreverwin.modular.core.exception.BusinessException;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.equip.model.EdcDataResource;
|
||||
import com.foreverwin.mesnac.equip.mapper.EdcDataResourceMapper;
|
||||
import com.foreverwin.mesnac.equip.service.EdcDataResourceService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@Service
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public class EdcDataResourceServiceImpl extends ServiceImpl<EdcDataResourceMapper, EdcDataResource> implements EdcDataResourceService {
|
||||
|
||||
|
||||
@Autowired
|
||||
private EdcDataResourceMapper edcDataResourceMapper;
|
||||
@Autowired
|
||||
private DcParameterMapper dcParameterMapper;
|
||||
|
||||
@Override
|
||||
public IPage<EdcDataResource> selectPage(FrontPage<EdcDataResource> frontPage, EdcDataResource edcDataResource) {
|
||||
QueryWrapper<EdcDataResource> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(edcDataResource);
|
||||
return super.page(frontPage.getPagePlus(), queryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<EdcDataResource> selectList(EdcDataResource edcDataResource) {
|
||||
QueryWrapper<EdcDataResource> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(edcDataResource);
|
||||
return super.list(queryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String saveResourceParamByMq(String text) {
|
||||
JSONObject jsonObject = JSONObject.parseObject(text);
|
||||
|
||||
String handle = jsonObject.getString("TRANID");
|
||||
String site = jsonObject.getString("SITE");
|
||||
String resource = jsonObject.getString("RESOURCE");
|
||||
// 发送时间
|
||||
String sendTime = jsonObject.getString("SEND_TIME");
|
||||
/*DateTimeFormatter dataFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
|
||||
LocalDateTime dateTime = LocalDateTime.parse(sendTime, dataFormatter);
|
||||
String dateString = dateTime.toString();
|
||||
String dateStr = dateString.replace('T', ' ').substring(0, 19);*/
|
||||
// 参数
|
||||
String paramList = jsonObject.getString("PARAM_LIST");
|
||||
JSONArray jsonArray = JSON.parseArray(paramList);
|
||||
Map<String,String> map = new HashMap<>();
|
||||
for (int i = 0; i < jsonArray.size(); i++) {
|
||||
JSONObject jsonObj = (JSONObject) jsonArray.get(i);
|
||||
String paramVal = jsonObj.getString("PARAM_VAL");
|
||||
String param = jsonObj.getString("PARAM");
|
||||
map.put(param,paramVal);
|
||||
}
|
||||
// 获取数据收集组HANDLE
|
||||
String resourceBo = HandleEnum.RESOURCE.getHandle(site, resource);
|
||||
String dcGroupBo = edcDataResourceMapper.getDcGroupBoByResourceBo(resourceBo);
|
||||
if (dcGroupBo == null){
|
||||
dcGroupBo = edcDataResourceMapper.getDcGroupBoByResourceBo2(resourceBo);
|
||||
if (dcGroupBo == null){
|
||||
throw BusinessException.build("设备未维护数据收集组!");
|
||||
}
|
||||
}
|
||||
// 获取数据收集组的字段配置信息
|
||||
StringBuilder columnValSql = new StringBuilder();
|
||||
StringBuilder columnSql = new StringBuilder();
|
||||
List<DcParameter> getParamList = dcParameterMapper.getDcParameterByDcGroupBo(dcGroupBo);
|
||||
for (DcParameter dcParam:getParamList) {
|
||||
String parameterName = dcParam.getParameterName();
|
||||
// 数据收集组---值-列
|
||||
String dcValueMask = dcParam.getDcValueMask();
|
||||
// json值
|
||||
String value = map.get(parameterName);
|
||||
if (value == null){
|
||||
continue;
|
||||
}
|
||||
columnSql.append(dcValueMask);
|
||||
columnSql.append(",");
|
||||
columnValSql.append("'").append(value).append("'");
|
||||
columnValSql.append(",");
|
||||
}
|
||||
StringBuilder sqlStr = new StringBuilder();
|
||||
String nowString = LocalDateTime.now().toString();
|
||||
String nowDate = nowString.substring(0, 19).replace('T', ' ');
|
||||
sqlStr.append("INSERT INTO Z_EDC_DATA_")
|
||||
.append(resource.replace("-","_"))
|
||||
.append(" (HANDLE,SITE,RESRCE,DC_GROUP_BO,DATE_TIME,CREATED_DATE_TIME,CREATE_USER,")
|
||||
.append(columnSql.substring(0,columnSql.length()-1))
|
||||
.append(") ")
|
||||
.append(" VALUES ('")
|
||||
.append(UUID.randomUUID()).append("','")
|
||||
.append(site).append("','")
|
||||
.append(resource).append("','")
|
||||
.append(dcGroupBo).append("',")
|
||||
.append("TO_DATE('").append(sendTime).append("','yyyy-MM-dd hh24:mi-ss') ,")
|
||||
.append("TO_DATE('").append(nowDate).append("','yyyy-MM-dd hh24:mi-ss') ,'")
|
||||
.append("SITE_ADMIN").append("',")
|
||||
.append(columnValSql.substring(0,columnValSql.length()-1))
|
||||
.append(" )");
|
||||
System.out.println(sqlStr);
|
||||
return handle;
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,106 @@
|
||||
package com.foreverwin.mesnac.equip.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.foreverwin.mesnac.common.util.StringUtil;
|
||||
import com.foreverwin.modular.core.exception.BusinessException;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.equip.model.ResourceFaultReceive;
|
||||
import com.foreverwin.mesnac.equip.mapper.ResourceFaultReceiveMapper;
|
||||
import com.foreverwin.mesnac.equip.service.ResourceFaultReceiveService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.joda.time.LocalDate;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 设备故障信息接收表-接口 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.Liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@Service
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public class ResourceFaultReceiveServiceImpl extends ServiceImpl<ResourceFaultReceiveMapper, ResourceFaultReceive> implements ResourceFaultReceiveService {
|
||||
|
||||
|
||||
@Autowired
|
||||
private ResourceFaultReceiveMapper resourceFaultReceiveMapper;
|
||||
@Autowired
|
||||
private ResourceFaultReceiveService resourceFaultReceiveService;
|
||||
|
||||
@Override
|
||||
public IPage<ResourceFaultReceive> selectPage(FrontPage<ResourceFaultReceive> frontPage, ResourceFaultReceive resourceFaultReceive) {
|
||||
QueryWrapper<ResourceFaultReceive> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(resourceFaultReceive);
|
||||
return super.page(frontPage.getPagePlus(), queryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ResourceFaultReceive> selectList(ResourceFaultReceive resourceFaultReceive) {
|
||||
QueryWrapper<ResourceFaultReceive> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(resourceFaultReceive);
|
||||
return super.list(queryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String parseResourceFaultInfo(String text) {
|
||||
JSONObject jsonObject = JSONObject.parseObject(text);
|
||||
|
||||
String handle = jsonObject.getString("TRANID");
|
||||
String site = jsonObject.getString("SITE");
|
||||
String resource = jsonObject.getString("RESOURCE");
|
||||
String faultList = jsonObject.getString("FAULT_LIST");
|
||||
|
||||
String sendTime = jsonObject.getString("SEND_TIME");
|
||||
DateTimeFormatter dataFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
|
||||
LocalDateTime sendDate = LocalDateTime.parse(sendTime, dataFormatter);
|
||||
|
||||
if (StringUtil.isBlank(handle)) {
|
||||
throw BusinessException.build("唯一标识不能为空!");
|
||||
}
|
||||
if (StringUtil.isBlank(site)) {
|
||||
throw BusinessException.build("站点不能为空!");
|
||||
}
|
||||
if (StringUtil.isBlank(resource)) {
|
||||
throw BusinessException.build("设备编号不能为空!");
|
||||
}
|
||||
List<ResourceFaultReceive> list = new ArrayList<>();
|
||||
// 故障编码及故障时间
|
||||
JSONArray jsonArray = JSON.parseArray(faultList);
|
||||
for (int i = 0; i < jsonArray.size(); i++) {
|
||||
ResourceFaultReceive resourceFaultReceive = new ResourceFaultReceive();
|
||||
// 设备编号、站点、创建时间-使用SEND_TIME、创建用户
|
||||
resourceFaultReceive.setResrce(resource);
|
||||
resourceFaultReceive.setSite(site);
|
||||
resourceFaultReceive.setCreatedDateTime(sendDate);
|
||||
resourceFaultReceive.setCreateUser("SITE_ADMIN");
|
||||
|
||||
JSONObject jsonObj = (JSONObject) jsonArray.get(i);
|
||||
String faultCode = jsonObj.getString("FAULT_CODE");
|
||||
resourceFaultReceive.setFaultCode(faultCode);
|
||||
String dateTime = jsonObj.getString("DATE_TIME");
|
||||
LocalDateTime faultDate = LocalDateTime.parse(dateTime, dataFormatter);
|
||||
resourceFaultReceive.setFaultDate(faultDate);
|
||||
resourceFaultReceive.setHandle(UUID.randomUUID().toString());
|
||||
list.add(resourceFaultReceive);
|
||||
}
|
||||
resourceFaultReceiveService.saveBatch(list);
|
||||
return handle;
|
||||
}
|
||||
|
||||
|
||||
}
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,386 @@
|
||||
<?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.equip.mapper.ResourceFaultReceiveMapper">
|
||||
|
||||
<!-- 通用查询映射结果 -->
|
||||
<resultMap id="BaseResultMap" type="com.foreverwin.mesnac.equip.model.ResourceFaultReceive">
|
||||
<id column="HANDLE" property="handle" />
|
||||
<result column="SITE" property="site" />
|
||||
<result column="RESRCE" property="resrce" />
|
||||
<result column="FAULT_CODE" property="faultCode" />
|
||||
<result column="FAULT_DATE" property="faultDate" />
|
||||
<result column="CREATE_USER" property="createUser" />
|
||||
<result column="CREATED_DATE_TIME" property="createdDateTime" />
|
||||
<result column="MODIFY_USER" property="modifyUser" />
|
||||
<result column="MODIFIED_DATE_TIME" property="modifiedDateTime" />
|
||||
</resultMap>
|
||||
|
||||
<!-- 通用查询结果列 -->
|
||||
<sql id="Base_Column_List">
|
||||
HANDLE, SITE, RESRCE, FAULT_CODE, FAULT_DATE, CREATE_USER, CREATED_DATE_TIME, MODIFY_USER, MODIFIED_DATE_TIME
|
||||
</sql>
|
||||
|
||||
<!-- BaseMapper标准查询/修改/删除 -->
|
||||
<select id="selectById" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include> FROM Z_RESOURCE_FAULT_RECEIVE WHERE HANDLE=#{handle}
|
||||
</select>
|
||||
|
||||
<select id="selectByMap" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include>
|
||||
FROM Z_RESOURCE_FAULT_RECEIVE
|
||||
<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="selectBatchIds" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include>
|
||||
FROM Z_RESOURCE_FAULT_RECEIVE WHERE HANDLE IN (
|
||||
<foreach item="item" index="index" collection="coll" separator=",">#{item}
|
||||
</foreach>)
|
||||
</select>
|
||||
|
||||
<select id="selectOne" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include> FROM Z_RESOURCE_FAULT_RECEIVE
|
||||
<where>
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.handle}
|
||||
</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_FAULT_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_FAULT_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_FAULT_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_FAULT_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_FAULT_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_FAULT_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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.equip.model.ResourceFaultReceive">
|
||||
INSERT INTO Z_RESOURCE_FAULT_RECEIVE
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
HANDLE,
|
||||
<if test="site!=null">SITE,</if>
|
||||
<if test="resrce!=null">RESRCE,</if>
|
||||
<if test="faultCode!=null">FAULT_CODE,</if>
|
||||
<if test="faultDate!=null">FAULT_DATE,</if>
|
||||
<if test="createUser!=null">CREATE_USER,</if>
|
||||
<if test="createdDateTime!=null">CREATED_DATE_TIME,</if>
|
||||
<if test="modifyUser!=null">MODIFY_USER,</if>
|
||||
<if test="modifiedDateTime!=null">MODIFIED_DATE_TIME,</if>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
<if test="site!=null">#{site},</if>
|
||||
<if test="resrce!=null">#{resrce},</if>
|
||||
<if test="faultCode!=null">#{faultCode},</if>
|
||||
<if test="faultDate!=null">#{faultDate},</if>
|
||||
<if test="createUser!=null">#{createUser},</if>
|
||||
<if test="createdDateTime!=null">#{createdDateTime},</if>
|
||||
<if test="modifyUser!=null">#{modifyUser},</if>
|
||||
<if test="modifiedDateTime!=null">#{modifiedDateTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<insert id="insertAllColumn" parameterType="com.foreverwin.mesnac.equip.model.ResourceFaultReceive">
|
||||
INSERT INTO Z_RESOURCE_FAULT_RECEIVE
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<include refid="Base_Column_List"></include>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
#{site},
|
||||
#{resrce},
|
||||
#{faultCode},
|
||||
#{faultDate},
|
||||
#{createUser},
|
||||
#{createdDateTime},
|
||||
#{modifyUser},
|
||||
#{modifiedDateTime},
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
|
||||
<update id="updateById">
|
||||
UPDATE Z_RESOURCE_FAULT_RECEIVE <trim prefix="SET" suffixOverrides=",">
|
||||
<if test="et.site!=null">SITE=#{et.site},</if>
|
||||
<if test="et.resrce!=null">RESRCE=#{et.resrce},</if>
|
||||
<if test="et.faultCode!=null">FAULT_CODE=#{et.faultCode},</if>
|
||||
<if test="et.faultDate!=null">FAULT_DATE=#{et.faultDate},</if>
|
||||
<if test="et.createUser!=null">CREATE_USER=#{et.createUser},</if>
|
||||
<if test="et.createdDateTime!=null">CREATED_DATE_TIME=#{et.createdDateTime},</if>
|
||||
<if test="et.modifyUser!=null">MODIFY_USER=#{et.modifyUser},</if>
|
||||
<if test="et.modifiedDateTime!=null">MODIFIED_DATE_TIME=#{et.modifiedDateTime},</if>
|
||||
</trim> WHERE HANDLE=#{et.handle} <if test="et instanceof java.util.Map"><if test="et.MP_OPTLOCK_VERSION_ORIGINAL!=null">and ${et.MP_OPTLOCK_VERSION_COLUMN}=#{et.MP_OPTLOCK_VERSION_ORIGINAL}</if></if>
|
||||
</update>
|
||||
|
||||
|
||||
<update id="updateAllColumnById">
|
||||
UPDATE Z_RESOURCE_FAULT_RECEIVE <trim prefix="SET" suffixOverrides=",">
|
||||
SITE=#{et.site},
|
||||
RESRCE=#{et.resrce},
|
||||
FAULT_CODE=#{et.faultCode},
|
||||
FAULT_DATE=#{et.faultDate},
|
||||
CREATE_USER=#{et.createUser},
|
||||
CREATED_DATE_TIME=#{et.createdDateTime},
|
||||
MODIFY_USER=#{et.modifyUser},
|
||||
MODIFIED_DATE_TIME=#{et.modifiedDateTime},
|
||||
</trim> WHERE HANDLE=#{et.handle} <if test="et instanceof java.util.Map"><if test="et.MP_OPTLOCK_VERSION_ORIGINAL!=null">and ${et.MP_OPTLOCK_VERSION_COLUMN}=#{et.MP_OPTLOCK_VERSION_ORIGINAL}</if></if>
|
||||
</update>
|
||||
|
||||
|
||||
<update id="update">
|
||||
UPDATE Z_RESOURCE_FAULT_RECEIVE <trim prefix="SET" suffixOverrides=",">
|
||||
<if test="et.site!=null">SITE=#{et.site},</if>
|
||||
<if test="et.resrce!=null">RESRCE=#{et.resrce},</if>
|
||||
<if test="et.faultCode!=null">FAULT_CODE=#{et.faultCode},</if>
|
||||
<if test="et.faultDate!=null">FAULT_DATE=#{et.faultDate},</if>
|
||||
<if test="et.createUser!=null">CREATE_USER=#{et.createUser},</if>
|
||||
<if test="et.createdDateTime!=null">CREATED_DATE_TIME=#{et.createdDateTime},</if>
|
||||
<if test="et.modifyUser!=null">MODIFY_USER=#{et.modifyUser},</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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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="deleteById">
|
||||
DELETE FROM Z_RESOURCE_FAULT_RECEIVE WHERE HANDLE=#{handle}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteByMap">
|
||||
DELETE FROM Z_RESOURCE_FAULT_RECEIVE
|
||||
<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 Z_RESOURCE_FAULT_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.faultCode!=null"> AND FAULT_CODE=#{ew.entity.faultCode}</if>
|
||||
<if test="ew.entity.faultDate!=null"> AND FAULT_DATE=#{ew.entity.faultDate}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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>
|
||||
|
||||
<delete id="deleteBatchIds">
|
||||
DELETE FROM Z_RESOURCE_FAULT_RECEIVE WHERE HANDLE IN (
|
||||
<foreach item="item" index="index" collection="coll" separator=",">#{item}
|
||||
</foreach>)
|
||||
</delete>
|
||||
<!-- BaseMapper标准查询/修改/删除 -->
|
||||
|
||||
</mapper>
|
@ -0,0 +1,447 @@
|
||||
<?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.equip.mapper.ResourceStatusReceiveMapper">
|
||||
|
||||
<!-- 通用查询映射结果 -->
|
||||
<resultMap id="BaseResultMap" type="com.foreverwin.mesnac.equip.model.ResourceStatusReceive">
|
||||
<id column="HANDLE" property="handle" />
|
||||
<result column="SITE" property="site" />
|
||||
<result column="RESRCE" property="resrce" />
|
||||
<result column="STATUS" property="status" />
|
||||
<result column="DATE_TIME" property="dateTime" />
|
||||
<result column="CHANGE_STATUS" property="changeStatus" />
|
||||
<result column="CHANGE_DATE_TIME" property="changeDateTime" />
|
||||
<result column="INTERVAL_TIME" property="intervalTime" />
|
||||
<result column="CREATE_USER" property="createUser" />
|
||||
<result column="CREATED_DATE_TIME" property="createdDateTime" />
|
||||
<result column="MODIFY_USER" property="modifyUser" />
|
||||
<result column="MODIFIED_DATE_TIME" property="modifiedDateTime" />
|
||||
</resultMap>
|
||||
|
||||
<!-- 通用查询结果列 -->
|
||||
<sql id="Base_Column_List">
|
||||
HANDLE, SITE, RESRCE, STATUS, DATE_TIME, CHANGE_STATUS, CHANGE_DATE_TIME, INTERVAL_TIME, CREATE_USER, CREATED_DATE_TIME, MODIFY_USER, MODIFIED_DATE_TIME
|
||||
</sql>
|
||||
|
||||
<!-- BaseMapper标准查询/修改/删除 -->
|
||||
<select id="selectById" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include> FROM Z_RESOURCE_STATUS_RECEIVE WHERE HANDLE=#{handle}
|
||||
</select>
|
||||
|
||||
<select id="selectByMap" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include>
|
||||
FROM Z_RESOURCE_STATUS_RECEIVE
|
||||
<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="selectBatchIds" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include>
|
||||
FROM Z_RESOURCE_STATUS_RECEIVE WHERE HANDLE IN (
|
||||
<foreach item="item" index="index" collection="coll" separator=",">#{item}
|
||||
</foreach>)
|
||||
</select>
|
||||
|
||||
<select id="selectOne" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include> FROM Z_RESOURCE_STATUS_RECEIVE
|
||||
<where>
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.handle}
|
||||
</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_STATUS_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_STATUS_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_STATUS_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_STATUS_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_STATUS_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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 Z_RESOURCE_STATUS_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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.equip.model.ResourceStatusReceive">
|
||||
INSERT INTO Z_RESOURCE_STATUS_RECEIVE
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
HANDLE,
|
||||
<if test="site!=null">SITE,</if>
|
||||
<if test="resrce!=null">RESRCE,</if>
|
||||
<if test="status!=null">STATUS,</if>
|
||||
<if test="dateTime!=null">DATE_TIME,</if>
|
||||
<if test="changeStatus!=null">CHANGE_STATUS,</if>
|
||||
<if test="changeDateTime!=null">CHANGE_DATE_TIME,</if>
|
||||
<if test="intervalTime!=null">INTERVAL_TIME,</if>
|
||||
<if test="createUser!=null">CREATE_USER,</if>
|
||||
<if test="createdDateTime!=null">CREATED_DATE_TIME,</if>
|
||||
<if test="modifyUser!=null">MODIFY_USER,</if>
|
||||
<if test="modifiedDateTime!=null">MODIFIED_DATE_TIME,</if>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
<if test="site!=null">#{site},</if>
|
||||
<if test="resrce!=null">#{resrce},</if>
|
||||
<if test="status!=null">#{status},</if>
|
||||
<if test="dateTime!=null">#{dateTime},</if>
|
||||
<if test="changeStatus!=null">#{changeStatus},</if>
|
||||
<if test="changeDateTime!=null">#{changeDateTime},</if>
|
||||
<if test="intervalTime!=null">#{intervalTime},</if>
|
||||
<if test="createUser!=null">#{createUser},</if>
|
||||
<if test="createdDateTime!=null">#{createdDateTime},</if>
|
||||
<if test="modifyUser!=null">#{modifyUser},</if>
|
||||
<if test="modifiedDateTime!=null">#{modifiedDateTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<insert id="insertAllColumn" parameterType="com.foreverwin.mesnac.equip.model.ResourceStatusReceive">
|
||||
INSERT INTO Z_RESOURCE_STATUS_RECEIVE
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<include refid="Base_Column_List"></include>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
#{site},
|
||||
#{resrce},
|
||||
#{status},
|
||||
#{dateTime},
|
||||
#{changeStatus},
|
||||
#{changeDateTime},
|
||||
#{intervalTime},
|
||||
#{createUser},
|
||||
#{createdDateTime},
|
||||
#{modifyUser},
|
||||
#{modifiedDateTime},
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
|
||||
<update id="updateById">
|
||||
UPDATE Z_RESOURCE_STATUS_RECEIVE <trim prefix="SET" suffixOverrides=",">
|
||||
<if test="et.site!=null">SITE=#{et.site},</if>
|
||||
<if test="et.resrce!=null">RESRCE=#{et.resrce},</if>
|
||||
<if test="et.status!=null">STATUS=#{et.status},</if>
|
||||
<if test="et.dateTime!=null">DATE_TIME=#{et.dateTime},</if>
|
||||
<if test="et.changeStatus!=null">CHANGE_STATUS=#{et.changeStatus},</if>
|
||||
<if test="et.changeDateTime!=null">CHANGE_DATE_TIME=#{et.changeDateTime},</if>
|
||||
<if test="et.intervalTime!=null">INTERVAL_TIME=#{et.intervalTime},</if>
|
||||
<if test="et.createUser!=null">CREATE_USER=#{et.createUser},</if>
|
||||
<if test="et.createdDateTime!=null">CREATED_DATE_TIME=#{et.createdDateTime},</if>
|
||||
<if test="et.modifyUser!=null">MODIFY_USER=#{et.modifyUser},</if>
|
||||
<if test="et.modifiedDateTime!=null">MODIFIED_DATE_TIME=#{et.modifiedDateTime},</if>
|
||||
</trim> WHERE HANDLE=#{et.handle} <if test="et instanceof java.util.Map"><if test="et.MP_OPTLOCK_VERSION_ORIGINAL!=null">and ${et.MP_OPTLOCK_VERSION_COLUMN}=#{et.MP_OPTLOCK_VERSION_ORIGINAL}</if></if>
|
||||
</update>
|
||||
|
||||
|
||||
<update id="updateAllColumnById">
|
||||
UPDATE Z_RESOURCE_STATUS_RECEIVE <trim prefix="SET" suffixOverrides=",">
|
||||
SITE=#{et.site},
|
||||
RESRCE=#{et.resrce},
|
||||
STATUS=#{et.status},
|
||||
DATE_TIME=#{et.dateTime},
|
||||
CHANGE_STATUS=#{et.changeStatus},
|
||||
CHANGE_DATE_TIME=#{et.changeDateTime},
|
||||
INTERVAL_TIME=#{et.intervalTime},
|
||||
CREATE_USER=#{et.createUser},
|
||||
CREATED_DATE_TIME=#{et.createdDateTime},
|
||||
MODIFY_USER=#{et.modifyUser},
|
||||
MODIFIED_DATE_TIME=#{et.modifiedDateTime},
|
||||
</trim> WHERE HANDLE=#{et.handle} <if test="et instanceof java.util.Map"><if test="et.MP_OPTLOCK_VERSION_ORIGINAL!=null">and ${et.MP_OPTLOCK_VERSION_COLUMN}=#{et.MP_OPTLOCK_VERSION_ORIGINAL}</if></if>
|
||||
</update>
|
||||
|
||||
|
||||
<update id="update">
|
||||
UPDATE Z_RESOURCE_STATUS_RECEIVE <trim prefix="SET" suffixOverrides=",">
|
||||
<if test="et.site!=null">SITE=#{et.site},</if>
|
||||
<if test="et.resrce!=null">RESRCE=#{et.resrce},</if>
|
||||
<if test="et.status!=null">STATUS=#{et.status},</if>
|
||||
<if test="et.dateTime!=null">DATE_TIME=#{et.dateTime},</if>
|
||||
<if test="et.changeStatus!=null">CHANGE_STATUS=#{et.changeStatus},</if>
|
||||
<if test="et.changeDateTime!=null">CHANGE_DATE_TIME=#{et.changeDateTime},</if>
|
||||
<if test="et.intervalTime!=null">INTERVAL_TIME=#{et.intervalTime},</if>
|
||||
<if test="et.createUser!=null">CREATE_USER=#{et.createUser},</if>
|
||||
<if test="et.createdDateTime!=null">CREATED_DATE_TIME=#{et.createdDateTime},</if>
|
||||
<if test="et.modifyUser!=null">MODIFY_USER=#{et.modifyUser},</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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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="deleteById">
|
||||
DELETE FROM Z_RESOURCE_STATUS_RECEIVE WHERE HANDLE=#{handle}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteByMap">
|
||||
DELETE FROM Z_RESOURCE_STATUS_RECEIVE
|
||||
<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 Z_RESOURCE_STATUS_RECEIVE
|
||||
<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.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.resrce!=null"> AND RESRCE=#{ew.entity.resrce}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.dateTime!=null"> AND DATE_TIME=#{ew.entity.dateTime}</if>
|
||||
<if test="ew.entity.changeStatus!=null"> AND CHANGE_STATUS=#{ew.entity.changeStatus}</if>
|
||||
<if test="ew.entity.changeDateTime!=null"> AND CHANGE_DATE_TIME=#{ew.entity.changeDateTime}</if>
|
||||
<if test="ew.entity.intervalTime!=null"> AND INTERVAL_TIME=#{ew.entity.intervalTime}</if>
|
||||
<if test="ew.entity.createUser!=null"> AND CREATE_USER=#{ew.entity.createUser}</if>
|
||||
<if test="ew.entity.createdDateTime!=null"> AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}</if>
|
||||
<if test="ew.entity.modifyUser!=null"> AND MODIFY_USER=#{ew.entity.modifyUser}</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>
|
||||
|
||||
<delete id="deleteBatchIds">
|
||||
DELETE FROM Z_RESOURCE_STATUS_RECEIVE WHERE HANDLE IN (
|
||||
<foreach item="item" index="index" collection="coll" separator=",">#{item}
|
||||
</foreach>)
|
||||
</delete>
|
||||
<!-- BaseMapper标准查询/修改/删除 -->
|
||||
|
||||
<!--自定义sql-->
|
||||
<select id="getOneByMaxCreateDateTime" resultType="com.foreverwin.mesnac.equip.model.ResourceStatusReceive">
|
||||
SELECT RSR.*
|
||||
FROM
|
||||
Z_RESOURCE_STATUS_RECEIVE RSR
|
||||
WHERE
|
||||
RSR.CREATED_DATE_TIME = (SELECT MAX(CREATED_DATE_TIME) FROM Z_RESOURCE_STATUS_RECEIVE )
|
||||
AND RSR.SITE = #{site}
|
||||
</select>
|
||||
<!--自定义sql-->
|
||||
|
||||
|
||||
|
||||
</mapper>
|
@ -0,0 +1,134 @@
|
||||
package com.foreverwin.mesnac.meapi.controller;
|
||||
|
||||
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.meapi.service.DcGroupService;
|
||||
import com.foreverwin.mesnac.meapi.model.DcGroup;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/DC-GROUP")
|
||||
public class DcGroupController {
|
||||
|
||||
@Autowired
|
||||
public DcGroupService dcGroupService;
|
||||
|
||||
/**
|
||||
* 根据id查询
|
||||
*
|
||||
* @param id 主键
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/{id:.+}")
|
||||
public R getDcGroupById(@PathVariable String id) {
|
||||
return R.ok( dcGroupService.getById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有数据
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("")
|
||||
public R getDcGroupList(DcGroup dcGroup){
|
||||
List<DcGroup> result;
|
||||
QueryWrapper<DcGroup> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(dcGroup);
|
||||
result = dcGroupService.list(queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询数据
|
||||
*
|
||||
* @param frontPage 分页信息
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/page")
|
||||
public R page(FrontPage<DcGroup> frontPage, DcGroup dcGroup){
|
||||
IPage result;
|
||||
QueryWrapper<DcGroup> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(dcGroup);
|
||||
if (frontPage.getGlobalQuery() != null && !"".equals(frontPage.getGlobalQuery().trim())) {
|
||||
//TODO modify global query
|
||||
queryWrapper.lambda().and(wrapper -> wrapper
|
||||
.like(DcGroup::getHandle, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getDcGroup, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getDescription, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getSite, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getCollectDataAt, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getCustomButtonId, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getPassFailGroup, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getRevision, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getCurrentRevision, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getStatusBo, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getAuthenticationRequired, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getErp, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getCollectMethod, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getCollectionType, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getErpInspection, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getErpWholeGroupInspection, frontPage.getGlobalQuery())
|
||||
.or().like(DcGroup::getMeEvalInspection, frontPage.getGlobalQuery())
|
||||
);
|
||||
}
|
||||
result = dcGroupService.page(frontPage.getPagePlus(), queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增
|
||||
* @param dcGroup 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PostMapping
|
||||
public R save(@RequestBody DcGroup dcGroup) {
|
||||
return R.ok(dcGroupService.save(dcGroup));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
* @param dcGroup 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PutMapping
|
||||
public R updateById(@RequestBody DcGroup dcGroup) {
|
||||
return R.ok(dcGroupService.updateById(dcGroup));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据id删除对象
|
||||
* @param id 实体ID
|
||||
* @return 0 失败 1 成功
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(method = RequestMethod.DELETE, value = "/{id:.+}")
|
||||
public R removeById(@PathVariable("id") String id){
|
||||
return R.ok(dcGroupService.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(dcGroupService.removeByIds(ids));
|
||||
}
|
||||
}
|
@ -0,0 +1,152 @@
|
||||
package com.foreverwin.mesnac.meapi.controller;
|
||||
|
||||
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.meapi.service.DcParameterService;
|
||||
import com.foreverwin.mesnac.meapi.model.DcParameter;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/DC-PARAMETER")
|
||||
public class DcParameterController {
|
||||
|
||||
@Autowired
|
||||
public DcParameterService dcParameterService;
|
||||
|
||||
/**
|
||||
* 根据id查询
|
||||
*
|
||||
* @param id 主键
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/{id:.+}")
|
||||
public R getDcParameterById(@PathVariable String id) {
|
||||
return R.ok( dcParameterService.getById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询所有数据
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("")
|
||||
public R getDcParameterList(DcParameter dcParameter){
|
||||
List<DcParameter> result;
|
||||
QueryWrapper<DcParameter> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(dcParameter);
|
||||
result = dcParameterService.list(queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询数据
|
||||
*
|
||||
* @param frontPage 分页信息
|
||||
* @return
|
||||
*/
|
||||
@ResponseBody
|
||||
@GetMapping("/page")
|
||||
public R page(FrontPage<DcParameter> frontPage, DcParameter dcParameter){
|
||||
IPage result;
|
||||
QueryWrapper<DcParameter> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(dcParameter);
|
||||
if (frontPage.getGlobalQuery() != null && !"".equals(frontPage.getGlobalQuery().trim())) {
|
||||
//TODO modify global query
|
||||
queryWrapper.lambda().and(wrapper -> wrapper
|
||||
.like(DcParameter::getHandle, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getDcGroupBo, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getParameterName, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getDataType, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getStatus, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getAllowMissingValue, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getPerformSpc, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getDisplayChart, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getDescription, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getUnits, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getSpcChartBo, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getDisplayDataInformation, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOverrideMinMax, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getDcValueMask, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getExpressionBuilder, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getShortRun, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcAcquireAt, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcServer, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcDevice, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcTag, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcServerHostname, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcServerModel, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcServerProgid, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcServerClsid, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcDeviceId, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getOpcTagId, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getScriptBo, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getBooleanZeroValue, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getBooleanOneValue, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getErpQmCharType, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getErpIsQmCritical, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getSoftLimitCheck, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getAutoLogNc, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getNcCodeBo, frontPage.getGlobalQuery())
|
||||
.or().like(DcParameter::getDataFieldBo, frontPage.getGlobalQuery())
|
||||
);
|
||||
}
|
||||
result = dcParameterService.page(frontPage.getPagePlus(), queryWrapper);
|
||||
return R.ok(result);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增
|
||||
* @param dcParameter 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PostMapping
|
||||
public R save(@RequestBody DcParameter dcParameter) {
|
||||
return R.ok(dcParameterService.save(dcParameter));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改
|
||||
* @param dcParameter 传递的实体
|
||||
* @return null 失败 实体成功
|
||||
*/
|
||||
@PutMapping
|
||||
public R updateById(@RequestBody DcParameter dcParameter) {
|
||||
return R.ok(dcParameterService.updateById(dcParameter));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据id删除对象
|
||||
* @param id 实体ID
|
||||
* @return 0 失败 1 成功
|
||||
*/
|
||||
@ResponseBody
|
||||
@RequestMapping(method = RequestMethod.DELETE, value = "/{id:.+}")
|
||||
public R removeById(@PathVariable("id") String id){
|
||||
return R.ok(dcParameterService.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(dcParameterService.removeByIds(ids));
|
||||
}
|
||||
}
|
@ -0,0 +1,18 @@
|
||||
package com.foreverwin.mesnac.meapi.mapper;
|
||||
|
||||
import com.foreverwin.mesnac.meapi.model.DcGroup;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@Repository
|
||||
public interface DcGroupMapper extends BaseMapper<DcGroup> {
|
||||
|
||||
}
|
@ -0,0 +1,32 @@
|
||||
package com.foreverwin.mesnac.meapi.mapper;
|
||||
|
||||
import com.foreverwin.mesnac.meapi.model.DcParameter;
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.stereotype.Repository;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Mapper 接口
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@Repository
|
||||
public interface DcParameterMapper extends BaseMapper<DcParameter> {
|
||||
|
||||
/**
|
||||
* 获取数据收集组下的字段关联关系-为参数接口服务
|
||||
* @param dcGroupBo
|
||||
* @return
|
||||
*/
|
||||
List<DcParameter> getDcParameterByDcGroupBo(@Param("dcGroupBo")String dcGroupBo);
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,300 @@
|
||||
package com.foreverwin.mesnac.meapi.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;
|
||||
import java.io.Serializable;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
|
||||
@TableName("DC_GROUP")
|
||||
|
||||
public class DcGroup extends Model<DcGroup> {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@TableField("HANDLE")
|
||||
private String handle;
|
||||
@TableField("DC_GROUP")
|
||||
private String dcGroup;
|
||||
@TableField("DESCRIPTION")
|
||||
private String description;
|
||||
@TableField("SITE")
|
||||
private String site;
|
||||
@TableField("COLLECT_DATA_AT")
|
||||
private String collectDataAt;
|
||||
@TableField("CUSTOM_BUTTON_ID")
|
||||
private String customButtonId;
|
||||
@TableField("PASS_FAIL_GROUP")
|
||||
private String passFailGroup;
|
||||
@TableField("REVISION")
|
||||
private String revision;
|
||||
@TableField("CURRENT_REVISION")
|
||||
private String currentRevision;
|
||||
@TableField("STATUS_BO")
|
||||
private String statusBo;
|
||||
@TableField("AUTHENTICATION_REQUIRED")
|
||||
private String authenticationRequired;
|
||||
@TableField("ERP")
|
||||
private String erp;
|
||||
@TableField("COLLECT_METHOD")
|
||||
private String collectMethod;
|
||||
@TableField("COLLECTION_TYPE")
|
||||
private String collectionType;
|
||||
@TableField("CREATED_DATE_TIME")
|
||||
private LocalDateTime createdDateTime;
|
||||
@TableField("MODIFIED_DATE_TIME")
|
||||
private LocalDateTime modifiedDateTime;
|
||||
@TableField("ERP_INSPECTION")
|
||||
private String erpInspection;
|
||||
@TableField("ERP_WHOLE_GROUP_INSPECTION")
|
||||
private String erpWholeGroupInspection;
|
||||
@TableField("ME_EVAL_INSPECTION")
|
||||
private String meEvalInspection;
|
||||
@TableField("PASS_FAIL_NUMBER")
|
||||
private Long passFailNumber;
|
||||
|
||||
|
||||
public String getHandle() {
|
||||
return handle;
|
||||
}
|
||||
|
||||
public void setHandle(String handle) {
|
||||
this.handle = handle;
|
||||
}
|
||||
|
||||
public String getDcGroup() {
|
||||
return dcGroup;
|
||||
}
|
||||
|
||||
public void setDcGroup(String dcGroup) {
|
||||
this.dcGroup = dcGroup;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public String getSite() {
|
||||
return site;
|
||||
}
|
||||
|
||||
public void setSite(String site) {
|
||||
this.site = site;
|
||||
}
|
||||
|
||||
public String getCollectDataAt() {
|
||||
return collectDataAt;
|
||||
}
|
||||
|
||||
public void setCollectDataAt(String collectDataAt) {
|
||||
this.collectDataAt = collectDataAt;
|
||||
}
|
||||
|
||||
public String getCustomButtonId() {
|
||||
return customButtonId;
|
||||
}
|
||||
|
||||
public void setCustomButtonId(String customButtonId) {
|
||||
this.customButtonId = customButtonId;
|
||||
}
|
||||
|
||||
public String getPassFailGroup() {
|
||||
return passFailGroup;
|
||||
}
|
||||
|
||||
public void setPassFailGroup(String passFailGroup) {
|
||||
this.passFailGroup = passFailGroup;
|
||||
}
|
||||
|
||||
public String getRevision() {
|
||||
return revision;
|
||||
}
|
||||
|
||||
public void setRevision(String revision) {
|
||||
this.revision = revision;
|
||||
}
|
||||
|
||||
public String getCurrentRevision() {
|
||||
return currentRevision;
|
||||
}
|
||||
|
||||
public void setCurrentRevision(String currentRevision) {
|
||||
this.currentRevision = currentRevision;
|
||||
}
|
||||
|
||||
public String getStatusBo() {
|
||||
return statusBo;
|
||||
}
|
||||
|
||||
public void setStatusBo(String statusBo) {
|
||||
this.statusBo = statusBo;
|
||||
}
|
||||
|
||||
public String getAuthenticationRequired() {
|
||||
return authenticationRequired;
|
||||
}
|
||||
|
||||
public void setAuthenticationRequired(String authenticationRequired) {
|
||||
this.authenticationRequired = authenticationRequired;
|
||||
}
|
||||
|
||||
public String getErp() {
|
||||
return erp;
|
||||
}
|
||||
|
||||
public void setErp(String erp) {
|
||||
this.erp = erp;
|
||||
}
|
||||
|
||||
public String getCollectMethod() {
|
||||
return collectMethod;
|
||||
}
|
||||
|
||||
public void setCollectMethod(String collectMethod) {
|
||||
this.collectMethod = collectMethod;
|
||||
}
|
||||
|
||||
public String getCollectionType() {
|
||||
return collectionType;
|
||||
}
|
||||
|
||||
public void setCollectionType(String collectionType) {
|
||||
this.collectionType = collectionType;
|
||||
}
|
||||
|
||||
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 String getErpInspection() {
|
||||
return erpInspection;
|
||||
}
|
||||
|
||||
public void setErpInspection(String erpInspection) {
|
||||
this.erpInspection = erpInspection;
|
||||
}
|
||||
|
||||
public String getErpWholeGroupInspection() {
|
||||
return erpWholeGroupInspection;
|
||||
}
|
||||
|
||||
public void setErpWholeGroupInspection(String erpWholeGroupInspection) {
|
||||
this.erpWholeGroupInspection = erpWholeGroupInspection;
|
||||
}
|
||||
|
||||
public String getMeEvalInspection() {
|
||||
return meEvalInspection;
|
||||
}
|
||||
|
||||
public void setMeEvalInspection(String meEvalInspection) {
|
||||
this.meEvalInspection = meEvalInspection;
|
||||
}
|
||||
|
||||
public Long getPassFailNumber() {
|
||||
return passFailNumber;
|
||||
}
|
||||
|
||||
public void setPassFailNumber(Long passFailNumber) {
|
||||
this.passFailNumber = passFailNumber;
|
||||
}
|
||||
|
||||
public static final String HANDLE = "HANDLE";
|
||||
|
||||
public static final String DC_GROUP = "DC_GROUP";
|
||||
|
||||
public static final String DESCRIPTION = "DESCRIPTION";
|
||||
|
||||
public static final String SITE = "SITE";
|
||||
|
||||
public static final String COLLECT_DATA_AT = "COLLECT_DATA_AT";
|
||||
|
||||
public static final String CUSTOM_BUTTON_ID = "CUSTOM_BUTTON_ID";
|
||||
|
||||
public static final String PASS_FAIL_GROUP = "PASS_FAIL_GROUP";
|
||||
|
||||
public static final String REVISION = "REVISION";
|
||||
|
||||
public static final String CURRENT_REVISION = "CURRENT_REVISION";
|
||||
|
||||
public static final String STATUS_BO = "STATUS_BO";
|
||||
|
||||
public static final String AUTHENTICATION_REQUIRED = "AUTHENTICATION_REQUIRED";
|
||||
|
||||
public static final String ERP = "ERP";
|
||||
|
||||
public static final String COLLECT_METHOD = "COLLECT_METHOD";
|
||||
|
||||
public static final String COLLECTION_TYPE = "COLLECTION_TYPE";
|
||||
|
||||
public static final String CREATED_DATE_TIME = "CREATED_DATE_TIME";
|
||||
|
||||
public static final String MODIFIED_DATE_TIME = "MODIFIED_DATE_TIME";
|
||||
|
||||
public static final String ERP_INSPECTION = "ERP_INSPECTION";
|
||||
|
||||
public static final String ERP_WHOLE_GROUP_INSPECTION = "ERP_WHOLE_GROUP_INSPECTION";
|
||||
|
||||
public static final String ME_EVAL_INSPECTION = "ME_EVAL_INSPECTION";
|
||||
|
||||
public static final String PASS_FAIL_NUMBER = "PASS_FAIL_NUMBER";
|
||||
|
||||
|
||||
@Override
|
||||
protected Serializable pkVal() {
|
||||
return this.handle;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "DcGroup{" +
|
||||
"handle = " + handle +
|
||||
", dcGroup = " + dcGroup +
|
||||
", description = " + description +
|
||||
", site = " + site +
|
||||
", collectDataAt = " + collectDataAt +
|
||||
", customButtonId = " + customButtonId +
|
||||
", passFailGroup = " + passFailGroup +
|
||||
", revision = " + revision +
|
||||
", currentRevision = " + currentRevision +
|
||||
", statusBo = " + statusBo +
|
||||
", authenticationRequired = " + authenticationRequired +
|
||||
", erp = " + erp +
|
||||
", collectMethod = " + collectMethod +
|
||||
", collectionType = " + collectionType +
|
||||
", createdDateTime = " + createdDateTime +
|
||||
", modifiedDateTime = " + modifiedDateTime +
|
||||
", erpInspection = " + erpInspection +
|
||||
", erpWholeGroupInspection = " + erpWholeGroupInspection +
|
||||
", meEvalInspection = " + meEvalInspection +
|
||||
", passFailNumber = " + passFailNumber +
|
||||
"}";
|
||||
}
|
||||
}
|
@ -0,0 +1,585 @@
|
||||
package com.foreverwin.mesnac.meapi.model;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.baomidou.mybatisplus.extension.activerecord.Model;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import java.io.Serializable;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
*
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
|
||||
@TableName("DC_PARAMETER")
|
||||
|
||||
public class DcParameter extends Model<DcParameter> {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@TableField("HANDLE")
|
||||
private String handle;
|
||||
@TableField("DC_GROUP_BO")
|
||||
private String dcGroupBo;
|
||||
@TableField("PARAMETER_NAME")
|
||||
private String parameterName;
|
||||
@TableField("DATA_TYPE")
|
||||
private String dataType;
|
||||
@TableField("STATUS")
|
||||
private String status;
|
||||
@TableField("ALLOW_MISSING_VALUE")
|
||||
private String allowMissingValue;
|
||||
@TableField("MIN_VALUE")
|
||||
private Double minValue;
|
||||
@TableField("MAX_VALUE")
|
||||
private Double maxValue;
|
||||
@TableField("SEQUENCE")
|
||||
private Long sequence;
|
||||
@TableField("PERFORM_SPC")
|
||||
private String performSpc;
|
||||
@TableField("DISPLAY_CHART")
|
||||
private String displayChart;
|
||||
@TableField("DESCRIPTION")
|
||||
private String description;
|
||||
@TableField("UNITS")
|
||||
private String units;
|
||||
@TableField("SPC_CHART_BO")
|
||||
private String spcChartBo;
|
||||
@TableField("DISPLAY_DATA_INFORMATION")
|
||||
private String displayDataInformation;
|
||||
@TableField("OVERRIDE_MIN_MAX")
|
||||
private String overrideMinMax;
|
||||
@TableField("DC_VALUE_MASK")
|
||||
private String dcValueMask;
|
||||
@TableField("EXPRESSION_BUILDER")
|
||||
private String expressionBuilder;
|
||||
@TableField("REQUIRED_DATA_ENTRIES")
|
||||
private Long requiredDataEntries;
|
||||
@TableField("OPTIONAL_DATA_ENTRIES")
|
||||
private Long optionalDataEntries;
|
||||
@TableField("SHORT_RUN")
|
||||
private String shortRun;
|
||||
@TableField("OPC_ACQUIRE_AT")
|
||||
private String opcAcquireAt;
|
||||
@TableField("OPC_SERVER")
|
||||
private String opcServer;
|
||||
@TableField("OPC_DEVICE")
|
||||
private String opcDevice;
|
||||
@TableField("OPC_TAG")
|
||||
private String opcTag;
|
||||
@TableField("OPC_SERVER_HOSTNAME")
|
||||
private String opcServerHostname;
|
||||
@TableField("OPC_SERVER_MODEL")
|
||||
private String opcServerModel;
|
||||
@TableField("OPC_SERVER_PROGID")
|
||||
private String opcServerProgid;
|
||||
@TableField("OPC_SERVER_CLSID")
|
||||
private String opcServerClsid;
|
||||
@TableField("OPC_DEVICE_ID")
|
||||
private String opcDeviceId;
|
||||
@TableField("OPC_TAG_ID")
|
||||
private String opcTagId;
|
||||
@TableField("SCRIPT_BO")
|
||||
private String scriptBo;
|
||||
@TableField("BOOLEAN_ZERO_VALUE")
|
||||
private String booleanZeroValue;
|
||||
@TableField("BOOLEAN_ONE_VALUE")
|
||||
private String booleanOneValue;
|
||||
@TableField("ERP_QM_CHAR_TYPE")
|
||||
private String erpQmCharType;
|
||||
@TableField("ERP_IS_QM_CRITICAL")
|
||||
private String erpIsQmCritical;
|
||||
@TableField("SOFT_LIMIT_CHECK")
|
||||
private String softLimitCheck;
|
||||
@TableField("AUTO_LOG_NC")
|
||||
private String autoLogNc;
|
||||
@TableField("NC_CODE_BO")
|
||||
private String ncCodeBo;
|
||||
@TableField("DATA_FIELD_BO")
|
||||
private String dataFieldBo;
|
||||
@TableField("INSPECTION_SAMPLE_SIZE")
|
||||
private Long inspectionSampleSize;
|
||||
@TableField("TARGET_VALUE")
|
||||
private Double targetValue;
|
||||
|
||||
|
||||
public String getHandle() {
|
||||
return handle;
|
||||
}
|
||||
|
||||
public void setHandle(String handle) {
|
||||
this.handle = handle;
|
||||
}
|
||||
|
||||
public String getDcGroupBo() {
|
||||
return dcGroupBo;
|
||||
}
|
||||
|
||||
public void setDcGroupBo(String dcGroupBo) {
|
||||
this.dcGroupBo = dcGroupBo;
|
||||
}
|
||||
|
||||
public String getParameterName() {
|
||||
return parameterName;
|
||||
}
|
||||
|
||||
public void setParameterName(String parameterName) {
|
||||
this.parameterName = parameterName;
|
||||
}
|
||||
|
||||
public String getDataType() {
|
||||
return dataType;
|
||||
}
|
||||
|
||||
public void setDataType(String dataType) {
|
||||
this.dataType = dataType;
|
||||
}
|
||||
|
||||
public String getStatus() {
|
||||
return status;
|
||||
}
|
||||
|
||||
public void setStatus(String status) {
|
||||
this.status = status;
|
||||
}
|
||||
|
||||
public String getAllowMissingValue() {
|
||||
return allowMissingValue;
|
||||
}
|
||||
|
||||
public void setAllowMissingValue(String allowMissingValue) {
|
||||
this.allowMissingValue = allowMissingValue;
|
||||
}
|
||||
|
||||
public Double getMinValue() {
|
||||
return minValue;
|
||||
}
|
||||
|
||||
public void setMinValue(Double minValue) {
|
||||
this.minValue = minValue;
|
||||
}
|
||||
|
||||
public Double getMaxValue() {
|
||||
return maxValue;
|
||||
}
|
||||
|
||||
public void setMaxValue(Double maxValue) {
|
||||
this.maxValue = maxValue;
|
||||
}
|
||||
|
||||
public Long getSequence() {
|
||||
return sequence;
|
||||
}
|
||||
|
||||
public void setSequence(Long sequence) {
|
||||
this.sequence = sequence;
|
||||
}
|
||||
|
||||
public String getPerformSpc() {
|
||||
return performSpc;
|
||||
}
|
||||
|
||||
public void setPerformSpc(String performSpc) {
|
||||
this.performSpc = performSpc;
|
||||
}
|
||||
|
||||
public String getDisplayChart() {
|
||||
return displayChart;
|
||||
}
|
||||
|
||||
public void setDisplayChart(String displayChart) {
|
||||
this.displayChart = displayChart;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public void setDescription(String description) {
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public String getUnits() {
|
||||
return units;
|
||||
}
|
||||
|
||||
public void setUnits(String units) {
|
||||
this.units = units;
|
||||
}
|
||||
|
||||
public String getSpcChartBo() {
|
||||
return spcChartBo;
|
||||
}
|
||||
|
||||
public void setSpcChartBo(String spcChartBo) {
|
||||
this.spcChartBo = spcChartBo;
|
||||
}
|
||||
|
||||
public String getDisplayDataInformation() {
|
||||
return displayDataInformation;
|
||||
}
|
||||
|
||||
public void setDisplayDataInformation(String displayDataInformation) {
|
||||
this.displayDataInformation = displayDataInformation;
|
||||
}
|
||||
|
||||
public String getOverrideMinMax() {
|
||||
return overrideMinMax;
|
||||
}
|
||||
|
||||
public void setOverrideMinMax(String overrideMinMax) {
|
||||
this.overrideMinMax = overrideMinMax;
|
||||
}
|
||||
|
||||
public String getDcValueMask() {
|
||||
return dcValueMask;
|
||||
}
|
||||
|
||||
public void setDcValueMask(String dcValueMask) {
|
||||
this.dcValueMask = dcValueMask;
|
||||
}
|
||||
|
||||
public String getExpressionBuilder() {
|
||||
return expressionBuilder;
|
||||
}
|
||||
|
||||
public void setExpressionBuilder(String expressionBuilder) {
|
||||
this.expressionBuilder = expressionBuilder;
|
||||
}
|
||||
|
||||
public Long getRequiredDataEntries() {
|
||||
return requiredDataEntries;
|
||||
}
|
||||
|
||||
public void setRequiredDataEntries(Long requiredDataEntries) {
|
||||
this.requiredDataEntries = requiredDataEntries;
|
||||
}
|
||||
|
||||
public Long getOptionalDataEntries() {
|
||||
return optionalDataEntries;
|
||||
}
|
||||
|
||||
public void setOptionalDataEntries(Long optionalDataEntries) {
|
||||
this.optionalDataEntries = optionalDataEntries;
|
||||
}
|
||||
|
||||
public String getShortRun() {
|
||||
return shortRun;
|
||||
}
|
||||
|
||||
public void setShortRun(String shortRun) {
|
||||
this.shortRun = shortRun;
|
||||
}
|
||||
|
||||
public String getOpcAcquireAt() {
|
||||
return opcAcquireAt;
|
||||
}
|
||||
|
||||
public void setOpcAcquireAt(String opcAcquireAt) {
|
||||
this.opcAcquireAt = opcAcquireAt;
|
||||
}
|
||||
|
||||
public String getOpcServer() {
|
||||
return opcServer;
|
||||
}
|
||||
|
||||
public void setOpcServer(String opcServer) {
|
||||
this.opcServer = opcServer;
|
||||
}
|
||||
|
||||
public String getOpcDevice() {
|
||||
return opcDevice;
|
||||
}
|
||||
|
||||
public void setOpcDevice(String opcDevice) {
|
||||
this.opcDevice = opcDevice;
|
||||
}
|
||||
|
||||
public String getOpcTag() {
|
||||
return opcTag;
|
||||
}
|
||||
|
||||
public void setOpcTag(String opcTag) {
|
||||
this.opcTag = opcTag;
|
||||
}
|
||||
|
||||
public String getOpcServerHostname() {
|
||||
return opcServerHostname;
|
||||
}
|
||||
|
||||
public void setOpcServerHostname(String opcServerHostname) {
|
||||
this.opcServerHostname = opcServerHostname;
|
||||
}
|
||||
|
||||
public String getOpcServerModel() {
|
||||
return opcServerModel;
|
||||
}
|
||||
|
||||
public void setOpcServerModel(String opcServerModel) {
|
||||
this.opcServerModel = opcServerModel;
|
||||
}
|
||||
|
||||
public String getOpcServerProgid() {
|
||||
return opcServerProgid;
|
||||
}
|
||||
|
||||
public void setOpcServerProgid(String opcServerProgid) {
|
||||
this.opcServerProgid = opcServerProgid;
|
||||
}
|
||||
|
||||
public String getOpcServerClsid() {
|
||||
return opcServerClsid;
|
||||
}
|
||||
|
||||
public void setOpcServerClsid(String opcServerClsid) {
|
||||
this.opcServerClsid = opcServerClsid;
|
||||
}
|
||||
|
||||
public String getOpcDeviceId() {
|
||||
return opcDeviceId;
|
||||
}
|
||||
|
||||
public void setOpcDeviceId(String opcDeviceId) {
|
||||
this.opcDeviceId = opcDeviceId;
|
||||
}
|
||||
|
||||
public String getOpcTagId() {
|
||||
return opcTagId;
|
||||
}
|
||||
|
||||
public void setOpcTagId(String opcTagId) {
|
||||
this.opcTagId = opcTagId;
|
||||
}
|
||||
|
||||
public String getScriptBo() {
|
||||
return scriptBo;
|
||||
}
|
||||
|
||||
public void setScriptBo(String scriptBo) {
|
||||
this.scriptBo = scriptBo;
|
||||
}
|
||||
|
||||
public String getBooleanZeroValue() {
|
||||
return booleanZeroValue;
|
||||
}
|
||||
|
||||
public void setBooleanZeroValue(String booleanZeroValue) {
|
||||
this.booleanZeroValue = booleanZeroValue;
|
||||
}
|
||||
|
||||
public String getBooleanOneValue() {
|
||||
return booleanOneValue;
|
||||
}
|
||||
|
||||
public void setBooleanOneValue(String booleanOneValue) {
|
||||
this.booleanOneValue = booleanOneValue;
|
||||
}
|
||||
|
||||
public String getErpQmCharType() {
|
||||
return erpQmCharType;
|
||||
}
|
||||
|
||||
public void setErpQmCharType(String erpQmCharType) {
|
||||
this.erpQmCharType = erpQmCharType;
|
||||
}
|
||||
|
||||
public String getErpIsQmCritical() {
|
||||
return erpIsQmCritical;
|
||||
}
|
||||
|
||||
public void setErpIsQmCritical(String erpIsQmCritical) {
|
||||
this.erpIsQmCritical = erpIsQmCritical;
|
||||
}
|
||||
|
||||
public String getSoftLimitCheck() {
|
||||
return softLimitCheck;
|
||||
}
|
||||
|
||||
public void setSoftLimitCheck(String softLimitCheck) {
|
||||
this.softLimitCheck = softLimitCheck;
|
||||
}
|
||||
|
||||
public String getAutoLogNc() {
|
||||
return autoLogNc;
|
||||
}
|
||||
|
||||
public void setAutoLogNc(String autoLogNc) {
|
||||
this.autoLogNc = autoLogNc;
|
||||
}
|
||||
|
||||
public String getNcCodeBo() {
|
||||
return ncCodeBo;
|
||||
}
|
||||
|
||||
public void setNcCodeBo(String ncCodeBo) {
|
||||
this.ncCodeBo = ncCodeBo;
|
||||
}
|
||||
|
||||
public String getDataFieldBo() {
|
||||
return dataFieldBo;
|
||||
}
|
||||
|
||||
public void setDataFieldBo(String dataFieldBo) {
|
||||
this.dataFieldBo = dataFieldBo;
|
||||
}
|
||||
|
||||
public Long getInspectionSampleSize() {
|
||||
return inspectionSampleSize;
|
||||
}
|
||||
|
||||
public void setInspectionSampleSize(Long inspectionSampleSize) {
|
||||
this.inspectionSampleSize = inspectionSampleSize;
|
||||
}
|
||||
|
||||
public Double getTargetValue() {
|
||||
return targetValue;
|
||||
}
|
||||
|
||||
public void setTargetValue(Double targetValue) {
|
||||
this.targetValue = targetValue;
|
||||
}
|
||||
|
||||
public static final String HANDLE = "HANDLE";
|
||||
|
||||
public static final String DC_GROUP_BO = "DC_GROUP_BO";
|
||||
|
||||
public static final String PARAMETER_NAME = "PARAMETER_NAME";
|
||||
|
||||
public static final String DATA_TYPE = "DATA_TYPE";
|
||||
|
||||
public static final String STATUS = "STATUS";
|
||||
|
||||
public static final String ALLOW_MISSING_VALUE = "ALLOW_MISSING_VALUE";
|
||||
|
||||
public static final String MIN_VALUE = "MIN_VALUE";
|
||||
|
||||
public static final String MAX_VALUE = "MAX_VALUE";
|
||||
|
||||
public static final String SEQUENCE = "SEQUENCE";
|
||||
|
||||
public static final String PERFORM_SPC = "PERFORM_SPC";
|
||||
|
||||
public static final String DISPLAY_CHART = "DISPLAY_CHART";
|
||||
|
||||
public static final String DESCRIPTION = "DESCRIPTION";
|
||||
|
||||
public static final String UNITS = "UNITS";
|
||||
|
||||
public static final String SPC_CHART_BO = "SPC_CHART_BO";
|
||||
|
||||
public static final String DISPLAY_DATA_INFORMATION = "DISPLAY_DATA_INFORMATION";
|
||||
|
||||
public static final String OVERRIDE_MIN_MAX = "OVERRIDE_MIN_MAX";
|
||||
|
||||
public static final String DC_VALUE_MASK = "DC_VALUE_MASK";
|
||||
|
||||
public static final String EXPRESSION_BUILDER = "EXPRESSION_BUILDER";
|
||||
|
||||
public static final String REQUIRED_DATA_ENTRIES = "REQUIRED_DATA_ENTRIES";
|
||||
|
||||
public static final String OPTIONAL_DATA_ENTRIES = "OPTIONAL_DATA_ENTRIES";
|
||||
|
||||
public static final String SHORT_RUN = "SHORT_RUN";
|
||||
|
||||
public static final String OPC_ACQUIRE_AT = "OPC_ACQUIRE_AT";
|
||||
|
||||
public static final String OPC_SERVER = "OPC_SERVER";
|
||||
|
||||
public static final String OPC_DEVICE = "OPC_DEVICE";
|
||||
|
||||
public static final String OPC_TAG = "OPC_TAG";
|
||||
|
||||
public static final String OPC_SERVER_HOSTNAME = "OPC_SERVER_HOSTNAME";
|
||||
|
||||
public static final String OPC_SERVER_MODEL = "OPC_SERVER_MODEL";
|
||||
|
||||
public static final String OPC_SERVER_PROGID = "OPC_SERVER_PROGID";
|
||||
|
||||
public static final String OPC_SERVER_CLSID = "OPC_SERVER_CLSID";
|
||||
|
||||
public static final String OPC_DEVICE_ID = "OPC_DEVICE_ID";
|
||||
|
||||
public static final String OPC_TAG_ID = "OPC_TAG_ID";
|
||||
|
||||
public static final String SCRIPT_BO = "SCRIPT_BO";
|
||||
|
||||
public static final String BOOLEAN_ZERO_VALUE = "BOOLEAN_ZERO_VALUE";
|
||||
|
||||
public static final String BOOLEAN_ONE_VALUE = "BOOLEAN_ONE_VALUE";
|
||||
|
||||
public static final String ERP_QM_CHAR_TYPE = "ERP_QM_CHAR_TYPE";
|
||||
|
||||
public static final String ERP_IS_QM_CRITICAL = "ERP_IS_QM_CRITICAL";
|
||||
|
||||
public static final String SOFT_LIMIT_CHECK = "SOFT_LIMIT_CHECK";
|
||||
|
||||
public static final String AUTO_LOG_NC = "AUTO_LOG_NC";
|
||||
|
||||
public static final String NC_CODE_BO = "NC_CODE_BO";
|
||||
|
||||
public static final String DATA_FIELD_BO = "DATA_FIELD_BO";
|
||||
|
||||
public static final String INSPECTION_SAMPLE_SIZE = "INSPECTION_SAMPLE_SIZE";
|
||||
|
||||
public static final String TARGET_VALUE = "TARGET_VALUE";
|
||||
|
||||
|
||||
@Override
|
||||
protected Serializable pkVal() {
|
||||
return this.handle;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "DcParameter{" +
|
||||
"handle = " + handle +
|
||||
", dcGroupBo = " + dcGroupBo +
|
||||
", parameterName = " + parameterName +
|
||||
", dataType = " + dataType +
|
||||
", status = " + status +
|
||||
", allowMissingValue = " + allowMissingValue +
|
||||
", minValue = " + minValue +
|
||||
", maxValue = " + maxValue +
|
||||
", sequence = " + sequence +
|
||||
", performSpc = " + performSpc +
|
||||
", displayChart = " + displayChart +
|
||||
", description = " + description +
|
||||
", units = " + units +
|
||||
", spcChartBo = " + spcChartBo +
|
||||
", displayDataInformation = " + displayDataInformation +
|
||||
", overrideMinMax = " + overrideMinMax +
|
||||
", dcValueMask = " + dcValueMask +
|
||||
", expressionBuilder = " + expressionBuilder +
|
||||
", requiredDataEntries = " + requiredDataEntries +
|
||||
", optionalDataEntries = " + optionalDataEntries +
|
||||
", shortRun = " + shortRun +
|
||||
", opcAcquireAt = " + opcAcquireAt +
|
||||
", opcServer = " + opcServer +
|
||||
", opcDevice = " + opcDevice +
|
||||
", opcTag = " + opcTag +
|
||||
", opcServerHostname = " + opcServerHostname +
|
||||
", opcServerModel = " + opcServerModel +
|
||||
", opcServerProgid = " + opcServerProgid +
|
||||
", opcServerClsid = " + opcServerClsid +
|
||||
", opcDeviceId = " + opcDeviceId +
|
||||
", opcTagId = " + opcTagId +
|
||||
", scriptBo = " + scriptBo +
|
||||
", booleanZeroValue = " + booleanZeroValue +
|
||||
", booleanOneValue = " + booleanOneValue +
|
||||
", erpQmCharType = " + erpQmCharType +
|
||||
", erpIsQmCritical = " + erpIsQmCritical +
|
||||
", softLimitCheck = " + softLimitCheck +
|
||||
", autoLogNc = " + autoLogNc +
|
||||
", ncCodeBo = " + ncCodeBo +
|
||||
", dataFieldBo = " + dataFieldBo +
|
||||
", inspectionSampleSize = " + inspectionSampleSize +
|
||||
", targetValue = " + targetValue +
|
||||
"}";
|
||||
}
|
||||
}
|
@ -0,0 +1,28 @@
|
||||
package com.foreverwin.mesnac.meapi.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.meapi.model.DcGroup;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
public interface DcGroupService extends IService<DcGroup> {
|
||||
|
||||
/**
|
||||
* 分页查询
|
||||
* @param frontPage
|
||||
* @return
|
||||
*/
|
||||
IPage<DcGroup> selectPage(FrontPage<DcGroup> frontPage, DcGroup dcGroup);
|
||||
|
||||
List<DcGroup> selectList(DcGroup dcGroup);
|
||||
}
|
@ -0,0 +1,28 @@
|
||||
package com.foreverwin.mesnac.meapi.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.meapi.model.DcParameter;
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* 服务类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
public interface DcParameterService extends IService<DcParameter> {
|
||||
|
||||
/**
|
||||
* 分页查询
|
||||
* @param frontPage
|
||||
* @return
|
||||
*/
|
||||
IPage<DcParameter> selectPage(FrontPage<DcParameter> frontPage, DcParameter dcParameter);
|
||||
|
||||
List<DcParameter> selectList(DcParameter dcParameter);
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.foreverwin.mesnac.meapi.service.impl;
|
||||
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.meapi.model.DcGroup;
|
||||
import com.foreverwin.mesnac.meapi.mapper.DcGroupMapper;
|
||||
import com.foreverwin.mesnac.meapi.service.DcGroupService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.List;
|
||||
/**
|
||||
* <p>
|
||||
* 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@Service
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public class DcGroupServiceImpl extends ServiceImpl<DcGroupMapper, DcGroup> implements DcGroupService {
|
||||
|
||||
|
||||
@Autowired
|
||||
private DcGroupMapper dcGroupMapper;
|
||||
|
||||
@Override
|
||||
public IPage<DcGroup> selectPage(FrontPage<DcGroup> frontPage, DcGroup dcGroup) {
|
||||
QueryWrapper<DcGroup> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(dcGroup);
|
||||
return super.page(frontPage.getPagePlus(), queryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<DcGroup> selectList(DcGroup dcGroup) {
|
||||
QueryWrapper<DcGroup> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(dcGroup);
|
||||
return super.list(queryWrapper);
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.foreverwin.mesnac.meapi.service.impl;
|
||||
|
||||
import com.foreverwin.modular.core.util.FrontPage;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.foreverwin.mesnac.meapi.model.DcParameter;
|
||||
import com.foreverwin.mesnac.meapi.mapper.DcParameterMapper;
|
||||
import com.foreverwin.mesnac.meapi.service.DcParameterService;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.List;
|
||||
/**
|
||||
* <p>
|
||||
* 服务实现类
|
||||
* </p>
|
||||
*
|
||||
* @author pavel.liu
|
||||
* @since 2021-07-13
|
||||
*/
|
||||
@Service
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public class DcParameterServiceImpl extends ServiceImpl<DcParameterMapper, DcParameter> implements DcParameterService {
|
||||
|
||||
|
||||
@Autowired
|
||||
private DcParameterMapper dcParameterMapper;
|
||||
|
||||
@Override
|
||||
public IPage<DcParameter> selectPage(FrontPage<DcParameter> frontPage, DcParameter dcParameter) {
|
||||
QueryWrapper<DcParameter> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(dcParameter);
|
||||
return super.page(frontPage.getPagePlus(), queryWrapper);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<DcParameter> selectList(DcParameter dcParameter) {
|
||||
QueryWrapper<DcParameter> queryWrapper = new QueryWrapper<>();
|
||||
queryWrapper.setEntity(dcParameter);
|
||||
return super.list(queryWrapper);
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,500 @@
|
||||
<?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.meapi.mapper.DcGroupMapper">
|
||||
|
||||
<!-- 通用查询映射结果 -->
|
||||
<resultMap id="BaseResultMap" type="com.foreverwin.mesnac.meapi.model.DcGroup">
|
||||
<result column="HANDLE" property="handle" />
|
||||
<result column="DC_GROUP" property="dcGroup" />
|
||||
<result column="DESCRIPTION" property="description" />
|
||||
<result column="SITE" property="site" />
|
||||
<result column="COLLECT_DATA_AT" property="collectDataAt" />
|
||||
<result column="CUSTOM_BUTTON_ID" property="customButtonId" />
|
||||
<result column="PASS_FAIL_GROUP" property="passFailGroup" />
|
||||
<result column="REVISION" property="revision" />
|
||||
<result column="CURRENT_REVISION" property="currentRevision" />
|
||||
<result column="STATUS_BO" property="statusBo" />
|
||||
<result column="AUTHENTICATION_REQUIRED" property="authenticationRequired" />
|
||||
<result column="ERP" property="erp" />
|
||||
<result column="COLLECT_METHOD" property="collectMethod" />
|
||||
<result column="COLLECTION_TYPE" property="collectionType" />
|
||||
<result column="CREATED_DATE_TIME" property="createdDateTime" />
|
||||
<result column="MODIFIED_DATE_TIME" property="modifiedDateTime" />
|
||||
<result column="ERP_INSPECTION" property="erpInspection" />
|
||||
<result column="ERP_WHOLE_GROUP_INSPECTION" property="erpWholeGroupInspection" />
|
||||
<result column="ME_EVAL_INSPECTION" property="meEvalInspection" />
|
||||
<result column="PASS_FAIL_NUMBER" property="passFailNumber" />
|
||||
</resultMap>
|
||||
|
||||
<!-- 通用查询结果列 -->
|
||||
<sql id="Base_Column_List">
|
||||
HANDLE, DC_GROUP, DESCRIPTION, SITE, COLLECT_DATA_AT, CUSTOM_BUTTON_ID, PASS_FAIL_GROUP, REVISION, CURRENT_REVISION, STATUS_BO, AUTHENTICATION_REQUIRED, ERP, COLLECT_METHOD, COLLECTION_TYPE, CREATED_DATE_TIME, MODIFIED_DATE_TIME, ERP_INSPECTION, ERP_WHOLE_GROUP_INSPECTION, ME_EVAL_INSPECTION, PASS_FAIL_NUMBER
|
||||
</sql>
|
||||
|
||||
<!-- BaseMapper标准查询/修改/删除 -->
|
||||
|
||||
<select id="selectByMap" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include>
|
||||
FROM DC_GROUP
|
||||
<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 DC_GROUP
|
||||
<where>
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.handle}
|
||||
</if>
|
||||
<if test="ew.entity.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectCount" resultType="Integer">
|
||||
SELECT COUNT(1) FROM DC_GROUP
|
||||
<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.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</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 DC_GROUP
|
||||
<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.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</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 DC_GROUP
|
||||
<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.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</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 DC_GROUP
|
||||
<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.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</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 DC_GROUP
|
||||
<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.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</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 DC_GROUP
|
||||
<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.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</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.meapi.model.DcGroup">
|
||||
INSERT INTO DC_GROUP
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
HANDLE,
|
||||
<if test="dcGroup!=null">DC_GROUP,</if>
|
||||
<if test="description!=null">DESCRIPTION,</if>
|
||||
<if test="site!=null">SITE,</if>
|
||||
<if test="collectDataAt!=null">COLLECT_DATA_AT,</if>
|
||||
<if test="customButtonId!=null">CUSTOM_BUTTON_ID,</if>
|
||||
<if test="passFailGroup!=null">PASS_FAIL_GROUP,</if>
|
||||
<if test="revision!=null">REVISION,</if>
|
||||
<if test="currentRevision!=null">CURRENT_REVISION,</if>
|
||||
<if test="statusBo!=null">STATUS_BO,</if>
|
||||
<if test="authenticationRequired!=null">AUTHENTICATION_REQUIRED,</if>
|
||||
<if test="erp!=null">ERP,</if>
|
||||
<if test="collectMethod!=null">COLLECT_METHOD,</if>
|
||||
<if test="collectionType!=null">COLLECTION_TYPE,</if>
|
||||
<if test="createdDateTime!=null">CREATED_DATE_TIME,</if>
|
||||
<if test="modifiedDateTime!=null">MODIFIED_DATE_TIME,</if>
|
||||
<if test="erpInspection!=null">ERP_INSPECTION,</if>
|
||||
<if test="erpWholeGroupInspection!=null">ERP_WHOLE_GROUP_INSPECTION,</if>
|
||||
<if test="meEvalInspection!=null">ME_EVAL_INSPECTION,</if>
|
||||
<if test="passFailNumber!=null">PASS_FAIL_NUMBER,</if>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
<if test="dcGroup!=null">#{dcGroup},</if>
|
||||
<if test="description!=null">#{description},</if>
|
||||
<if test="site!=null">#{site},</if>
|
||||
<if test="collectDataAt!=null">#{collectDataAt},</if>
|
||||
<if test="customButtonId!=null">#{customButtonId},</if>
|
||||
<if test="passFailGroup!=null">#{passFailGroup},</if>
|
||||
<if test="revision!=null">#{revision},</if>
|
||||
<if test="currentRevision!=null">#{currentRevision},</if>
|
||||
<if test="statusBo!=null">#{statusBo},</if>
|
||||
<if test="authenticationRequired!=null">#{authenticationRequired},</if>
|
||||
<if test="erp!=null">#{erp},</if>
|
||||
<if test="collectMethod!=null">#{collectMethod},</if>
|
||||
<if test="collectionType!=null">#{collectionType},</if>
|
||||
<if test="createdDateTime!=null">#{createdDateTime},</if>
|
||||
<if test="modifiedDateTime!=null">#{modifiedDateTime},</if>
|
||||
<if test="erpInspection!=null">#{erpInspection},</if>
|
||||
<if test="erpWholeGroupInspection!=null">#{erpWholeGroupInspection},</if>
|
||||
<if test="meEvalInspection!=null">#{meEvalInspection},</if>
|
||||
<if test="passFailNumber!=null">#{passFailNumber},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<insert id="insertAllColumn" parameterType="com.foreverwin.mesnac.meapi.model.DcGroup">
|
||||
INSERT INTO DC_GROUP
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<include refid="Base_Column_List"></include>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
#{dcGroup},
|
||||
#{description},
|
||||
#{site},
|
||||
#{collectDataAt},
|
||||
#{customButtonId},
|
||||
#{passFailGroup},
|
||||
#{revision},
|
||||
#{currentRevision},
|
||||
#{statusBo},
|
||||
#{authenticationRequired},
|
||||
#{erp},
|
||||
#{collectMethod},
|
||||
#{collectionType},
|
||||
#{createdDateTime},
|
||||
#{modifiedDateTime},
|
||||
#{erpInspection},
|
||||
#{erpWholeGroupInspection},
|
||||
#{meEvalInspection},
|
||||
#{passFailNumber},
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<update id="update">
|
||||
UPDATE DC_GROUP <trim prefix="SET" suffixOverrides=",">
|
||||
<if test="et.handle!=null">HANDLE=#{et.handle},</if>
|
||||
<if test="et.dcGroup!=null">DC_GROUP=#{et.dcGroup},</if>
|
||||
<if test="et.description!=null">DESCRIPTION=#{et.description},</if>
|
||||
<if test="et.site!=null">SITE=#{et.site},</if>
|
||||
<if test="et.collectDataAt!=null">COLLECT_DATA_AT=#{et.collectDataAt},</if>
|
||||
<if test="et.customButtonId!=null">CUSTOM_BUTTON_ID=#{et.customButtonId},</if>
|
||||
<if test="et.passFailGroup!=null">PASS_FAIL_GROUP=#{et.passFailGroup},</if>
|
||||
<if test="et.revision!=null">REVISION=#{et.revision},</if>
|
||||
<if test="et.currentRevision!=null">CURRENT_REVISION=#{et.currentRevision},</if>
|
||||
<if test="et.statusBo!=null">STATUS_BO=#{et.statusBo},</if>
|
||||
<if test="et.authenticationRequired!=null">AUTHENTICATION_REQUIRED=#{et.authenticationRequired},</if>
|
||||
<if test="et.erp!=null">ERP=#{et.erp},</if>
|
||||
<if test="et.collectMethod!=null">COLLECT_METHOD=#{et.collectMethod},</if>
|
||||
<if test="et.collectionType!=null">COLLECTION_TYPE=#{et.collectionType},</if>
|
||||
<if test="et.createdDateTime!=null">CREATED_DATE_TIME=#{et.createdDateTime},</if>
|
||||
<if test="et.modifiedDateTime!=null">MODIFIED_DATE_TIME=#{et.modifiedDateTime},</if>
|
||||
<if test="et.erpInspection!=null">ERP_INSPECTION=#{et.erpInspection},</if>
|
||||
<if test="et.erpWholeGroupInspection!=null">ERP_WHOLE_GROUP_INSPECTION=#{et.erpWholeGroupInspection},</if>
|
||||
<if test="et.meEvalInspection!=null">ME_EVAL_INSPECTION=#{et.meEvalInspection},</if>
|
||||
<if test="et.passFailNumber!=null">PASS_FAIL_NUMBER=#{et.passFailNumber},</if>
|
||||
</trim>
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
<if test="ew.entity.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</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 DC_GROUP
|
||||
<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 DC_GROUP
|
||||
<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.dcGroup!=null"> AND DC_GROUP=#{ew.entity.dcGroup}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.site!=null"> AND SITE=#{ew.entity.site}</if>
|
||||
<if test="ew.entity.collectDataAt!=null"> AND COLLECT_DATA_AT=#{ew.entity.collectDataAt}</if>
|
||||
<if test="ew.entity.customButtonId!=null"> AND CUSTOM_BUTTON_ID=#{ew.entity.customButtonId}</if>
|
||||
<if test="ew.entity.passFailGroup!=null"> AND PASS_FAIL_GROUP=#{ew.entity.passFailGroup}</if>
|
||||
<if test="ew.entity.revision!=null"> AND REVISION=#{ew.entity.revision}</if>
|
||||
<if test="ew.entity.currentRevision!=null"> AND CURRENT_REVISION=#{ew.entity.currentRevision}</if>
|
||||
<if test="ew.entity.statusBo!=null"> AND STATUS_BO=#{ew.entity.statusBo}</if>
|
||||
<if test="ew.entity.authenticationRequired!=null"> AND AUTHENTICATION_REQUIRED=#{ew.entity.authenticationRequired}</if>
|
||||
<if test="ew.entity.erp!=null"> AND ERP=#{ew.entity.erp}</if>
|
||||
<if test="ew.entity.collectMethod!=null"> AND COLLECT_METHOD=#{ew.entity.collectMethod}</if>
|
||||
<if test="ew.entity.collectionType!=null"> AND COLLECTION_TYPE=#{ew.entity.collectionType}</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 test="ew.entity.erpInspection!=null"> AND ERP_INSPECTION=#{ew.entity.erpInspection}</if>
|
||||
<if test="ew.entity.erpWholeGroupInspection!=null"> AND ERP_WHOLE_GROUP_INSPECTION=#{ew.entity.erpWholeGroupInspection}</if>
|
||||
<if test="ew.entity.meEvalInspection!=null"> AND ME_EVAL_INSPECTION=#{ew.entity.meEvalInspection}</if>
|
||||
<if test="ew.entity.passFailNumber!=null"> AND PASS_FAIL_NUMBER=#{ew.entity.passFailNumber}</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>
|
@ -0,0 +1,815 @@
|
||||
<?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.meapi.mapper.DcParameterMapper">
|
||||
|
||||
<!-- 通用查询映射结果 -->
|
||||
<resultMap id="BaseResultMap" type="com.foreverwin.mesnac.meapi.model.DcParameter">
|
||||
<result column="HANDLE" property="handle" />
|
||||
<result column="DC_GROUP_BO" property="dcGroupBo" />
|
||||
<result column="PARAMETER_NAME" property="parameterName" />
|
||||
<result column="DATA_TYPE" property="dataType" />
|
||||
<result column="STATUS" property="status" />
|
||||
<result column="ALLOW_MISSING_VALUE" property="allowMissingValue" />
|
||||
<result column="MIN_VALUE" property="minValue" />
|
||||
<result column="MAX_VALUE" property="maxValue" />
|
||||
<result column="SEQUENCE" property="sequence" />
|
||||
<result column="PERFORM_SPC" property="performSpc" />
|
||||
<result column="DISPLAY_CHART" property="displayChart" />
|
||||
<result column="DESCRIPTION" property="description" />
|
||||
<result column="UNITS" property="units" />
|
||||
<result column="SPC_CHART_BO" property="spcChartBo" />
|
||||
<result column="DISPLAY_DATA_INFORMATION" property="displayDataInformation" />
|
||||
<result column="OVERRIDE_MIN_MAX" property="overrideMinMax" />
|
||||
<result column="DC_VALUE_MASK" property="dcValueMask" />
|
||||
<result column="EXPRESSION_BUILDER" property="expressionBuilder" />
|
||||
<result column="REQUIRED_DATA_ENTRIES" property="requiredDataEntries" />
|
||||
<result column="OPTIONAL_DATA_ENTRIES" property="optionalDataEntries" />
|
||||
<result column="SHORT_RUN" property="shortRun" />
|
||||
<result column="OPC_ACQUIRE_AT" property="opcAcquireAt" />
|
||||
<result column="OPC_SERVER" property="opcServer" />
|
||||
<result column="OPC_DEVICE" property="opcDevice" />
|
||||
<result column="OPC_TAG" property="opcTag" />
|
||||
<result column="OPC_SERVER_HOSTNAME" property="opcServerHostname" />
|
||||
<result column="OPC_SERVER_MODEL" property="opcServerModel" />
|
||||
<result column="OPC_SERVER_PROGID" property="opcServerProgid" />
|
||||
<result column="OPC_SERVER_CLSID" property="opcServerClsid" />
|
||||
<result column="OPC_DEVICE_ID" property="opcDeviceId" />
|
||||
<result column="OPC_TAG_ID" property="opcTagId" />
|
||||
<result column="SCRIPT_BO" property="scriptBo" />
|
||||
<result column="BOOLEAN_ZERO_VALUE" property="booleanZeroValue" />
|
||||
<result column="BOOLEAN_ONE_VALUE" property="booleanOneValue" />
|
||||
<result column="ERP_QM_CHAR_TYPE" property="erpQmCharType" />
|
||||
<result column="ERP_IS_QM_CRITICAL" property="erpIsQmCritical" />
|
||||
<result column="SOFT_LIMIT_CHECK" property="softLimitCheck" />
|
||||
<result column="AUTO_LOG_NC" property="autoLogNc" />
|
||||
<result column="NC_CODE_BO" property="ncCodeBo" />
|
||||
<result column="DATA_FIELD_BO" property="dataFieldBo" />
|
||||
<result column="INSPECTION_SAMPLE_SIZE" property="inspectionSampleSize" />
|
||||
<result column="TARGET_VALUE" property="targetValue" />
|
||||
</resultMap>
|
||||
|
||||
<!-- 通用查询结果列 -->
|
||||
<sql id="Base_Column_List">
|
||||
HANDLE, DC_GROUP_BO, PARAMETER_NAME, DATA_TYPE, STATUS, ALLOW_MISSING_VALUE, MIN_VALUE, MAX_VALUE, SEQUENCE, PERFORM_SPC, DISPLAY_CHART, DESCRIPTION, UNITS, SPC_CHART_BO, DISPLAY_DATA_INFORMATION, OVERRIDE_MIN_MAX, DC_VALUE_MASK, EXPRESSION_BUILDER, REQUIRED_DATA_ENTRIES, OPTIONAL_DATA_ENTRIES, SHORT_RUN, OPC_ACQUIRE_AT, OPC_SERVER, OPC_DEVICE, OPC_TAG, OPC_SERVER_HOSTNAME, OPC_SERVER_MODEL, OPC_SERVER_PROGID, OPC_SERVER_CLSID, OPC_DEVICE_ID, OPC_TAG_ID, SCRIPT_BO, BOOLEAN_ZERO_VALUE, BOOLEAN_ONE_VALUE, ERP_QM_CHAR_TYPE, ERP_IS_QM_CRITICAL, SOFT_LIMIT_CHECK, AUTO_LOG_NC, NC_CODE_BO, DATA_FIELD_BO, INSPECTION_SAMPLE_SIZE, TARGET_VALUE
|
||||
</sql>
|
||||
|
||||
<!-- BaseMapper标准查询/修改/删除 -->
|
||||
|
||||
<select id="selectByMap" resultMap="BaseResultMap">
|
||||
SELECT <include refid="Base_Column_List"></include>
|
||||
FROM DC_PARAMETER
|
||||
<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 DC_PARAMETER
|
||||
<where>
|
||||
<if test="ew.entity.handle!=null">
|
||||
HANDLE=#{ew.handle}
|
||||
</if>
|
||||
<if test="ew.entity.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectCount" resultType="Integer">
|
||||
SELECT COUNT(1) FROM DC_PARAMETER
|
||||
<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.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</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 DC_PARAMETER
|
||||
<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.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</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 DC_PARAMETER
|
||||
<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.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</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 DC_PARAMETER
|
||||
<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.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</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 DC_PARAMETER
|
||||
<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.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</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 DC_PARAMETER
|
||||
<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.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</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.meapi.model.DcParameter">
|
||||
INSERT INTO DC_PARAMETER
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
HANDLE,
|
||||
<if test="dcGroupBo!=null">DC_GROUP_BO,</if>
|
||||
<if test="parameterName!=null">PARAMETER_NAME,</if>
|
||||
<if test="dataType!=null">DATA_TYPE,</if>
|
||||
<if test="status!=null">STATUS,</if>
|
||||
<if test="allowMissingValue!=null">ALLOW_MISSING_VALUE,</if>
|
||||
<if test="minValue!=null">MIN_VALUE,</if>
|
||||
<if test="maxValue!=null">MAX_VALUE,</if>
|
||||
<if test="sequence!=null">SEQUENCE,</if>
|
||||
<if test="performSpc!=null">PERFORM_SPC,</if>
|
||||
<if test="displayChart!=null">DISPLAY_CHART,</if>
|
||||
<if test="description!=null">DESCRIPTION,</if>
|
||||
<if test="units!=null">UNITS,</if>
|
||||
<if test="spcChartBo!=null">SPC_CHART_BO,</if>
|
||||
<if test="displayDataInformation!=null">DISPLAY_DATA_INFORMATION,</if>
|
||||
<if test="overrideMinMax!=null">OVERRIDE_MIN_MAX,</if>
|
||||
<if test="dcValueMask!=null">DC_VALUE_MASK,</if>
|
||||
<if test="expressionBuilder!=null">EXPRESSION_BUILDER,</if>
|
||||
<if test="requiredDataEntries!=null">REQUIRED_DATA_ENTRIES,</if>
|
||||
<if test="optionalDataEntries!=null">OPTIONAL_DATA_ENTRIES,</if>
|
||||
<if test="shortRun!=null">SHORT_RUN,</if>
|
||||
<if test="opcAcquireAt!=null">OPC_ACQUIRE_AT,</if>
|
||||
<if test="opcServer!=null">OPC_SERVER,</if>
|
||||
<if test="opcDevice!=null">OPC_DEVICE,</if>
|
||||
<if test="opcTag!=null">OPC_TAG,</if>
|
||||
<if test="opcServerHostname!=null">OPC_SERVER_HOSTNAME,</if>
|
||||
<if test="opcServerModel!=null">OPC_SERVER_MODEL,</if>
|
||||
<if test="opcServerProgid!=null">OPC_SERVER_PROGID,</if>
|
||||
<if test="opcServerClsid!=null">OPC_SERVER_CLSID,</if>
|
||||
<if test="opcDeviceId!=null">OPC_DEVICE_ID,</if>
|
||||
<if test="opcTagId!=null">OPC_TAG_ID,</if>
|
||||
<if test="scriptBo!=null">SCRIPT_BO,</if>
|
||||
<if test="booleanZeroValue!=null">BOOLEAN_ZERO_VALUE,</if>
|
||||
<if test="booleanOneValue!=null">BOOLEAN_ONE_VALUE,</if>
|
||||
<if test="erpQmCharType!=null">ERP_QM_CHAR_TYPE,</if>
|
||||
<if test="erpIsQmCritical!=null">ERP_IS_QM_CRITICAL,</if>
|
||||
<if test="softLimitCheck!=null">SOFT_LIMIT_CHECK,</if>
|
||||
<if test="autoLogNc!=null">AUTO_LOG_NC,</if>
|
||||
<if test="ncCodeBo!=null">NC_CODE_BO,</if>
|
||||
<if test="dataFieldBo!=null">DATA_FIELD_BO,</if>
|
||||
<if test="inspectionSampleSize!=null">INSPECTION_SAMPLE_SIZE,</if>
|
||||
<if test="targetValue!=null">TARGET_VALUE,</if>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
<if test="dcGroupBo!=null">#{dcGroupBo},</if>
|
||||
<if test="parameterName!=null">#{parameterName},</if>
|
||||
<if test="dataType!=null">#{dataType},</if>
|
||||
<if test="status!=null">#{status},</if>
|
||||
<if test="allowMissingValue!=null">#{allowMissingValue},</if>
|
||||
<if test="minValue!=null">#{minValue},</if>
|
||||
<if test="maxValue!=null">#{maxValue},</if>
|
||||
<if test="sequence!=null">#{sequence},</if>
|
||||
<if test="performSpc!=null">#{performSpc},</if>
|
||||
<if test="displayChart!=null">#{displayChart},</if>
|
||||
<if test="description!=null">#{description},</if>
|
||||
<if test="units!=null">#{units},</if>
|
||||
<if test="spcChartBo!=null">#{spcChartBo},</if>
|
||||
<if test="displayDataInformation!=null">#{displayDataInformation},</if>
|
||||
<if test="overrideMinMax!=null">#{overrideMinMax},</if>
|
||||
<if test="dcValueMask!=null">#{dcValueMask},</if>
|
||||
<if test="expressionBuilder!=null">#{expressionBuilder},</if>
|
||||
<if test="requiredDataEntries!=null">#{requiredDataEntries},</if>
|
||||
<if test="optionalDataEntries!=null">#{optionalDataEntries},</if>
|
||||
<if test="shortRun!=null">#{shortRun},</if>
|
||||
<if test="opcAcquireAt!=null">#{opcAcquireAt},</if>
|
||||
<if test="opcServer!=null">#{opcServer},</if>
|
||||
<if test="opcDevice!=null">#{opcDevice},</if>
|
||||
<if test="opcTag!=null">#{opcTag},</if>
|
||||
<if test="opcServerHostname!=null">#{opcServerHostname},</if>
|
||||
<if test="opcServerModel!=null">#{opcServerModel},</if>
|
||||
<if test="opcServerProgid!=null">#{opcServerProgid},</if>
|
||||
<if test="opcServerClsid!=null">#{opcServerClsid},</if>
|
||||
<if test="opcDeviceId!=null">#{opcDeviceId},</if>
|
||||
<if test="opcTagId!=null">#{opcTagId},</if>
|
||||
<if test="scriptBo!=null">#{scriptBo},</if>
|
||||
<if test="booleanZeroValue!=null">#{booleanZeroValue},</if>
|
||||
<if test="booleanOneValue!=null">#{booleanOneValue},</if>
|
||||
<if test="erpQmCharType!=null">#{erpQmCharType},</if>
|
||||
<if test="erpIsQmCritical!=null">#{erpIsQmCritical},</if>
|
||||
<if test="softLimitCheck!=null">#{softLimitCheck},</if>
|
||||
<if test="autoLogNc!=null">#{autoLogNc},</if>
|
||||
<if test="ncCodeBo!=null">#{ncCodeBo},</if>
|
||||
<if test="dataFieldBo!=null">#{dataFieldBo},</if>
|
||||
<if test="inspectionSampleSize!=null">#{inspectionSampleSize},</if>
|
||||
<if test="targetValue!=null">#{targetValue},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<insert id="insertAllColumn" parameterType="com.foreverwin.mesnac.meapi.model.DcParameter">
|
||||
INSERT INTO DC_PARAMETER
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<include refid="Base_Column_List"></include>
|
||||
</trim> VALUES
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
#{handle},
|
||||
#{dcGroupBo},
|
||||
#{parameterName},
|
||||
#{dataType},
|
||||
#{status},
|
||||
#{allowMissingValue},
|
||||
#{minValue},
|
||||
#{maxValue},
|
||||
#{sequence},
|
||||
#{performSpc},
|
||||
#{displayChart},
|
||||
#{description},
|
||||
#{units},
|
||||
#{spcChartBo},
|
||||
#{displayDataInformation},
|
||||
#{overrideMinMax},
|
||||
#{dcValueMask},
|
||||
#{expressionBuilder},
|
||||
#{requiredDataEntries},
|
||||
#{optionalDataEntries},
|
||||
#{shortRun},
|
||||
#{opcAcquireAt},
|
||||
#{opcServer},
|
||||
#{opcDevice},
|
||||
#{opcTag},
|
||||
#{opcServerHostname},
|
||||
#{opcServerModel},
|
||||
#{opcServerProgid},
|
||||
#{opcServerClsid},
|
||||
#{opcDeviceId},
|
||||
#{opcTagId},
|
||||
#{scriptBo},
|
||||
#{booleanZeroValue},
|
||||
#{booleanOneValue},
|
||||
#{erpQmCharType},
|
||||
#{erpIsQmCritical},
|
||||
#{softLimitCheck},
|
||||
#{autoLogNc},
|
||||
#{ncCodeBo},
|
||||
#{dataFieldBo},
|
||||
#{inspectionSampleSize},
|
||||
#{targetValue},
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<update id="update">
|
||||
UPDATE DC_PARAMETER <trim prefix="SET" suffixOverrides=",">
|
||||
<if test="et.handle!=null">HANDLE=#{et.handle},</if>
|
||||
<if test="et.dcGroupBo!=null">DC_GROUP_BO=#{et.dcGroupBo},</if>
|
||||
<if test="et.parameterName!=null">PARAMETER_NAME=#{et.parameterName},</if>
|
||||
<if test="et.dataType!=null">DATA_TYPE=#{et.dataType},</if>
|
||||
<if test="et.status!=null">STATUS=#{et.status},</if>
|
||||
<if test="et.allowMissingValue!=null">ALLOW_MISSING_VALUE=#{et.allowMissingValue},</if>
|
||||
<if test="et.minValue!=null">MIN_VALUE=#{et.minValue},</if>
|
||||
<if test="et.maxValue!=null">MAX_VALUE=#{et.maxValue},</if>
|
||||
<if test="et.sequence!=null">SEQUENCE=#{et.sequence},</if>
|
||||
<if test="et.performSpc!=null">PERFORM_SPC=#{et.performSpc},</if>
|
||||
<if test="et.displayChart!=null">DISPLAY_CHART=#{et.displayChart},</if>
|
||||
<if test="et.description!=null">DESCRIPTION=#{et.description},</if>
|
||||
<if test="et.units!=null">UNITS=#{et.units},</if>
|
||||
<if test="et.spcChartBo!=null">SPC_CHART_BO=#{et.spcChartBo},</if>
|
||||
<if test="et.displayDataInformation!=null">DISPLAY_DATA_INFORMATION=#{et.displayDataInformation},</if>
|
||||
<if test="et.overrideMinMax!=null">OVERRIDE_MIN_MAX=#{et.overrideMinMax},</if>
|
||||
<if test="et.dcValueMask!=null">DC_VALUE_MASK=#{et.dcValueMask},</if>
|
||||
<if test="et.expressionBuilder!=null">EXPRESSION_BUILDER=#{et.expressionBuilder},</if>
|
||||
<if test="et.requiredDataEntries!=null">REQUIRED_DATA_ENTRIES=#{et.requiredDataEntries},</if>
|
||||
<if test="et.optionalDataEntries!=null">OPTIONAL_DATA_ENTRIES=#{et.optionalDataEntries},</if>
|
||||
<if test="et.shortRun!=null">SHORT_RUN=#{et.shortRun},</if>
|
||||
<if test="et.opcAcquireAt!=null">OPC_ACQUIRE_AT=#{et.opcAcquireAt},</if>
|
||||
<if test="et.opcServer!=null">OPC_SERVER=#{et.opcServer},</if>
|
||||
<if test="et.opcDevice!=null">OPC_DEVICE=#{et.opcDevice},</if>
|
||||
<if test="et.opcTag!=null">OPC_TAG=#{et.opcTag},</if>
|
||||
<if test="et.opcServerHostname!=null">OPC_SERVER_HOSTNAME=#{et.opcServerHostname},</if>
|
||||
<if test="et.opcServerModel!=null">OPC_SERVER_MODEL=#{et.opcServerModel},</if>
|
||||
<if test="et.opcServerProgid!=null">OPC_SERVER_PROGID=#{et.opcServerProgid},</if>
|
||||
<if test="et.opcServerClsid!=null">OPC_SERVER_CLSID=#{et.opcServerClsid},</if>
|
||||
<if test="et.opcDeviceId!=null">OPC_DEVICE_ID=#{et.opcDeviceId},</if>
|
||||
<if test="et.opcTagId!=null">OPC_TAG_ID=#{et.opcTagId},</if>
|
||||
<if test="et.scriptBo!=null">SCRIPT_BO=#{et.scriptBo},</if>
|
||||
<if test="et.booleanZeroValue!=null">BOOLEAN_ZERO_VALUE=#{et.booleanZeroValue},</if>
|
||||
<if test="et.booleanOneValue!=null">BOOLEAN_ONE_VALUE=#{et.booleanOneValue},</if>
|
||||
<if test="et.erpQmCharType!=null">ERP_QM_CHAR_TYPE=#{et.erpQmCharType},</if>
|
||||
<if test="et.erpIsQmCritical!=null">ERP_IS_QM_CRITICAL=#{et.erpIsQmCritical},</if>
|
||||
<if test="et.softLimitCheck!=null">SOFT_LIMIT_CHECK=#{et.softLimitCheck},</if>
|
||||
<if test="et.autoLogNc!=null">AUTO_LOG_NC=#{et.autoLogNc},</if>
|
||||
<if test="et.ncCodeBo!=null">NC_CODE_BO=#{et.ncCodeBo},</if>
|
||||
<if test="et.dataFieldBo!=null">DATA_FIELD_BO=#{et.dataFieldBo},</if>
|
||||
<if test="et.inspectionSampleSize!=null">INSPECTION_SAMPLE_SIZE=#{et.inspectionSampleSize},</if>
|
||||
<if test="et.targetValue!=null">TARGET_VALUE=#{et.targetValue},</if>
|
||||
</trim>
|
||||
<where>
|
||||
<if test="ew!=null">
|
||||
<if test="ew.entity!=null">
|
||||
HANDLE=#{ew.entity.handle}
|
||||
<if test="ew.entity.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</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 DC_PARAMETER
|
||||
<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 DC_PARAMETER
|
||||
<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.dcGroupBo!=null"> AND DC_GROUP_BO=#{ew.entity.dcGroupBo}</if>
|
||||
<if test="ew.entity.parameterName!=null"> AND PARAMETER_NAME=#{ew.entity.parameterName}</if>
|
||||
<if test="ew.entity.dataType!=null"> AND DATA_TYPE=#{ew.entity.dataType}</if>
|
||||
<if test="ew.entity.status!=null"> AND STATUS=#{ew.entity.status}</if>
|
||||
<if test="ew.entity.allowMissingValue!=null"> AND ALLOW_MISSING_VALUE=#{ew.entity.allowMissingValue}</if>
|
||||
<if test="ew.entity.minValue!=null"> AND MIN_VALUE=#{ew.entity.minValue}</if>
|
||||
<if test="ew.entity.maxValue!=null"> AND MAX_VALUE=#{ew.entity.maxValue}</if>
|
||||
<if test="ew.entity.sequence!=null"> AND SEQUENCE=#{ew.entity.sequence}</if>
|
||||
<if test="ew.entity.performSpc!=null"> AND PERFORM_SPC=#{ew.entity.performSpc}</if>
|
||||
<if test="ew.entity.displayChart!=null"> AND DISPLAY_CHART=#{ew.entity.displayChart}</if>
|
||||
<if test="ew.entity.description!=null"> AND DESCRIPTION=#{ew.entity.description}</if>
|
||||
<if test="ew.entity.units!=null"> AND UNITS=#{ew.entity.units}</if>
|
||||
<if test="ew.entity.spcChartBo!=null"> AND SPC_CHART_BO=#{ew.entity.spcChartBo}</if>
|
||||
<if test="ew.entity.displayDataInformation!=null"> AND DISPLAY_DATA_INFORMATION=#{ew.entity.displayDataInformation}</if>
|
||||
<if test="ew.entity.overrideMinMax!=null"> AND OVERRIDE_MIN_MAX=#{ew.entity.overrideMinMax}</if>
|
||||
<if test="ew.entity.dcValueMask!=null"> AND DC_VALUE_MASK=#{ew.entity.dcValueMask}</if>
|
||||
<if test="ew.entity.expressionBuilder!=null"> AND EXPRESSION_BUILDER=#{ew.entity.expressionBuilder}</if>
|
||||
<if test="ew.entity.requiredDataEntries!=null"> AND REQUIRED_DATA_ENTRIES=#{ew.entity.requiredDataEntries}</if>
|
||||
<if test="ew.entity.optionalDataEntries!=null"> AND OPTIONAL_DATA_ENTRIES=#{ew.entity.optionalDataEntries}</if>
|
||||
<if test="ew.entity.shortRun!=null"> AND SHORT_RUN=#{ew.entity.shortRun}</if>
|
||||
<if test="ew.entity.opcAcquireAt!=null"> AND OPC_ACQUIRE_AT=#{ew.entity.opcAcquireAt}</if>
|
||||
<if test="ew.entity.opcServer!=null"> AND OPC_SERVER=#{ew.entity.opcServer}</if>
|
||||
<if test="ew.entity.opcDevice!=null"> AND OPC_DEVICE=#{ew.entity.opcDevice}</if>
|
||||
<if test="ew.entity.opcTag!=null"> AND OPC_TAG=#{ew.entity.opcTag}</if>
|
||||
<if test="ew.entity.opcServerHostname!=null"> AND OPC_SERVER_HOSTNAME=#{ew.entity.opcServerHostname}</if>
|
||||
<if test="ew.entity.opcServerModel!=null"> AND OPC_SERVER_MODEL=#{ew.entity.opcServerModel}</if>
|
||||
<if test="ew.entity.opcServerProgid!=null"> AND OPC_SERVER_PROGID=#{ew.entity.opcServerProgid}</if>
|
||||
<if test="ew.entity.opcServerClsid!=null"> AND OPC_SERVER_CLSID=#{ew.entity.opcServerClsid}</if>
|
||||
<if test="ew.entity.opcDeviceId!=null"> AND OPC_DEVICE_ID=#{ew.entity.opcDeviceId}</if>
|
||||
<if test="ew.entity.opcTagId!=null"> AND OPC_TAG_ID=#{ew.entity.opcTagId}</if>
|
||||
<if test="ew.entity.scriptBo!=null"> AND SCRIPT_BO=#{ew.entity.scriptBo}</if>
|
||||
<if test="ew.entity.booleanZeroValue!=null"> AND BOOLEAN_ZERO_VALUE=#{ew.entity.booleanZeroValue}</if>
|
||||
<if test="ew.entity.booleanOneValue!=null"> AND BOOLEAN_ONE_VALUE=#{ew.entity.booleanOneValue}</if>
|
||||
<if test="ew.entity.erpQmCharType!=null"> AND ERP_QM_CHAR_TYPE=#{ew.entity.erpQmCharType}</if>
|
||||
<if test="ew.entity.erpIsQmCritical!=null"> AND ERP_IS_QM_CRITICAL=#{ew.entity.erpIsQmCritical}</if>
|
||||
<if test="ew.entity.softLimitCheck!=null"> AND SOFT_LIMIT_CHECK=#{ew.entity.softLimitCheck}</if>
|
||||
<if test="ew.entity.autoLogNc!=null"> AND AUTO_LOG_NC=#{ew.entity.autoLogNc}</if>
|
||||
<if test="ew.entity.ncCodeBo!=null"> AND NC_CODE_BO=#{ew.entity.ncCodeBo}</if>
|
||||
<if test="ew.entity.dataFieldBo!=null"> AND DATA_FIELD_BO=#{ew.entity.dataFieldBo}</if>
|
||||
<if test="ew.entity.inspectionSampleSize!=null"> AND INSPECTION_SAMPLE_SIZE=#{ew.entity.inspectionSampleSize}</if>
|
||||
<if test="ew.entity.targetValue!=null"> AND TARGET_VALUE=#{ew.entity.targetValue}</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标准查询/修改/删除 -->
|
||||
|
||||
<!--自定义sql-->
|
||||
<select id="getDcParameterByDcGroupBo" resultType="com.foreverwin.mesnac.meapi.model.DcParameter">
|
||||
SELECT * FROM WIP.DC_PARAMETER DP WHERE DP.DC_GROUP_BO = #{dcGroupBo}
|
||||
</select>
|
||||
|
||||
<!--自定义sql-->
|
||||
|
||||
</mapper>
|
Loading…
Reference in New Issue