Commit 673f7664 authored by 廖旭伟's avatar 廖旭伟

Merge remote-tracking branch 'origin/master'

parents b58eb377 d2cdffbd
...@@ -31,9 +31,14 @@ CREATE TABLE `mortals_xhx_child_license` ( ...@@ -31,9 +31,14 @@ CREATE TABLE `mortals_xhx_child_license` (
`formContent` mediumtext COMMENT '提交的表单', `formContent` mediumtext COMMENT '提交的表单',
`processStatus` tinyint(2) DEFAULT '0' COMMENT '处理状态(0.未处理,1.已处理)', `processStatus` tinyint(2) DEFAULT '0' COMMENT '处理状态(0.未处理,1.已处理)',
`remark` varchar(2048) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '备注', `remark` varchar(2048) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '备注',
`reportUserId` bigint(20) DEFAULT NULL COMMENT '联报用户',
`reportUserName` varchar(64) DEFAULT NULL COMMENT '联报用户名称',
`reportTime` datetime DEFAULT NULL COMMENT '联报时间',
`createTime` datetime(0) NOT NULL COMMENT '创建时间', `createTime` datetime(0) NOT NULL COMMENT '创建时间',
`createUserId` bigint(20) NOT NULL COMMENT '创建用户', `createUserId` bigint(20) NOT NULL COMMENT '创建用户',
`createUserName` varchar(64) DEFAULT NULL COMMENT '创建用户名称',
`updateUserId` bigint(20) DEFAULT NULL COMMENT '更新用户', `updateUserId` bigint(20) DEFAULT NULL COMMENT '更新用户',
`updateUserName` varchar(64) DEFAULT NULL COMMENT '更新用户名称',
`updateTime` datetime DEFAULT NULL COMMENT '更新时间', `updateTime` datetime DEFAULT NULL COMMENT '更新时间',
PRIMARY KEY (`id`) USING BTREE, PRIMARY KEY (`id`) USING BTREE,
KEY `siteId` (`siteId`) USING BTREE, KEY `siteId` (`siteId`) USING BTREE,
...@@ -43,3 +48,4 @@ CREATE TABLE `mortals_xhx_child_license` ( ...@@ -43,3 +48,4 @@ CREATE TABLE `mortals_xhx_child_license` (
KEY `deptId` (`deptId`) USING BTREE KEY `deptId` (`deptId`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '行业许可子证' ROW_FORMAT = Dynamic; ) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci COMMENT = '行业许可子证' ROW_FORMAT = Dynamic;
ALTER TABLE mortals_xhx_child_license ADD COLUMN `resolutionValue` varchar(64) DEFAULT '' COMMENT '设备分辨率' AFTER resolution;
...@@ -116,9 +116,10 @@ public class LoginController extends BaseCRUDJsonBodyMappingController<UserServi ...@@ -116,9 +116,10 @@ public class LoginController extends BaseCRUDJsonBodyMappingController<UserServi
} }
@RequestMapping("logout") @RequestMapping("logout")
public void logout(HttpServletRequest request, HttpServletResponse response) throws Exception { public Rest<String> logout(HttpServletRequest request, HttpServletResponse response) throws Exception {
recordSysLog(request, "退出登录"); recordSysLog(request, "退出登录");
super.removeCurrUser(request); super.removeCurrUser(request);
return Rest.ok("退出登录成功");
} }
@RequestMapping("index") @RequestMapping("index")
......
package com.mortals.xhx.module.certificate.web; package com.mortals.xhx.module.certificate.web;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.model.Context; import com.mortals.framework.model.Context;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController; import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.base.system.param.service.ParamService; import com.mortals.xhx.base.system.param.service.ParamService;
...@@ -10,6 +11,7 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -10,6 +11,7 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import java.util.List;
import java.util.Map; import java.util.Map;
/** /**
* *
...@@ -36,6 +38,12 @@ public class CertificateDocumentController extends BaseCRUDJsonBodyMappingContro ...@@ -36,6 +38,12 @@ public class CertificateDocumentController extends BaseCRUDJsonBodyMappingContro
} }
@Override
protected void doListAfter(CertificateDocumentEntity query, List<CertificateDocumentEntity> list, Context context) throws AppException {
list.forEach(item->{
item.setFormContent("");
});
super.doListAfter(query, list, context);
}
} }
\ No newline at end of file
...@@ -11,11 +11,11 @@ import com.mortals.framework.model.BaseEntityLong; ...@@ -11,11 +11,11 @@ import com.mortals.framework.model.BaseEntityLong;
import com.mortals.xhx.module.child.model.vo.ChildLicenseVo; import com.mortals.xhx.module.child.model.vo.ChildLicenseVo;
import lombok.Data; import lombok.Data;
/** /**
* 行业许可子证实体对象 * 行业许可子证实体对象
* *
* @author zxfei * @author zxfei
* @date 2024-07-28 * @date 2024-07-28
*/ */
@Data @Data
public class ChildLicenseEntity extends ChildLicenseVo { public class ChildLicenseEntity extends ChildLicenseVo {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
...@@ -128,6 +128,26 @@ public class ChildLicenseEntity extends ChildLicenseVo { ...@@ -128,6 +128,26 @@ public class ChildLicenseEntity extends ChildLicenseVo {
* 备注 * 备注
*/ */
private String remark; private String remark;
/**
* 联报用户
*/
private Long reportUserId;
/**
* 联报用户名称
*/
private String reportUserName;
/**
* 联报时间
*/
private Date reportTime;
/**
* 创建用户名称
*/
private String createUserName;
/**
* 更新用户名称
*/
private String updateUserName;
@Override @Override
public int hashCode() { public int hashCode() {
return this.getId().hashCode(); return this.getId().hashCode();
...@@ -172,5 +192,10 @@ public class ChildLicenseEntity extends ChildLicenseVo { ...@@ -172,5 +192,10 @@ public class ChildLicenseEntity extends ChildLicenseVo {
this.formContent = ""; this.formContent = "";
this.processStatus = 0; this.processStatus = 0;
this.remark = ""; this.remark = "";
this.reportUserId = null;
this.reportUserName = "";
this.reportTime = null;
this.createUserName = "";
this.updateUserName = "";
} }
} }
\ No newline at end of file
...@@ -4,11 +4,11 @@ import java.util.Date; ...@@ -4,11 +4,11 @@ import java.util.Date;
import java.util.List; import java.util.List;
import com.mortals.xhx.module.child.model.ChildLicenseEntity; import com.mortals.xhx.module.child.model.ChildLicenseEntity;
/** /**
* 行业许可子证查询对象 * 行业许可子证查询对象
* *
* @author zxfei * @author zxfei
* @date 2024-07-28 * @date 2024-07-28
*/ */
public class ChildLicenseQuery extends ChildLicenseEntity { public class ChildLicenseQuery extends ChildLicenseEntity {
/** 开始 主键ID,主键,自增长 */ /** 开始 主键ID,主键,自增长 */
private Long idStart; private Long idStart;
...@@ -263,6 +263,42 @@ public class ChildLicenseQuery extends ChildLicenseEntity { ...@@ -263,6 +263,42 @@ public class ChildLicenseQuery extends ChildLicenseEntity {
/** 结束 更新时间 */ /** 结束 更新时间 */
private String updateTimeEnd; private String updateTimeEnd;
/** 开始 联报用户 */
private Long reportUserIdStart;
/** 结束 联报用户 */
private Long reportUserIdEnd;
/** 增加 联报用户 */
private Long reportUserIdIncrement;
/** 联报用户列表 */
private List <Long> reportUserIdList;
/** 联报用户排除列表 */
private List <Long> reportUserIdNotList;
/** 联报用户名称 */
private List<String> reportUserNameList;
/** 联报用户名称排除列表 */
private List <String> reportUserNameNotList;
/** 开始 联报时间 */
private String reportTimeStart;
/** 结束 联报时间 */
private String reportTimeEnd;
/** 创建用户名称 */
private List<String> createUserNameList;
/** 创建用户名称排除列表 */
private List <String> createUserNameNotList;
/** 更新用户名称 */
private List<String> updateUserNameList;
/** 更新用户名称排除列表 */
private List <String> updateUserNameNotList;
/** 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<ChildLicenseQuery> orConditionList; private List<ChildLicenseQuery> orConditionList;
...@@ -1736,6 +1772,215 @@ public class ChildLicenseQuery extends ChildLicenseEntity { ...@@ -1736,6 +1772,215 @@ public class ChildLicenseQuery extends ChildLicenseEntity {
this.updateTimeEnd = updateTimeEnd; this.updateTimeEnd = updateTimeEnd;
} }
/**
* 获取 开始 联报用户
* @return reportUserIdStart
*/
public Long getReportUserIdStart(){
return this.reportUserIdStart;
}
/**
* 设置 开始 联报用户
* @param reportUserIdStart
*/
public void setReportUserIdStart(Long reportUserIdStart){
this.reportUserIdStart = reportUserIdStart;
}
/**
* 获取 结束 联报用户
* @return $reportUserIdEnd
*/
public Long getReportUserIdEnd(){
return this.reportUserIdEnd;
}
/**
* 设置 结束 联报用户
* @param reportUserIdEnd
*/
public void setReportUserIdEnd(Long reportUserIdEnd){
this.reportUserIdEnd = reportUserIdEnd;
}
/**
* 获取 增加 联报用户
* @return reportUserIdIncrement
*/
public Long getReportUserIdIncrement(){
return this.reportUserIdIncrement;
}
/**
* 设置 增加 联报用户
* @param reportUserIdIncrement
*/
public void setReportUserIdIncrement(Long reportUserIdIncrement){
this.reportUserIdIncrement = reportUserIdIncrement;
}
/**
* 获取 联报用户
* @return reportUserIdList
*/
public List<Long> getReportUserIdList(){
return this.reportUserIdList;
}
/**
* 设置 联报用户
* @param reportUserIdList
*/
public void setReportUserIdList(List<Long> reportUserIdList){
this.reportUserIdList = reportUserIdList;
}
/**
* 获取 联报用户
* @return reportUserIdNotList
*/
public List<Long> getReportUserIdNotList(){
return this.reportUserIdNotList;
}
/**
* 设置 联报用户
* @param reportUserIdNotList
*/
public void setReportUserIdNotList(List<Long> reportUserIdNotList){
this.reportUserIdNotList = reportUserIdNotList;
}
/**
* 获取 联报用户名称
* @return reportUserNameList
*/
public List<String> getReportUserNameList(){
return this.reportUserNameList;
}
/**
* 设置 联报用户名称
* @param reportUserNameList
*/
public void setReportUserNameList(List<String> reportUserNameList){
this.reportUserNameList = reportUserNameList;
}
/**
* 获取 联报用户名称
* @return reportUserNameNotList
*/
public List<String> getReportUserNameNotList(){
return this.reportUserNameNotList;
}
/**
* 设置 联报用户名称
* @param reportUserNameNotList
*/
public void setReportUserNameNotList(List<String> reportUserNameNotList){
this.reportUserNameNotList = reportUserNameNotList;
}
/**
* 获取 开始 联报时间
* @return reportTimeStart
*/
public String getReportTimeStart(){
return this.reportTimeStart;
}
/**
* 设置 开始 联报时间
* @param reportTimeStart
*/
public void setReportTimeStart(String reportTimeStart){
this.reportTimeStart = reportTimeStart;
}
/**
* 获取 结束 联报时间
* @return reportTimeEnd
*/
public String getReportTimeEnd(){
return this.reportTimeEnd;
}
/**
* 设置 结束 联报时间
* @param reportTimeEnd
*/
public void setReportTimeEnd(String reportTimeEnd){
this.reportTimeEnd = reportTimeEnd;
}
/**
* 获取 创建用户名称
* @return createUserNameList
*/
public List<String> getCreateUserNameList(){
return this.createUserNameList;
}
/**
* 设置 创建用户名称
* @param createUserNameList
*/
public void setCreateUserNameList(List<String> createUserNameList){
this.createUserNameList = createUserNameList;
}
/**
* 获取 创建用户名称
* @return createUserNameNotList
*/
public List<String> getCreateUserNameNotList(){
return this.createUserNameNotList;
}
/**
* 设置 创建用户名称
* @param createUserNameNotList
*/
public void setCreateUserNameNotList(List<String> createUserNameNotList){
this.createUserNameNotList = createUserNameNotList;
}
/**
* 获取 更新用户名称
* @return updateUserNameList
*/
public List<String> getUpdateUserNameList(){
return this.updateUserNameList;
}
/**
* 设置 更新用户名称
* @param updateUserNameList
*/
public void setUpdateUserNameList(List<String> updateUserNameList){
this.updateUserNameList = updateUserNameList;
}
/**
* 获取 更新用户名称
* @return updateUserNameNotList
*/
public List<String> getUpdateUserNameNotList(){
return this.updateUserNameNotList;
}
/**
* 设置 更新用户名称
* @param updateUserNameNotList
*/
public void setUpdateUserNameNotList(List<String> updateUserNameNotList){
this.updateUserNameNotList = updateUserNameNotList;
}
/** /**
* 设置 主键ID,主键,自增长 * 设置 主键ID,主键,自增长
* @param id * @param id
...@@ -2605,6 +2850,118 @@ public class ChildLicenseQuery extends ChildLicenseEntity { ...@@ -2605,6 +2850,118 @@ public class ChildLicenseQuery extends ChildLicenseEntity {
} }
/**
* 设置 联报用户
* @param reportUserId
*/
public ChildLicenseQuery reportUserId(Long reportUserId){
setReportUserId(reportUserId);
return this;
}
/**
* 设置 开始 联报用户
* @param reportUserIdStart
*/
public ChildLicenseQuery reportUserIdStart(Long reportUserIdStart){
this.reportUserIdStart = reportUserIdStart;
return this;
}
/**
* 设置 结束 联报用户
* @param reportUserIdEnd
*/
public ChildLicenseQuery reportUserIdEnd(Long reportUserIdEnd){
this.reportUserIdEnd = reportUserIdEnd;
return this;
}
/**
* 设置 增加 联报用户
* @param reportUserIdIncrement
*/
public ChildLicenseQuery reportUserIdIncrement(Long reportUserIdIncrement){
this.reportUserIdIncrement = reportUserIdIncrement;
return this;
}
/**
* 设置 联报用户
* @param reportUserIdList
*/
public ChildLicenseQuery reportUserIdList(List<Long> reportUserIdList){
this.reportUserIdList = reportUserIdList;
return this;
}
/**
* 设置 联报用户
* @param reportUserIdNotList
*/
public ChildLicenseQuery reportUserIdNotList(List<Long> reportUserIdNotList){
this.reportUserIdNotList = reportUserIdNotList;
return this;
}
/**
* 设置 联报用户名称
* @param reportUserName
*/
public ChildLicenseQuery reportUserName(String reportUserName){
setReportUserName(reportUserName);
return this;
}
/**
* 设置 联报用户名称
* @param reportUserNameList
*/
public ChildLicenseQuery reportUserNameList(List<String> reportUserNameList){
this.reportUserNameList = reportUserNameList;
return this;
}
/**
* 设置 创建用户名称
* @param createUserName
*/
public ChildLicenseQuery createUserName(String createUserName){
setCreateUserName(createUserName);
return this;
}
/**
* 设置 创建用户名称
* @param createUserNameList
*/
public ChildLicenseQuery createUserNameList(List<String> createUserNameList){
this.createUserNameList = createUserNameList;
return this;
}
/**
* 设置 更新用户名称
* @param updateUserName
*/
public ChildLicenseQuery updateUserName(String updateUserName){
setUpdateUserName(updateUserName);
return this;
}
/**
* 设置 更新用户名称
* @param updateUserNameList
*/
public ChildLicenseQuery updateUserNameList(List<String> updateUserNameList){
this.updateUserNameList = updateUserNameList;
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
......
...@@ -19,5 +19,10 @@ public class ChildLicenseVo extends BaseEntityLong { ...@@ -19,5 +19,10 @@ public class ChildLicenseVo extends BaseEntityLong {
/** 主键ID,主键,自增长列表 */ /** 主键ID,主键,自增长列表 */
private List <Long> idList; private List <Long> idList;
/** 开始 创建时间 */
private String createTimeStart;
/** 结束 创建时间 */
private String createTimeEnd;
} }
\ No newline at end of file
...@@ -81,4 +81,7 @@ public class ChildLicenseServiceImpl extends AbstractCRUDServiceImpl<ChildLicens ...@@ -81,4 +81,7 @@ public class ChildLicenseServiceImpl extends AbstractCRUDServiceImpl<ChildLicens
} }
return result; return result;
} }
} }
\ No newline at end of file
package com.mortals.xhx.module.child.web; package com.mortals.xhx.module.child.web;
import com.mortals.framework.common.Rest; import com.mortals.framework.common.Rest;
import com.mortals.framework.exception.AppException;
import com.mortals.framework.web.BaseCRUDJsonBodyMappingController; import com.mortals.framework.web.BaseCRUDJsonBodyMappingController;
import com.mortals.xhx.annotation.DataPermission; import com.mortals.xhx.annotation.DataPermission;
import com.mortals.xhx.base.system.param.service.ParamService; import com.mortals.xhx.base.system.param.service.ParamService;
import com.mortals.xhx.module.certificate.model.CertificateDocumentQuery;
import com.mortals.xhx.module.certificate.service.CertificateDocumentService;
import com.mortals.xhx.module.device.model.DeviceEntity;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
...@@ -19,15 +23,11 @@ import com.mortals.xhx.module.child.service.ChildLicenseService; ...@@ -19,15 +23,11 @@ import com.mortals.xhx.module.child.service.ChildLicenseService;
import org.apache.commons.lang3.ArrayUtils; import org.apache.commons.lang3.ArrayUtils;
import com.mortals.framework.util.StringUtils; import com.mortals.framework.util.StringUtils;
import java.util.HashMap; import java.util.*;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import java.util.Arrays;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
...@@ -45,8 +45,9 @@ import com.mortals.xhx.common.code.*; ...@@ -45,8 +45,9 @@ import com.mortals.xhx.common.code.*;
@RequestMapping("child/license") @RequestMapping("child/license")
public class ChildLicenseController extends BaseCRUDJsonBodyMappingController<ChildLicenseService, ChildLicenseEntity, Long> { public class ChildLicenseController extends BaseCRUDJsonBodyMappingController<ChildLicenseService, ChildLicenseEntity, Long> {
@Autowired @Autowired
private ParamService paramService; private CertificateDocumentService certificateDocumentService;
public ChildLicenseController() { public ChildLicenseController() {
super.setModuleDesc("行业许可子证"); super.setModuleDesc("行业许可子证");
...@@ -56,6 +57,11 @@ public class ChildLicenseController extends BaseCRUDJsonBodyMappingController<Ch ...@@ -56,6 +57,11 @@ public class ChildLicenseController extends BaseCRUDJsonBodyMappingController<Ch
protected void init(Map<String, Object> model, Context context) { protected void init(Map<String, Object> model, Context context) {
this.addDict(model, "legalPersonName", LegalPersonNameEnum.getEnumMap()); this.addDict(model, "legalPersonName", LegalPersonNameEnum.getEnumMap());
this.addDict(model, "processStatus", ProcessStatusEnum.getEnumMap()); this.addDict(model, "processStatus", ProcessStatusEnum.getEnumMap());
this.addDict(model, "documentId", certificateDocumentService.find(new CertificateDocumentQuery())
.stream().collect(Collectors.toMap(x -> x.getId(), y -> y.getDocumentName(), (o, n) -> n)));
super.init(model, context); super.init(model, context);
} }
...@@ -64,4 +70,47 @@ public class ChildLicenseController extends BaseCRUDJsonBodyMappingController<Ch ...@@ -64,4 +70,47 @@ public class ChildLicenseController extends BaseCRUDJsonBodyMappingController<Ch
public Rest<Object> list(@RequestBody ChildLicenseEntity query) { public Rest<Object> list(@RequestBody ChildLicenseEntity query) {
return super.list(query); return super.list(query);
} }
@Override
protected void doListAfter(ChildLicenseEntity query, List<ChildLicenseEntity> list, Context context) throws AppException {
list.forEach(item -> {
item.setFormContent("");
item.setFormStyleContent("");
});
super.doListAfter(query, list, context);
}
/**
* 子证联报
*/
@PostMapping(value = "report")
public String report(@RequestBody ChildLicenseEntity childLicenseEntity) {
JSONObject jsonObject = new JSONObject();
Map<String, Object> model = new HashMap<>();
String busiDesc = this.getModuleDesc() + "联报";
try {
if (childLicenseEntity.newEntity()) throw new AppException("Id不能为空!");
ChildLicenseEntity sourceEntity = this.service.get(childLicenseEntity.getId());
if (ProcessStatusEnum.已处理.getValue() == sourceEntity.getProcessStatus())
throw new AppException("当前子证已经联报");
childLicenseEntity.setReportUserId(this.getContextUserId(getContext()));
childLicenseEntity.setReportUserName(this.getContext().getUser().getRealName());
childLicenseEntity.setReportTime(new Date());
childLicenseEntity.setProcessStatus(ProcessStatusEnum.已处理.getValue());
this.service.update(childLicenseEntity, getContext());
recordSysLog(request, busiDesc + " 【成功】");
jsonObject.put(KEY_RESULT_DATA, model);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_SUCCESS);
} catch (Exception e) {
log.error("子证联报异常", e);
jsonObject.put(KEY_RESULT_CODE, VALUE_RESULT_FAILURE);
jsonObject.put(KEY_RESULT_MSG, super.convertException(e));
}
return jsonObject.toJSONString();
}
} }
\ No newline at end of file
<?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.child.dao.ibatis.ChildLicenseDaoImpl"> <mapper namespace="com.mortals.xhx.module.child.dao.ibatis.ChildLicenseDaoImpl">
<!-- 字段和属性映射 --> <!-- 字段和属性映射 -->
...@@ -37,6 +37,11 @@ ...@@ -37,6 +37,11 @@
<result property="createUserId" column="createUserId" /> <result property="createUserId" column="createUserId" />
<result property="updateUserId" column="updateUserId" /> <result property="updateUserId" column="updateUserId" />
<result property="updateTime" column="updateTime" /> <result property="updateTime" column="updateTime" />
<result property="reportUserId" column="reportUserId" />
<result property="reportUserName" column="reportUserName" />
<result property="reportTime" column="reportTime" />
<result property="createUserName" column="createUserName" />
<result property="updateUserName" column="updateUserName" />
</resultMap> </resultMap>
<!-- 表所有列 --> <!-- 表所有列 -->
...@@ -138,23 +143,38 @@ ...@@ -138,23 +143,38 @@
<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.updateTime, a.updateTime,
</if> </if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('reportUserId') or colPickMode == 1 and data.containsKey('reportUserId')))">
a.reportUserId,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('reportUserName') or colPickMode == 1 and data.containsKey('reportUserName')))">
a.reportUserName,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('reportTime') or colPickMode == 1 and data.containsKey('reportTime')))">
a.reportTime,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('createUserName') or colPickMode == 1 and data.containsKey('createUserName')))">
a.createUserName,
</if>
<if test="(data == null) or (data != null and ( colPickMode == 0 and !data.containsKey('updateUserName') or colPickMode == 1 and data.containsKey('updateUserName')))">
a.updateUserName,
</if>
</trim> </trim>
</sql> </sql>
<!-- 新增 区分主键自增加还是业务插入 --> <!-- 新增 区分主键自增加还是业务插入 -->
<insert id="insert" parameterType="ChildLicenseEntity" useGeneratedKeys="true" keyProperty="id"> <insert id="insert" parameterType="ChildLicenseEntity" useGeneratedKeys="true" keyProperty="id">
insert into mortals_xhx_child_license insert into mortals_xhx_child_license
(siteId,siteName,catalogId,catalogName,applyId,documentId,documentName,deptId,deptName,marketEntityName,licenseCode,legalPersonName,creditCode,productLicenseTime,certQRCode,certAuthority,businessPlace,licensedItems,originalFileName,originalFilePath,copyFileName,copyFilePath,summary,formStyleContent,formContent,processStatus,remark,createTime,createUserId,updateUserId,updateTime) (siteId,siteName,catalogId,catalogName,applyId,documentId,documentName,deptId,deptName,marketEntityName,licenseCode,legalPersonName,creditCode,productLicenseTime,certQRCode,certAuthority,businessPlace,licensedItems,originalFileName,originalFilePath,copyFileName,copyFilePath,summary,formStyleContent,formContent,processStatus,remark,createTime,createUserId,updateUserId,updateTime,reportUserId,reportUserName,reportTime,createUserName,updateUserName)
VALUES VALUES
(#{siteId},#{siteName},#{catalogId},#{catalogName},#{applyId},#{documentId},#{documentName},#{deptId},#{deptName},#{marketEntityName},#{licenseCode},#{legalPersonName},#{creditCode},#{productLicenseTime},#{certQRCode},#{certAuthority},#{businessPlace},#{licensedItems},#{originalFileName},#{originalFilePath},#{copyFileName},#{copyFilePath},#{summary},#{formStyleContent},#{formContent},#{processStatus},#{remark},#{createTime},#{createUserId},#{updateUserId},#{updateTime}) (#{siteId},#{siteName},#{catalogId},#{catalogName},#{applyId},#{documentId},#{documentName},#{deptId},#{deptName},#{marketEntityName},#{licenseCode},#{legalPersonName},#{creditCode},#{productLicenseTime},#{certQRCode},#{certAuthority},#{businessPlace},#{licensedItems},#{originalFileName},#{originalFilePath},#{copyFileName},#{copyFilePath},#{summary},#{formStyleContent},#{formContent},#{processStatus},#{remark},#{createTime},#{createUserId},#{updateUserId},#{updateTime},#{reportUserId},#{reportUserName},#{reportTime},#{createUserName},#{updateUserName})
</insert> </insert>
<!-- 批量新增 --> <!-- 批量新增 -->
<insert id="insertBatch" parameterType="paramDto"> <insert id="insertBatch" parameterType="paramDto">
insert into mortals_xhx_child_license insert into mortals_xhx_child_license
(siteId,siteName,catalogId,catalogName,applyId,documentId,documentName,deptId,deptName,marketEntityName,licenseCode,legalPersonName,creditCode,productLicenseTime,certQRCode,certAuthority,businessPlace,licensedItems,originalFileName,originalFilePath,copyFileName,copyFilePath,summary,formStyleContent,formContent,processStatus,remark,createTime,createUserId,updateUserId,updateTime) (siteId,siteName,catalogId,catalogName,applyId,documentId,documentName,deptId,deptName,marketEntityName,licenseCode,legalPersonName,creditCode,productLicenseTime,certQRCode,certAuthority,businessPlace,licensedItems,originalFileName,originalFilePath,copyFileName,copyFilePath,summary,formStyleContent,formContent,processStatus,remark,createTime,createUserId,updateUserId,updateTime,reportUserId,reportUserName,reportTime,createUserName,updateUserName)
VALUES VALUES
<foreach collection="data.dataList" item="item" index="index" separator="," > <foreach collection="data.dataList" item="item" index="index" separator="," >
(#{item.siteId},#{item.siteName},#{item.catalogId},#{item.catalogName},#{item.applyId},#{item.documentId},#{item.documentName},#{item.deptId},#{item.deptName},#{item.marketEntityName},#{item.licenseCode},#{item.legalPersonName},#{item.creditCode},#{item.productLicenseTime},#{item.certQRCode},#{item.certAuthority},#{item.businessPlace},#{item.licensedItems},#{item.originalFileName},#{item.originalFilePath},#{item.copyFileName},#{item.copyFilePath},#{item.summary},#{item.formStyleContent},#{item.formContent},#{item.processStatus},#{item.remark},#{item.createTime},#{item.createUserId},#{item.updateUserId},#{item.updateTime}) (#{item.siteId},#{item.siteName},#{item.catalogId},#{item.catalogName},#{item.applyId},#{item.documentId},#{item.documentName},#{item.deptId},#{item.deptName},#{item.marketEntityName},#{item.licenseCode},#{item.legalPersonName},#{item.creditCode},#{item.productLicenseTime},#{item.certQRCode},#{item.certAuthority},#{item.businessPlace},#{item.licensedItems},#{item.originalFileName},#{item.originalFilePath},#{item.copyFileName},#{item.copyFilePath},#{item.summary},#{item.formStyleContent},#{item.formContent},#{item.processStatus},#{item.remark},#{item.createTime},#{item.createUserId},#{item.updateUserId},#{item.updateTime},#{item.reportUserId},#{item.reportUserName},#{item.reportTime},#{item.createUserName},#{item.updateUserName})
</foreach> </foreach>
</insert> </insert>
...@@ -281,6 +301,24 @@ ...@@ -281,6 +301,24 @@
<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.updateTime=#{data.updateTime}, a.updateTime=#{data.updateTime},
</if> </if>
<if test="(colPickMode==0 and data.containsKey('reportUserId')) or (colPickMode==1 and !data.containsKey('reportUserId'))">
a.reportUserId=#{data.reportUserId},
</if>
<if test="(colPickMode==0 and data.containsKey('reportUserIdIncrement')) or (colPickMode==1 and !data.containsKey('reportUserIdIncrement'))">
a.reportUserId=ifnull(a.reportUserId,0) + #{data.reportUserIdIncrement},
</if>
<if test="(colPickMode==0 and data.containsKey('reportUserName')) or (colPickMode==1 and !data.containsKey('reportUserName'))">
a.reportUserName=#{data.reportUserName},
</if>
<if test="(colPickMode==0 and data.containsKey('reportTime')) or (colPickMode==1 and !data.containsKey('reportTime'))">
a.reportTime=#{data.reportTime},
</if>
<if test="(colPickMode==0 and data.containsKey('createUserName')) or (colPickMode==1 and !data.containsKey('createUserName'))">
a.createUserName=#{data.createUserName},
</if>
<if test="(colPickMode==0 and data.containsKey('updateUserName')) or (colPickMode==1 and !data.containsKey('updateUserName'))">
a.updateUserName=#{data.updateUserName},
</if>
</trim> </trim>
<trim suffixOverrides="where" suffix=""> <trim suffixOverrides="where" suffix="">
where where
...@@ -550,6 +588,46 @@ ...@@ -550,6 +588,46 @@
</if> </if>
</foreach> </foreach>
</trim> </trim>
<trim prefix="reportUserId=(case" suffix="ELSE reportUserId end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<choose>
<when test="(colPickMode==0 and item.containsKey('reportUserId')) or (colPickMode==1 and !item.containsKey('reportUserId'))">
when a.id=#{item.id} then #{item.reportUserId}
</when>
<when test="(colPickMode==0 and item.containsKey('reportUserIdIncrement')) or (colPickMode==1 and !item.containsKey('reportUserIdIncrement'))">
when a.id=#{item.id} then ifnull(a.reportUserId,0) + #{item.reportUserIdIncrement}
</when>
</choose>
</foreach>
</trim>
<trim prefix="reportUserName=(case" suffix="ELSE reportUserName end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('reportUserName')) or (colPickMode==1 and !item.containsKey('reportUserName'))">
when a.id=#{item.id} then #{item.reportUserName}
</if>
</foreach>
</trim>
<trim prefix="reportTime=(case" suffix="ELSE reportTime end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('reportTime')) or (colPickMode==1 and !item.containsKey('reportTime'))">
when a.id=#{item.id} then #{item.reportTime}
</if>
</foreach>
</trim>
<trim prefix="createUserName=(case" suffix="ELSE createUserName end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('createUserName')) or (colPickMode==1 and !item.containsKey('createUserName'))">
when a.id=#{item.id} then #{item.createUserName}
</if>
</foreach>
</trim>
<trim prefix="updateUserName=(case" suffix="ELSE updateUserName end),">
<foreach collection="data.dataList" item="item" index="index" separator="" >
<if test="(colPickMode==0 and item.containsKey('updateUserName')) or (colPickMode==1 and !item.containsKey('updateUserName'))">
when a.id=#{item.id} then #{item.updateUserName}
</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=")">
...@@ -1378,6 +1456,111 @@ ...@@ -1378,6 +1456,111 @@
<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.updateTime <![CDATA[ <= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.updateTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s') ${_conditionType_} a.updateTime <![CDATA[ <= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.updateTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s')
</if> </if>
<if test="conditionParamRef.containsKey('reportUserId')">
<if test="conditionParamRef.reportUserId != null ">
${_conditionType_} a.reportUserId = #{${_conditionParam_}.reportUserId}
</if>
<if test="conditionParamRef.reportUserId == null">
${_conditionType_} a.reportUserId is null
</if>
</if>
<if test="conditionParamRef.containsKey('reportUserIdList') and conditionParamRef.reportUserIdList.size() > 0">
${_conditionType_} a.reportUserId in
<foreach collection="conditionParamRef.reportUserIdList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('reportUserIdNotList') and conditionParamRef.reportUserIdNotList.size() > 0">
${_conditionType_} a.reportUserId not in
<foreach collection="conditionParamRef.reportUserIdNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('reportUserIdStart') and conditionParamRef.reportUserIdStart != null">
${_conditionType_} a.reportUserId <![CDATA[ >= ]]> #{${_conditionParam_}.reportUserIdStart}
</if>
<if test="conditionParamRef.containsKey('reportUserIdEnd') and conditionParamRef.reportUserIdEnd != null">
${_conditionType_} a.reportUserId <![CDATA[ <= ]]> #{${_conditionParam_}.reportUserIdEnd}
</if>
<if test="conditionParamRef.containsKey('reportUserName')">
<if test="conditionParamRef.reportUserName != null and conditionParamRef.reportUserName != ''">
${_conditionType_} a.reportUserName like #{${_conditionParam_}.reportUserName}
</if>
<if test="conditionParamRef.reportUserName == null">
${_conditionType_} a.reportUserName is null
</if>
</if>
<if test="conditionParamRef.containsKey('reportUserNameList') and conditionParamRef.reportUserNameList.size() > 0">
${_conditionType_} a.reportUserName in
<foreach collection="conditionParamRef.reportUserNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('reportUserNameNotList') and conditionParamRef.reportUserNameNotList.size() > 0">
${_conditionType_} a.reportUserName not in
<foreach collection="conditionParamRef.reportUserNameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('reportTime')">
<if test="conditionParamRef.reportTime != null ">
${_conditionType_} a.reportTime = #{${_conditionParam_}.reportTime}
</if>
<if test="conditionParamRef.reportTime == null">
${_conditionType_} a.reportTime is null
</if>
</if>
<if test="conditionParamRef.containsKey('reportTimeStart') and conditionParamRef.reportTimeStart != null and conditionParamRef.reportTimeStart!=''">
${_conditionType_} a.reportTime <![CDATA[ >= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.reportTimeStart},' 00:00:00'),19),'%Y-%m-%d %k:%i:%s')
</if>
<if test="conditionParamRef.containsKey('reportTimeEnd') and conditionParamRef.reportTimeEnd != null and conditionParamRef.reportTimeEnd!=''">
${_conditionType_} a.reportTime <![CDATA[ <= ]]> STR_TO_DATE(left(concat(#{${_conditionParam_}.reportTimeEnd},' 23:59:59'),19),'%Y-%m-%d %k:%i:%s')
</if>
<if test="conditionParamRef.containsKey('createUserName')">
<if test="conditionParamRef.createUserName != null and conditionParamRef.createUserName != ''">
${_conditionType_} a.createUserName like #{${_conditionParam_}.createUserName}
</if>
<if test="conditionParamRef.createUserName == null">
${_conditionType_} a.createUserName is null
</if>
</if>
<if test="conditionParamRef.containsKey('createUserNameList') and conditionParamRef.createUserNameList.size() > 0">
${_conditionType_} a.createUserName in
<foreach collection="conditionParamRef.createUserNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('createUserNameNotList') and conditionParamRef.createUserNameNotList.size() > 0">
${_conditionType_} a.createUserName not in
<foreach collection="conditionParamRef.createUserNameNotList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('updateUserName')">
<if test="conditionParamRef.updateUserName != null and conditionParamRef.updateUserName != ''">
${_conditionType_} a.updateUserName like #{${_conditionParam_}.updateUserName}
</if>
<if test="conditionParamRef.updateUserName == null">
${_conditionType_} a.updateUserName is null
</if>
</if>
<if test="conditionParamRef.containsKey('updateUserNameList') and conditionParamRef.updateUserNameList.size() > 0">
${_conditionType_} a.updateUserName in
<foreach collection="conditionParamRef.updateUserNameList" open="(" close=")" index="index" item="item" separator=",">
#{item}
</foreach>
</if>
<if test="conditionParamRef.containsKey('updateUserNameNotList') and conditionParamRef.updateUserNameNotList.size() > 0">
${_conditionType_} a.updateUserName not in
<foreach collection="conditionParamRef.updateUserNameNotList" 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()">
...@@ -1445,6 +1628,13 @@ ...@@ -1445,6 +1628,13 @@
</foreach> </foreach>
, ,
</if> </if>
<if test="conditionParamRef.containsKey('reportUserIdList') and conditionParamRef.reportUserIdList.size() > 0">
field(a.reportUserId,
<foreach collection="conditionParamRef.reportUserIdList" 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}
...@@ -1516,6 +1706,13 @@ ...@@ -1516,6 +1706,13 @@
</foreach> </foreach>
, ,
</if> </if>
<if test="conditionParamRef.containsKey('reportUserIdList') and conditionParamRef.reportUserIdList.size() > 0">
field(a.reportUserId,
<foreach collection="conditionParamRef.reportUserIdList" 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
...@@ -1677,6 +1874,31 @@ ...@@ -1677,6 +1874,31 @@
<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('reportUserId')">
a.reportUserId
<if test='orderCol.reportUserId != null and "DESC".equalsIgnoreCase(orderCol.reportUserId)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('reportUserName')">
a.reportUserName
<if test='orderCol.reportUserName != null and "DESC".equalsIgnoreCase(orderCol.reportUserName)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('reportTime')">
a.reportTime
<if test='orderCol.reportTime != null and "DESC".equalsIgnoreCase(orderCol.reportTime)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('createUserName')">
a.createUserName
<if test='orderCol.createUserName != null and "DESC".equalsIgnoreCase(orderCol.createUserName)'>DESC</if>
,
</if>
<if test="orderCol.containsKey('updateUserName')">
a.updateUserName
<if test='orderCol.updateUserName != null and "DESC".equalsIgnoreCase(orderCol.updateUserName)'>DESC</if>
,
</if>
</trim> </trim>
</if> </if>
......
...@@ -37,3 +37,9 @@ POST {{baseUrl}}/user/interlist ...@@ -37,3 +37,9 @@ POST {{baseUrl}}/user/interlist
Content-Type: application/json Content-Type: application/json
{} {}
###获取参数列表
POST {{baseUrl}}/param/interlist
Content-Type: application/json
{}
\ No newline at end of file
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