提交 6d4933d2 编写于 作者: ibizdev's avatar ibizdev

lab_gzf 部署微服务接口

上级 56fae8ab
......@@ -12,6 +12,6 @@ CMD echo "The application will start in ${IBIZ_SLEEP}s..." && \
sleep ${IBIZ_SLEEP} && \
java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /assetmanagement-app-assetmanagement.jar
EXPOSE 10325
EXPOSE 8080
ADD assetmanagement-app-assetmanagement.jar /assetmanagement-app-assetmanagement.jar
......@@ -3,25 +3,9 @@ services:
assetmanagement-app-assetmanagement:
image: registry.cn-shanghai.aliyuncs.com/ibizsys/assetmanagement-app-assetmanagement:latest
ports:
- "10325:10325"
- "8080:8080"
networks:
- agent_network
environment:
- SPRING_CLOUD_NACOS_DISCOVERY_IP=172.16.240.110
- SERVER_PORT=10325
- SPRING_CLOUD_NACOS_DISCOVERY_SERVER-ADDR=172.16.240.110:8848
- SPRING_REDIS_HOST=172.16.240.110
- SPRING_REDIS_PORT=6379
- SPRING_REDIS_DATABASE=0
- SPRING_DATASOURCE_USERNAME=a_LAB01_e85d8801c
- SPRING_DATASOURCE_PASSWORD=b1@@@772
- SPRING_DATASOURCE_URL=jdbc:mysql://172.16.186.185:3306/a_LAB01_e85d8801c?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8&useOldAliasMetadataBehavior=true&allowMultiQueries=true
- SPRING_DATASOURCE_DRIVER-CLASS-NAME=com.mysql.jdbc.Driver
- SPRING_DATASOURCE_DEFAULTSCHEMA=a_LAB01_e85d8801c
- CAS=https://passport.ibizlab.cn
- NACOS=172.16.240.110:8848
- SEATA_REGISTRY_NACOS_SERVER-ADDR=172.16.240.110:8848
- SEATA_ENABLED=true
deploy:
resources:
limits:
......
......@@ -43,6 +43,10 @@ zuul:
path: /eamproducts/**
serviceId: ${ibiz.ref.service.ibizassetmanagement-assetapi:ibizassetmanagement-assetapi}
stripPrefix: false
eamservicelevel:
path: /eamservicelevels/**
serviceId: ${ibiz.ref.service.ibizassetmanagement-assetapi:ibizassetmanagement-assetapi}
stripPrefix: false
eamsparepartspro:
path: /eamsparepartspros/**
serviceId: ${ibiz.ref.service.ibizassetmanagement-assetapi:ibizassetmanagement-assetapi}
......
......@@ -133,6 +133,48 @@ public class EAMApply extends EntityMP implements Serializable {
@JSONField(name = "endtime" , format="yyyy-MM-dd HH:mm:ss")
@JsonProperty("endtime")
private Timestamp endtime;
/**
* 资产
*/
@TableField(exist = false)
@JSONField(name = "assetname")
@JsonProperty("assetname")
private String assetname;
/**
* 功能位置
*/
@TableField(exist = false)
@JSONField(name = "eamlocationname")
@JsonProperty("eamlocationname")
private String eamlocationname;
/**
* 维护申请类型
*/
@TableField(exist = false)
@JSONField(name = "eamapplytypename")
@JsonProperty("eamapplytypename")
private String eamapplytypename;
/**
* 维护申请编号
*/
@TableField(value = "applynumber")
@JSONField(name = "applynumber")
@JsonProperty("applynumber")
private String applynumber;
/**
* 服务等级标识
*/
@TableField(value = "eamservicelevelid")
@JSONField(name = "eamservicelevelid")
@JsonProperty("eamservicelevelid")
private String eamservicelevelid;
/**
* 服务等级
*/
@TableField(exist = false)
@JSONField(name = "eamservicelevelname")
@JsonProperty("eamservicelevelname")
private String eamservicelevelname;
/**
*
......@@ -158,6 +200,14 @@ public class EAMApply extends EntityMP implements Serializable {
@TableField(exist = false)
private cn.ibizlab.assetmanagement.core.location.domain.EAMLocation eamlocation;
/**
*
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel eamservicelevel;
/**
......@@ -236,6 +286,22 @@ public class EAMApply extends EntityMP implements Serializable {
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
return sdf.format(endtime);
}
/**
* 设置 [维护申请编号]
*/
public void setApplynumber(String applynumber){
this.applynumber = applynumber ;
this.modify("applynumber",applynumber);
}
/**
* 设置 [服务等级标识]
*/
public void setEamservicelevelid(String eamservicelevelid){
this.eamservicelevelid = eamservicelevelid ;
this.modify("eamservicelevelid",eamservicelevelid);
}
}
......
......@@ -96,6 +96,13 @@ public class EAMApplyType extends EntityMP implements Serializable {
@JSONField(name = "eamapplystatemodelid")
@JsonProperty("eamapplystatemodelid")
private String eamapplystatemodelid;
/**
* 描述
*/
@TableField(value = "description")
@JSONField(name = "description")
@JsonProperty("description")
private String description;
/**
*
......@@ -123,6 +130,14 @@ public class EAMApplyType extends EntityMP implements Serializable {
this.modify("eamapplystatemodelid",eamapplystatemodelid);
}
/**
* 设置 [描述]
*/
public void setDescription(String description){
this.description = description ;
this.modify("description",description);
}
}
......
......@@ -55,6 +55,69 @@ public class EAMApplySearchContext extends QueryWrapperContext<EAMApply> {
this.getSearchCond().eq("assetid", n_assetid_eq);
}
}
private String n_assetname_eq;//[资产]
public void setN_assetname_eq(String n_assetname_eq) {
this.n_assetname_eq = n_assetname_eq;
if(!ObjectUtils.isEmpty(this.n_assetname_eq)){
this.getSearchCond().eq("assetname", n_assetname_eq);
}
}
private String n_assetname_like;//[资产]
public void setN_assetname_like(String n_assetname_like) {
this.n_assetname_like = n_assetname_like;
if(!ObjectUtils.isEmpty(this.n_assetname_like)){
this.getSearchCond().like("assetname", n_assetname_like);
}
}
private String n_eamlocationname_eq;//[功能位置]
public void setN_eamlocationname_eq(String n_eamlocationname_eq) {
this.n_eamlocationname_eq = n_eamlocationname_eq;
if(!ObjectUtils.isEmpty(this.n_eamlocationname_eq)){
this.getSearchCond().eq("eamlocationname", n_eamlocationname_eq);
}
}
private String n_eamlocationname_like;//[功能位置]
public void setN_eamlocationname_like(String n_eamlocationname_like) {
this.n_eamlocationname_like = n_eamlocationname_like;
if(!ObjectUtils.isEmpty(this.n_eamlocationname_like)){
this.getSearchCond().like("eamlocationname", n_eamlocationname_like);
}
}
private String n_eamapplytypename_eq;//[维护申请类型]
public void setN_eamapplytypename_eq(String n_eamapplytypename_eq) {
this.n_eamapplytypename_eq = n_eamapplytypename_eq;
if(!ObjectUtils.isEmpty(this.n_eamapplytypename_eq)){
this.getSearchCond().eq("eamapplytypename", n_eamapplytypename_eq);
}
}
private String n_eamapplytypename_like;//[维护申请类型]
public void setN_eamapplytypename_like(String n_eamapplytypename_like) {
this.n_eamapplytypename_like = n_eamapplytypename_like;
if(!ObjectUtils.isEmpty(this.n_eamapplytypename_like)){
this.getSearchCond().like("eamapplytypename", n_eamapplytypename_like);
}
}
private String n_eamservicelevelid_eq;//[服务等级标识]
public void setN_eamservicelevelid_eq(String n_eamservicelevelid_eq) {
this.n_eamservicelevelid_eq = n_eamservicelevelid_eq;
if(!ObjectUtils.isEmpty(this.n_eamservicelevelid_eq)){
this.getSearchCond().eq("eamservicelevelid", n_eamservicelevelid_eq);
}
}
private String n_eamservicelevelname_eq;//[服务等级]
public void setN_eamservicelevelname_eq(String n_eamservicelevelname_eq) {
this.n_eamservicelevelname_eq = n_eamservicelevelname_eq;
if(!ObjectUtils.isEmpty(this.n_eamservicelevelname_eq)){
this.getSearchCond().eq("eamservicelevelname", n_eamservicelevelname_eq);
}
}
private String n_eamservicelevelname_like;//[服务等级]
public void setN_eamservicelevelname_like(String n_eamservicelevelname_like) {
this.n_eamservicelevelname_like = n_eamservicelevelname_like;
if(!ObjectUtils.isEmpty(this.n_eamservicelevelname_like)){
this.getSearchCond().like("eamservicelevelname", n_eamservicelevelname_like);
}
}
/**
* 启用快速搜索
......
......@@ -68,4 +68,6 @@ public interface EAMApplyMapper extends BaseMapper<EAMApply>{
List<EAMApply> selectByEamlocationid(@Param("eamlocationid") Serializable eamlocationid) ;
List<EAMApply> selectByEamservicelevelid(@Param("eamservicelevelid") Serializable eamservicelevelid) ;
}
......@@ -43,6 +43,8 @@ public interface IEAMApplyService extends IService<EAMApply>{
void removeByAssetid(String assetid) ;
List<EAMApply> selectByEamlocationid(String eamlocationid) ;
void removeByEamlocationid(String eamlocationid) ;
List<EAMApply> selectByEamservicelevelid(String eamservicelevelid) ;
void removeByEamservicelevelid(String eamservicelevelid) ;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
......
......@@ -54,12 +54,16 @@ public class EAMApplyServiceImpl extends ServiceImpl<EAMApplyMapper, EAMApply> i
@Autowired
@Lazy
protected cn.ibizlab.assetmanagement.core.location.service.IEAMLocationService eamlocationService;
@Autowired
@Lazy
protected cn.ibizlab.assetmanagement.core.workorder.service.IEAMServiceLevelService eamservicelevelService;
protected int batchSize = 500;
@Override
@Transactional
public boolean create(EAMApply et) {
fillParentData(et);
createIndexMajorEntityData(et);
if(!this.retBool(this.baseMapper.insert(et)))
return false;
......@@ -69,12 +73,14 @@ public class EAMApplyServiceImpl extends ServiceImpl<EAMApplyMapper, EAMApply> i
@Override
public void createBatch(List<EAMApply> list) {
list.forEach(item->fillParentData(item));
this.saveBatch(list,batchSize);
}
@Override
@Transactional
public boolean update(EAMApply et) {
fillParentData(et);
wooriginService.update(eamapplyInheritMapping.toWoorigin(et));
if(!update(et,(Wrapper) et.getUpdateWrapper(true).eq("eamapplyid",et.getEamapplyid())))
return false;
......@@ -84,6 +90,7 @@ public class EAMApplyServiceImpl extends ServiceImpl<EAMApplyMapper, EAMApply> i
@Override
public void updateBatch(List<EAMApply> list) {
list.forEach(item->fillParentData(item));
updateBatchById(list,batchSize);
}
......@@ -115,6 +122,7 @@ public class EAMApplyServiceImpl extends ServiceImpl<EAMApplyMapper, EAMApply> i
@Override
public EAMApply getDraft(EAMApply et) {
fillParentData(et);
return et;
}
......@@ -142,12 +150,14 @@ public class EAMApplyServiceImpl extends ServiceImpl<EAMApplyMapper, EAMApply> i
@Override
public boolean saveBatch(Collection<EAMApply> list) {
list.forEach(item->fillParentData(item));
saveOrUpdateBatch(list,batchSize);
return true;
}
@Override
public void saveBatch(List<EAMApply> list) {
list.forEach(item->fillParentData(item));
saveOrUpdateBatch(list,batchSize);
}
......@@ -182,6 +192,16 @@ public class EAMApplyServiceImpl extends ServiceImpl<EAMApplyMapper, EAMApply> i
this.remove(new QueryWrapper<EAMApply>().eq("eamlocationid",eamlocationid));
}
@Override
public List<EAMApply> selectByEamservicelevelid(String eamservicelevelid) {
return baseMapper.selectByEamservicelevelid(eamservicelevelid);
}
@Override
public void removeByEamservicelevelid(String eamservicelevelid) {
this.remove(new QueryWrapper<EAMApply>().eq("eamservicelevelid",eamservicelevelid));
}
/**
* 查询集合 DEFAULT
......@@ -194,6 +214,52 @@ public class EAMApplyServiceImpl extends ServiceImpl<EAMApplyMapper, EAMApply> i
/**
* 为当前实体填充父数据(外键值文本、外键值附加数据)
* @param et
*/
private void fillParentData(EAMApply et){
//实体关系[DER1N_EAMAPPLY_EAMAPPLYTYPE_EAMAPPLYTYPEID]
if(!ObjectUtils.isEmpty(et.getEamapplytypeid())){
cn.ibizlab.assetmanagement.core.apply.domain.EAMApplyType eamapplytype=et.getEamapplytype();
if(ObjectUtils.isEmpty(eamapplytype)){
cn.ibizlab.assetmanagement.core.apply.domain.EAMApplyType majorEntity=eamapplytypeService.get(et.getEamapplytypeid());
et.setEamapplytype(majorEntity);
eamapplytype=majorEntity;
}
et.setEamapplytypename(eamapplytype.getEamapplytypename());
}
//实体关系[DER1N_EAMAPPLY_EAMASSET_ASSETID]
if(!ObjectUtils.isEmpty(et.getAssetid())){
cn.ibizlab.assetmanagement.core.asset.domain.EAMAsset asset=et.getAsset();
if(ObjectUtils.isEmpty(asset)){
cn.ibizlab.assetmanagement.core.asset.domain.EAMAsset majorEntity=eamassetService.get(et.getAssetid());
et.setAsset(majorEntity);
asset=majorEntity;
}
et.setAssetname(asset.getAssetname());
}
//实体关系[DER1N_EAMAPPLY_EAMLOCATION_EAMLOCATIONID]
if(!ObjectUtils.isEmpty(et.getEamlocationid())){
cn.ibizlab.assetmanagement.core.location.domain.EAMLocation eamlocation=et.getEamlocation();
if(ObjectUtils.isEmpty(eamlocation)){
cn.ibizlab.assetmanagement.core.location.domain.EAMLocation majorEntity=eamlocationService.get(et.getEamlocationid());
et.setEamlocation(majorEntity);
eamlocation=majorEntity;
}
et.setEamlocationname(eamlocation.getEamlocationname());
}
//实体关系[DER1N_EAMAPPLY_EAMSERVICELEVEL_EAMSERVICELEVELID]
if(!ObjectUtils.isEmpty(et.getEamservicelevelid())){
cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel eamservicelevel=et.getEamservicelevel();
if(ObjectUtils.isEmpty(eamservicelevel)){
cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel majorEntity=eamservicelevelService.get(et.getEamservicelevelid());
et.setEamservicelevel(majorEntity);
eamservicelevel=majorEntity;
}
et.setEamservicelevelname(eamservicelevel.getEamservicelevelname());
}
}
......
......@@ -138,6 +138,13 @@ public class EAMLocation extends EntityMP implements Serializable {
@JSONField(name = "locationnumber")
@JsonProperty("locationnumber")
private String locationnumber;
/**
* 描述
*/
@TableField(value = "description")
@JSONField(name = "description")
@JsonProperty("description")
private String description;
/**
*
......@@ -205,6 +212,14 @@ public class EAMLocation extends EntityMP implements Serializable {
this.modify("locationnumber",locationnumber);
}
/**
* 设置 [描述]
*/
public void setDescription(String description){
this.description = description ;
this.modify("description",description);
}
}
......
......@@ -103,6 +103,13 @@ public class EAMLocationType extends EntityMP implements Serializable {
@JSONField(name = "eamlocationstatemodelname")
@JsonProperty("eamlocationstatemodelname")
private String eamlocationstatemodelname;
/**
* 描述
*/
@TableField(value = "description")
@JSONField(name = "description")
@JsonProperty("description")
private String description;
/**
*
......@@ -130,6 +137,14 @@ public class EAMLocationType extends EntityMP implements Serializable {
this.modify("eamlocationstatemodelid",eamlocationstatemodelid);
}
/**
* 设置 [描述]
*/
public void setDescription(String description){
this.description = description ;
this.modify("description",description);
}
}
......
package cn.ibizlab.assetmanagement.core.workorder.domain;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.math.BigInteger;
import java.util.HashMap;
import java.math.BigDecimal;
import java.text.SimpleDateFormat;
import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.util.ObjectUtils;
import org.springframework.util.DigestUtils;
import cn.ibizlab.assetmanagement.util.domain.EntityBase;
import cn.ibizlab.assetmanagement.util.annotation.DEField;
import cn.ibizlab.assetmanagement.util.enums.DEPredefinedFieldType;
import cn.ibizlab.assetmanagement.util.enums.DEFieldDefaultValueType;
import java.io.Serializable;
import lombok.*;
import org.springframework.data.annotation.Transient;
import cn.ibizlab.assetmanagement.util.annotation.Audit;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.baomidou.mybatisplus.annotation.*;
import cn.ibizlab.assetmanagement.util.domain.EntityMP;
/**
* 实体[服务等级]
*/
@Getter
@Setter
@NoArgsConstructor
@JsonIgnoreProperties(value = "handler")
@TableName(value = "EAMSERVICELEVEL",resultMap = "EAMServiceLevelResultMap")
public class EAMServiceLevel extends EntityMP implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 建立人
*/
@DEField(preType = DEPredefinedFieldType.CREATEMAN)
@TableField(value = "createman" , fill = FieldFill.INSERT)
@JSONField(name = "createman")
@JsonProperty("createman")
private String createman;
/**
* 建立时间
*/
@DEField(preType = DEPredefinedFieldType.CREATEDATE)
@TableField(value = "createdate" , fill = FieldFill.INSERT)
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", locale = "zh" , timezone="GMT+8")
@JSONField(name = "createdate" , format="yyyy-MM-dd HH:mm:ss")
@JsonProperty("createdate")
private Timestamp createdate;
/**
* 服务等级标识
*/
@DEField(isKeyField=true)
@TableId(value= "eamservicelevelid",type=IdType.ASSIGN_UUID)
@JSONField(name = "eamservicelevelid")
@JsonProperty("eamservicelevelid")
private String eamservicelevelid;
/**
* 更新人
*/
@DEField(preType = DEPredefinedFieldType.UPDATEMAN)
@TableField(value = "updateman")
@JSONField(name = "updateman")
@JsonProperty("updateman")
private String updateman;
/**
* 服务等级名称
*/
@TableField(value = "eamservicelevelname")
@JSONField(name = "eamservicelevelname")
@JsonProperty("eamservicelevelname")
private String eamservicelevelname;
/**
* 更新时间
*/
@DEField(preType = DEPredefinedFieldType.UPDATEDATE)
@TableField(value = "updatedate")
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", locale = "zh" , timezone="GMT+8")
@JSONField(name = "updatedate" , format="yyyy-MM-dd HH:mm:ss")
@JsonProperty("updatedate")
private Timestamp updatedate;
/**
* 描述
*/
@TableField(value = "description")
@JSONField(name = "description")
@JsonProperty("description")
private String description;
/**
* 设置 [服务等级名称]
*/
public void setEamservicelevelname(String eamservicelevelname){
this.eamservicelevelname = eamservicelevelname ;
this.modify("eamservicelevelname",eamservicelevelname);
}
/**
* 设置 [描述]
*/
public void setDescription(String description){
this.description = description ;
this.modify("description",description);
}
}
package cn.ibizlab.assetmanagement.core.workorder.filter;
import java.math.BigDecimal;
import java.math.BigInteger;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.HashMap;
import lombok.*;
import lombok.extern.slf4j.Slf4j;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.alibaba.fastjson.annotation.JSONField;
import org.springframework.util.ObjectUtils;
import org.springframework.util.StringUtils;
import cn.ibizlab.assetmanagement.util.filter.QueryWrapperContext;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel;
/**
* 关系型数据实体[EAMServiceLevel] 查询条件对象
*/
@Slf4j
@Data
public class EAMServiceLevelSearchContext extends QueryWrapperContext<EAMServiceLevel> {
private String n_eamservicelevelname_like;//[服务等级名称]
public void setN_eamservicelevelname_like(String n_eamservicelevelname_like) {
this.n_eamservicelevelname_like = n_eamservicelevelname_like;
if(!ObjectUtils.isEmpty(this.n_eamservicelevelname_like)){
this.getSearchCond().like("eamservicelevelname", n_eamservicelevelname_like);
}
}
/**
* 启用快速搜索
*/
public void setQuery(String query)
{
this.query=query;
if(!StringUtils.isEmpty(query)){
this.getSearchCond().and( wrapper ->
wrapper.like("eamservicelevelname", query)
);
}
}
}
package cn.ibizlab.assetmanagement.core.workorder.mapper;
import java.util.List;
import org.apache.ibatis.annotations.*;
import java.util.Map;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import java.util.HashMap;
import org.apache.ibatis.annotations.Select;
import cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel;
import cn.ibizlab.assetmanagement.core.workorder.filter.EAMServiceLevelSearchContext;
import org.springframework.cache.annotation.CacheEvict;
import org.springframework.cache.annotation.Cacheable;
import java.io.Serializable;
import com.baomidou.mybatisplus.core.toolkit.Constants;
import com.alibaba.fastjson.JSONObject;
public interface EAMServiceLevelMapper extends BaseMapper<EAMServiceLevel>{
Page<EAMServiceLevel> searchDefault(IPage page, @Param("srf") EAMServiceLevelSearchContext context, @Param("ew") Wrapper<EAMServiceLevel> wrapper) ;
@Override
EAMServiceLevel selectById(Serializable id);
@Override
int insert(EAMServiceLevel entity);
@Override
int updateById(@Param(Constants.ENTITY) EAMServiceLevel entity);
@Override
int update(@Param(Constants.ENTITY) EAMServiceLevel entity, @Param("ew") Wrapper<EAMServiceLevel> updateWrapper);
@Override
int deleteById(Serializable id);
/**
* 自定义查询SQL
* @param sql
* @return
*/
@Select("${sql}")
List<JSONObject> selectBySQL(@Param("sql") String sql, @Param("et")Map param);
/**
* 自定义更新SQL
* @param sql
* @return
*/
@Update("${sql}")
boolean updateBySQL(@Param("sql") String sql, @Param("et")Map param);
/**
* 自定义插入SQL
* @param sql
* @return
*/
@Insert("${sql}")
boolean insertBySQL(@Param("sql") String sql, @Param("et")Map param);
/**
* 自定义删除SQL
* @param sql
* @return
*/
@Delete("${sql}")
boolean deleteBySQL(@Param("sql") String sql, @Param("et")Map param);
}
package cn.ibizlab.assetmanagement.core.workorder.service;
import java.io.Serializable;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.HashMap;
import java.util.Collection;
import java.math.BigInteger;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import com.alibaba.fastjson.JSONObject;
import org.springframework.cache.annotation.CacheEvict;
import cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel;
import cn.ibizlab.assetmanagement.core.workorder.filter.EAMServiceLevelSearchContext;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* 实体[EAMServiceLevel] 服务对象接口
*/
public interface IEAMServiceLevelService extends IService<EAMServiceLevel>{
boolean create(EAMServiceLevel et) ;
void createBatch(List<EAMServiceLevel> list) ;
boolean update(EAMServiceLevel et) ;
void updateBatch(List<EAMServiceLevel> list) ;
boolean remove(String key) ;
void removeBatch(Collection<String> idList) ;
EAMServiceLevel get(String key) ;
EAMServiceLevel getDraft(EAMServiceLevel et) ;
boolean checkKey(EAMServiceLevel et) ;
boolean save(EAMServiceLevel et) ;
void saveBatch(List<EAMServiceLevel> list) ;
Page<EAMServiceLevel> searchDefault(EAMServiceLevelSearchContext context) ;
/**
*自定义查询SQL
* @param sql select * from table where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return select * from table where id = '1'
*/
List<JSONObject> select(String sql, Map param);
/**
*自定义SQL
* @param sql update table set name ='test' where id =#{et.param}
* @param param 参数列表 param.put("param","1");
* @return update table set name ='test' where id = '1'
*/
boolean execute(String sql, Map param);
List<EAMServiceLevel> getEamservicelevelByIds(List<String> ids) ;
List<EAMServiceLevel> getEamservicelevelByEntities(List<EAMServiceLevel> entities) ;
}
package cn.ibizlab.assetmanagement.core.workorder.service.impl;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
import java.util.Map;
import java.util.HashSet;
import java.util.HashMap;
import java.util.Collection;
import java.util.Objects;
import java.util.Optional;
import java.math.BigInteger;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cglib.beans.BeanCopier;
import org.springframework.stereotype.Service;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageImpl;
import org.springframework.data.domain.Pageable;
import org.springframework.util.ObjectUtils;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.context.annotation.Lazy;
import cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel;
import cn.ibizlab.assetmanagement.core.workorder.filter.EAMServiceLevelSearchContext;
import cn.ibizlab.assetmanagement.core.workorder.service.IEAMServiceLevelService;
import cn.ibizlab.assetmanagement.util.helper.CachedBeanCopier;
import cn.ibizlab.assetmanagement.util.helper.DEFieldCacheMap;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.ibizlab.assetmanagement.core.workorder.mapper.EAMServiceLevelMapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.alibaba.fastjson.JSONObject;
import org.springframework.util.StringUtils;
/**
* 实体[服务等级] 服务对象接口实现
*/
@Slf4j
@Service("EAMServiceLevelServiceImpl")
public class EAMServiceLevelServiceImpl extends ServiceImpl<EAMServiceLevelMapper, EAMServiceLevel> implements IEAMServiceLevelService {
@Autowired
@Lazy
protected cn.ibizlab.assetmanagement.core.apply.service.IEAMApplyService eamapplyService;
protected int batchSize = 500;
@Override
@Transactional
public boolean create(EAMServiceLevel et) {
if(!this.retBool(this.baseMapper.insert(et)))
return false;
CachedBeanCopier.copy(get(et.getEamservicelevelid()),et);
return true;
}
@Override
public void createBatch(List<EAMServiceLevel> list) {
this.saveBatch(list,batchSize);
}
@Override
@Transactional
public boolean update(EAMServiceLevel et) {
if(!update(et,(Wrapper) et.getUpdateWrapper(true).eq("eamservicelevelid",et.getEamservicelevelid())))
return false;
CachedBeanCopier.copy(get(et.getEamservicelevelid()),et);
return true;
}
@Override
public void updateBatch(List<EAMServiceLevel> list) {
updateBatchById(list,batchSize);
}
@Override
@Transactional
public boolean remove(String key) {
boolean result=removeById(key);
return result ;
}
@Override
public void removeBatch(Collection<String> idList) {
removeByIds(idList);
}
@Override
@Transactional
public EAMServiceLevel get(String key) {
EAMServiceLevel et = getById(key);
if(et==null){
et=new EAMServiceLevel();
et.setEamservicelevelid(key);
}
else{
}
return et;
}
@Override
public EAMServiceLevel getDraft(EAMServiceLevel et) {
return et;
}
@Override
public boolean checkKey(EAMServiceLevel et) {
return (!ObjectUtils.isEmpty(et.getEamservicelevelid()))&&(!Objects.isNull(this.getById(et.getEamservicelevelid())));
}
@Override
@Transactional
public boolean save(EAMServiceLevel et) {
if(!saveOrUpdate(et))
return false;
return true;
}
@Override
@Transactional
public boolean saveOrUpdate(EAMServiceLevel et) {
if (null == et) {
return false;
} else {
return checkKey(et) ? this.update(et) : this.create(et);
}
}
@Override
public boolean saveBatch(Collection<EAMServiceLevel> list) {
saveOrUpdateBatch(list,batchSize);
return true;
}
@Override
public void saveBatch(List<EAMServiceLevel> list) {
saveOrUpdateBatch(list,batchSize);
}
/**
* 查询集合 DEFAULT
*/
@Override
public Page<EAMServiceLevel> searchDefault(EAMServiceLevelSearchContext context) {
com.baomidou.mybatisplus.extension.plugins.pagination.Page<EAMServiceLevel> pages=baseMapper.searchDefault(context.getPages(),context,context.getSelectCond());
return new PageImpl<EAMServiceLevel>(pages.getRecords(), context.getPageable(), pages.getTotal());
}
@Override
public List<JSONObject> select(String sql, Map param){
return this.baseMapper.selectBySQL(sql,param);
}
@Override
@Transactional
public boolean execute(String sql , Map param){
if (sql == null || sql.isEmpty()) {
return false;
}
if (sql.toLowerCase().trim().startsWith("insert")) {
return this.baseMapper.insertBySQL(sql,param);
}
if (sql.toLowerCase().trim().startsWith("update")) {
return this.baseMapper.updateBySQL(sql,param);
}
if (sql.toLowerCase().trim().startsWith("delete")) {
return this.baseMapper.deleteBySQL(sql,param);
}
log.warn("暂未支持的SQL语法");
return true;
}
@Override
public List<EAMServiceLevel> getEamservicelevelByIds(List<String> ids) {
return this.listByIds(ids);
}
@Override
public List<EAMServiceLevel> getEamservicelevelByEntities(List<EAMServiceLevel> entities) {
List ids =new ArrayList();
for(EAMServiceLevel entity : entities){
Serializable id=entity.getEamservicelevelid();
if(!ObjectUtils.isEmpty(id)){
ids.add(id);
}
}
if(ids.size()>0)
return this.listByIds(ids);
else
return entities;
}
}
......@@ -5,7 +5,7 @@
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="EAMApplyResultMap" databaseId="mysql">
<![CDATA[select t1.* from (SELECT t1.`ASSETID`, t1.`BEGINTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYID`, t1.`EAMAPPLYNAME`, t1.`EAMAPPLYTYPEID`, t1.`EAMLOCATIONID`, t1.`ENDTIME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLY` t1 ) t1 where eamapplyid=#{id}]]>
<![CDATA[select t1.* from (SELECT t1.`APPLYNUMBER`, t1.`ASSETID`, t11.`ASSETNAME`, t1.`BEGINTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYID`, t1.`EAMAPPLYNAME`, t1.`EAMAPPLYTYPEID`, t31.`EAMAPPLYTYPENAME`, t1.`EAMLOCATIONID`, t21.`EAMLOCATIONNAME`, t1.`EAMSERVICELEVELID`, t41.`EAMSERVICELEVELNAME`, t1.`ENDTIME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLY` t1 LEFT JOIN ASSET t11 ON t1.ASSETID = t11.ASSETID LEFT JOIN EAMLOCATION t21 ON t1.EAMLOCATIONID = t21.EAMLOCATIONID LEFT JOIN EAMAPPLYTYPE t31 ON t1.EAMAPPLYTYPEID = t31.EAMAPPLYTYPEID LEFT JOIN EAMSERVICELEVEL t41 ON t1.EAMSERVICELEVELID = t41.EAMSERVICELEVELID ) t1 where eamapplyid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
......@@ -14,6 +14,7 @@
<result property="eamapplytypeid" column="eamapplytypeid" />
<result property="eamlocationid" column="eamlocationid" />
<result property="assetid" column="assetid" />
<result property="eamservicelevelid" column="eamservicelevelid" />
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
......@@ -22,6 +23,8 @@
<association property="asset" javaType="cn.ibizlab.assetmanagement.core.asset.domain.EAMAsset" column="assetid" select="cn.ibizlab.assetmanagement.core.asset.mapper.EAMAssetMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="eamlocation" javaType="cn.ibizlab.assetmanagement.core.location.domain.EAMLocation" column="eamlocationid" select="cn.ibizlab.assetmanagement.core.location.mapper.EAMLocationMapper.selectById" fetchType="lazy"></association>
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="eamservicelevel" javaType="cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel" column="eamservicelevelid" select="cn.ibizlab.assetmanagement.core.workorder.mapper.EAMServiceLevelMapper.selectById" fetchType="lazy"></association>
</resultMap>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_EAMAPPLY_EAMAPPLYTYPE_EAMAPPLYTYPEID] -->
......@@ -44,6 +47,13 @@
<include refid="Default" />
) t1
where eamlocationid=#{eamlocationid}
</select>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_EAMAPPLY_EAMSERVICELEVEL_EAMSERVICELEVELID] -->
<select id="selectByEamservicelevelid" resultMap="EAMApplyResultMap">
select t1.* from (
<include refid="Default" />
) t1
where eamservicelevelid=#{eamservicelevelid}
</select>
<!--数据集合[Default]-->
......@@ -57,12 +67,12 @@
<!--数据查询[Default]-->
<sql id="Default" databaseId="mysql">
<![CDATA[ SELECT t1.`ASSETID`, t1.`BEGINTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYID`, t1.`EAMAPPLYNAME`, t1.`EAMAPPLYTYPEID`, t1.`EAMLOCATIONID`, t1.`ENDTIME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLY` t1
<![CDATA[ SELECT t1.`APPLYNUMBER`, t1.`ASSETID`, t11.`ASSETNAME`, t1.`BEGINTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYID`, t1.`EAMAPPLYNAME`, t1.`EAMAPPLYTYPEID`, t31.`EAMAPPLYTYPENAME`, t1.`EAMLOCATIONID`, t21.`EAMLOCATIONNAME`, t1.`EAMSERVICELEVELID`, t41.`EAMSERVICELEVELNAME`, t1.`ENDTIME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLY` t1 LEFT JOIN ASSET t11 ON t1.ASSETID = t11.ASSETID LEFT JOIN EAMLOCATION t21 ON t1.EAMLOCATIONID = t21.EAMLOCATIONID LEFT JOIN EAMAPPLYTYPE t31 ON t1.EAMAPPLYTYPEID = t31.EAMAPPLYTYPEID LEFT JOIN EAMSERVICELEVEL t41 ON t1.EAMSERVICELEVELID = t41.EAMSERVICELEVELID
]]>
</sql>
<!--数据查询[View]-->
<sql id="View" databaseId="mysql">
<![CDATA[ SELECT t1.`ASSETID`, t1.`BEGINTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYID`, t1.`EAMAPPLYNAME`, t1.`EAMAPPLYTYPEID`, t1.`EAMLOCATIONID`, t1.`ENDTIME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLY` t1
<![CDATA[ SELECT t1.`APPLYNUMBER`, t1.`ASSETID`, t11.`ASSETNAME`, t1.`BEGINTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYID`, t1.`EAMAPPLYNAME`, t1.`EAMAPPLYTYPEID`, t31.`EAMAPPLYTYPENAME`, t1.`EAMLOCATIONID`, t21.`EAMLOCATIONNAME`, t1.`EAMSERVICELEVELID`, t41.`EAMSERVICELEVELNAME`, t1.`ENDTIME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLY` t1 LEFT JOIN ASSET t11 ON t1.ASSETID = t11.ASSETID LEFT JOIN EAMLOCATION t21 ON t1.EAMLOCATIONID = t21.EAMLOCATIONID LEFT JOIN EAMAPPLYTYPE t31 ON t1.EAMAPPLYTYPEID = t31.EAMAPPLYTYPEID LEFT JOIN EAMSERVICELEVEL t41 ON t1.EAMSERVICELEVELID = t41.EAMSERVICELEVELID
]]>
</sql>
</mapper>
......
......@@ -5,7 +5,7 @@
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="EAMApplyTypeResultMap" databaseId="mysql">
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMAPPLYSTATEMODELID`, t1.`EAMAPPLYTYPEID`, t1.`EAMAPPLYTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLYTYPE` t1 ) t1 where eamapplytypeid=#{id}]]>
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYSTATEMODELID`, t1.`EAMAPPLYTYPEID`, t1.`EAMAPPLYTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLYTYPE` t1 ) t1 where eamapplytypeid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
......@@ -37,12 +37,12 @@
<!--数据查询[Default]-->
<sql id="Default" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMAPPLYSTATEMODELID`, t1.`EAMAPPLYTYPEID`, t1.`EAMAPPLYTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLYTYPE` t1
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYSTATEMODELID`, t1.`EAMAPPLYTYPEID`, t1.`EAMAPPLYTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLYTYPE` t1
]]>
</sql>
<!--数据查询[View]-->
<sql id="View" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMAPPLYSTATEMODELID`, t1.`EAMAPPLYTYPEID`, t1.`EAMAPPLYTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLYTYPE` t1
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMAPPLYSTATEMODELID`, t1.`EAMAPPLYTYPEID`, t1.`EAMAPPLYTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMAPPLYTYPE` t1
]]>
</sql>
</mapper>
......
......@@ -5,7 +5,7 @@
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="EAMLocationResultMap" databaseId="mysql">
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID ) t1 where eamlocationid=#{id}]]>
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID ) t1 where eamlocationid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
......@@ -84,30 +84,30 @@
<!--数据查询[Child]-->
<sql id="Child" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
WHERE ( t1.`PEAMLOCATIONID` = #{srf.datacontext.eamlocationid} )
]]>
</sql>
<!--数据查询[ChildLocation]-->
<sql id="ChildLocation" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
WHERE ( t1.`PEAMLOCATIONID` = #{srf.datacontext.srfparentkey} )
]]>
</sql>
<!--数据查询[Default]-->
<sql id="Default" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
]]>
</sql>
<!--数据查询[Top]-->
<sql id="Top" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
WHERE ( t1.`PEAMLOCATIONID` IS NULL )
]]>
</sql>
<!--数据查询[View]-->
<sql id="View" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONID`, t1.`EAMLOCATIONNAME`, t1.`EAMLOCATIONSTATEID`, t31.`EAMLOCATIONSTATENAME`, t1.`EAMLOCATIONTYPEID`, t21.`EAMLOCATIONTYPENAME`, t1.`LOCATIONNUMBER`, t1.`PEAMLOCATIONID`, t11.`EAMLOCATIONNAME` AS `PEAMLOCATIONNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATION` t1 LEFT JOIN EAMLOCATION t11 ON t1.PEAMLOCATIONID = t11.EAMLOCATIONID LEFT JOIN EAMLOCATIONTYPE t21 ON t1.EAMLOCATIONTYPEID = t21.EAMLOCATIONTYPEID LEFT JOIN EAMLOCATIONSTATE t31 ON t1.EAMLOCATIONSTATEID = t31.EAMLOCATIONSTATEID
]]>
</sql>
</mapper>
......
......@@ -5,7 +5,7 @@
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="EAMLocationTypeResultMap" databaseId="mysql">
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONSTATEMODELID`, t11.`EAMLOCATIONSTATEMODELNAME`, t1.`EAMLOCATIONTYPEID`, t1.`EAMLOCATIONTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATIONTYPE` t1 LEFT JOIN EAMLOCATIONSTATEMODEL t11 ON t1.EAMLOCATIONSTATEMODELID = t11.EAMLOCATIONSTATEMODELID ) t1 where eamlocationtypeid=#{id}]]>
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONSTATEMODELID`, t11.`EAMLOCATIONSTATEMODELNAME`, t1.`EAMLOCATIONTYPEID`, t1.`EAMLOCATIONTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATIONTYPE` t1 LEFT JOIN EAMLOCATIONSTATEMODEL t11 ON t1.EAMLOCATIONSTATEMODELID = t11.EAMLOCATIONSTATEMODELID ) t1 where eamlocationtypeid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
......@@ -37,12 +37,12 @@
<!--数据查询[Default]-->
<sql id="Default" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONSTATEMODELID`, t11.`EAMLOCATIONSTATEMODELNAME`, t1.`EAMLOCATIONTYPEID`, t1.`EAMLOCATIONTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATIONTYPE` t1 LEFT JOIN EAMLOCATIONSTATEMODEL t11 ON t1.EAMLOCATIONSTATEMODELID = t11.EAMLOCATIONSTATEMODELID
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONSTATEMODELID`, t11.`EAMLOCATIONSTATEMODELNAME`, t1.`EAMLOCATIONTYPEID`, t1.`EAMLOCATIONTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATIONTYPE` t1 LEFT JOIN EAMLOCATIONSTATEMODEL t11 ON t1.EAMLOCATIONSTATEMODELID = t11.EAMLOCATIONSTATEMODELID
]]>
</sql>
<!--数据查询[View]-->
<sql id="View" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`EAMLOCATIONSTATEMODELID`, t11.`EAMLOCATIONSTATEMODELNAME`, t1.`EAMLOCATIONTYPEID`, t1.`EAMLOCATIONTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATIONTYPE` t1 LEFT JOIN EAMLOCATIONSTATEMODEL t11 ON t1.EAMLOCATIONSTATEMODELID = t11.EAMLOCATIONSTATEMODELID
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMLOCATIONSTATEMODELID`, t11.`EAMLOCATIONSTATEMODELNAME`, t1.`EAMLOCATIONTYPEID`, t1.`EAMLOCATIONTYPENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMLOCATIONTYPE` t1 LEFT JOIN EAMLOCATIONSTATEMODEL t11 ON t1.EAMLOCATIONSTATEMODELID = t11.EAMLOCATIONSTATEMODELID
]]>
</sql>
</mapper>
......
<?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="cn.ibizlab.assetmanagement.core.workorder.mapper.EAMServiceLevelMapper">
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="EAMServiceLevelResultMap" databaseId="mysql">
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMSERVICELEVELID`, t1.`EAMSERVICELEVELNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMSERVICELEVEL` t1 ) t1 where eamservicelevelid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
<resultMap id="EAMServiceLevelResultMap" type="cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel" autoMapping="true">
<id property="eamservicelevelid" column="eamservicelevelid" /><!--主键字段映射-->
</resultMap>
<!--数据集合[Default]-->
<select id="searchDefault" parameterType="cn.ibizlab.assetmanagement.core.workorder.filter.EAMServiceLevelSearchContext" resultMap="EAMServiceLevelResultMap">
select t1.* from (
<include refid="Default" />
)t1
<where><if test="ew!=null and ew.sqlSegment!=null and !ew.emptyOfWhere">${ew.sqlSegment}</if></where>
<if test="ew!=null and ew.sqlSegment!=null and ew.emptyOfWhere">${ew.sqlSegment}</if>
</select>
<!--数据查询[Default]-->
<sql id="Default" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMSERVICELEVELID`, t1.`EAMSERVICELEVELNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMSERVICELEVEL` t1
]]>
</sql>
<!--数据查询[View]-->
<sql id="View" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`DESCRIPTION`, t1.`EAMSERVICELEVELID`, t1.`EAMSERVICELEVELNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `EAMSERVICELEVEL` t1
]]>
</sql>
</mapper>
......@@ -76,6 +76,14 @@
"datascope":[{"id":"all","name":"全部数据"}, {"id":"createman","name":"创建人"}]
}
, {
"dename":"EAMServiceLevel",
"delogicname":"服务等级",
"sysmoudle":{"id":"WORKORDER","name":"工单管理"},
"dedataset":[{"id":"Default" , "name":"DEFAULT"}],
"deaction":[{"id":"Create" , "name":"Create" , "type":"BUILTIN" },{"id":"Update" , "name":"Update" , "type":"BUILTIN" },{"id":"Remove" , "name":"Remove" , "type":"BUILTIN" },{"id":"Get" , "name":"Get" , "type":"BUILTIN" },{"id":"GetDraft" , "name":"GetDraft" , "type":"BUILTIN" },{"id":"CheckKey" , "name":"CheckKey" , "type":"BUILTIN" },{"id":"Save" , "name":"Save" , "type":"BUILTIN" }],
"datascope":[{"id":"all","name":"全部数据"}, {"id":"createman","name":"创建人"}]
}
, {
"dename":"EAMSparePartsPRO",
"delogicname":"备件包物料",
"sysmoudle":{"id":"ASSET","name":"资产管理"},
......@@ -153,7 +161,7 @@
{
"appid":"AssetManagement",
"appname":"资产管理",
"appmenu":[{"menuid":"AppIndexView", "menuname":"AppIndexView", "menuitem":[{ "id":"user_menus" , "name":"用户菜单" },{ "id":"top_menus" , "name":"顶部菜单" },{ "id":"left_exp" , "name":"左侧菜单" , "items":[{ "id":"menuitem1" , "name":"功能位置" , "items":[{ "id":"menuitem6" , "name":"功能位置状态" },{ "id":"menuitem7" , "name":"功能位置状态模型" },{ "id":"menuitem8" , "name":"功能位置类型" },{ "id":"menuitem9" , "name":"功能位置" }]},{ "id":"menuitem2" , "name":"资产管理" , "items":[{ "id":"menuitem10" , "name":"资产状态" },{ "id":"menuitem11" , "name":"资产状态模型" },{ "id":"menuitem12" , "name":"资产类型" },{ "id":"menuitem13" , "name":"资产管理" },{ "id":"menuitem14" , "name":"备件包" }]},{ "id":"menuitem3" , "name":"维护申请" },{ "id":"menuitem4" , "name":"工单管理" },{ "id":"menuitem5" , "name":"维护计划" }]}] }]
"appmenu":[{"menuid":"AppIndexView", "menuname":"AppIndexView", "menuitem":[{ "id":"user_menus" , "name":"用户菜单" },{ "id":"top_menus" , "name":"顶部菜单" , "items":[{ "id":"menuitem15" , "name":"系统设置" , "items":[{ "id":"menuitem16" , "name":"服务等级" },{ "id":"menuitem17" , "name":"维护申请类型" }]}]},{ "id":"left_exp" , "name":"左侧菜单" , "items":[{ "id":"menuitem1" , "name":"功能位置" , "items":[{ "id":"menuitem6" , "name":"功能位置状态" },{ "id":"menuitem7" , "name":"功能位置状态模型" },{ "id":"menuitem8" , "name":"功能位置类型" },{ "id":"menuitem9" , "name":"功能位置" }]},{ "id":"menuitem2" , "name":"资产管理" , "items":[{ "id":"menuitem10" , "name":"资产状态" },{ "id":"menuitem11" , "name":"资产状态模型" },{ "id":"menuitem12" , "name":"资产类型" },{ "id":"menuitem13" , "name":"资产管理" },{ "id":"menuitem14" , "name":"备件包" }]},{ "id":"menuitem3" , "name":"维护申请" },{ "id":"menuitem4" , "name":"工单管理" },{ "id":"menuitem5" , "name":"维护计划" }]}] }]
}
]
}
......@@ -12,6 +12,6 @@ CMD echo "The application will start in ${IBIZ_SLEEP}s..." && \
sleep ${IBIZ_SLEEP} && \
java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /assetmanagement-provider-assetapi.jar
EXPOSE 8081
EXPOSE 10315
ADD assetmanagement-provider-assetapi.jar /assetmanagement-provider-assetapi.jar
......@@ -3,9 +3,25 @@ services:
assetmanagement-provider-assetapi:
image: registry.cn-shanghai.aliyuncs.com/ibizsys/assetmanagement-provider-assetapi:latest
ports:
- "8081:8081"
- "10315:10315"
networks:
- agent_network
environment:
- SPRING_CLOUD_NACOS_DISCOVERY_IP=172.16.240.110
- SERVER_PORT=10315
- SPRING_CLOUD_NACOS_DISCOVERY_SERVER-ADDR=172.16.240.110:8848
- SPRING_REDIS_HOST=172.16.240.110
- SPRING_REDIS_PORT=6379
- SPRING_REDIS_DATABASE=0
- SPRING_DATASOURCE_USERNAME=a_LAB01_e85d8801c
- SPRING_DATASOURCE_PASSWORD=b1@@@772
- SPRING_DATASOURCE_URL=jdbc:mysql://172.16.186.185:3306/a_LAB01_e85d8801c?autoReconnect=true&useUnicode=true&characterEncoding=UTF-8&useOldAliasMetadataBehavior=true&allowMultiQueries=true
- SPRING_DATASOURCE_DRIVER-CLASS-NAME=com.mysql.jdbc.Driver
- SPRING_DATASOURCE_DEFAULTSCHEMA=a_LAB01_e85d8801c
- CAS=https://passport.ibizlab.cn
- NACOS=172.16.240.110:8848
- SEATA_REGISTRY_NACOS_SERVER-ADDR=172.16.240.110:8848
- SEATA_ENABLED=true
deploy:
resources:
limits:
......
......@@ -123,6 +123,54 @@ public class EAMApplyDTO extends DTOBase implements Serializable {
@JsonProperty("endtime")
private Timestamp endtime;
/**
* 属性 [ASSETNAME]
*
*/
@JSONField(name = "assetname")
@JsonProperty("assetname")
private String assetname;
/**
* 属性 [EAMLOCATIONNAME]
*
*/
@JSONField(name = "eamlocationname")
@JsonProperty("eamlocationname")
private String eamlocationname;
/**
* 属性 [EAMAPPLYTYPENAME]
*
*/
@JSONField(name = "eamapplytypename")
@JsonProperty("eamapplytypename")
private String eamapplytypename;
/**
* 属性 [APPLYNUMBER]
*
*/
@JSONField(name = "applynumber")
@JsonProperty("applynumber")
private String applynumber;
/**
* 属性 [EAMSERVICELEVELID]
*
*/
@JSONField(name = "eamservicelevelid")
@JsonProperty("eamservicelevelid")
private String eamservicelevelid;
/**
* 属性 [EAMSERVICELEVELNAME]
*
*/
@JSONField(name = "eamservicelevelname")
@JsonProperty("eamservicelevelname")
private String eamservicelevelname;
/**
* 设置 [EAMAPPLYNAME]
......@@ -180,6 +228,22 @@ public class EAMApplyDTO extends DTOBase implements Serializable {
this.modify("endtime",endtime);
}
/**
* 设置 [APPLYNUMBER]
*/
public void setApplynumber(String applynumber){
this.applynumber = applynumber ;
this.modify("applynumber",applynumber);
}
/**
* 设置 [EAMSERVICELEVELID]
*/
public void setEamservicelevelid(String eamservicelevelid){
this.eamservicelevelid = eamservicelevelid ;
this.modify("eamservicelevelid",eamservicelevelid);
}
}
......@@ -81,6 +81,14 @@ public class EAMApplyTypeDTO extends DTOBase implements Serializable {
@JsonProperty("eamapplystatemodelid")
private String eamapplystatemodelid;
/**
* 属性 [DESCRIPTION]
*
*/
@JSONField(name = "description")
@JsonProperty("description")
private String description;
/**
* 设置 [EAMAPPLYTYPENAME]
......@@ -98,6 +106,14 @@ public class EAMApplyTypeDTO extends DTOBase implements Serializable {
this.modify("eamapplystatemodelid",eamapplystatemodelid);
}
/**
* 设置 [DESCRIPTION]
*/
public void setDescription(String description){
this.description = description ;
this.modify("description",description);
}
}
......@@ -129,6 +129,14 @@ public class EAMLocationDTO extends DTOBase implements Serializable {
@JsonProperty("locationnumber")
private String locationnumber;
/**
* 属性 [DESCRIPTION]
*
*/
@JSONField(name = "description")
@JsonProperty("description")
private String description;
/**
* 设置 [EAMLOCATIONNAME]
......@@ -170,6 +178,14 @@ public class EAMLocationDTO extends DTOBase implements Serializable {
this.modify("locationnumber",locationnumber);
}
/**
* 设置 [DESCRIPTION]
*/
public void setDescription(String description){
this.description = description ;
this.modify("description",description);
}
}
......@@ -89,6 +89,14 @@ public class EAMLocationTypeDTO extends DTOBase implements Serializable {
@JsonProperty("eamlocationstatemodelname")
private String eamlocationstatemodelname;
/**
* 属性 [DESCRIPTION]
*
*/
@JSONField(name = "description")
@JsonProperty("description")
private String description;
/**
* 设置 [EAMLOCATIONTYPENAME]
......@@ -106,6 +114,14 @@ public class EAMLocationTypeDTO extends DTOBase implements Serializable {
this.modify("eamlocationstatemodelid",eamlocationstatemodelid);
}
/**
* 设置 [DESCRIPTION]
*/
public void setDescription(String description){
this.description = description ;
this.modify("description",description);
}
}
package cn.ibizlab.assetmanagement.assetapi.dto;
import java.sql.Timestamp;
import java.util.ArrayList;
import java.util.List;
import java.math.BigInteger;
import java.util.Map;
import java.util.HashMap;
import java.io.Serializable;
import java.math.BigDecimal;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.alibaba.fastjson.annotation.JSONField;
import cn.ibizlab.assetmanagement.util.domain.DTOBase;
import lombok.Data;
/**
* 服务DTO对象[EAMServiceLevelDTO]
*/
@Data
public class EAMServiceLevelDTO extends DTOBase implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 属性 [CREATEMAN]
*
*/
@JSONField(name = "createman")
@JsonProperty("createman")
private String createman;
/**
* 属性 [CREATEDATE]
*
*/
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", locale = "zh" , timezone="GMT+8")
@JSONField(name = "createdate" , format="yyyy-MM-dd HH:mm:ss")
@JsonProperty("createdate")
private Timestamp createdate;
/**
* 属性 [EAMSERVICELEVELID]
*
*/
@JSONField(name = "eamservicelevelid")
@JsonProperty("eamservicelevelid")
private String eamservicelevelid;
/**
* 属性 [UPDATEMAN]
*
*/
@JSONField(name = "updateman")
@JsonProperty("updateman")
private String updateman;
/**
* 属性 [EAMSERVICELEVELNAME]
*
*/
@JSONField(name = "eamservicelevelname")
@JsonProperty("eamservicelevelname")
private String eamservicelevelname;
/**
* 属性 [UPDATEDATE]
*
*/
@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss", locale = "zh" , timezone="GMT+8")
@JSONField(name = "updatedate" , format="yyyy-MM-dd HH:mm:ss")
@JsonProperty("updatedate")
private Timestamp updatedate;
/**
* 属性 [DESCRIPTION]
*
*/
@JSONField(name = "description")
@JsonProperty("description")
private String description;
/**
* 设置 [EAMSERVICELEVELNAME]
*/
public void setEamservicelevelname(String eamservicelevelname){
this.eamservicelevelname = eamservicelevelname ;
this.modify("eamservicelevelname",eamservicelevelname);
}
/**
* 设置 [DESCRIPTION]
*/
public void setDescription(String description){
this.description = description ;
this.modify("description",description);
}
}
package cn.ibizlab.assetmanagement.assetapi.mapping;
import org.mapstruct.*;
import cn.ibizlab.assetmanagement.core.workorder.domain.EAMServiceLevel;
import cn.ibizlab.assetmanagement.assetapi.dto.EAMServiceLevelDTO;
import cn.ibizlab.assetmanagement.util.domain.MappingBase;
import org.mapstruct.factory.Mappers;
@Mapper(componentModel = "spring", uses = {},implementationName="AssetApiEAMServiceLevelMapping",
nullValuePropertyMappingStrategy = NullValuePropertyMappingStrategy.IGNORE,
nullValueCheckStrategy = NullValueCheckStrategy.ALWAYS)
public interface EAMServiceLevelMapping extends MappingBase<EAMServiceLevelDTO, EAMServiceLevel> {
}
......@@ -37,11 +37,11 @@
git clone -b master $para2 ibizassetmanagement/
export NODE_OPTIONS=--max-old-space-size=4096
cd ibizassetmanagement/
mvn clean package -Passetmanagement
cd assetmanagement-app/assetmanagement-app-assetmanagement
mvn -Passetmanagement docker:build
mvn -Passetmanagement docker:push
docker -H $para1 stack deploy --compose-file=src/main/docker/assetmanagement-app-assetmanagement.yaml iBizEE --with-registry-auth
mvn clean package -Passetapi
cd assetmanagement-provider/assetmanagement-provider-assetapi
mvn -Passetapi docker:build
mvn -Passetapi docker:push
docker -H $para1 stack deploy --compose-file=src/main/docker/assetmanagement-provider-assetapi.yaml iBizEE --with-registry-auth
</command>
</hudson.tasks.Shell>
</builders>
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册