Commit df11e6ea authored by 赵啸非's avatar 赵啸非

修改配置文件

parent 65e67146
...@@ -28,14 +28,8 @@ CREATE TABLE `mortals_ent_life_matter` ...@@ -28,14 +28,8 @@ CREATE TABLE `mortals_ent_life_matter`
`id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID,主键,自增长', `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '主键ID,主键,自增长',
`life_cycle_id` bigint(20) DEFAULT NULL COMMENT '企业生命周期id', `life_cycle_id` bigint(20) DEFAULT NULL COMMENT '企业生命周期id',
`life_cycle_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '生命周期名称', `life_cycle_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '生命周期名称',
`matter_id` bigint(20) DEFAULT NULL COMMENT '事项id', `matter_group_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '事项组名称',
`matter_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '事项名称', `dept_id` bigint(20) NULL DEFAULT NULL COMMENT '办理单位数量',
`matter_code` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '事项编码',
`area_code` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '区域编码',
`area_name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '区域名称',
`area_level` tinyint(2) NULL DEFAULT 1 COMMENT '区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)',
`dept_id` bigint(20) NULL DEFAULT NULL COMMENT '办理单位ID',
`dept_name` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '办理单位名称',
`remark` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '备注', `remark` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '备注',
`create_user_id` bigint(20) DEFAULT NULL COMMENT '创建用户', `create_user_id` bigint(20) DEFAULT NULL COMMENT '创建用户',
`create_user_name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建用户名称', `create_user_name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建用户名称',
...@@ -63,6 +57,7 @@ CREATE TABLE `mortals_ent_life_matter_sub` ...@@ -63,6 +57,7 @@ CREATE TABLE `mortals_ent_life_matter_sub`
`area_level` tinyint(2) NULL DEFAULT 1 COMMENT '区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)', `area_level` tinyint(2) NULL DEFAULT 1 COMMENT '区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)',
`dept_id` bigint(20) NULL DEFAULT NULL COMMENT '办理单位ID', `dept_id` bigint(20) NULL DEFAULT NULL COMMENT '办理单位ID',
`dept_name` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '办理单位名称', `dept_name` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '办理单位名称',
`sort` int(4) NULL DEFAULT 0 COMMENT '排序字段',
`remark` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '备注', `remark` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '备注',
`create_user_id` bigint(20) DEFAULT NULL COMMENT '创建用户', `create_user_id` bigint(20) DEFAULT NULL COMMENT '创建用户',
`create_user_name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建用户名称', `create_user_name` varchar(50) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建用户名称',
......
...@@ -105,11 +105,10 @@ public class AuthTokenServiceImpl implements IAuthTokenService { ...@@ -105,11 +105,10 @@ public class AuthTokenServiceImpl implements IAuthTokenService {
Claims claims = parseToken(token); Claims claims = parseToken(token);
String uuid = (String) claims.get(SysConstains.LOGIN_USER_KEY); String uuid = (String) claims.get(SysConstains.LOGIN_USER_KEY);
String userKey = getTokenKey(uuid); String userKey = getTokenKey(uuid);
String userStr = cacheService.get(userKey);
//cacheService.select(portalDb); //cacheService.select(portalDb);
// String userStr = cacheService.get(userKey); // String userStr = cacheService.get(userKey);
/* RedisTemplate<String, String> redisTemplate = cacheService.selectDbRedisTemplate(portalDb); RedisTemplate<String, String> redisTemplate = cacheService.selectDbRedisTemplate(portalDb);
String userStr =redisTemplate.opsForValue().get(userKey);*/ String userStr =redisTemplate.opsForValue().get(userKey);
//刷新token时间 //刷新token时间
UserEntity userEntity = JSONObject.parseObject(userStr, UserEntity.class); UserEntity userEntity = JSONObject.parseObject(userStr, UserEntity.class);
......
package com.mortals.xhx.base.login;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.mortals.framework.common.Rest;
import com.mortals.framework.service.IAuthTokenService;
import com.mortals.framework.service.ICacheService;
import com.mortals.framework.service.IUser;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.login.web.LoginForm;
import com.mortals.xhx.base.system.menu.model.MenuEntity;
import com.mortals.xhx.base.system.menu.service.MenuService;
import com.mortals.xhx.base.system.resource.service.ResourceService;
import com.mortals.xhx.base.system.user.model.UserEntity;
import com.mortals.xhx.base.system.user.service.UserService;
import com.mortals.xhx.common.key.RedisKey;
import com.mortals.xhx.common.pdu.user.LoginPdu;
import com.mortals.xhx.common.utils.MenuEncodeUtil;
import com.mortals.xhx.feign.site.ISiteFeign;
import com.mortals.xhx.feign.user.IUserFeign;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.List;
import java.util.Set;
import static com.mortals.xhx.common.key.ErrorCode.ERROR_TOKEN_EXPIRED;
import static com.mortals.xhx.common.key.ErrorCode.ERROR_TOKEN_EXPIRED_CONTENT;
@RestController
@Slf4j
@RequestMapping("login")
public class LoginController extends BaseCRUDJsonBodyMappingController<UserService, UserEntity, Long> implements InitializingBean {
@Autowired
private ResourceService resourceService;
@Autowired
private MenuService menuService;
@Autowired
private ICacheService cacheService;
@Autowired
private IAuthTokenService authTokenService;
@Autowired
private IUserFeign userFeign;
@Autowired
private ISiteFeign siteFeign;
@RequestMapping("login")
public String login(@RequestBody LoginForm loginForm) throws Exception {
String loginName = loginForm.getLoginName();
String password = loginForm.getPassword();
LoginPdu loginPdu = new LoginPdu();
loginPdu.setLoginName(loginName);
loginPdu.setPassword(password);
loginPdu.setSecurityCode("admin");
String resp = userFeign.portalLogin(loginPdu);
return resp;
}
@RequestMapping("logout")
public void logout(HttpServletRequest request, HttpServletResponse response) throws Exception {
recordSysLog(request, "退出登录");
super.removeCurrUser(request);
}
@RequestMapping("index")
public String index() throws Exception {
JSONObject ret = new JSONObject();
IUser user = this.getCurUser();
if (user == null) {
return JSONObject.toJSONString(Rest.fail(ERROR_TOKEN_EXPIRED, ERROR_TOKEN_EXPIRED_CONTENT));
}
Set<String> urls = resourceService.findUrlSetByUserId(user.getId());
log.info("userId:{},urls:{}", user.getId(), JSON.toJSONString(urls));
// List<MenuEntity> outlookBarList = menuService.findTreeMenu(user, urls);
List<MenuEntity> treeMenuList = menuService.findTreeMenu(user);
String currUserName = user.getRealName();
if (currUserName == null || currUserName.trim().length() == 0) {
currUserName = "管理员";
}
JSONObject data = new JSONObject();
String token = authTokenService.getToken(request);
data.put("token", token);
data.put("currUserName", currUserName);
data.put("menuList", treeMenuList);
data.put("id", user.getId());
data.put("userType", user.getUserType());
ret.put(KEY_RESULT_DATA, data);
cacheService.hset(RedisKey.KEY_USER_MENU_CACHE, user.getId().toString(), MenuEncodeUtil.generateMenuUrlCode(urls));
ret.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
ret.put(KEY_RESULT_MSG, "用户登录系统成功!");
ret.put("resources", urls);
return ret.toJSONString();
}
@Override
public void afterPropertiesSet() throws Exception {
log.info("初始化加载登录。。。");
}
}
package com.mortals.xhx.base.login.interceptor;
import com.mortals.framework.annotation.UnAuth;
import com.mortals.xhx.base.framework.config.InterceptorConfig;
import com.mortals.framework.ap.CookieService;
import com.mortals.framework.ap.SysConstains;
import com.mortals.framework.model.CookieInfo;
import com.mortals.framework.service.ICacheService;
import com.mortals.framework.util.AESUtil;
import com.mortals.framework.util.HttpUtil;
import com.mortals.framework.util.StringUtils;
import com.mortals.framework.web.interceptor.BaseInterceptor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;
import org.springframework.web.method.HandlerMethod;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.lang.reflect.Method;
@Order(1)
//@Component
public class AuthJsonInterceptor extends BaseInterceptor {
@Autowired
private InterceptorConfig config;
@Autowired
private ICacheService cacheService;
@Override
public int getOrder() {
return Integer.MAX_VALUE - 9;
}
@Override
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler)
throws Exception {
try {
HandlerMethod handlerMethod = (HandlerMethod) handler;
Method method = handlerMethod.getMethod();
UnAuth annotation = method.getAnnotation(UnAuth.class);
if (annotation != null) {
//取消校验
return true;
}
String uri = request.getServletPath();
if (config.needCheckAuth(uri)) {
boolean auth = this.checkAuth(request, uri, config.getSecurityKey());
if (!auth) {
CookieInfo cookie = CookieService.getLoginCookie(request, config.getSecurityKey());
if (cookie == null || cookie.getUser() == null) {
writeJsonResponse(response, HttpServletResponse.SC_FORBIDDEN, "用户未登录或登录失效,请重新登录");
return false;
} else if (cookie.getUser().isAdmin()) {
return super.preHandle(request, response, handler);
} else {
writeJsonResponse(response, HttpServletResponse.SC_UNAUTHORIZED, "用户无该操作权限");
return false;
}
}
}
} catch (Exception e) {
logger.error("权限校验拦截请求处理异常-->" + e.getMessage());
writeJsonResponse(response, HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "用户权限校验异常");
return false;
}
return super.preHandle(request, response, handler);
}
private boolean checkAuth(HttpServletRequest request, String requestUrl, String securityKey) throws Exception {
int code = requestUrl.hashCode() & (Integer.MAX_VALUE - 1);
String cacheKey = HttpUtil.getCookieValue(request, SysConstains.COOKIE_MENU);
if (StringUtils.isEmpty(cacheKey)) {
return false;
}
String menuUrl = cacheService.get(cacheKey);
if (StringUtils.isEmpty(menuUrl)) {
return false;
}
menuUrl = AESUtil.decrypt(menuUrl, securityKey);
String codes = "," + menuUrl + ",";
String codeKey = "," + code + ",";
if (codes.indexOf(codeKey) != -1) {
return true;
}
return false;
}
}
package com.mortals.xhx.base.login.interceptor;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.mortals.xhx.base.framework.config.InterceptorConfig;
import org.springframework.beans.factory.annotation.Autowired;
import com.mortals.framework.ap.CookieService;
import com.mortals.framework.model.CookieInfo;
import com.mortals.framework.service.ITokenService;
import com.mortals.framework.web.interceptor.BaseInterceptor;
//@Component
public class LoginJsonInterceptor extends BaseInterceptor {
@Autowired(required = false)
private ITokenService tokenService;
@Autowired
private InterceptorConfig config;
@Override
public int getOrder() {
return Integer.MAX_VALUE - 10;
}
@Override
public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler)
throws Exception {
try {
String uri = request.getServletPath();
if (config.needCheckAuth(uri)) {
CookieInfo cookie = CookieService.getLoginCookie(request, config.getSecurityKey());
boolean expire = true;
try {
if (cookie == null || cookie.getUser() == null
|| (cookie != null && tokenService != null && tokenService.isExpireToken(cookie))) {
expire = true;
} else {
expire = false;
}
} catch (Exception e) {
logger.warn("校验cookie是否过期异常-->原因:" + e.getMessage());
}
// 判断用户是否登录
if (expire) {
CookieService.deleteLoginCookie(request, response);
writeJsonResponse(response, HttpServletResponse.SC_FORBIDDEN, "用户未登录或登录失效,请重新登录111333");
return false;
}
}
} catch (Exception e) {
logger.error("登录校验拦截请求处理异常-->" + e.getMessage());
writeJsonResponse(response, HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "用户登录校验异常");
return false;
}
return super.preHandle(request, response, handler);
}
}
...@@ -12,11 +12,11 @@ import com.mortals.xhx.module.ent.model.vo.EntLifeMatterVo; ...@@ -12,11 +12,11 @@ import com.mortals.xhx.module.ent.model.vo.EntLifeMatterVo;
import com.mortals.xhx.module.ent.model.EntLifeMatterSubEntity; import com.mortals.xhx.module.ent.model.EntLifeMatterSubEntity;
import lombok.Data; import lombok.Data;
/** /**
* 企业周期事项主实体对象 * 企业周期事项主实体对象
* *
* @author zxfei * @author zxfei
* @date 2025-03-15 * @date 2025-03-17
*/ */
@Data @Data
public class EntLifeMatterEntity extends EntLifeMatterVo { public class EntLifeMatterEntity extends EntLifeMatterVo {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
...@@ -30,38 +30,10 @@ public class EntLifeMatterEntity extends EntLifeMatterVo { ...@@ -30,38 +30,10 @@ public class EntLifeMatterEntity extends EntLifeMatterVo {
*/ */
private String lifeCycleName; private String lifeCycleName;
/** /**
* 事项id
*/
private Long matterId;
/**
* 事项名称
*/
private String matterName;
/**
* 事项编码
*/
private String matterCode;
/**
* 区域编码
*/
private String areaCode;
/**
* 区域名称
*/
private String areaName;
/**
* 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
*/
private Integer areaLevel;
/**
* 办理单位ID * 办理单位ID
*/ */
private Long deptId; private Long deptId;
/** /**
* 办理单位名称
*/
private String deptName;
/**
* 备注 * 备注
*/ */
private String remark; private String remark;
...@@ -69,6 +41,10 @@ public class EntLifeMatterEntity extends EntLifeMatterVo { ...@@ -69,6 +41,10 @@ public class EntLifeMatterEntity extends EntLifeMatterVo {
* 创建用户名称 * 创建用户名称
*/ */
private String createUserName; private String createUserName;
/**
* 事项组名称
*/
private String matterGroupName;
/** /**
* 企业周期事项子信息 * 企业周期事项子信息
*/ */
...@@ -99,15 +75,9 @@ public class EntLifeMatterEntity extends EntLifeMatterVo { ...@@ -99,15 +75,9 @@ public class EntLifeMatterEntity extends EntLifeMatterVo {
public void initAttrValue(){ public void initAttrValue(){
this.lifeCycleId = null; this.lifeCycleId = null;
this.lifeCycleName = ""; this.lifeCycleName = "";
this.matterId = null;
this.matterName = "";
this.matterCode = "";
this.areaCode = "";
this.areaName = "";
this.areaLevel = 1;
this.deptId = null; this.deptId = null;
this.deptName = "";
this.remark = ""; this.remark = "";
this.createUserName = ""; this.createUserName = "";
this.matterGroupName = "";
} }
} }
\ No newline at end of file
...@@ -4,11 +4,11 @@ import java.util.List; ...@@ -4,11 +4,11 @@ import java.util.List;
import java.util.List; import java.util.List;
import com.mortals.xhx.module.ent.model.EntLifeMatterEntity; import com.mortals.xhx.module.ent.model.EntLifeMatterEntity;
/** /**
* 企业周期事项主查询对象 * 企业周期事项主查询对象
* *
* @author zxfei * @author zxfei
* @date 2025-03-15 * @date 2025-03-17
*/ */
public class EntLifeMatterQuery extends EntLifeMatterEntity { public class EntLifeMatterQuery extends EntLifeMatterEntity {
/** 开始 主键ID,主键,自增长 */ /** 开始 主键ID,主键,自增长 */
private Long idStart; private Long idStart;
...@@ -45,56 +45,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -45,56 +45,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
/** 生命周期名称排除列表 */ /** 生命周期名称排除列表 */
private List <String> lifeCycleNameNotList; private List <String> lifeCycleNameNotList;
/** 开始 事项id */
private Long matterIdStart;
/** 结束 事项id */
private Long matterIdEnd;
/** 增加 事项id */
private Long matterIdIncrement;
/** 事项id列表 */
private List <Long> matterIdList;
/** 事项id排除列表 */
private List <Long> matterIdNotList;
/** 事项名称 */
private List<String> matterNameList;
/** 事项名称排除列表 */
private List <String> matterNameNotList;
/** 事项编码 */
private List<String> matterCodeList;
/** 事项编码排除列表 */
private List <String> matterCodeNotList;
/** 区域编码 */
private List<String> areaCodeList;
/** 区域编码排除列表 */
private List <String> areaCodeNotList;
/** 区域名称 */
private List<String> areaNameList;
/** 区域名称排除列表 */
private List <String> areaNameNotList;
/** 开始 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区) */
private Integer areaLevelStart;
/** 结束 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区) */
private Integer areaLevelEnd;
/** 增加 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区) */
private Integer areaLevelIncrement;
/** 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)列表 */
private List <Integer> areaLevelList;
/** 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)排除列表 */
private List <Integer> areaLevelNotList;
/** 开始 办理单位ID */ /** 开始 办理单位ID */
private Long deptIdStart; private Long deptIdStart;
...@@ -110,11 +60,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -110,11 +60,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
/** 办理单位ID排除列表 */ /** 办理单位ID排除列表 */
private List <Long> deptIdNotList; private List <Long> deptIdNotList;
/** 办理单位名称 */
private List<String> deptNameList;
/** 办理单位名称排除列表 */
private List <String> deptNameNotList;
/** 备注 */ /** 备注 */
private List<String> remarkList; private List<String> remarkList;
...@@ -152,6 +97,11 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -152,6 +97,11 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
/** 结束 更新时间 */ /** 结束 更新时间 */
private String updateTimeEnd; private String updateTimeEnd;
/** 事项组名称 */
private List<String> matterGroupNameList;
/** 事项组名称排除列表 */
private List <String> matterGroupNameNotList;
/** OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4) */ /** OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4) */
private List<EntLifeMatterQuery> orConditionList; private List<EntLifeMatterQuery> orConditionList;
...@@ -354,296 +304,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -354,296 +304,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
this.lifeCycleNameNotList = lifeCycleNameNotList; this.lifeCycleNameNotList = lifeCycleNameNotList;
} }
/**
* 获取 开始 事项id
* @return matterIdStart
*/
public Long getMatterIdStart(){
return this.matterIdStart;
}
/**
* 设置 开始 事项id
* @param matterIdStart
*/
public void setMatterIdStart(Long matterIdStart){
this.matterIdStart = matterIdStart;
}
/**
* 获取 结束 事项id
* @return $matterIdEnd
*/
public Long getMatterIdEnd(){
return this.matterIdEnd;
}
/**
* 设置 结束 事项id
* @param matterIdEnd
*/
public void setMatterIdEnd(Long matterIdEnd){
this.matterIdEnd = matterIdEnd;
}
/**
* 获取 增加 事项id
* @return matterIdIncrement
*/
public Long getMatterIdIncrement(){
return this.matterIdIncrement;
}
/**
* 设置 增加 事项id
* @param matterIdIncrement
*/
public void setMatterIdIncrement(Long matterIdIncrement){
this.matterIdIncrement = matterIdIncrement;
}
/**
* 获取 事项id
* @return matterIdList
*/
public List<Long> getMatterIdList(){
return this.matterIdList;
}
/**
* 设置 事项id
* @param matterIdList
*/
public void setMatterIdList(List<Long> matterIdList){
this.matterIdList = matterIdList;
}
/**
* 获取 事项id
* @return matterIdNotList
*/
public List<Long> getMatterIdNotList(){
return this.matterIdNotList;
}
/**
* 设置 事项id
* @param matterIdNotList
*/
public void setMatterIdNotList(List<Long> matterIdNotList){
this.matterIdNotList = matterIdNotList;
}
/**
* 获取 事项名称
* @return matterNameList
*/
public List<String> getMatterNameList(){
return this.matterNameList;
}
/**
* 设置 事项名称
* @param matterNameList
*/
public void setMatterNameList(List<String> matterNameList){
this.matterNameList = matterNameList;
}
/**
* 获取 事项名称
* @return matterNameNotList
*/
public List<String> getMatterNameNotList(){
return this.matterNameNotList;
}
/**
* 设置 事项名称
* @param matterNameNotList
*/
public void setMatterNameNotList(List<String> matterNameNotList){
this.matterNameNotList = matterNameNotList;
}
/**
* 获取 事项编码
* @return matterCodeList
*/
public List<String> getMatterCodeList(){
return this.matterCodeList;
}
/**
* 设置 事项编码
* @param matterCodeList
*/
public void setMatterCodeList(List<String> matterCodeList){
this.matterCodeList = matterCodeList;
}
/**
* 获取 事项编码
* @return matterCodeNotList
*/
public List<String> getMatterCodeNotList(){
return this.matterCodeNotList;
}
/**
* 设置 事项编码
* @param matterCodeNotList
*/
public void setMatterCodeNotList(List<String> matterCodeNotList){
this.matterCodeNotList = matterCodeNotList;
}
/**
* 获取 区域编码
* @return areaCodeList
*/
public List<String> getAreaCodeList(){
return this.areaCodeList;
}
/**
* 设置 区域编码
* @param areaCodeList
*/
public void setAreaCodeList(List<String> areaCodeList){
this.areaCodeList = areaCodeList;
}
/**
* 获取 区域编码
* @return areaCodeNotList
*/
public List<String> getAreaCodeNotList(){
return this.areaCodeNotList;
}
/**
* 设置 区域编码
* @param areaCodeNotList
*/
public void setAreaCodeNotList(List<String> areaCodeNotList){
this.areaCodeNotList = areaCodeNotList;
}
/**
* 获取 区域名称
* @return areaNameList
*/
public List<String> getAreaNameList(){
return this.areaNameList;
}
/**
* 设置 区域名称
* @param areaNameList
*/
public void setAreaNameList(List<String> areaNameList){
this.areaNameList = areaNameList;
}
/**
* 获取 区域名称
* @return areaNameNotList
*/
public List<String> getAreaNameNotList(){
return this.areaNameNotList;
}
/**
* 设置 区域名称
* @param areaNameNotList
*/
public void setAreaNameNotList(List<String> areaNameNotList){
this.areaNameNotList = areaNameNotList;
}
/**
* 获取 开始 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @return areaLevelStart
*/
public Integer getAreaLevelStart(){
return this.areaLevelStart;
}
/**
* 设置 开始 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelStart
*/
public void setAreaLevelStart(Integer areaLevelStart){
this.areaLevelStart = areaLevelStart;
}
/**
* 获取 结束 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @return $areaLevelEnd
*/
public Integer getAreaLevelEnd(){
return this.areaLevelEnd;
}
/**
* 设置 结束 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelEnd
*/
public void setAreaLevelEnd(Integer areaLevelEnd){
this.areaLevelEnd = areaLevelEnd;
}
/**
* 获取 增加 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @return areaLevelIncrement
*/
public Integer getAreaLevelIncrement(){
return this.areaLevelIncrement;
}
/**
* 设置 增加 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelIncrement
*/
public void setAreaLevelIncrement(Integer areaLevelIncrement){
this.areaLevelIncrement = areaLevelIncrement;
}
/**
* 获取 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @return areaLevelList
*/
public List<Integer> getAreaLevelList(){
return this.areaLevelList;
}
/**
* 设置 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelList
*/
public void setAreaLevelList(List<Integer> areaLevelList){
this.areaLevelList = areaLevelList;
}
/**
* 获取 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @return areaLevelNotList
*/
public List<Integer> getAreaLevelNotList(){
return this.areaLevelNotList;
}
/**
* 设置 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelNotList
*/
public void setAreaLevelNotList(List<Integer> areaLevelNotList){
this.areaLevelNotList = areaLevelNotList;
}
/** /**
* 获取 开始 办理单位ID * 获取 开始 办理单位ID
* @return deptIdStart * @return deptIdStart
...@@ -725,38 +385,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -725,38 +385,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
} }
/**
* 获取 办理单位名称
* @return deptNameList
*/
public List<String> getDeptNameList(){
return this.deptNameList;
}
/**
* 设置 办理单位名称
* @param deptNameList
*/
public void setDeptNameList(List<String> deptNameList){
this.deptNameList = deptNameList;
}
/**
* 获取 办理单位名称
* @return deptNameNotList
*/
public List<String> getDeptNameNotList(){
return this.deptNameNotList;
}
/**
* 设置 办理单位名称
* @param deptNameNotList
*/
public void setDeptNameNotList(List<String> deptNameNotList){
this.deptNameNotList = deptNameNotList;
}
/** /**
* 获取 备注 * 获取 备注
* @return remarkList * @return remarkList
...@@ -966,6 +594,38 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -966,6 +594,38 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
this.updateTimeEnd = updateTimeEnd; this.updateTimeEnd = updateTimeEnd;
} }
/**
* 获取 事项组名称
* @return matterGroupNameList
*/
public List<String> getMatterGroupNameList(){
return this.matterGroupNameList;
}
/**
* 设置 事项组名称
* @param matterGroupNameList
*/
public void setMatterGroupNameList(List<String> matterGroupNameList){
this.matterGroupNameList = matterGroupNameList;
}
/**
* 获取 事项组名称
* @return matterGroupNameNotList
*/
public List<String> getMatterGroupNameNotList(){
return this.matterGroupNameNotList;
}
/**
* 设置 事项组名称
* @param matterGroupNameNotList
*/
public void setMatterGroupNameNotList(List<String> matterGroupNameNotList){
this.matterGroupNameNotList = matterGroupNameNotList;
}
/** /**
* 设置 主键ID,主键,自增长 * 设置 主键ID,主键,自增长
* @param id * @param id
...@@ -1093,190 +753,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -1093,190 +753,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
return this; return this;
} }
/**
* 设置 事项id
* @param matterId
*/
public EntLifeMatterQuery matterId(Long matterId){
setMatterId(matterId);
return this;
}
/**
* 设置 开始 事项id
* @param matterIdStart
*/
public EntLifeMatterQuery matterIdStart(Long matterIdStart){
this.matterIdStart = matterIdStart;
return this;
}
/**
* 设置 结束 事项id
* @param matterIdEnd
*/
public EntLifeMatterQuery matterIdEnd(Long matterIdEnd){
this.matterIdEnd = matterIdEnd;
return this;
}
/**
* 设置 增加 事项id
* @param matterIdIncrement
*/
public EntLifeMatterQuery matterIdIncrement(Long matterIdIncrement){
this.matterIdIncrement = matterIdIncrement;
return this;
}
/**
* 设置 事项id
* @param matterIdList
*/
public EntLifeMatterQuery matterIdList(List<Long> matterIdList){
this.matterIdList = matterIdList;
return this;
}
/**
* 设置 事项id
* @param matterIdNotList
*/
public EntLifeMatterQuery matterIdNotList(List<Long> matterIdNotList){
this.matterIdNotList = matterIdNotList;
return this;
}
/**
* 设置 事项名称
* @param matterName
*/
public EntLifeMatterQuery matterName(String matterName){
setMatterName(matterName);
return this;
}
/**
* 设置 事项名称
* @param matterNameList
*/
public EntLifeMatterQuery matterNameList(List<String> matterNameList){
this.matterNameList = matterNameList;
return this;
}
/**
* 设置 事项编码
* @param matterCode
*/
public EntLifeMatterQuery matterCode(String matterCode){
setMatterCode(matterCode);
return this;
}
/**
* 设置 事项编码
* @param matterCodeList
*/
public EntLifeMatterQuery matterCodeList(List<String> matterCodeList){
this.matterCodeList = matterCodeList;
return this;
}
/**
* 设置 区域编码
* @param areaCode
*/
public EntLifeMatterQuery areaCode(String areaCode){
setAreaCode(areaCode);
return this;
}
/**
* 设置 区域编码
* @param areaCodeList
*/
public EntLifeMatterQuery areaCodeList(List<String> areaCodeList){
this.areaCodeList = areaCodeList;
return this;
}
/**
* 设置 区域名称
* @param areaName
*/
public EntLifeMatterQuery areaName(String areaName){
setAreaName(areaName);
return this;
}
/**
* 设置 区域名称
* @param areaNameList
*/
public EntLifeMatterQuery areaNameList(List<String> areaNameList){
this.areaNameList = areaNameList;
return this;
}
/**
* 设置 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevel
*/
public EntLifeMatterQuery areaLevel(Integer areaLevel){
setAreaLevel(areaLevel);
return this;
}
/**
* 设置 开始 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelStart
*/
public EntLifeMatterQuery areaLevelStart(Integer areaLevelStart){
this.areaLevelStart = areaLevelStart;
return this;
}
/**
* 设置 结束 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelEnd
*/
public EntLifeMatterQuery areaLevelEnd(Integer areaLevelEnd){
this.areaLevelEnd = areaLevelEnd;
return this;
}
/**
* 设置 增加 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelIncrement
*/
public EntLifeMatterQuery areaLevelIncrement(Integer areaLevelIncrement){
this.areaLevelIncrement = areaLevelIncrement;
return this;
}
/**
* 设置 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelList
*/
public EntLifeMatterQuery areaLevelList(List<Integer> areaLevelList){
this.areaLevelList = areaLevelList;
return this;
}
/**
* 设置 区域等级(1.省,2.地市州,3.区县,4.街道,5.社区)
* @param areaLevelNotList
*/
public EntLifeMatterQuery areaLevelNotList(List<Integer> areaLevelNotList){
this.areaLevelNotList = areaLevelNotList;
return this;
}
/** /**
* 设置 办理单位ID * 设置 办理单位ID
* @param deptId * @param deptId
...@@ -1332,25 +808,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -1332,25 +808,6 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
} }
/**
* 设置 办理单位名称
* @param deptName
*/
public EntLifeMatterQuery deptName(String deptName){
setDeptName(deptName);
return this;
}
/**
* 设置 办理单位名称
* @param deptNameList
*/
public EntLifeMatterQuery deptNameList(List<String> deptNameList){
this.deptNameList = deptNameList;
return this;
}
/** /**
* 设置 备注 * 设置 备注
* @param remark * @param remark
...@@ -1444,6 +901,25 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity { ...@@ -1444,6 +901,25 @@ public class EntLifeMatterQuery extends EntLifeMatterEntity {
/**
* 设置 事项组名称
* @param matterGroupName
*/
public EntLifeMatterQuery matterGroupName(String matterGroupName){
setMatterGroupName(matterGroupName);
return this;
}
/**
* 设置 事项组名称
* @param matterGroupNameList
*/
public EntLifeMatterQuery matterGroupNameList(List<String> matterGroupNameList){
this.matterGroupNameList = matterGroupNameList;
return this;
}
/** /**
* 获取 OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4) * 获取 OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4)
* @return orConditionList * @return orConditionList
......
...@@ -10,11 +10,11 @@ import com.mortals.framework.model.BaseEntityLong; ...@@ -10,11 +10,11 @@ import com.mortals.framework.model.BaseEntityLong;
import com.mortals.xhx.module.ent.model.vo.EntLifeMatterSubVo; import com.mortals.xhx.module.ent.model.vo.EntLifeMatterSubVo;
import lombok.Data; import lombok.Data;
/** /**
* 企业周期事项子实体对象 * 企业周期事项子实体对象
* *
* @author zxfei * @author zxfei
* @date 2025-03-15 * @date 2025-03-17
*/ */
@Data @Data
public class EntLifeMatterSubEntity extends EntLifeMatterSubVo { public class EntLifeMatterSubEntity extends EntLifeMatterSubVo {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
...@@ -63,6 +63,10 @@ public class EntLifeMatterSubEntity extends EntLifeMatterSubVo { ...@@ -63,6 +63,10 @@ public class EntLifeMatterSubEntity extends EntLifeMatterSubVo {
* 创建用户名称 * 创建用户名称
*/ */
private String createUserName; private String createUserName;
/**
* 排序字段
*/
private Integer sort;
@Override @Override
public int hashCode() { public int hashCode() {
return this.getId().hashCode(); return this.getId().hashCode();
...@@ -91,5 +95,6 @@ public class EntLifeMatterSubEntity extends EntLifeMatterSubVo { ...@@ -91,5 +95,6 @@ public class EntLifeMatterSubEntity extends EntLifeMatterSubVo {
this.deptName = ""; this.deptName = "";
this.remark = ""; this.remark = "";
this.createUserName = ""; this.createUserName = "";
this.sort = 0;
} }
} }
\ No newline at end of file
...@@ -3,11 +3,11 @@ package com.mortals.xhx.module.ent.model; ...@@ -3,11 +3,11 @@ package com.mortals.xhx.module.ent.model;
import java.util.List; import java.util.List;
import com.mortals.xhx.module.ent.model.EntLifeMatterSubEntity; import com.mortals.xhx.module.ent.model.EntLifeMatterSubEntity;
/** /**
* 企业周期事项子查询对象 * 企业周期事项子查询对象
* *
* @author zxfei * @author zxfei
* @date 2025-03-15 * @date 2025-03-17
*/ */
public class EntLifeMatterSubQuery extends EntLifeMatterSubEntity { public class EntLifeMatterSubQuery extends EntLifeMatterSubEntity {
/** 开始 主键ID,主键,自增长 */ /** 开始 主键ID,主键,自增长 */
private Long idStart; private Long idStart;
...@@ -146,6 +146,21 @@ public class EntLifeMatterSubQuery extends EntLifeMatterSubEntity { ...@@ -146,6 +146,21 @@ public class EntLifeMatterSubQuery extends EntLifeMatterSubEntity {
/** 结束 更新时间 */ /** 结束 更新时间 */
private String updateTimeEnd; private String updateTimeEnd;
/** 开始 排序字段 */
private Integer sortStart;
/** 结束 排序字段 */
private Integer sortEnd;
/** 增加 排序字段 */
private Integer sortIncrement;
/** 排序字段列表 */
private List <Integer> sortList;
/** 排序字段排除列表 */
private List <Integer> sortNotList;
/** OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4) */ /** OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4) */
private List<EntLifeMatterSubQuery> orConditionList; private List<EntLifeMatterSubQuery> orConditionList;
...@@ -928,6 +943,87 @@ public class EntLifeMatterSubQuery extends EntLifeMatterSubEntity { ...@@ -928,6 +943,87 @@ public class EntLifeMatterSubQuery extends EntLifeMatterSubEntity {
this.updateTimeEnd = updateTimeEnd; this.updateTimeEnd = updateTimeEnd;
} }
/**
* 获取 开始 排序字段
* @return sortStart
*/
public Integer getSortStart(){
return this.sortStart;
}
/**
* 设置 开始 排序字段
* @param sortStart
*/
public void setSortStart(Integer sortStart){
this.sortStart = sortStart;
}
/**
* 获取 结束 排序字段
* @return $sortEnd
*/
public Integer getSortEnd(){
return this.sortEnd;
}
/**
* 设置 结束 排序字段
* @param sortEnd
*/
public void setSortEnd(Integer sortEnd){
this.sortEnd = sortEnd;
}
/**
* 获取 增加 排序字段
* @return sortIncrement
*/
public Integer getSortIncrement(){
return this.sortIncrement;
}
/**
* 设置 增加 排序字段
* @param sortIncrement
*/
public void setSortIncrement(Integer sortIncrement){
this.sortIncrement = sortIncrement;
}
/**
* 获取 排序字段
* @return sortList
*/
public List<Integer> getSortList(){
return this.sortList;
}
/**
* 设置 排序字段
* @param sortList
*/
public void setSortList(List<Integer> sortList){
this.sortList = sortList;
}
/**
* 获取 排序字段
* @return sortNotList
*/
public List<Integer> getSortNotList(){
return this.sortNotList;
}
/**
* 设置 排序字段
* @param sortNotList
*/
public void setSortNotList(List<Integer> sortNotList){
this.sortNotList = sortNotList;
}
/** /**
* 设置 主键ID,主键,自增长 * 设置 主键ID,主键,自增长
* @param id * @param id
...@@ -1387,6 +1483,60 @@ public class EntLifeMatterSubQuery extends EntLifeMatterSubEntity { ...@@ -1387,6 +1483,60 @@ public class EntLifeMatterSubQuery extends EntLifeMatterSubEntity {
/**
* 设置 排序字段
* @param sort
*/
public EntLifeMatterSubQuery sort(Integer sort){
setSort(sort);
return this;
}
/**
* 设置 开始 排序字段
* @param sortStart
*/
public EntLifeMatterSubQuery sortStart(Integer sortStart){
this.sortStart = sortStart;
return this;
}
/**
* 设置 结束 排序字段
* @param sortEnd
*/
public EntLifeMatterSubQuery sortEnd(Integer sortEnd){
this.sortEnd = sortEnd;
return this;
}
/**
* 设置 增加 排序字段
* @param sortIncrement
*/
public EntLifeMatterSubQuery sortIncrement(Integer sortIncrement){
this.sortIncrement = sortIncrement;
return this;
}
/**
* 设置 排序字段
* @param sortList
*/
public EntLifeMatterSubQuery sortList(List<Integer> sortList){
this.sortList = sortList;
return this;
}
/**
* 设置 排序字段
* @param sortNotList
*/
public EntLifeMatterSubQuery sortNotList(List<Integer> sortNotList){
this.sortNotList = sortNotList;
return this;
}
/** /**
* 获取 OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4) * 获取 OR条件集合,列表项之间是OR,项内容之间是AND,如:(list[0].1 and list[0].2) or (list[1].3 and list[1].4)
* @return orConditionList * @return orConditionList
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"mybatis-3-mapper.dtd"> "mybatis-3-mapper.dtd">
<mapper namespace="com.mortals.xhx.module.ent.dao.ibatis.EntLifeMatterDaoImpl"> <mapper namespace="com.mortals.xhx.module.ent.dao.ibatis.EntLifeMatterDaoImpl">
<!-- 字段和属性映射 --> <!-- 字段和属性映射 -->
...@@ -8,19 +8,13 @@ ...@@ -8,19 +8,13 @@
<id property="id" column="id" /> <id property="id" column="id" />
<result property="lifeCycleId" column="life_cycle_id" /> <result property="lifeCycleId" column="life_cycle_id" />
<result property="lifeCycleName" column="life_cycle_name" /> <result property="lifeCycleName" column="life_cycle_name" />
<result property="matterId" column="matter_id" />
<result property="matterName" column="matter_name" />
<result property="matterCode" column="matter_code" />
<result property="areaCode" column="area_code" />
<result property="areaName" column="area_name" />
<result property="areaLevel" column="area_level" />
<result property="deptId" column="dept_id" /> <result property="deptId" column="dept_id" />
<result property="deptName" column="dept_name" />
<result property="remark" column="remark" /> <result property="remark" column="remark" />
<result property="createUserId" column="create_user_id" /> <result property="createUserId" column="create_user_id" />
<result property="createUserName" column="create_user_name" /> <result property="createUserName" column="create_user_name" />
<result property="createTime" column="create_time" /> <result property="createTime" column="create_time" />
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="matterGroupName" column="matter_group_name" />
</resultMap> </resultMap>
<!-- 表所有列 --> <!-- 表所有列 -->
...@@ -35,30 +29,9 @@ ...@@ -35,30 +29,9 @@
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('lifeCycleName') or colPickMode == 1 and data.containsKey('lifeCycleName')))"> <if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('lifeCycleName') or colPickMode == 1 and data.containsKey('lifeCycleName')))">
a.life_cycle_name, a.life_cycle_name,
</if> </if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('matterId') or colPickMode == 1 and data.containsKey('matterId')))">
a.matter_id,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('matterName') or colPickMode == 1 and data.containsKey('matterName')))">
a.matter_name,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('matterCode') or colPickMode == 1 and data.containsKey('matterCode')))">
a.matter_code,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('areaCode') or colPickMode == 1 and data.containsKey('areaCode')))">
a.area_code,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('areaName') or colPickMode == 1 and data.containsKey('areaName')))">
a.area_name,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('areaLevel') or colPickMode == 1 and data.containsKey('areaLevel')))">
a.area_level,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('deptId') or colPickMode == 1 and data.containsKey('deptId')))"> <if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('deptId') or colPickMode == 1 and data.containsKey('deptId')))">
a.dept_id, a.dept_id,
</if> </if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('deptName') or colPickMode == 1 and data.containsKey('deptName')))">
a.dept_name,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('remark') or colPickMode == 1 and data.containsKey('remark')))"> <if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('remark') or colPickMode == 1 and data.containsKey('remark')))">
a.remark, a.remark,
</if> </if>
...@@ -74,29 +47,32 @@ ...@@ -74,29 +47,32 @@
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('updateTime') or colPickMode == 1 and data.containsKey('updateTime')))"> <if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('updateTime') or colPickMode == 1 and data.containsKey('updateTime')))">
a.update_time, a.update_time,
</if> </if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('matterGroupName') or colPickMode == 1 and data.containsKey('matterGroupName')))">
a.matter_group_name,
</if>
</trim> </trim>
</sql> </sql>
<!-- 子表所有列 --> <!-- 子表所有列 -->
<sql id="_columns_sub"> <sql id="_columns_sub">
<trim suffixOverrides="," suffix=""> <trim suffixOverrides="," suffix="">
b.id,b.master_record_id,b.matter_id,b.matter_name,b.matter_code,b.area_code,b.area_name,b.area_level,b.dept_id,b.dept_name,b.remark,b.create_user_id,b.create_user_name,b.create_time,b.update_time, b.id,b.master_record_id,b.matter_id,b.matter_name,b.matter_code,b.area_code,b.area_name,b.area_level,b.dept_id,b.dept_name,b.remark,b.create_user_id,b.create_user_name,b.create_time,b.update_time,b.sort,
</trim> </trim>
</sql> </sql>
<!-- 新增 区分主键自增加还是业务插入 --> <!-- 新增 区分主键自增加还是业务插入 -->
<insert id="insert" parameterType="EntLifeMatterEntity" useGeneratedKeys="true" keyProperty="id"> <insert id="insert" parameterType="EntLifeMatterEntity" useGeneratedKeys="true" keyProperty="id">
insert into mortals_ent_life_matter insert into mortals_ent_life_matter
(life_cycle_id,life_cycle_name,matter_id,matter_name,matter_code,area_code,area_name,area_level,dept_id,dept_name,remark,create_user_id,create_user_name,create_time,update_time) (life_cycle_id,life_cycle_name,dept_id,remark,create_user_id,create_user_name,create_time,update_time,matter_group_name)
VALUES VALUES
(#{lifeCycleId},#{lifeCycleName},#{matterId},#{matterName},#{matterCode},#{areaCode},#{areaName},#{areaLevel},#{deptId},#{deptName},#{remark},#{createUserId},#{createUserName},#{createTime},#{updateTime}) (#{lifeCycleId},#{lifeCycleName},#{deptId},#{remark},#{createUserId},#{createUserName},#{createTime},#{updateTime},#{matterGroupName})
</insert> </insert>
<!-- 批量新增 --> <!-- 批量新增 -->
<insert id="insertBatch" parameterType="paramDto"> <insert id="insertBatch" parameterType="paramDto">
insert into mortals_ent_life_matter insert into mortals_ent_life_matter
(life_cycle_id,life_cycle_name,matter_id,matter_name,matter_code,area_code,area_name,area_level,dept_id,dept_name,remark,create_user_id,create_user_name,create_time,update_time) (life_cycle_id,life_cycle_name,dept_id,remark,create_user_id,create_user_name,create_time,update_time,matter_group_name)
VALUES VALUES
<foreach collection="data.dataList" item="item" index="index" separator="," > <foreach collection="data.dataList" item="item" index="index" separator="," >
(#{item.lifeCycleId},#{item.lifeCycleName},#{item.matterId},#{item.matterName},#{item.matterCode},#{item.areaCode},#{item.areaName},#{item.areaLevel},#{item.deptId},#{item.deptName},#{item.remark},#{item.createUserId},#{item.createUserName},#{item.createTime},#{item.updateTime}) (#{item.lifeCycleId},#{item.lifeCycleName},#{item.deptId},#{item.remark},#{item.createUserId},#{item.createUserName},#{item.createTime},#{item.updateTime},#{item.matterGroupName})
</foreach> </foreach>
</insert> </insert>
...@@ -115,39 +91,12 @@ ...@@ -115,39 +91,12 @@
<if test="(colPickMode==0 and data.containsKey('lifeCycleName')) or (colPickMode==1 and !data.containsKey('lifeCycleName'))"> <if test="(colPickMode==0 and data.containsKey('lifeCycleName')) or (colPickMode==1 and !data.containsKey('lifeCycleName'))">
a.life_cycle_name=#{data.lifeCycleName}, a.life_cycle_name=#{data.lifeCycleName},
</if> </if>
<if test="(colPickMode==0 and data.containsKey('matterId')) or (colPickMode==1 and !data.containsKey('matterId'))">
a.matter_id=#{data.matterId},
</if>
<if test="(colPickMode==0 and data.containsKey('matterIdIncrement')) or (colPickMode==1 and !data.containsKey('matterIdIncrement'))">
a.matter_id=ifnull(a.matter_id,0) + #{data.matterIdIncrement},
</if>
<if test="(colPickMode==0 and data.containsKey('matterName')) or (colPickMode==1 and !data.containsKey('matterName'))">
a.matter_name=#{data.matterName},
</if>
<if test="(colPickMode==0 and data.containsKey('matterCode')) or (colPickMode==1 and !data.containsKey('matterCode'))">
a.matter_code=#{data.matterCode},
</if>
<if test="(colPickMode==0 and data.containsKey('areaCode')) or (colPickMode==1 and !data.containsKey('areaCode'))">
a.area_code=#{data.areaCode},
</if>
<if test="(colPickMode==0 and data.containsKey('areaName')) or (colPickMode==1 and !data.containsKey('areaName'))">
a.area_name=#{data.areaName},
</if>
<if test="(colPickMode==0 and data.containsKey('areaLevel')) or (colPickMode==1 and !data.containsKey('areaLevel'))">
a.area_level=#{data.areaLevel},
</if>
<if test="(colPickMode==0 and data.containsKey('areaLevelIncrement')) or (colPickMode==1 and !data.containsKey('areaLevelIncrement'))">
a.area_level=ifnull(a.area_level,0) + #{data.areaLevelIncrement},
</if>
<if test="(colPickMode==0 and data.containsKey('deptId')) or (colPickMode==1 and !data.containsKey('deptId'))"> <if test="(colPickMode==0 and data.containsKey('deptId')) or (colPickMode==1 and !data.containsKey('deptId'))">
a.dept_id=#{data.deptId}, a.dept_id=#{data.deptId},
</if> </if>
<if test="(colPickMode==0 and data.containsKey('deptIdIncrement')) or (colPickMode==1 and !data.containsKey('deptIdIncrement'))"> <if test="(colPickMode==0 and data.containsKey('deptIdIncrement')) or (colPickMode==1 and !data.containsKey('deptIdIncrement'))">
a.dept_id=ifnull(a.dept_id,0) + #{data.deptIdIncrement}, a.dept_id=ifnull(a.dept_id,0) + #{data.deptIdIncrement},
</if> </if>
<if test="(colPickMode==0 and data.containsKey('deptName')) or (colPickMode==1 and !data.containsKey('deptName'))">
a.dept_name=#{data.deptName},
</if>
<if test="(colPickMode==0 and data.containsKey('remark')) or (colPickMode==1 and !data.containsKey('remark'))"> <if test="(colPickMode==0 and data.containsKey('remark')) or (colPickMode==1 and !data.containsKey('remark'))">
a.remark=#{data.remark}, a.remark=#{data.remark},
</if> </if>
...@@ -166,6 +115,9 @@ ...@@ -166,6 +115,9 @@
<if test="(colPickMode==0 and data.containsKey('updateTime')) or (colPickMode==1 and !data.containsKey('updateTime'))"> <if test="(colPickMode==0 and data.containsKey('updateTime')) or (colPickMode==1 and !data.containsKey('updateTime'))">
a.update_time=#{data.updateTime}, a.update_time=#{data.updateTime},
</if> </if>
<if test="(colPickMode==0 and data.containsKey('matterGroupName')) or (colPickMode==1 and !data.containsKey('matterGroupName'))">
a.matter_group_name=#{data.matterGroupName},
</if>
</trim> </trim>
<trim suffixOverrides="where" suffix=""> <trim suffixOverrides="where" suffix="">
where where
...@@ -196,58 +148,6 @@ ...@@ -196,58 +148,6 @@
when a.id=#{item.id} then #{item.lifeCycleName} when a.id=#{item.id} then #{item.lifeCycleName}
</if> </if>
</foreach> </foreach>
</trim>
<trim prefix="matter_id=(case" suffix="ELSE matter_id end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('matterId')) or (colPickMode==1 and !item.containsKey('matterId'))">
when a.id=#{item.id} then #{item.matterId}
</when>
<when test="(colPickMode==0 and item.containsKey('matterIdIncrement')) or (colPickMode==1 and !item.containsKey('matterIdIncrement'))">
when a.id=#{item.id} then ifnull(a.matter_id,0) + #{item.matterIdIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="matter_name=(case" suffix="ELSE matter_name end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('matterName')) or (colPickMode==1 and !item.containsKey('matterName'))">
when a.id=#{item.id} then #{item.matterName}
</if>
</foreach>
</trim>
<trim prefix="matter_code=(case" suffix="ELSE matter_code end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('matterCode')) or (colPickMode==1 and !item.containsKey('matterCode'))">
when a.id=#{item.id} then #{item.matterCode}
</if>
</foreach>
</trim>
<trim prefix="area_code=(case" suffix="ELSE area_code end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('areaCode')) or (colPickMode==1 and !item.containsKey('areaCode'))">
when a.id=#{item.id} then #{item.areaCode}
</if>
</foreach>
</trim>
<trim prefix="area_name=(case" suffix="ELSE area_name end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('areaName')) or (colPickMode==1 and !item.containsKey('areaName'))">
when a.id=#{item.id} then #{item.areaName}
</if>
</foreach>
</trim>
<trim prefix="area_level=(case" suffix="ELSE area_level end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('areaLevel')) or (colPickMode==1 and !item.containsKey('areaLevel'))">
when a.id=#{item.id} then #{item.areaLevel}
</when>
<when test="(colPickMode==0 and item.containsKey('areaLevelIncrement')) or (colPickMode==1 and !item.containsKey('areaLevelIncrement'))">
when a.id=#{item.id} then ifnull(a.area_level,0) + #{item.areaLevelIncrement}
</when>
</choose>
</foreach>
</trim> </trim>
<trim prefix="dept_id=(case" suffix="ELSE dept_id end),"> <trim prefix="dept_id=(case" suffix="ELSE dept_id end),">
<foreach collection="data.dataList" item="item" index="index" separator="" > <foreach collection="data.dataList" item="item" index="index" separator="" >
...@@ -261,13 +161,6 @@ ...@@ -261,13 +161,6 @@
</choose> </choose>
</foreach> </foreach>
</trim> </trim>
<trim prefix="dept_name=(case" suffix="ELSE dept_name end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('deptName')) or (colPickMode==1 and !item.containsKey('deptName'))">
when a.id=#{item.id} then #{item.deptName}
</if>
</foreach>
</trim>
<trim prefix="remark=(case" suffix="ELSE remark end),"> <trim prefix="remark=(case" suffix="ELSE remark end),">
<foreach collection="data.dataList" item="item" index="index" separator="" > <foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('remark')) or (colPickMode==1 and !item.containsKey('remark'))"> <if test="(colPickMode==0 and item.containsKey('remark')) or (colPickMode==1 and !item.containsKey('remark'))">
...@@ -308,6 +201,13 @@ ...@@ -308,6 +201,13 @@
</if> </if>
</foreach> </foreach>
</trim> </trim>
<trim prefix="matter_group_name=(case" suffix="ELSE matter_group_name end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('matterGroupName')) or (colPickMode==1 and !item.containsKey('matterGroupName'))">
when a.id=#{item.id} then #{item.matterGroupName}
</if>
</foreach>
</trim>
</trim> </trim>
where id in where id in
<foreach collection="data.dataList" item="item" index="index" open="(" separator="," close=")"> <foreach collection="data.dataList" item="item" index="index" open="(" separator="," close=")">
...@@ -504,144 +404,6 @@ ...@@ -504,144 +404,6 @@
#{item} #{item}
</foreach> </foreach>
</if> </if>
<if test="conditionParamRef.containsKey('matterId')">
<if test="conditionParamRef.matterId != null ">
${_conditionType_} a.matter_id = #{${_conditionParam_}.matterId}
</if>
<if test="conditionParamRef.matterId == null">
${_conditionType_} a.matter_id is null
</if>
</if>
<if test="conditionParamRef.containsKey('matterIdList') and conditionParamRef.matterIdList.size() > 0">
${_conditionType_} a.matter_id in
<foreach collection="conditionParamRef.matterIdList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('matterIdNotList') and conditionParamRef.matterIdNotList.size() > 0">
${_conditionType_} a.matter_id not in
<foreach collection="conditionParamRef.matterIdNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('matterIdStart') and conditionParamRef.matterIdStart != null">
${_conditionType_} a.matter_id <![CDATA[ >= ]]> #{${_conditionParam_}.matterIdStart}
</if>
<if test="conditionParamRef.containsKey('matterIdEnd') and conditionParamRef.matterIdEnd != null">
${_conditionType_} a.matter_id <![CDATA[ <= ]]> #{${_conditionParam_}.matterIdEnd}
</if>
<if test="conditionParamRef.containsKey('matterName')">
<if test="conditionParamRef.matterName != null and conditionParamRef.matterName != ''">
${_conditionType_} a.matter_name like #{${_conditionParam_}.matterName}
</if>
<if test="conditionParamRef.matterName == null">
${_conditionType_} a.matter_name is null
</if>
</if>
<if test="conditionParamRef.containsKey('matterNameList') and conditionParamRef.matterNameList.size() > 0">
${_conditionType_} a.matter_name in
<foreach collection="conditionParamRef.matterNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('matterNameNotList') and conditionParamRef.matterNameNotList.size() > 0">
${_conditionType_} a.matter_name not in
<foreach collection="conditionParamRef.matterNameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('matterCode')">
<if test="conditionParamRef.matterCode != null and conditionParamRef.matterCode != ''">
${_conditionType_} a.matter_code like #{${_conditionParam_}.matterCode}
</if>
<if test="conditionParamRef.matterCode == null">
${_conditionType_} a.matter_code is null
</if>
</if>
<if test="conditionParamRef.containsKey('matterCodeList') and conditionParamRef.matterCodeList.size() > 0">
${_conditionType_} a.matter_code in
<foreach collection="conditionParamRef.matterCodeList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('matterCodeNotList') and conditionParamRef.matterCodeNotList.size() > 0">
${_conditionType_} a.matter_code not in
<foreach collection="conditionParamRef.matterCodeNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('areaCode')">
<if test="conditionParamRef.areaCode != null and conditionParamRef.areaCode != ''">
${_conditionType_} a.area_code like #{${_conditionParam_}.areaCode}
</if>
<if test="conditionParamRef.areaCode == null">
${_conditionType_} a.area_code is null
</if>
</if>
<if test="conditionParamRef.containsKey('areaCodeList') and conditionParamRef.areaCodeList.size() > 0">
${_conditionType_} a.area_code in
<foreach collection="conditionParamRef.areaCodeList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('areaCodeNotList') and conditionParamRef.areaCodeNotList.size() > 0">
${_conditionType_} a.area_code not in
<foreach collection="conditionParamRef.areaCodeNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('areaName')">
<if test="conditionParamRef.areaName != null and conditionParamRef.areaName != ''">
${_conditionType_} a.area_name like #{${_conditionParam_}.areaName}
</if>
<if test="conditionParamRef.areaName == null">
${_conditionType_} a.area_name is null
</if>
</if>
<if test="conditionParamRef.containsKey('areaNameList') and conditionParamRef.areaNameList.size() > 0">
${_conditionType_} a.area_name in
<foreach collection="conditionParamRef.areaNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('areaNameNotList') and conditionParamRef.areaNameNotList.size() > 0">
${_conditionType_} a.area_name not in
<foreach collection="conditionParamRef.areaNameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('areaLevel')">
<if test="conditionParamRef.areaLevel != null ">
${_conditionType_} a.area_level = #{${_conditionParam_}.areaLevel}
</if>
<if test="conditionParamRef.areaLevel == null">
${_conditionType_} a.area_level is null
</if>
</if>
<if test="conditionParamRef.containsKey('areaLevelList') and conditionParamRef.areaLevelList.size() > 0">
${_conditionType_} a.area_level in
<foreach collection="conditionParamRef.areaLevelList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('areaLevelNotList') and conditionParamRef.areaLevelNotList.size() > 0">
${_conditionType_} a.area_level not in
<foreach collection="conditionParamRef.areaLevelNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('areaLevelStart') and conditionParamRef.areaLevelStart != null">
${_conditionType_} a.area_level <![CDATA[ >= ]]> #{${_conditionParam_}.areaLevelStart}
</if>
<if test="conditionParamRef.containsKey('areaLevelEnd') and conditionParamRef.areaLevelEnd != null">
${_conditionType_} a.area_level <![CDATA[ <= ]]> #{${_conditionParam_}.areaLevelEnd}
</if>
<if test="conditionParamRef.containsKey('deptId')"> <if test="conditionParamRef.containsKey('deptId')">
<if test="conditionParamRef.deptId != null "> <if test="conditionParamRef.deptId != null ">
${_conditionType_} a.dept_id = #{${_conditionParam_}.deptId} ${_conditionType_} a.dept_id = #{${_conditionParam_}.deptId}
...@@ -670,27 +432,6 @@ ...@@ -670,27 +432,6 @@
</if> </if>
<if test="conditionParamRef.containsKey('deptName')">
<if test="conditionParamRef.deptName != null and conditionParamRef.deptName != ''">
${_conditionType_} a.dept_name like #{${_conditionParam_}.deptName}
</if>
<if test="conditionParamRef.deptName == null">
${_conditionType_} a.dept_name is null
</if>
</if>
<if test="conditionParamRef.containsKey('deptNameList') and conditionParamRef.deptNameList.size() > 0">
${_conditionType_} a.dept_name in
<foreach collection="conditionParamRef.deptNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('deptNameNotList') and conditionParamRef.deptNameNotList.size() > 0">
${_conditionType_} a.dept_name not in
<foreach collection="conditionParamRef.deptNameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('remark')"> <if test="conditionParamRef.containsKey('remark')">
<if test="conditionParamRef.remark != null and conditionParamRef.remark != ''"> <if test="conditionParamRef.remark != null and conditionParamRef.remark != ''">
${_conditionType_} a.remark like #{${_conditionParam_}.remark} ${_conditionType_} a.remark like #{${_conditionParam_}.remark}
...@@ -789,6 +530,27 @@ ...@@ -789,6 +530,27 @@
<if test="conditionParamRef.containsKey('updateTimeEnd') and conditionParamRef.updateTimeEnd != null and conditionParamRef.updateTimeEnd!=''"> <if test="conditionParamRef.containsKey('updateTimeEnd') and conditionParamRef.updateTimeEnd != null and conditionParamRef.updateTimeEnd!=''">
${_conditionType_} a.update_time <![CDATA[ <= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.updateTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s') ${_conditionType_} a.update_time <![CDATA[ <= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.updateTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s')
</if> </if>
<if test="conditionParamRef.containsKey('matterGroupName')">
<if test="conditionParamRef.matterGroupName != null and conditionParamRef.matterGroupName != ''">
${_conditionType_} a.matter_group_name like #{${_conditionParam_}.matterGroupName}
</if>
<if test="conditionParamRef.matterGroupName == null">
${_conditionType_} a.matter_group_name is null
</if>
</if>
<if test="conditionParamRef.containsKey('matterGroupNameList') and conditionParamRef.matterGroupNameList.size() > 0">
${_conditionType_} a.matter_group_name in
<foreach collection="conditionParamRef.matterGroupNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('matterGroupNameNotList') and conditionParamRef.matterGroupNameNotList.size() > 0">
${_conditionType_} a.matter_group_name not in
<foreach collection="conditionParamRef.matterGroupNameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
</sql> </sql>
<sql id="_orderCols_"> <sql id="_orderCols_">
<if test="orderColList != null and !orderColList.isEmpty()"> <if test="orderColList != null and !orderColList.isEmpty()">
...@@ -807,20 +569,6 @@ ...@@ -807,20 +569,6 @@
</foreach> </foreach>
, ,
</if> </if>
<if test="conditionParamRef.containsKey('matterIdList') and conditionParamRef.matterIdList.size() > 0">
field(a.matterId,
<foreach collection="conditionParamRef.matterIdList" open="" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
,
</if>
<if test="conditionParamRef.containsKey('areaLevelList') and conditionParamRef.areaLevelList.size() > 0">
field(a.areaLevel,
<foreach collection="conditionParamRef.areaLevelList" open="" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
,
</if>
<if test="conditionParamRef.containsKey('deptIdList') and conditionParamRef.deptIdList.size() > 0"> <if test="conditionParamRef.containsKey('deptIdList') and conditionParamRef.deptIdList.size() > 0">
field(a.deptId, field(a.deptId,
<foreach collection="conditionParamRef.deptIdList" open="" close=")" index="index" item="item" separator=","> <foreach collection="conditionParamRef.deptIdList" open="" close=")" index="index" item="item" separator=",">
...@@ -857,20 +605,6 @@ ...@@ -857,20 +605,6 @@
</foreach> </foreach>
, ,
</if> </if>
<if test="conditionParamRef.containsKey('matterIdList') and conditionParamRef.matterIdList.size() > 0">
field(a.matterId,
<foreach collection="conditionParamRef.matterIdList" open="" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
,
</if>
<if test="conditionParamRef.containsKey('areaLevelList') and conditionParamRef.areaLevelList.size() > 0">
field(a.areaLevel,
<foreach collection="conditionParamRef.areaLevelList" open="" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
,
</if>
<if test="conditionParamRef.containsKey('deptIdList') and conditionParamRef.deptIdList.size() > 0"> <if test="conditionParamRef.containsKey('deptIdList') and conditionParamRef.deptIdList.size() > 0">
field(a.deptId, field(a.deptId,
<foreach collection="conditionParamRef.deptIdList" open="" close=")" index="index" item="item" separator=","> <foreach collection="conditionParamRef.deptIdList" open="" close=")" index="index" item="item" separator=",">
...@@ -901,46 +635,11 @@ ...@@ -901,46 +635,11 @@
<if test='orderCol.lifeCycleName != null and "DESC".equalsIgnoreCase(orderCol.lifeCycleName)'>DESC</if> <if test='orderCol.lifeCycleName != null and "DESC".equalsIgnoreCase(orderCol.lifeCycleName)'>DESC</if>
, ,
</if> </if>
<if test="orderCol.containsKey('matterId')">
a.matter_id
<if test='orderCol.matterId != null and "DESC".equalsIgnoreCase(orderCol.matterId)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('matterName')">
a.matter_name
<if test='orderCol.matterName != null and "DESC".equalsIgnoreCase(orderCol.matterName)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('matterCode')">
a.matter_code
<if test='orderCol.matterCode != null and "DESC".equalsIgnoreCase(orderCol.matterCode)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('areaCode')">
a.area_code
<if test='orderCol.areaCode != null and "DESC".equalsIgnoreCase(orderCol.areaCode)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('areaName')">
a.area_name
<if test='orderCol.areaName != null and "DESC".equalsIgnoreCase(orderCol.areaName)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('areaLevel')">
a.area_level
<if test='orderCol.areaLevel != null and "DESC".equalsIgnoreCase(orderCol.areaLevel)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('deptId')"> <if test="orderCol.containsKey('deptId')">
a.dept_id a.dept_id
<if test='orderCol.deptId != null and "DESC".equalsIgnoreCase(orderCol.deptId)'>DESC</if> <if test='orderCol.deptId != null and "DESC".equalsIgnoreCase(orderCol.deptId)'>DESC</if>
, ,
</if> </if>
<if test="orderCol.containsKey('deptName')">
a.dept_name
<if test='orderCol.deptName != null and "DESC".equalsIgnoreCase(orderCol.deptName)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('remark')"> <if test="orderCol.containsKey('remark')">
a.remark a.remark
<if test='orderCol.remark != null and "DESC".equalsIgnoreCase(orderCol.remark)'>DESC</if> <if test='orderCol.remark != null and "DESC".equalsIgnoreCase(orderCol.remark)'>DESC</if>
...@@ -966,6 +665,11 @@ ...@@ -966,6 +665,11 @@
<if test='orderCol.updateTime != null and "DESC".equalsIgnoreCase(orderCol.updateTime)'>DESC</if> <if test='orderCol.updateTime != null and "DESC".equalsIgnoreCase(orderCol.updateTime)'>DESC</if>
, ,
</if> </if>
<if test="orderCol.containsKey('matterGroupName')">
a.matter_group_name
<if test='orderCol.matterGroupName != null and "DESC".equalsIgnoreCase(orderCol.matterGroupName)'>DESC</if>
,
</if>
</trim> </trim>
</if> </if>
......
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"mybatis-3-mapper.dtd"> "mybatis-3-mapper.dtd">
<mapper namespace="com.mortals.xhx.module.ent.dao.ibatis.EntLifeMatterSubDaoImpl"> <mapper namespace="com.mortals.xhx.module.ent.dao.ibatis.EntLifeMatterSubDaoImpl">
<!-- 字段和属性映射 --> <!-- 字段和属性映射 -->
...@@ -20,6 +20,7 @@ ...@@ -20,6 +20,7 @@
<result property="createUserName" column="create_user_name" /> <result property="createUserName" column="create_user_name" />
<result property="createTime" column="create_time" /> <result property="createTime" column="create_time" />
<result property="updateTime" column="update_time" /> <result property="updateTime" column="update_time" />
<result property="sort" column="sort" />
</resultMap> </resultMap>
<!-- 表所有列 --> <!-- 表所有列 -->
...@@ -70,23 +71,26 @@ ...@@ -70,23 +71,26 @@
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('updateTime') or colPickMode == 1 and data.containsKey('updateTime')))"> <if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('updateTime') or colPickMode == 1 and data.containsKey('updateTime')))">
a.update_time, a.update_time,
</if> </if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('sort') or colPickMode == 1 and data.containsKey('sort')))">
a.sort,
</if>
</trim> </trim>
</sql> </sql>
<!-- 新增 区分主键自增加还是业务插入 --> <!-- 新增 区分主键自增加还是业务插入 -->
<insert id="insert" parameterType="EntLifeMatterSubEntity" useGeneratedKeys="true" keyProperty="id"> <insert id="insert" parameterType="EntLifeMatterSubEntity" useGeneratedKeys="true" keyProperty="id">
insert into mortals_ent_life_matter_sub insert into mortals_ent_life_matter_sub
(master_record_id,matter_id,matter_name,matter_code,area_code,area_name,area_level,dept_id,dept_name,remark,create_user_id,create_user_name,create_time,update_time) (master_record_id,matter_id,matter_name,matter_code,area_code,area_name,area_level,dept_id,dept_name,remark,create_user_id,create_user_name,create_time,update_time,sort)
VALUES VALUES
(#{masterRecordId},#{matterId},#{matterName},#{matterCode},#{areaCode},#{areaName},#{areaLevel},#{deptId},#{deptName},#{remark},#{createUserId},#{createUserName},#{createTime},#{updateTime}) (#{masterRecordId},#{matterId},#{matterName},#{matterCode},#{areaCode},#{areaName},#{areaLevel},#{deptId},#{deptName},#{remark},#{createUserId},#{createUserName},#{createTime},#{updateTime},#{sort})
</insert> </insert>
<!-- 批量新增 --> <!-- 批量新增 -->
<insert id="insertBatch" parameterType="paramDto"> <insert id="insertBatch" parameterType="paramDto">
insert into mortals_ent_life_matter_sub insert into mortals_ent_life_matter_sub
(master_record_id,matter_id,matter_name,matter_code,area_code,area_name,area_level,dept_id,dept_name,remark,create_user_id,create_user_name,create_time,update_time) (master_record_id,matter_id,matter_name,matter_code,area_code,area_name,area_level,dept_id,dept_name,remark,create_user_id,create_user_name,create_time,update_time,sort)
VALUES VALUES
<foreach collection="data.dataList" item="item" index="index" separator="," > <foreach collection="data.dataList" item="item" index="index" separator="," >
(#{item.masterRecordId},#{item.matterId},#{item.matterName},#{item.matterCode},#{item.areaCode},#{item.areaName},#{item.areaLevel},#{item.deptId},#{item.deptName},#{item.remark},#{item.createUserId},#{item.createUserName},#{item.createTime},#{item.updateTime}) (#{item.masterRecordId},#{item.matterId},#{item.matterName},#{item.matterCode},#{item.areaCode},#{item.areaName},#{item.areaLevel},#{item.deptId},#{item.deptName},#{item.remark},#{item.createUserId},#{item.createUserName},#{item.createTime},#{item.updateTime},#{item.sort})
</foreach> </foreach>
</insert> </insert>
...@@ -153,6 +157,12 @@ ...@@ -153,6 +157,12 @@
<if test="(colPickMode==0 and data.containsKey('updateTime')) or (colPickMode==1 and !data.containsKey('updateTime'))"> <if test="(colPickMode==0 and data.containsKey('updateTime')) or (colPickMode==1 and !data.containsKey('updateTime'))">
a.update_time=#{data.updateTime}, a.update_time=#{data.updateTime},
</if> </if>
<if test="(colPickMode==0 and data.containsKey('sort')) or (colPickMode==1 and !data.containsKey('sort'))">
a.sort=#{data.sort},
</if>
<if test="(colPickMode==0 and data.containsKey('sortIncrement')) or (colPickMode==1 and !data.containsKey('sortIncrement'))">
a.sort=ifnull(a.sort,0) + #{data.sortIncrement},
</if>
</trim> </trim>
<trim suffixOverrides="where" suffix=""> <trim suffixOverrides="where" suffix="">
where where
...@@ -288,6 +298,18 @@ ...@@ -288,6 +298,18 @@
</if> </if>
</foreach> </foreach>
</trim> </trim>
<trim prefix="sort=(case" suffix="ELSE sort end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('sort')) or (colPickMode==1 and !item.containsKey('sort'))">
when a.id=#{item.id} then #{item.sort}
</when>
<when test="(colPickMode==0 and item.containsKey('sortIncrement')) or (colPickMode==1 and !item.containsKey('sortIncrement'))">
when a.id=#{item.id} then ifnull(a.sort,0) + #{item.sortIncrement}
</when>
</choose>
</foreach>
</trim>
</trim> </trim>
where id in where id in
<foreach collection="data.dataList" item="item" index="index" open="(" separator="," close=")"> <foreach collection="data.dataList" item="item" index="index" open="(" separator="," close=")">
...@@ -747,6 +769,33 @@ ...@@ -747,6 +769,33 @@
<if test="conditionParamRef.containsKey('updateTimeEnd') and conditionParamRef.updateTimeEnd != null and conditionParamRef.updateTimeEnd!=''"> <if test="conditionParamRef.containsKey('updateTimeEnd') and conditionParamRef.updateTimeEnd != null and conditionParamRef.updateTimeEnd!=''">
${_conditionType_} a.update_time <![CDATA[ <= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.updateTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s') ${_conditionType_} a.update_time <![CDATA[ <= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.updateTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s')
</if> </if>
<if test="conditionParamRef.containsKey('sort')">
<if test="conditionParamRef.sort != null ">
${_conditionType_} a.sort = #{${_conditionParam_}.sort}
</if>
<if test="conditionParamRef.sort == null">
${_conditionType_} a.sort is null
</if>
</if>
<if test="conditionParamRef.containsKey('sortList') and conditionParamRef.sortList.size() > 0">
${_conditionType_} a.sort in
<foreach collection="conditionParamRef.sortList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('sortNotList') and conditionParamRef.sortNotList.size() > 0">
${_conditionType_} a.sort not in
<foreach collection="conditionParamRef.sortNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('sortStart') and conditionParamRef.sortStart != null">
${_conditionType_} a.sort <![CDATA[ >= ]]> #{${_conditionParam_}.sortStart}
</if>
<if test="conditionParamRef.containsKey('sortEnd') and conditionParamRef.sortEnd != null">
${_conditionType_} a.sort <![CDATA[ <= ]]> #{${_conditionParam_}.sortEnd}
</if>
</sql> </sql>
<sql id="_orderCols_"> <sql id="_orderCols_">
<if test="orderColList != null and !orderColList.isEmpty()"> <if test="orderColList != null and !orderColList.isEmpty()">
...@@ -793,6 +842,13 @@ ...@@ -793,6 +842,13 @@
</foreach> </foreach>
, ,
</if> </if>
<if test="conditionParamRef.containsKey('sortList') and conditionParamRef.sortList.size() > 0">
field(a.sort,
<foreach collection="conditionParamRef.sortList" open="" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
,
</if>
<trim suffixOverrides="," suffix=""> <trim suffixOverrides="," suffix="">
<foreach collection="orderColList" open="" close="" index="index" item="item" separator=","> <foreach collection="orderColList" open="" close="" index="index" item="item" separator=",">
a.${item.colName} ${item.sortKind} a.${item.colName} ${item.sortKind}
...@@ -843,6 +899,13 @@ ...@@ -843,6 +899,13 @@
</foreach> </foreach>
, ,
</if> </if>
<if test="conditionParamRef.containsKey('sortList') and conditionParamRef.sortList.size() > 0">
field(a.sort,
<foreach collection="conditionParamRef.sortList" open="" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
,
</if>
<trim suffixOverrides="," suffix=""> <trim suffixOverrides="," suffix="">
<if test="orderCol.containsKey('id')"> <if test="orderCol.containsKey('id')">
a.id a.id
...@@ -919,6 +982,11 @@ ...@@ -919,6 +982,11 @@
<if test='orderCol.updateTime != null and "DESC".equalsIgnoreCase(orderCol.updateTime)'>DESC</if> <if test='orderCol.updateTime != null and "DESC".equalsIgnoreCase(orderCol.updateTime)'>DESC</if>
, ,
</if> </if>
<if test="orderCol.containsKey('sort')">
a.sort
<if test='orderCol.sort != null and "DESC".equalsIgnoreCase(orderCol.sort)'>DESC</if>
,
</if>
</trim> </trim>
</if> </if>
......
...@@ -15,6 +15,7 @@ client.global.set("authToken", JSON.parse(response.body).data.token); ...@@ -15,6 +15,7 @@ client.global.set("authToken", JSON.parse(response.body).data.token);
###企业生命周期列表 ###企业生命周期列表
POST {{baseUrl}}/ent/life/cycle/list POST {{baseUrl}}/ent/life/cycle/list
Authorization: {{authToken}}
Content-Type: application/json Content-Type: application/json
{ {
...@@ -33,7 +34,7 @@ Content-Type: application/json ...@@ -33,7 +34,7 @@ Content-Type: application/json
"lifeCycleName":"tiaNvx", "lifeCycleName":"tiaNvx",
"sort":0, "sort":0,
"remark":"tpsUjo", "remark":"tpsUjo",
"createUserName":"PrDtwb", "createUserName":"PrDtwb"
} }
> {% > {%
......
...@@ -46,26 +46,6 @@ POST {{baseUrl}}/resource/refreshUrl ...@@ -46,26 +46,6 @@ POST {{baseUrl}}/resource/refreshUrl
Accept: application/json Accept: application/json
###测试json提交
POST {{baseUrl}}/test/getHcpSin/json
Content-Type: application/json
{"affairCode":"abcd1234ddddd"}
###针对某一接入
POST {{baseUrl}}/role/auth/editMenu
Authorization: {{authToken}}
Content-Type: application/json
{
"roleId": 2
}
###子区域更新 ###子区域更新
POST {{baseUrl}}/base/area/genSubAreaByAreaName POST {{baseUrl}}/base/area/genSubAreaByAreaName
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment