提交 3a76cde6 编写于 作者: ibizdev's avatar ibizdev

JunZai 发布系统代码

上级 84f61df7
...@@ -1331,6 +1331,16 @@ div::-webkit-scrollbar-thumb { ...@@ -1331,6 +1331,16 @@ div::-webkit-scrollbar-thumb {
-webkit-box-direction: normal; -webkit-box-direction: normal;
-ms-flex-direction: column; -ms-flex-direction: column;
flex-direction: column; flex-direction: column;
.app-search-form {
display: flex;
flex-direction: column-reverse;
.search-button {
width: 100%;
}
.form-content {
width: 100%;
}
}
} }
} }
} }
......
...@@ -37,11 +37,6 @@ ...@@ -37,11 +37,6 @@
git clone -b master $para2 ibizhumanresources/ git clone -b master $para2 ibizhumanresources/
export NODE_OPTIONS=--max-old-space-size=4096 export NODE_OPTIONS=--max-old-space-size=4096
cd ibizhumanresources/ cd ibizhumanresources/
mvn clean package -Ppim
cd humanresource-app/humanresource-app-pim
mvn -Ppim docker:build
mvn -Ppim docker:push
docker -H $para1 stack deploy --compose-file=src/main/docker/humanresource-app-pim.yaml iBizEE --with-registry-auth
</command> </command>
</hudson.tasks.Shell> </hudson.tasks.Shell>
</builders> </builders>
......
...@@ -12,6 +12,6 @@ CMD echo "The application will start in ${IBIZ_SLEEP}s..." && \ ...@@ -12,6 +12,6 @@ CMD echo "The application will start in ${IBIZ_SLEEP}s..." && \
sleep ${IBIZ_SLEEP} && \ sleep ${IBIZ_SLEEP} && \
java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /humanresource-app-pim.jar java ${JAVA_OPTS} -Djava.security.egd=file:/dev/./urandom -jar /humanresource-app-pim.jar
EXPOSE 10327 EXPOSE 8080
ADD humanresource-app-pim.jar /humanresource-app-pim.jar ADD humanresource-app-pim.jar /humanresource-app-pim.jar
...@@ -3,25 +3,9 @@ services: ...@@ -3,25 +3,9 @@ services:
humanresource-app-pim: humanresource-app-pim:
image: registry.cn-shanghai.aliyuncs.com/ibizsys/humanresource-app-pim:latest image: registry.cn-shanghai.aliyuncs.com/ibizsys/humanresource-app-pim:latest
ports: ports:
- "10327:10327" - "8080:8080"
networks: networks:
- agent_network - agent_network
environment:
- SPRING_CLOUD_NACOS_DISCOVERY_IP=172.16.240.110
- SERVER_PORT=10327
- 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: deploy:
resources: resources:
limits: limits:
......
...@@ -89,6 +89,73 @@ public class HRArchivesBorrow extends EntityMP implements Serializable { ...@@ -89,6 +89,73 @@ public class HRArchivesBorrow extends EntityMP implements Serializable {
@JSONField(name = "updateman") @JSONField(name = "updateman")
@JsonProperty("updateman") @JsonProperty("updateman")
private String updateman; private String updateman;
/**
* 档案信息标识
*/
@TableField(value = "hrarchivesid")
@JSONField(name = "hrarchivesid")
@JsonProperty("hrarchivesid")
private String hrarchivesid;
/**
* 借阅状态
*/
@TableField(value = "borrowstate")
@JSONField(name = "borrowstate")
@JsonProperty("borrowstate")
private String borrowstate;
/**
* 借阅人
*/
@TableField(value = "borrowman")
@JSONField(name = "borrowman")
@JsonProperty("borrowman")
private String borrowman;
/**
* 借阅时间
*/
@TableField(value = "begintime")
@JsonFormat(pattern="yyyy-MM-dd", locale = "zh" , timezone="GMT+8")
@JSONField(name = "begintime" , format="yyyy-MM-dd")
@JsonProperty("begintime")
private Timestamp begintime;
/**
* 归还时间
*/
@TableField(value = "endtime")
@JsonFormat(pattern="yyyy-MM-dd", locale = "zh" , timezone="GMT+8")
@JSONField(name = "endtime" , format="yyyy-MM-dd")
@JsonProperty("endtime")
private Timestamp endtime;
/**
* 审批同意人
*/
@TableField(value = "checkman")
@JSONField(name = "checkman")
@JsonProperty("checkman")
private String checkman;
/**
* 审批时间
*/
@TableField(value = "checktime")
@JsonFormat(pattern="yyyy-MM-dd", locale = "zh" , timezone="GMT+8")
@JSONField(name = "checktime" , format="yyyy-MM-dd")
@JsonProperty("checktime")
private Timestamp checktime;
/**
* 借阅原因
*/
@TableField(value = "borrowreason")
@JSONField(name = "borrowreason")
@JsonProperty("borrowreason")
private String borrowreason;
/**
* 员工档案
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.humanresource.core.humanresource.domain.HRArchives hrarchives;
...@@ -100,6 +167,100 @@ public class HRArchivesBorrow extends EntityMP implements Serializable { ...@@ -100,6 +167,100 @@ public class HRArchivesBorrow extends EntityMP implements Serializable {
this.modify("hrarchivesborrowname",hrarchivesborrowname); this.modify("hrarchivesborrowname",hrarchivesborrowname);
} }
/**
* 设置 [档案信息标识]
*/
public void setHrarchivesid(String hrarchivesid){
this.hrarchivesid = hrarchivesid ;
this.modify("hrarchivesid",hrarchivesid);
}
/**
* 设置 [借阅状态]
*/
public void setBorrowstate(String borrowstate){
this.borrowstate = borrowstate ;
this.modify("borrowstate",borrowstate);
}
/**
* 设置 [借阅人]
*/
public void setBorrowman(String borrowman){
this.borrowman = borrowman ;
this.modify("borrowman",borrowman);
}
/**
* 设置 [借阅时间]
*/
public void setBegintime(Timestamp begintime){
this.begintime = begintime ;
this.modify("begintime",begintime);
}
/**
* 格式化日期 [借阅时间]
*/
public String formatBegintime(){
if (this.begintime == null) {
return null;
}
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
return sdf.format(begintime);
}
/**
* 设置 [归还时间]
*/
public void setEndtime(Timestamp endtime){
this.endtime = endtime ;
this.modify("endtime",endtime);
}
/**
* 格式化日期 [归还时间]
*/
public String formatEndtime(){
if (this.endtime == null) {
return null;
}
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
return sdf.format(endtime);
}
/**
* 设置 [审批同意人]
*/
public void setCheckman(String checkman){
this.checkman = checkman ;
this.modify("checkman",checkman);
}
/**
* 设置 [审批时间]
*/
public void setChecktime(Timestamp checktime){
this.checktime = checktime ;
this.modify("checktime",checktime);
}
/**
* 格式化日期 [审批时间]
*/
public String formatChecktime(){
if (this.checktime == null) {
return null;
}
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
return sdf.format(checktime);
}
/**
* 设置 [借阅原因]
*/
public void setBorrowreason(String borrowreason){
this.borrowreason = borrowreason ;
this.modify("borrowreason",borrowreason);
}
} }
......
package cn.ibizlab.humanresource.core.humanresource.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.humanresource.util.domain.EntityBase;
import cn.ibizlab.humanresource.util.annotation.DEField;
import cn.ibizlab.humanresource.util.enums.DEPredefinedFieldType;
import cn.ibizlab.humanresource.util.enums.DEFieldDefaultValueType;
import java.io.Serializable;
import lombok.*;
import org.springframework.data.annotation.Transient;
import cn.ibizlab.humanresource.util.annotation.Audit;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.baomidou.mybatisplus.annotation.*;
import cn.ibizlab.humanresource.util.domain.EntityMP;
/**
* 实体[档案调档]
*/
@Getter
@Setter
@NoArgsConstructor
@JsonIgnoreProperties(value = "handler")
@TableName(value = "T_HRARCHIVESMOVE",resultMap = "HRArchivesMoveResultMap")
public class HRArchivesMove extends EntityMP implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 档案调档标识
*/
@DEField(isKeyField=true)
@TableId(value= "hrarchivesmoveid",type=IdType.ASSIGN_UUID)
@JSONField(name = "hrarchivesmoveid")
@JsonProperty("hrarchivesmoveid")
private String hrarchivesmoveid;
/**
* 档案调档名称
*/
@TableField(value = "hrarchivesmovename")
@JSONField(name = "hrarchivesmovename")
@JsonProperty("hrarchivesmovename")
private String hrarchivesmovename;
/**
* 更新人
*/
@DEField(preType = DEPredefinedFieldType.UPDATEMAN)
@TableField(value = "updateman")
@JSONField(name = "updateman")
@JsonProperty("updateman")
private String updateman;
/**
* 建立人
*/
@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(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 = "hrarchivesid")
@JSONField(name = "hrarchivesid")
@JsonProperty("hrarchivesid")
private String hrarchivesid;
/**
* 员工档案
*/
@JsonIgnore
@JSONField(serialize = false)
@TableField(exist = false)
private cn.ibizlab.humanresource.core.humanresource.domain.HRArchives hrarchives;
/**
* 设置 [档案调档名称]
*/
public void setHrarchivesmovename(String hrarchivesmovename){
this.hrarchivesmovename = hrarchivesmovename ;
this.modify("hrarchivesmovename",hrarchivesmovename);
}
/**
* 设置 [档案信息标识]
*/
public void setHrarchivesid(String hrarchivesid){
this.hrarchivesid = hrarchivesid ;
this.modify("hrarchivesid",hrarchivesid);
}
}
...@@ -34,6 +34,20 @@ public class HRArchivesBorrowSearchContext extends QueryWrapperContext<HRArchive ...@@ -34,6 +34,20 @@ public class HRArchivesBorrowSearchContext extends QueryWrapperContext<HRArchive
this.getSearchCond().like("hrarchivesborrowname", n_hrarchivesborrowname_like); this.getSearchCond().like("hrarchivesborrowname", n_hrarchivesborrowname_like);
} }
} }
private String n_hrarchivesid_eq;//[档案信息标识]
public void setN_hrarchivesid_eq(String n_hrarchivesid_eq) {
this.n_hrarchivesid_eq = n_hrarchivesid_eq;
if(!ObjectUtils.isEmpty(this.n_hrarchivesid_eq)){
this.getSearchCond().eq("hrarchivesid", n_hrarchivesid_eq);
}
}
private String n_borrowstate_eq;//[借阅状态]
public void setN_borrowstate_eq(String n_borrowstate_eq) {
this.n_borrowstate_eq = n_borrowstate_eq;
if(!ObjectUtils.isEmpty(this.n_borrowstate_eq)){
this.getSearchCond().eq("borrowstate", n_borrowstate_eq);
}
}
/** /**
* 启用快速搜索 * 启用快速搜索
......
package cn.ibizlab.humanresource.core.humanresource.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.humanresource.util.filter.QueryWrapperContext;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import cn.ibizlab.humanresource.core.humanresource.domain.HRArchivesMove;
/**
* 关系型数据实体[HRArchivesMove] 查询条件对象
*/
@Slf4j
@Data
public class HRArchivesMoveSearchContext extends QueryWrapperContext<HRArchivesMove> {
private String n_hrarchivesmovename_like;//[档案调档名称]
public void setN_hrarchivesmovename_like(String n_hrarchivesmovename_like) {
this.n_hrarchivesmovename_like = n_hrarchivesmovename_like;
if(!ObjectUtils.isEmpty(this.n_hrarchivesmovename_like)){
this.getSearchCond().like("hrarchivesmovename", n_hrarchivesmovename_like);
}
}
private String n_hrarchivesid_eq;//[档案信息标识]
public void setN_hrarchivesid_eq(String n_hrarchivesid_eq) {
this.n_hrarchivesid_eq = n_hrarchivesid_eq;
if(!ObjectUtils.isEmpty(this.n_hrarchivesid_eq)){
this.getSearchCond().eq("hrarchivesid", n_hrarchivesid_eq);
}
}
/**
* 启用快速搜索
*/
public void setQuery(String query)
{
this.query=query;
if(!StringUtils.isEmpty(query)){
this.getSearchCond().and( wrapper ->
wrapper.like("hrarchivesmovename", query)
);
}
}
}
...@@ -62,4 +62,6 @@ public interface HRArchivesBorrowMapper extends BaseMapper<HRArchivesBorrow>{ ...@@ -62,4 +62,6 @@ public interface HRArchivesBorrowMapper extends BaseMapper<HRArchivesBorrow>{
@Delete("${sql}") @Delete("${sql}")
boolean deleteBySQL(@Param("sql") String sql, @Param("et")Map param); boolean deleteBySQL(@Param("sql") String sql, @Param("et")Map param);
List<HRArchivesBorrow> selectByHrarchivesid(@Param("hrarchivesid") Serializable hrarchivesid) ;
} }
package cn.ibizlab.humanresource.core.humanresource.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.humanresource.core.humanresource.domain.HRArchivesMove;
import cn.ibizlab.humanresource.core.humanresource.filter.HRArchivesMoveSearchContext;
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 HRArchivesMoveMapper extends BaseMapper<HRArchivesMove>{
Page<HRArchivesMove> searchDefault(IPage page, @Param("srf") HRArchivesMoveSearchContext context, @Param("ew") Wrapper<HRArchivesMove> wrapper) ;
@Override
HRArchivesMove selectById(Serializable id);
@Override
int insert(HRArchivesMove entity);
@Override
int updateById(@Param(Constants.ENTITY) HRArchivesMove entity);
@Override
int update(@Param(Constants.ENTITY) HRArchivesMove entity, @Param("ew") Wrapper<HRArchivesMove> 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);
List<HRArchivesMove> selectByHrarchivesid(@Param("hrarchivesid") Serializable hrarchivesid) ;
}
...@@ -37,6 +37,8 @@ public interface IHRArchivesBorrowService extends IService<HRArchivesBorrow>{ ...@@ -37,6 +37,8 @@ public interface IHRArchivesBorrowService extends IService<HRArchivesBorrow>{
boolean save(HRArchivesBorrow et) ; boolean save(HRArchivesBorrow et) ;
void saveBatch(List<HRArchivesBorrow> list) ; void saveBatch(List<HRArchivesBorrow> list) ;
Page<HRArchivesBorrow> searchDefault(HRArchivesBorrowSearchContext context) ; Page<HRArchivesBorrow> searchDefault(HRArchivesBorrowSearchContext context) ;
List<HRArchivesBorrow> selectByHrarchivesid(String hrarchivesid) ;
void removeByHrarchivesid(String hrarchivesid) ;
/** /**
*自定义查询SQL *自定义查询SQL
* @param sql select * from table where id =#{et.param} * @param sql select * from table where id =#{et.param}
......
package cn.ibizlab.humanresource.core.humanresource.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.humanresource.core.humanresource.domain.HRArchivesMove;
import cn.ibizlab.humanresource.core.humanresource.filter.HRArchivesMoveSearchContext;
import com.baomidou.mybatisplus.extension.service.IService;
/**
* 实体[HRArchivesMove] 服务对象接口
*/
public interface IHRArchivesMoveService extends IService<HRArchivesMove>{
boolean create(HRArchivesMove et) ;
void createBatch(List<HRArchivesMove> list) ;
boolean update(HRArchivesMove et) ;
void updateBatch(List<HRArchivesMove> list) ;
boolean remove(String key) ;
void removeBatch(Collection<String> idList) ;
HRArchivesMove get(String key) ;
HRArchivesMove getDraft(HRArchivesMove et) ;
boolean checkKey(HRArchivesMove et) ;
boolean save(HRArchivesMove et) ;
void saveBatch(List<HRArchivesMove> list) ;
Page<HRArchivesMove> searchDefault(HRArchivesMoveSearchContext context) ;
List<HRArchivesMove> selectByHrarchivesid(String hrarchivesid) ;
void removeByHrarchivesid(String hrarchivesid) ;
/**
*自定义查询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<HRArchivesMove> getHrarchivesmoveByIds(List<String> ids) ;
List<HRArchivesMove> getHrarchivesmoveByEntities(List<HRArchivesMove> entities) ;
}
...@@ -45,6 +45,9 @@ import org.springframework.util.StringUtils; ...@@ -45,6 +45,9 @@ import org.springframework.util.StringUtils;
@Service("HRArchivesBorrowServiceImpl") @Service("HRArchivesBorrowServiceImpl")
public class HRArchivesBorrowServiceImpl extends ServiceImpl<HRArchivesBorrowMapper, HRArchivesBorrow> implements IHRArchivesBorrowService { public class HRArchivesBorrowServiceImpl extends ServiceImpl<HRArchivesBorrowMapper, HRArchivesBorrow> implements IHRArchivesBorrowService {
@Autowired
@Lazy
protected cn.ibizlab.humanresource.core.humanresource.service.IHRArchivesService hrarchivesService;
protected int batchSize = 500; protected int batchSize = 500;
...@@ -140,6 +143,16 @@ public class HRArchivesBorrowServiceImpl extends ServiceImpl<HRArchivesBorrowMap ...@@ -140,6 +143,16 @@ public class HRArchivesBorrowServiceImpl extends ServiceImpl<HRArchivesBorrowMap
} }
@Override
public List<HRArchivesBorrow> selectByHrarchivesid(String hrarchivesid) {
return baseMapper.selectByHrarchivesid(hrarchivesid);
}
@Override
public void removeByHrarchivesid(String hrarchivesid) {
this.remove(new QueryWrapper<HRArchivesBorrow>().eq("hrarchivesid",hrarchivesid));
}
/** /**
* 查询集合 DEFAULT * 查询集合 DEFAULT
......
package cn.ibizlab.humanresource.core.humanresource.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.humanresource.core.humanresource.domain.HRArchivesMove;
import cn.ibizlab.humanresource.core.humanresource.filter.HRArchivesMoveSearchContext;
import cn.ibizlab.humanresource.core.humanresource.service.IHRArchivesMoveService;
import cn.ibizlab.humanresource.util.helper.CachedBeanCopier;
import cn.ibizlab.humanresource.util.helper.DEFieldCacheMap;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import cn.ibizlab.humanresource.core.humanresource.mapper.HRArchivesMoveMapper;
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("HRArchivesMoveServiceImpl")
public class HRArchivesMoveServiceImpl extends ServiceImpl<HRArchivesMoveMapper, HRArchivesMove> implements IHRArchivesMoveService {
@Autowired
@Lazy
protected cn.ibizlab.humanresource.core.humanresource.service.IHRArchivesService hrarchivesService;
protected int batchSize = 500;
@Override
@Transactional
public boolean create(HRArchivesMove et) {
if(!this.retBool(this.baseMapper.insert(et)))
return false;
CachedBeanCopier.copy(get(et.getHrarchivesmoveid()),et);
return true;
}
@Override
public void createBatch(List<HRArchivesMove> list) {
this.saveBatch(list,batchSize);
}
@Override
@Transactional
public boolean update(HRArchivesMove et) {
if(!update(et,(Wrapper) et.getUpdateWrapper(true).eq("hrarchivesmoveid",et.getHrarchivesmoveid())))
return false;
CachedBeanCopier.copy(get(et.getHrarchivesmoveid()),et);
return true;
}
@Override
public void updateBatch(List<HRArchivesMove> 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 HRArchivesMove get(String key) {
HRArchivesMove et = getById(key);
if(et==null){
et=new HRArchivesMove();
et.setHrarchivesmoveid(key);
}
else{
}
return et;
}
@Override
public HRArchivesMove getDraft(HRArchivesMove et) {
return et;
}
@Override
public boolean checkKey(HRArchivesMove et) {
return (!ObjectUtils.isEmpty(et.getHrarchivesmoveid()))&&(!Objects.isNull(this.getById(et.getHrarchivesmoveid())));
}
@Override
@Transactional
public boolean save(HRArchivesMove et) {
if(!saveOrUpdate(et))
return false;
return true;
}
@Override
@Transactional
public boolean saveOrUpdate(HRArchivesMove et) {
if (null == et) {
return false;
} else {
return checkKey(et) ? this.update(et) : this.create(et);
}
}
@Override
public boolean saveBatch(Collection<HRArchivesMove> list) {
saveOrUpdateBatch(list,batchSize);
return true;
}
@Override
public void saveBatch(List<HRArchivesMove> list) {
saveOrUpdateBatch(list,batchSize);
}
@Override
public List<HRArchivesMove> selectByHrarchivesid(String hrarchivesid) {
return baseMapper.selectByHrarchivesid(hrarchivesid);
}
@Override
public void removeByHrarchivesid(String hrarchivesid) {
this.remove(new QueryWrapper<HRArchivesMove>().eq("hrarchivesid",hrarchivesid));
}
/**
* 查询集合 DEFAULT
*/
@Override
public Page<HRArchivesMove> searchDefault(HRArchivesMoveSearchContext context) {
com.baomidou.mybatisplus.extension.plugins.pagination.Page<HRArchivesMove> pages=baseMapper.searchDefault(context.getPages(),context,context.getSelectCond());
return new PageImpl<HRArchivesMove>(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<HRArchivesMove> getHrarchivesmoveByIds(List<String> ids) {
return this.listByIds(ids);
}
@Override
public List<HRArchivesMove> getHrarchivesmoveByEntities(List<HRArchivesMove> entities) {
List ids =new ArrayList();
for(HRArchivesMove entity : entities){
Serializable id=entity.getHrarchivesmoveid();
if(!ObjectUtils.isEmpty(id)){
ids.add(id);
}
}
if(ids.size()>0)
return this.listByIds(ids);
else
return entities;
}
}
...@@ -45,6 +45,12 @@ import org.springframework.util.StringUtils; ...@@ -45,6 +45,12 @@ import org.springframework.util.StringUtils;
@Service("HRArchivesServiceImpl") @Service("HRArchivesServiceImpl")
public class HRArchivesServiceImpl extends ServiceImpl<HRArchivesMapper, HRArchives> implements IHRArchivesService { public class HRArchivesServiceImpl extends ServiceImpl<HRArchivesMapper, HRArchives> implements IHRArchivesService {
@Autowired
@Lazy
protected cn.ibizlab.humanresource.core.humanresource.service.IHRArchivesBorrowService hrarchivesborrowService;
@Autowired
@Lazy
protected cn.ibizlab.humanresource.core.humanresource.service.IHRArchivesMoveService hrarchivesmoveService;
@Autowired @Autowired
@Lazy @Lazy
protected cn.ibizlab.humanresource.core.humanresource.service.IHREmployeeService hremployeeService; protected cn.ibizlab.humanresource.core.humanresource.service.IHREmployeeService hremployeeService;
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<!--输出实体[HRARCHIVES]数据结构 --> <!--输出实体[HRARCHIVES]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrarchives-104-1"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrarchives-106-1">
<createTable tableName="T_HRARCHIVES"> <createTable tableName="T_HRARCHIVES">
<column name="HRARCHIVESID" remarks="" type="VARCHAR(100)"> <column name="HRARCHIVESID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRARCHIVES_HRARCHIVESID"/> <constraints primaryKey="true" primaryKeyName="PK_HRARCHIVES_HRARCHIVESID"/>
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
<!--输出实体[HRARCHIVESBORROW]数据结构 --> <!--输出实体[HRARCHIVESBORROW]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrarchivesborrow-2-2"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrarchivesborrow-11-2">
<createTable tableName="T_HRARCHIVESBORROW"> <createTable tableName="T_HRARCHIVESBORROW">
<column name="CREATEMAN" remarks="" type="VARCHAR(60)"> <column name="CREATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -67,12 +67,50 @@ ...@@ -67,12 +67,50 @@
</column> </column>
<column name="UPDATEMAN" remarks="" type="VARCHAR(60)"> <column name="UPDATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
<column name="HRARCHIVESID" remarks="" type="VARCHAR(100)">
</column>
<column name="BORROWSTATE" remarks="" type="VARCHAR(60)">
</column>
<column name="BORROWMAN" remarks="" type="VARCHAR(100)">
</column>
<column name="BEGINTIME" remarks="" type="DATETIME">
</column>
<column name="ENDTIME" remarks="" type="DATETIME">
</column>
<column name="CHECKMAN" remarks="" type="VARCHAR(100)">
</column>
<column name="CHECKTIME" remarks="" type="DATETIME">
</column>
<column name="BORROWREASON" remarks="" type="VARCHAR(100)">
</column>
</createTable>
</changeSet>
<!--输出实体[HRARCHIVESMOVE]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrarchivesmove-3-3">
<createTable tableName="T_HRARCHIVESMOVE">
<column name="HRARCHIVESMOVEID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRARCHIVESMOVE_HRARCHIVESMO"/>
</column>
<column name="HRARCHIVESMOVENAME" remarks="" type="VARCHAR(200)">
</column>
<column name="UPDATEMAN" remarks="" type="VARCHAR(60)">
</column>
<column name="CREATEMAN" remarks="" type="VARCHAR(60)">
</column>
<column name="CREATEDATE" remarks="" type="DATETIME">
</column>
<column name="UPDATEDATE" remarks="" type="DATETIME">
</column>
<column name="HRARCHIVESID" remarks="" type="VARCHAR(100)">
</column>
</createTable> </createTable>
</changeSet> </changeSet>
<!--输出实体[HRATTENDANCE]数据结构 --> <!--输出实体[HRATTENDANCE]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrattendance-3-3"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrattendance-3-4">
<createTable tableName="ATTENDANCE"> <createTable tableName="ATTENDANCE">
<column name="CREATEDATE" remarks="" type="DATETIME"> <column name="CREATEDATE" remarks="" type="DATETIME">
</column> </column>
...@@ -92,7 +130,7 @@ ...@@ -92,7 +130,7 @@
<!--输出实体[HRCERTIFICATE]数据结构 --> <!--输出实体[HRCERTIFICATE]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrcertificate-93-4"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrcertificate-93-5">
<createTable tableName="T_HRCERTIFICATE"> <createTable tableName="T_HRCERTIFICATE">
<column name="HRCERTIFICATEID" remarks="" type="VARCHAR(100)"> <column name="HRCERTIFICATEID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRCERTIFICATE_HRCERTIFICATE"/> <constraints primaryKey="true" primaryKeyName="PK_HRCERTIFICATE_HRCERTIFICATE"/>
...@@ -134,7 +172,7 @@ ...@@ -134,7 +172,7 @@
<!--输出实体[HRCONTRACT]数据结构 --> <!--输出实体[HRCONTRACT]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrcontract-137-5"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrcontract-137-6">
<createTable tableName="T_HRCONTRACT"> <createTable tableName="T_HRCONTRACT">
<column name="CREATEMAN" remarks="" type="VARCHAR(60)"> <column name="CREATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -184,7 +222,7 @@ ...@@ -184,7 +222,7 @@
<!--输出实体[HRDISTRIBUTION]数据结构 --> <!--输出实体[HRDISTRIBUTION]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrdistribution-39-6"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrdistribution-39-7">
<createTable tableName="T_HRDISTRIBUTION"> <createTable tableName="T_HRDISTRIBUTION">
<column name="UPDATEMAN" remarks="" type="VARCHAR(60)"> <column name="UPDATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -214,7 +252,7 @@ ...@@ -214,7 +252,7 @@
<!--输出实体[HRDUTY]数据结构 --> <!--输出实体[HRDUTY]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrduty-67-7"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrduty-67-8">
<createTable tableName="T_HRDUTY"> <createTable tableName="T_HRDUTY">
<column name="HRDUTYID" remarks="" type="VARCHAR(100)"> <column name="HRDUTYID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRDUTY_HRDUTYID"/> <constraints primaryKey="true" primaryKeyName="PK_HRDUTY_HRDUTYID"/>
...@@ -236,7 +274,7 @@ ...@@ -236,7 +274,7 @@
<!--输出实体[HRDUTYCERT]数据结构 --> <!--输出实体[HRDUTYCERT]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrdutycert-23-8"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrdutycert-23-9">
<createTable tableName="T_HRDUTYCERT"> <createTable tableName="T_HRDUTYCERT">
<column name="HRDUTYCERTNAME" remarks="" type="VARCHAR(200)"> <column name="HRDUTYCERTNAME" remarks="" type="VARCHAR(200)">
</column> </column>
...@@ -262,7 +300,7 @@ ...@@ -262,7 +300,7 @@
<!--输出实体[HRDUTYEDU]数据结构 --> <!--输出实体[HRDUTYEDU]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrdutyedu-22-9"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrdutyedu-22-10">
<createTable tableName="T_HRDUTYEDU"> <createTable tableName="T_HRDUTYEDU">
<column name="HRDUTYEDUID" remarks="" type="VARCHAR(100)"> <column name="HRDUTYEDUID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRDUTYEDU_HRDUTYEDUID"/> <constraints primaryKey="true" primaryKeyName="PK_HRDUTYEDU_HRDUTYEDUID"/>
...@@ -288,7 +326,7 @@ ...@@ -288,7 +326,7 @@
<!--输出实体[HRDUTYSKILL]数据结构 --> <!--输出实体[HRDUTYSKILL]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrdutyskill-21-10"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrdutyskill-21-11">
<createTable tableName="T_HRDUTYSKILL"> <createTable tableName="T_HRDUTYSKILL">
<column name="HRDUTYSKILLNAME" remarks="" type="VARCHAR(200)"> <column name="HRDUTYSKILLNAME" remarks="" type="VARCHAR(200)">
</column> </column>
...@@ -314,7 +352,7 @@ ...@@ -314,7 +352,7 @@
<!--输出实体[HREDUCATION]数据结构 --> <!--输出实体[HREDUCATION]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hreducation-44-11"> <changeSet author="a_LAB01_e85d8801c" id="tab-hreducation-44-12">
<createTable tableName="T_HREDUCATION"> <createTable tableName="T_HREDUCATION">
<column name="HREDUCATIONID" remarks="" type="VARCHAR(100)"> <column name="HREDUCATIONID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HREDUCATION_HREDUCATIONID"/> <constraints primaryKey="true" primaryKeyName="PK_HREDUCATION_HREDUCATIONID"/>
...@@ -364,7 +402,7 @@ ...@@ -364,7 +402,7 @@
<!--输出实体[HREMPSTATE]数据结构 --> <!--输出实体[HREMPSTATE]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrempstate-18-12"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrempstate-18-13">
<createTable tableName="T_HREMPSTATE"> <createTable tableName="T_HREMPSTATE">
<column name="CREATEMAN" remarks="" type="VARCHAR(60)"> <column name="CREATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -390,7 +428,7 @@ ...@@ -390,7 +428,7 @@
<!--输出实体[HREMPLOYEE]数据结构 --> <!--输出实体[HREMPLOYEE]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hremployee-291-13"> <changeSet author="a_LAB01_e85d8801c" id="tab-hremployee-291-14">
<createTable tableName="EMPLOYEE"> <createTable tableName="EMPLOYEE">
<column name="EMPLOYEENAME" remarks="" type="VARCHAR(200)"> <column name="EMPLOYEENAME" remarks="" type="VARCHAR(200)">
</column> </column>
...@@ -474,7 +512,7 @@ ...@@ -474,7 +512,7 @@
<!--输出实体[HRFAMILY]数据结构 --> <!--输出实体[HRFAMILY]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrfamily-23-14"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrfamily-23-15">
<createTable tableName="T_HRFAMILY"> <createTable tableName="T_HRFAMILY">
<column name="CREATEDATE" remarks="" type="DATETIME"> <column name="CREATEDATE" remarks="" type="DATETIME">
</column> </column>
...@@ -514,7 +552,7 @@ ...@@ -514,7 +552,7 @@
<!--输出实体[HRLANGUAGEABILITY]数据结构 --> <!--输出实体[HRLANGUAGEABILITY]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrlanguageability-17-15"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrlanguageability-17-16">
<createTable tableName="T_HRLANGUAGEABILITY"> <createTable tableName="T_HRLANGUAGEABILITY">
<column name="UPDATEMAN" remarks="" type="VARCHAR(60)"> <column name="UPDATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -544,7 +582,7 @@ ...@@ -544,7 +582,7 @@
<!--输出实体[HRLEAVE]数据结构 --> <!--输出实体[HRLEAVE]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrleave-3-16"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrleave-3-17">
<createTable tableName="LEAVE"> <createTable tableName="LEAVE">
<column name="UPDATEDATE" remarks="" type="DATETIME"> <column name="UPDATEDATE" remarks="" type="DATETIME">
</column> </column>
...@@ -564,7 +602,7 @@ ...@@ -564,7 +602,7 @@
<!--输出实体[HRLEGAL]数据结构 --> <!--输出实体[HRLEGAL]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrlegal-90-17"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrlegal-90-18">
<createTable tableName="LEGAL"> <createTable tableName="LEGAL">
<column name="LEGALNAME" remarks="" type="VARCHAR(200)"> <column name="LEGALNAME" remarks="" type="VARCHAR(200)">
</column> </column>
...@@ -590,7 +628,7 @@ ...@@ -590,7 +628,7 @@
<!--输出实体[HROMHIERARCHYPURPOSE]数据结构 --> <!--输出实体[HROMHIERARCHYPURPOSE]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hromhierarchypurpose-11-18"> <changeSet author="a_LAB01_e85d8801c" id="tab-hromhierarchypurpose-11-19">
<createTable tableName="OMHIERARCHYPURPOSE"> <createTable tableName="OMHIERARCHYPURPOSE">
<column name="UPDATEDATE" remarks="" type="DATETIME"> <column name="UPDATEDATE" remarks="" type="DATETIME">
</column> </column>
...@@ -610,7 +648,7 @@ ...@@ -610,7 +648,7 @@
<!--输出实体[HROMHIERARCHY]数据结构 --> <!--输出实体[HROMHIERARCHY]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hromhierarchy-76-19"> <changeSet author="a_LAB01_e85d8801c" id="tab-hromhierarchy-76-20">
<createTable tableName="OMHIERARCHY"> <createTable tableName="OMHIERARCHY">
<column name="CREATEDATE" remarks="" type="DATETIME"> <column name="CREATEDATE" remarks="" type="DATETIME">
</column> </column>
...@@ -638,7 +676,7 @@ ...@@ -638,7 +676,7 @@
<!--输出实体[HROMHIERARCHYCAT]数据结构 --> <!--输出实体[HROMHIERARCHYCAT]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hromhierarchycat-99-20"> <changeSet author="a_LAB01_e85d8801c" id="tab-hromhierarchycat-99-21">
<createTable tableName="OMHIERARCHYCAT"> <createTable tableName="OMHIERARCHYCAT">
<column name="OMHIERARCHYCATID" remarks="" type="VARCHAR(100)"> <column name="OMHIERARCHYCATID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HROMHIERARCHYCAT_OMHIERARCH"/> <constraints primaryKey="true" primaryKeyName="PK_HROMHIERARCHYCAT_OMHIERARCH"/>
...@@ -660,7 +698,7 @@ ...@@ -660,7 +698,7 @@
<!--输出实体[HROMHIERARCHYPURPOSEREF]数据结构 --> <!--输出实体[HROMHIERARCHYPURPOSEREF]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hromhierarchypurposeref-6-21"> <changeSet author="a_LAB01_e85d8801c" id="tab-hromhierarchypurposeref-6-22">
<createTable tableName="OMHIERARCHYPURPOSEREF"> <createTable tableName="OMHIERARCHYPURPOSEREF">
<column name="UPDATEMAN" remarks="" type="VARCHAR(60)"> <column name="UPDATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -684,7 +722,7 @@ ...@@ -684,7 +722,7 @@
<!--输出实体[HROPERATIONUNIT]数据结构 --> <!--输出实体[HROPERATIONUNIT]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hroperationunit-64-22"> <changeSet author="a_LAB01_e85d8801c" id="tab-hroperationunit-64-23">
<createTable tableName="OPERATIONUNIT"> <createTable tableName="OPERATIONUNIT">
<column name="UPDATEDATE" remarks="" type="DATETIME"> <column name="UPDATEDATE" remarks="" type="DATETIME">
</column> </column>
...@@ -704,7 +742,7 @@ ...@@ -704,7 +742,7 @@
<!--输出实体[HRORGADDRESS]数据结构 --> <!--输出实体[HRORGADDRESS]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrorgaddress-29-23"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrorgaddress-29-24">
<createTable tableName="T_HRORGADDRESS"> <createTable tableName="T_HRORGADDRESS">
<column name="HRORGADDRESSNAME" remarks="" type="VARCHAR(200)"> <column name="HRORGADDRESSNAME" remarks="" type="VARCHAR(200)">
</column> </column>
...@@ -734,7 +772,7 @@ ...@@ -734,7 +772,7 @@
<!--输出实体[HRORGCONTACT]数据结构 --> <!--输出实体[HRORGCONTACT]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrorgcontact-24-24"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrorgcontact-24-25">
<createTable tableName="T_HRORGCONTACT"> <createTable tableName="T_HRORGCONTACT">
<column name="CREATEMAN" remarks="" type="VARCHAR(60)"> <column name="CREATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -762,7 +800,7 @@ ...@@ -762,7 +800,7 @@
<!--输出实体[HRORGANIZATION]数据结构 --> <!--输出实体[HRORGANIZATION]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrorganization-37-25"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrorganization-37-26">
<createTable tableName="ORGANIZATION"> <createTable tableName="ORGANIZATION">
<column name="UPDATEMAN" remarks="" type="VARCHAR(60)"> <column name="UPDATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -796,7 +834,7 @@ ...@@ -796,7 +834,7 @@
<!--输出实体[HRPAPER]数据结构 --> <!--输出实体[HRPAPER]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrpaper-16-26"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrpaper-16-27">
<createTable tableName="T_HRPAPER"> <createTable tableName="T_HRPAPER">
<column name="HRPAPERID" remarks="" type="VARCHAR(100)"> <column name="HRPAPERID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRPAPER_HRPAPERID"/> <constraints primaryKey="true" primaryKeyName="PK_HRPAPER_HRPAPERID"/>
...@@ -830,7 +868,7 @@ ...@@ -830,7 +868,7 @@
<!--输出实体[HRPATENT]数据结构 --> <!--输出实体[HRPATENT]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrpatent-17-27"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrpatent-17-28">
<createTable tableName="T_HRPATENT"> <createTable tableName="T_HRPATENT">
<column name="HRPATENTID" remarks="" type="VARCHAR(100)"> <column name="HRPATENTID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRPATENT_HRPATENTID"/> <constraints primaryKey="true" primaryKeyName="PK_HRPATENT_HRPATENTID"/>
...@@ -860,7 +898,7 @@ ...@@ -860,7 +898,7 @@
<!--输出实体[HRPOST]数据结构 --> <!--输出实体[HRPOST]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrpost-110-28"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrpost-110-29">
<createTable tableName="T_HRPOST"> <createTable tableName="T_HRPOST">
<column name="HRPOSTID" remarks="" type="VARCHAR(100)"> <column name="HRPOSTID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRPOST_HRPOSTID"/> <constraints primaryKey="true" primaryKeyName="PK_HRPOST_HRPOSTID"/>
...@@ -894,7 +932,7 @@ ...@@ -894,7 +932,7 @@
<!--输出实体[HRPOSTREL]数据结构 --> <!--输出实体[HRPOSTREL]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrpostrel-29-29"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrpostrel-29-30">
<createTable tableName="T_HRPOSTREL"> <createTable tableName="T_HRPOSTREL">
<column name="CREATEMAN" remarks="" type="VARCHAR(60)"> <column name="CREATEMAN" remarks="" type="VARCHAR(60)">
</column> </column>
...@@ -922,7 +960,7 @@ ...@@ -922,7 +960,7 @@
<!--输出实体[HRRESEARCH]数据结构 --> <!--输出实体[HRRESEARCH]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrresearch-14-30"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrresearch-14-31">
<createTable tableName="T_HRRESEARCH"> <createTable tableName="T_HRRESEARCH">
<column name="HRRESEARCHID" remarks="" type="VARCHAR(100)"> <column name="HRRESEARCHID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRRESEARCH_HRRESEARCHID"/> <constraints primaryKey="true" primaryKeyName="PK_HRRESEARCH_HRRESEARCHID"/>
...@@ -948,7 +986,7 @@ ...@@ -948,7 +986,7 @@
<!--输出实体[HRREWARD]数据结构 --> <!--输出实体[HRREWARD]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrreward-19-31"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrreward-19-32">
<createTable tableName="T_HRREWARD"> <createTable tableName="T_HRREWARD">
<column name="HRREWARDNAME" remarks="" type="VARCHAR(200)"> <column name="HRREWARDNAME" remarks="" type="VARCHAR(200)">
</column> </column>
...@@ -984,7 +1022,7 @@ ...@@ -984,7 +1022,7 @@
<!--输出实体[HRTECHNICALTITLE]数据结构 --> <!--输出实体[HRTECHNICALTITLE]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrtechnicaltitle-88-32"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrtechnicaltitle-88-33">
<createTable tableName="T_HRTECHNICALTITLE"> <createTable tableName="T_HRTECHNICALTITLE">
<column name="HRTECHNICALTITLEID" remarks="" type="VARCHAR(100)"> <column name="HRTECHNICALTITLEID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRTECHNICALTITLE_HRTECHNICA"/> <constraints primaryKey="true" primaryKeyName="PK_HRTECHNICALTITLE_HRTECHNICA"/>
...@@ -1024,7 +1062,7 @@ ...@@ -1024,7 +1062,7 @@
<!--输出实体[HRTRAININGRECORD]数据结构 --> <!--输出实体[HRTRAININGRECORD]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrtrainingrecord-8-33"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrtrainingrecord-8-34">
<createTable tableName="T_HRTRAININGRECORD"> <createTable tableName="T_HRTRAININGRECORD">
<column name="HRTRAININGRECORDID" remarks="" type="VARCHAR(100)"> <column name="HRTRAININGRECORDID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRTRAININGRECORD_HRTRAINING"/> <constraints primaryKey="true" primaryKeyName="PK_HRTRAININGRECORD_HRTRAINING"/>
...@@ -1046,7 +1084,7 @@ ...@@ -1046,7 +1084,7 @@
<!--输出实体[HRTRANSFERAPPLY]数据结构 --> <!--输出实体[HRTRANSFERAPPLY]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrtransferapply-205-34"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrtransferapply-205-35">
<createTable tableName="T_HRTRANSFERAPPLY"> <createTable tableName="T_HRTRANSFERAPPLY">
<column name="HRTRANSFERAPPLYID" remarks="" type="VARCHAR(100)"> <column name="HRTRANSFERAPPLYID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRTRANSFERAPPLY_HRTRANSFERA"/> <constraints primaryKey="true" primaryKeyName="PK_HRTRANSFERAPPLY_HRTRANSFERA"/>
...@@ -1092,7 +1130,7 @@ ...@@ -1092,7 +1130,7 @@
<!--输出实体[HRWORKRECORD]数据结构 --> <!--输出实体[HRWORKRECORD]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-hrworkrecord-16-35"> <changeSet author="a_LAB01_e85d8801c" id="tab-hrworkrecord-16-36">
<createTable tableName="T_HRWORKRECORD"> <createTable tableName="T_HRWORKRECORD">
<column name="HRWORKRECORDID" remarks="" type="VARCHAR(100)"> <column name="HRWORKRECORDID" remarks="" type="VARCHAR(100)">
<constraints primaryKey="true" primaryKeyName="PK_HRWORKRECORD_HRWORKRECORDID"/> <constraints primaryKey="true" primaryKeyName="PK_HRWORKRECORD_HRWORKRECORDID"/>
...@@ -1127,149 +1165,156 @@ ...@@ -1127,149 +1165,156 @@
</changeSet> </changeSet>
<!--输出实体[HRARCHIVES]外键关系 --> <!--输出实体[HRARCHIVES]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrarchives-104-36"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrarchives-106-37">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRARCHIVES" constraintName="DER1N_HRARCHIVES_HREMPLOYEE_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRARCHIVES" constraintName="DER1N_HRARCHIVES_HREMPLOYEE_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hrarchives-104-37"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrarchives-106-38">
<addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID" baseTableName="T_HRARCHIVES" constraintName="DER1N_HRARCHIVES_HRORGANIZATIO" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID" baseTableName="T_HRARCHIVES" constraintName="DER1N_HRARCHIVES_HRORGANIZATIO" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRARCHIVESBORROW]外键关系 --> <!--输出实体[HRARCHIVESBORROW]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrarchivesborrow-11-39">
<addForeignKeyConstraint baseColumnNames="HRARCHIVESID" baseTableName="T_HRARCHIVESBORROW" constraintName="DER1N_HRARCHIVESBORROW_HRARCHI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRARCHIVESID" referencedTableName="T_HRARCHIVES" validate="true"/>
</changeSet>
<!--输出实体[HRARCHIVESMOVE]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrarchivesmove-3-40">
<addForeignKeyConstraint baseColumnNames="HRARCHIVESID" baseTableName="T_HRARCHIVESMOVE" constraintName="DER1N_HRARCHIVESMOVE_HRARCHIVE" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRARCHIVESID" referencedTableName="T_HRARCHIVES" validate="true"/>
</changeSet>
<!--输出实体[HRATTENDANCE]外键关系 --> <!--输出实体[HRATTENDANCE]外键关系 -->
<!--输出实体[HRCERTIFICATE]外键关系 --> <!--输出实体[HRCERTIFICATE]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrcertificate-93-38"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrcertificate-93-41">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRCERTIFICATE" constraintName="DER1N_HRCERTIFICATE_HREMPLOYEE" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRCERTIFICATE" constraintName="DER1N_HRCERTIFICATE_HREMPLOYEE" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hrcertificate-93-39"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrcertificate-93-42">
<addForeignKeyConstraint baseColumnNames="REGISTERORGANIZATIONID" baseTableName="T_HRCERTIFICATE" constraintName="DER1N_HRCERTIFICATE_HRORGANIZA" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="REGISTERORGANIZATIONID" baseTableName="T_HRCERTIFICATE" constraintName="DER1N_HRCERTIFICATE_HRORGANIZA" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRCONTRACT]外键关系 --> <!--输出实体[HRCONTRACT]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrcontract-137-40"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrcontract-137-43">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRCONTRACT" constraintName="DER1N_HRCONTRACT_HREMPLOYEE_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRCONTRACT" constraintName="DER1N_HRCONTRACT_HREMPLOYEE_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hrcontract-137-41"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrcontract-137-44">
<addForeignKeyConstraint baseColumnNames="MGRORGANIZATIONID" baseTableName="T_HRCONTRACT" constraintName="DER1N_HRCONTRACT_HRORGANIZATIO" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="MGRORGANIZATIONID" baseTableName="T_HRCONTRACT" constraintName="DER1N_HRCONTRACT_HRORGANIZATIO" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRDISTRIBUTION]外键关系 --> <!--输出实体[HRDISTRIBUTION]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrdistribution-39-43"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrdistribution-39-46">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRDISTRIBUTION" constraintName="DER1N_HRDISTRIBUTION_HREMPLOYE" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRDISTRIBUTION" constraintName="DER1N_HRDISTRIBUTION_HREMPLOYE" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hrdistribution-39-44"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrdistribution-39-47">
<addForeignKeyConstraint baseColumnNames="HRPOSTID" baseTableName="T_HRDISTRIBUTION" constraintName="DER1N_HRDISTRIBUTION_HRPOST_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRPOSTID" baseTableName="T_HRDISTRIBUTION" constraintName="DER1N_HRDISTRIBUTION_HRPOST_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRDUTY]外键关系 --> <!--输出实体[HRDUTY]外键关系 -->
<!--输出实体[HRDUTYCERT]外键关系 --> <!--输出实体[HRDUTYCERT]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrdutycert-23-45"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrdutycert-23-48">
<addForeignKeyConstraint baseColumnNames="HRDUTYID" baseTableName="T_HRDUTYCERT" constraintName="DER1N_HRDUTYCERT_HRDUTY_HRDUTY" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRDUTYID" referencedTableName="T_HRDUTY" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRDUTYID" baseTableName="T_HRDUTYCERT" constraintName="DER1N_HRDUTYCERT_HRDUTY_HRDUTY" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRDUTYID" referencedTableName="T_HRDUTY" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRDUTYEDU]外键关系 --> <!--输出实体[HRDUTYEDU]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrdutyedu-22-46"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrdutyedu-22-49">
<addForeignKeyConstraint baseColumnNames="HRDUTYID" baseTableName="T_HRDUTYEDU" constraintName="DER1N_HRDUTYEDU_HRDUTY_HRDUTYI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRDUTYID" referencedTableName="T_HRDUTY" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRDUTYID" baseTableName="T_HRDUTYEDU" constraintName="DER1N_HRDUTYEDU_HRDUTY_HRDUTYI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRDUTYID" referencedTableName="T_HRDUTY" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRDUTYSKILL]外键关系 --> <!--输出实体[HRDUTYSKILL]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrdutyskill-21-47"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrdutyskill-21-50">
<addForeignKeyConstraint baseColumnNames="HRDUTYID" baseTableName="T_HRDUTYSKILL" constraintName="DER1N_HRDUTYSKILL_HRDUTY_HRDUT" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRDUTYID" referencedTableName="T_HRDUTY" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRDUTYID" baseTableName="T_HRDUTYSKILL" constraintName="DER1N_HRDUTYSKILL_HRDUTY_HRDUT" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRDUTYID" referencedTableName="T_HRDUTY" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HREDUCATION]外键关系 --> <!--输出实体[HREDUCATION]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hreducation-44-48"> <changeSet author="a_LAB01_e85d8801c" id="fk-hreducation-44-51">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HREDUCATION" constraintName="DER1N_HREDUCATION_HREMPLOYEE_H" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HREDUCATION" constraintName="DER1N_HREDUCATION_HREMPLOYEE_H" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HREMPSTATE]外键关系 --> <!--输出实体[HREMPSTATE]外键关系 -->
<!--输出实体[HREMPLOYEE]外键关系 --> <!--输出实体[HREMPLOYEE]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hremployee-291-49"> <changeSet author="a_LAB01_e85d8801c" id="fk-hremployee-291-52">
<addForeignKeyConstraint baseColumnNames="ORGANIZATIONID" baseTableName="EMPLOYEE" constraintName="DER1N_EMPLOYEE_ORGANIZATION_OR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="ORGANIZATIONID" baseTableName="EMPLOYEE" constraintName="DER1N_EMPLOYEE_ORGANIZATION_OR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hremployee-291-50"> <changeSet author="a_LAB01_e85d8801c" id="fk-hremployee-291-53">
<addForeignKeyConstraint baseColumnNames="EMPSTATE" baseTableName="EMPLOYEE" constraintName="DER1N_HREMPLOYEE_HREMPSTATE_EM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HREMPSTATEID" referencedTableName="T_HREMPSTATE" validate="true"/> <addForeignKeyConstraint baseColumnNames="EMPSTATE" baseTableName="EMPLOYEE" constraintName="DER1N_HREMPLOYEE_HREMPSTATE_EM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HREMPSTATEID" referencedTableName="T_HREMPSTATE" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hremployee-291-51"> <changeSet author="a_LAB01_e85d8801c" id="fk-hremployee-291-54">
<addForeignKeyConstraint baseColumnNames="HRPOSTID" baseTableName="EMPLOYEE" constraintName="DER1N_HREMPLOYEE_HRPOST_HRPOST" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRPOSTID" baseTableName="EMPLOYEE" constraintName="DER1N_HREMPLOYEE_HRPOST_HRPOST" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRFAMILY]外键关系 --> <!--输出实体[HRFAMILY]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrfamily-23-52"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrfamily-23-55">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRFAMILY" constraintName="DER1N_HRFAMILY_HREMPLOYEE_HREM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRFAMILY" constraintName="DER1N_HRFAMILY_HREMPLOYEE_HREM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRLANGUAGEABILITY]外键关系 --> <!--输出实体[HRLANGUAGEABILITY]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrlanguageability-17-53"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrlanguageability-17-56">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRLANGUAGEABILITY" constraintName="DER1N_HRLANGUAGEABILITY_HREMPL" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRLANGUAGEABILITY" constraintName="DER1N_HRLANGUAGEABILITY_HREMPL" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRLEAVE]外键关系 --> <!--输出实体[HRLEAVE]外键关系 -->
<!--输出实体[HRLEGAL]外键关系 --> <!--输出实体[HRLEGAL]外键关系 -->
<!--输出实体[HROMHIERARCHYPURPOSE]外键关系 --> <!--输出实体[HROMHIERARCHYPURPOSE]外键关系 -->
<!--输出实体[HROMHIERARCHY]外键关系 --> <!--输出实体[HROMHIERARCHY]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hromhierarchy-76-54"> <changeSet author="a_LAB01_e85d8801c" id="fk-hromhierarchy-76-57">
<addForeignKeyConstraint baseColumnNames="HROMHIERARCHYCATID" baseTableName="OMHIERARCHY" constraintName="DER1N_HROMHIERARCHY_HROMHIERAR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="OMHIERARCHYCATID" referencedTableName="OMHIERARCHYCAT" validate="true"/> <addForeignKeyConstraint baseColumnNames="HROMHIERARCHYCATID" baseTableName="OMHIERARCHY" constraintName="DER1N_HROMHIERARCHY_HROMHIERAR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="OMHIERARCHYCATID" referencedTableName="OMHIERARCHYCAT" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hromhierarchy-76-55"> <changeSet author="a_LAB01_e85d8801c" id="fk-hromhierarchy-76-58">
<addForeignKeyConstraint baseColumnNames="POMHIERARCHYID" baseTableName="OMHIERARCHY" constraintName="DER1N_OMHIERARCHY_OMHIERARCHY_" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="OMHIERARCHYID" referencedTableName="OMHIERARCHY" validate="true"/> <addForeignKeyConstraint baseColumnNames="POMHIERARCHYID" baseTableName="OMHIERARCHY" constraintName="DER1N_OMHIERARCHY_OMHIERARCHY_" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="OMHIERARCHYID" referencedTableName="OMHIERARCHY" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hromhierarchy-76-56"> <changeSet author="a_LAB01_e85d8801c" id="fk-hromhierarchy-76-59">
<addForeignKeyConstraint baseColumnNames="ORGANIZATIONID" baseTableName="OMHIERARCHY" constraintName="DER1N_OMHIERARCHY_ORGANIZATION" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="ORGANIZATIONID" baseTableName="OMHIERARCHY" constraintName="DER1N_OMHIERARCHY_ORGANIZATION" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HROMHIERARCHYCAT]外键关系 --> <!--输出实体[HROMHIERARCHYCAT]外键关系 -->
<!--输出实体[HROMHIERARCHYPURPOSEREF]外键关系 --> <!--输出实体[HROMHIERARCHYPURPOSEREF]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hromhierarchypurposeref-6-57"> <changeSet author="a_LAB01_e85d8801c" id="fk-hromhierarchypurposeref-6-60">
<addForeignKeyConstraint baseColumnNames="OMHIERARCHYCATID" baseTableName="OMHIERARCHYPURPOSEREF" constraintName="DER1N_OMHIERARCHYPURPOSEREF_OM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="OMHIERARCHYCATID" referencedTableName="OMHIERARCHYCAT" validate="true"/> <addForeignKeyConstraint baseColumnNames="OMHIERARCHYCATID" baseTableName="OMHIERARCHYPURPOSEREF" constraintName="DER1N_OMHIERARCHYPURPOSEREF_OM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="OMHIERARCHYCATID" referencedTableName="OMHIERARCHYCAT" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HROPERATIONUNIT]外键关系 --> <!--输出实体[HROPERATIONUNIT]外键关系 -->
<!--输出实体[HRORGADDRESS]外键关系 --> <!--输出实体[HRORGADDRESS]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrorgaddress-29-59"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrorgaddress-29-62">
<addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID" baseTableName="T_HRORGADDRESS" constraintName="DER1N_HRORGADDRESS_HRORGANIZAT" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID" baseTableName="T_HRORGADDRESS" constraintName="DER1N_HRORGADDRESS_HRORGANIZAT" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRORGCONTACT]外键关系 --> <!--输出实体[HRORGCONTACT]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrorgcontact-24-60"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrorgcontact-24-63">
<addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID" baseTableName="T_HRORGCONTACT" constraintName="DER1N_HRORGCONTACT_HRORGANIZAT" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID" baseTableName="T_HRORGCONTACT" constraintName="DER1N_HRORGCONTACT_HRORGANIZAT" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRORGANIZATION]外键关系 --> <!--输出实体[HRORGANIZATION]外键关系 -->
<!--输出实体[HRPAPER]外键关系 --> <!--输出实体[HRPAPER]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrpaper-16-61"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrpaper-16-64">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRPAPER" constraintName="DER1N_HRPAPER_HREMPLOYEE_HREMP" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRPAPER" constraintName="DER1N_HRPAPER_HREMPLOYEE_HREMP" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRPATENT]外键关系 --> <!--输出实体[HRPATENT]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrpatent-17-62"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrpatent-17-65">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRPATENT" constraintName="DER1N_HRPATENT_HREMPLOYEE_HREM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRPATENT" constraintName="DER1N_HRPATENT_HREMPLOYEE_HREM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRPOST]外键关系 --> <!--输出实体[HRPOST]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrpost-110-63"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrpost-110-66">
<addForeignKeyConstraint baseColumnNames="HRDUTYID" baseTableName="T_HRPOST" constraintName="DER1N_HRPOST_HRDUTY_HRDUTYID" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRDUTYID" referencedTableName="T_HRDUTY" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRDUTYID" baseTableName="T_HRPOST" constraintName="DER1N_HRPOST_HRDUTY_HRDUTYID" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRDUTYID" referencedTableName="T_HRDUTY" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hrpost-110-64"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrpost-110-67">
<addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID" baseTableName="T_HRPOST" constraintName="DER1N_HRPOST_HRORGANIZATION_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID" baseTableName="T_HRPOST" constraintName="DER1N_HRPOST_HRORGANIZATION_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRPOSTREL]外键关系 --> <!--输出实体[HRPOSTREL]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrpostrel-29-65"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrpostrel-29-68">
<addForeignKeyConstraint baseColumnNames="HRPOSTID" baseTableName="T_HRPOSTREL" constraintName="DER1N_HRPOSTREL_HRPOST_HRPOSTI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRPOSTID" baseTableName="T_HRPOSTREL" constraintName="DER1N_HRPOSTREL_HRPOST_HRPOSTI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hrpostrel-29-66"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrpostrel-29-69">
<addForeignKeyConstraint baseColumnNames="PHRPOSTID" baseTableName="T_HRPOSTREL" constraintName="DER1N_HRPOSTREL_HRPOST_PHRPOST" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/> <addForeignKeyConstraint baseColumnNames="PHRPOSTID" baseTableName="T_HRPOSTREL" constraintName="DER1N_HRPOSTREL_HRPOST_PHRPOST" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRRESEARCH]外键关系 --> <!--输出实体[HRRESEARCH]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrresearch-14-67"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrresearch-14-70">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRRESEARCH" constraintName="DER1N_HRRESEARCH_HREMPLOYEE_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRRESEARCH" constraintName="DER1N_HRRESEARCH_HREMPLOYEE_HR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRREWARD]外键关系 --> <!--输出实体[HRREWARD]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrreward-19-68"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrreward-19-71">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRREWARD" constraintName="DER1N_HRREWARD_HREMPLOYEE_HREM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRREWARD" constraintName="DER1N_HRREWARD_HREMPLOYEE_HREM" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRTECHNICALTITLE]外键关系 --> <!--输出实体[HRTECHNICALTITLE]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrtechnicaltitle-88-69"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrtechnicaltitle-88-72">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRTECHNICALTITLE" constraintName="DER1N_HRTECHNICALTITLE_HREMPLO" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRTECHNICALTITLE" constraintName="DER1N_HRTECHNICALTITLE_HREMPLO" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRTRAININGRECORD]外键关系 --> <!--输出实体[HRTRAININGRECORD]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrtrainingrecord-8-70"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrtrainingrecord-8-73">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRTRAININGRECORD" constraintName="DER1N_HRTRAININGRECORD_HREMPLO" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRTRAININGRECORD" constraintName="DER1N_HRTRAININGRECORD_HREMPLO" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRTRANSFERAPPLY]外键关系 --> <!--输出实体[HRTRANSFERAPPLY]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrtransferapply-205-71"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrtransferapply-205-74">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRTRANSFERAPPLY" constraintName="DER1N_HRTRANSFERAPPLY_HREMPLOY" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRTRANSFERAPPLY" constraintName="DER1N_HRTRANSFERAPPLY_HREMPLOY" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hrtransferapply-205-72"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrtransferapply-205-75">
<addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID2" baseTableName="T_HRTRANSFERAPPLY" constraintName="DER1N_HRTRANSFERAPPLY_HRORGANI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRORGANIZATIONID2" baseTableName="T_HRTRANSFERAPPLY" constraintName="DER1N_HRTRANSFERAPPLY_HRORGANI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ORGANIZATIONID" referencedTableName="ORGANIZATION" validate="true"/>
</changeSet> </changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-hrtransferapply-205-73"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrtransferapply-205-76">
<addForeignKeyConstraint baseColumnNames="HRPOSTID2" baseTableName="T_HRTRANSFERAPPLY" constraintName="DER1N_HRTRANSFERAPPLY_HRPOST_H" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/> <addForeignKeyConstraint baseColumnNames="HRPOSTID2" baseTableName="T_HRTRANSFERAPPLY" constraintName="DER1N_HRTRANSFERAPPLY_HRPOST_H" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="HRPOSTID" referencedTableName="T_HRPOST" validate="true"/>
</changeSet> </changeSet>
<!--输出实体[HRWORKRECORD]外键关系 --> <!--输出实体[HRWORKRECORD]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-hrworkrecord-16-74"> <changeSet author="a_LAB01_e85d8801c" id="fk-hrworkrecord-16-77">
<addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRWORKRECORD" constraintName="DER1N_HRWORKRECORD_HREMPLOYEE_" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/> <addForeignKeyConstraint baseColumnNames="HREMPLOYEEID" baseTableName="T_HRWORKRECORD" constraintName="DER1N_HRWORKRECORD_HREMPLOYEE_" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EMPLOYEEID" referencedTableName="EMPLOYEE" validate="true"/>
</changeSet> </changeSet>
......
...@@ -5,16 +5,26 @@ ...@@ -5,16 +5,26 @@
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性--> <!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="HRArchivesBorrowResultMap" databaseId="mysql"> <select id="selectById" resultMap="HRArchivesBorrowResultMap" databaseId="mysql">
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`HRARCHIVESBORROWID`, t1.`HRARCHIVESBORROWNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESBORROW` t1 ) t1 where hrarchivesborrowid=#{id}]]> <![CDATA[select t1.* from (SELECT t1.`BEGINTIME`, t1.`BORROWMAN`, t1.`BORROWREASON`, t1.`BORROWSTATE`, t1.`CHECKMAN`, t1.`CHECKTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`ENDTIME`, t1.`HRARCHIVESBORROWID`, t1.`HRARCHIVESBORROWNAME`, t1.`HRARCHIVESID`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESBORROW` t1 ) t1 where hrarchivesborrowid=#{id}]]>
</select> </select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 --> <!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
<resultMap id="HRArchivesBorrowResultMap" type="cn.ibizlab.humanresource.core.humanresource.domain.HRArchivesBorrow" autoMapping="true"> <resultMap id="HRArchivesBorrowResultMap" type="cn.ibizlab.humanresource.core.humanresource.domain.HRArchivesBorrow" autoMapping="true">
<id property="hrarchivesborrowid" column="hrarchivesborrowid" /><!--主键字段映射--> <id property="hrarchivesborrowid" column="hrarchivesborrowid" /><!--主键字段映射-->
<result property="hrarchivesid" column="hrarchivesid" />
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="hrarchives" javaType="cn.ibizlab.humanresource.core.humanresource.domain.HRArchives" column="hrarchivesid" select="cn.ibizlab.humanresource.core.humanresource.mapper.HRArchivesMapper.selectById" fetchType="lazy"></association>
</resultMap> </resultMap>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_HRARCHIVESBORROW_HRARCHIVES_HRARCHIVESID] -->
<select id="selectByHrarchivesid" resultMap="HRArchivesBorrowResultMap">
select t1.* from (
<include refid="Default" />
) t1
where hrarchivesid=#{hrarchivesid}
</select>
<!--数据集合[Default]--> <!--数据集合[Default]-->
<select id="searchDefault" parameterType="cn.ibizlab.humanresource.core.humanresource.filter.HRArchivesBorrowSearchContext" resultMap="HRArchivesBorrowResultMap"> <select id="searchDefault" parameterType="cn.ibizlab.humanresource.core.humanresource.filter.HRArchivesBorrowSearchContext" resultMap="HRArchivesBorrowResultMap">
...@@ -27,12 +37,12 @@ ...@@ -27,12 +37,12 @@
<!--数据查询[Default]--> <!--数据查询[Default]-->
<sql id="Default" databaseId="mysql"> <sql id="Default" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`HRARCHIVESBORROWID`, t1.`HRARCHIVESBORROWNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESBORROW` t1 <![CDATA[ SELECT t1.`BEGINTIME`, t1.`BORROWMAN`, t1.`BORROWREASON`, t1.`BORROWSTATE`, t1.`CHECKMAN`, t1.`CHECKTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`ENDTIME`, t1.`HRARCHIVESBORROWID`, t1.`HRARCHIVESBORROWNAME`, t1.`HRARCHIVESID`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESBORROW` t1
]]> ]]>
</sql> </sql>
<!--数据查询[View]--> <!--数据查询[View]-->
<sql id="View" databaseId="mysql"> <sql id="View" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`HRARCHIVESBORROWID`, t1.`HRARCHIVESBORROWNAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESBORROW` t1 <![CDATA[ SELECT t1.`BEGINTIME`, t1.`BORROWMAN`, t1.`BORROWREASON`, t1.`BORROWSTATE`, t1.`CHECKMAN`, t1.`CHECKTIME`, t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`ENDTIME`, t1.`HRARCHIVESBORROWID`, t1.`HRARCHIVESBORROWNAME`, t1.`HRARCHIVESID`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESBORROW` t1
]]> ]]>
</sql> </sql>
</mapper> </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.humanresource.core.humanresource.mapper.HRArchivesMoveMapper">
<!--该方法用于重写mybatis中selectById方法,以实现查询逻辑属性-->
<select id="selectById" resultMap="HRArchivesMoveResultMap" databaseId="mysql">
<![CDATA[select t1.* from (SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`HRARCHIVESID`, t1.`HRARCHIVESMOVEID`, t1.`HRARCHIVESMOVENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESMOVE` t1 ) t1 where hrarchivesmoveid=#{id}]]>
</select>
<!--通过mybatis将查询结果注入到entity中,通过配置autoMapping="true"由mybatis自动处理映射关系 -->
<resultMap id="HRArchivesMoveResultMap" type="cn.ibizlab.humanresource.core.humanresource.domain.HRArchivesMove" autoMapping="true">
<id property="hrarchivesmoveid" column="hrarchivesmoveid" /><!--主键字段映射-->
<result property="hrarchivesid" column="hrarchivesid" />
<!--通过mybatis自动注入关系属性[主实体],fetchType="lazy"为懒加载配置 -->
<association property="hrarchives" javaType="cn.ibizlab.humanresource.core.humanresource.domain.HRArchives" column="hrarchivesid" select="cn.ibizlab.humanresource.core.humanresource.mapper.HRArchivesMapper.selectById" fetchType="lazy"></association>
</resultMap>
<!--关系实体暴露select方法供主实体通过外键查询关系实体数据[实体关系名称:DER1N_HRARCHIVESMOVE_HRARCHIVES_HRARCHIVESID] -->
<select id="selectByHrarchivesid" resultMap="HRArchivesMoveResultMap">
select t1.* from (
<include refid="Default" />
) t1
where hrarchivesid=#{hrarchivesid}
</select>
<!--数据集合[Default]-->
<select id="searchDefault" parameterType="cn.ibizlab.humanresource.core.humanresource.filter.HRArchivesMoveSearchContext" resultMap="HRArchivesMoveResultMap">
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.`HRARCHIVESID`, t1.`HRARCHIVESMOVEID`, t1.`HRARCHIVESMOVENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESMOVE` t1
]]>
</sql>
<!--数据查询[View]-->
<sql id="View" databaseId="mysql">
<![CDATA[ SELECT t1.`CREATEDATE`, t1.`CREATEMAN`, t1.`HRARCHIVESID`, t1.`HRARCHIVESMOVEID`, t1.`HRARCHIVESMOVENAME`, t1.`UPDATEDATE`, t1.`UPDATEMAN` FROM `T_HRARCHIVESMOVE` t1
]]>
</sql>
</mapper>
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册