# Conflicts:
#	buildpackage/src/test/java/com/hzya/frame/temButtom.java
This commit is contained in:
xiang2lin 2024-09-19 09:33:12 +08:00
commit 4ede4a65ef
329 changed files with 45617 additions and 1622 deletions

View File

@ -36,69 +36,75 @@
</dependencies>
<profiles>
<profile>
<id>local</id> <!--本地环境-->
<properties>
<profile.active>local</profile.active>
</properties>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
</profile>
<profile>
<id>dev</id> <!--开发环境-->
<properties>
<profile.active>dev</profile.active>
</properties>
</profile>
<profile>
<id>ax</id> <!--澳星-->
<properties>
<profile.active>ax</profile.active>
</properties>
</profile>
<profile>
<id>hclocal</id> <!--何灿-->
<properties>
<profile.active>hclocal</profile.active>
</properties>
</profile>
<profile>
<id>llg</id> <!--吕磊钢-->
<properties>
<profile.active>llg</profile.active>
</properties>
</profile>
<profile>
<id>yuqh</id> <!--于群辉-->
<properties>
<profile.active>yuqh</profile.active>
</properties>
</profile>
<profile>
<id>xel</id> <!--相二林-->
<properties>
<profile.active>xel</profile.active>
</properties>
</profile>
<profile>
<id>ydc</id> <!--英德赛-->
<properties>
<profile.active>ydc</profile.active>
</properties>
</profile>
<profile>
<id>yc</id> <!--越城区-->
<properties>
<profile.active>yc</profile.active>
</properties>
</profile>
<profile>
<id>zqt</id> <!--越城区-->
<properties>
<profile.active>zqt</profile.active>
</properties>
</profile>
<!-- <profile>-->
<!-- <id>local</id> &lt;!&ndash;本地环境&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>local</profile.active>-->
<!-- </properties>-->
<!-- <activation>-->
<!-- <activeByDefault>true</activeByDefault>-->
<!-- </activation>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>dev</id> &lt;!&ndash;开发环境&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>dev</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>ax</id> &lt;!&ndash;澳星&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>ax</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>hclocal</id> &lt;!&ndash;何灿&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>hclocal</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>llg</id> &lt;!&ndash;吕磊钢&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>llg</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>zqtlocal</id> &lt;!&ndash;曾庆拓&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>zqtlocal</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>yuqh</id> &lt;!&ndash;于群辉&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>yuqh</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>xel</id> &lt;!&ndash;相二林&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>xel</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>ydc</id> &lt;!&ndash;英德赛&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>ydc</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>yc</id> &lt;!&ndash;越城区&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>yc</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<!-- <profile>-->
<!-- <id>zqt</id> &lt;!&ndash;越城区&ndash;&gt;-->
<!-- <properties>-->
<!-- <profile.active>zqt</profile.active>-->
<!-- </properties>-->
<!-- </profile>-->
<profile>
<id>dongj</id> <!--越城区-->
<properties>

View File

@ -66,9 +66,9 @@ public class CbsPluginServiceImpl implements ICbsPluginService {
@Autowired
private RestUtil restUtil;
@Value("${cbs8.elec_path}")
@Value("${cbs8.elec_path:}")
private String elec_path;
@Value("${OA.data_source_code}")
@Value("${OA.data_source_code:}")
private String oa_data_source_code;
/**
* 支付申请

View File

@ -544,7 +544,7 @@ public class MdmModulePluginInitializer extends PluginBaseEntity {
map1.put("tableName",mainDb);
map1.put("dataStatus", "N");
map1.put("deleteStatus", "0");
map1.put("size", 10);
map1.put("size", 50);
objects = mdmModuleDao.queryMdmSTs(map1);
objects = toLowerCaseKeys(objects);
@ -705,7 +705,7 @@ public class MdmModulePluginInitializer extends PluginBaseEntity {
continue;
}else {
//保存日志
saveMdmModuleSendLogEntity(mainCode,mdmModuleDistributeEntities.get(i1).getId(),"2","转发失败",mainDb,objects.get(i).getString("id"),sysApplicationEntity.getName(),sysApplicationEntity.getId(),apiEntity.getApiName(),apiEntity.getId(),doObjects.get(i).toJSONString(),"3");
saveMdmModuleSendLogEntity(mainCode,mdmModuleDistributeEntities.get(i1).getId(),"2","转发失败:"+jsonResultEntity.getAttribute(),mainDb,objects.get(i).getString("id"),sysApplicationEntity.getName(),sysApplicationEntity.getId(),apiEntity.getApiName(),apiEntity.getId(),doObjects.get(i).toJSONString(),"3");
continue;
}
}
@ -739,7 +739,7 @@ public class MdmModulePluginInitializer extends PluginBaseEntity {
map1.put("tableName",mainDb);
//map1.put("dataStatus", "F");
map1.put("updateStatus", "0");
map1.put("size", 10);
map1.put("size", 50);
objects = mdmModuleDao.queryMdmSTs(map1);
objects = toLowerCaseKeys(objects);
@ -886,7 +886,7 @@ public class MdmModulePluginInitializer extends PluginBaseEntity {
continue;
}else {
//保存日志
saveMdmModuleSendLogEntity(mainCode,mdmModuleDistributeEntities.get(i1).getId(),"2","转发失败",mainDb,objects.get(i).getString("id"),sysApplicationEntity.getName(),sysApplicationEntity.getId(),apiEntity.getApiName(),apiEntity.getId(),doObjects.get(i).toJSONString(),"2");
saveMdmModuleSendLogEntity(mainCode,mdmModuleDistributeEntities.get(i1).getId(),"2","转发失败:"+jsonResultEntity.getAttribute(),mainDb,objects.get(i).getString("id"),sysApplicationEntity.getName(),sysApplicationEntity.getId(),apiEntity.getApiName(),apiEntity.getId(),doObjects.get(i).toJSONString(),"2");
continue;
}
}
@ -927,7 +927,7 @@ public class MdmModulePluginInitializer extends PluginBaseEntity {
map1.put("tableName",mainDb);
//map1.put("dataStatus", "Y");
map1.put("addStatus", "0");
map1.put("size", 10);
map1.put("size", 50);
objects = mdmModuleDao.queryMdmSTs(map1);
objects = toLowerCaseKeys(objects);
@ -1125,7 +1125,7 @@ public class MdmModulePluginInitializer extends PluginBaseEntity {
continue;
}else {
//保存日志
saveMdmModuleSendLogEntity(mainCode,mdmModuleDistributeEntities.get(i1).getId(),"2","转发失败",mainDb,objects.get(i).getString("id"),sysApplicationEntity.getName(),sysApplicationEntity.getId(),apiEntity.getApiName(),apiEntity.getId(),doObjects.get(i).toJSONString(),"1");
saveMdmModuleSendLogEntity(mainCode,mdmModuleDistributeEntities.get(i1).getId(),"2","转发失败:"+jsonResultEntity.getAttribute(),mainDb,objects.get(i).getString("id"),sysApplicationEntity.getName(),sysApplicationEntity.getId(),apiEntity.getApiName(),apiEntity.getId(),doObjects.get(i).toJSONString(),"1");
continue;
}
}

View File

@ -0,0 +1,7 @@
package com.hzya.frame.plugin.pushMessage.dao;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.plugin.pushMessage.entity.PushMessageEntity;
public interface IPushMessageDao extends IBaseDao<PushMessageEntity, String> {
}

View File

@ -0,0 +1,8 @@
package com.hzya.frame.plugin.pushMessage.dao.impl;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import com.hzya.frame.plugin.pushMessage.dao.IPushMessageDao;
import com.hzya.frame.plugin.pushMessage.entity.PushMessageEntity;
public class PushMessageDaoImpl extends MybatisGenericDao<PushMessageEntity, String> implements IPushMessageDao {
}

View File

@ -0,0 +1,106 @@
package com.hzya.frame.plugin.pushMessage.entity;
import com.hzya.frame.web.entity.BaseEntity;
public class PushMessageEntity extends BaseEntity {
private String pushMethod;
private String warningAppCode;
private String warningApiCode;
private String recipientIdList;
private String warningAppType;
private String sendAppName;
private String receiveAppName;
private String receiveApiName;
private String returnData;
private String receiveApiCode;
private String status;
public String getPushMethod() {
return pushMethod;
}
public void setPushMethod(String pushMethod) {
this.pushMethod = pushMethod;
}
public String getWarningAppCode() {
return warningAppCode;
}
public void setWarningAppCode(String warningAppCode) {
this.warningAppCode = warningAppCode;
}
public String getWarningApiCode() {
return warningApiCode;
}
public void setWarningApiCode(String warningApiCode) {
this.warningApiCode = warningApiCode;
}
public String getRecipientIdList() {
return recipientIdList;
}
public void setRecipientIdList(String recipientIdList) {
this.recipientIdList = recipientIdList;
}
public String getWarningAppType() {
return warningAppType;
}
public void setWarningAppType(String warningAppType) {
this.warningAppType = warningAppType;
}
public String getSendAppName() {
return sendAppName;
}
public void setSendAppName(String sendAppName) {
this.sendAppName = sendAppName;
}
public String getReceiveAppName() {
return receiveAppName;
}
public void setReceiveAppName(String receiveAppName) {
this.receiveAppName = receiveAppName;
}
public String getReceiveApiName() {
return receiveApiName;
}
public void setReceiveApiName(String receiveApiName) {
this.receiveApiName = receiveApiName;
}
public String getReturnData() {
return returnData;
}
public void setReturnData(String returnData) {
this.returnData = returnData;
}
public String getReceiveApiCode() {
return receiveApiCode;
}
public void setReceiveApiCode(String receiveApiCode) {
this.receiveApiCode = receiveApiCode;
}
public String getStatus() {
return status;
}
public void setStatus(String status) {
this.status = status;
}
}

View File

@ -0,0 +1,43 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.plugin.pushMessage.dao.impl.PushMessageDaoImpl">
<resultMap id="get-PushMessageEntity-result" type="com.hzya.frame.plugin.pushMessage.entity.PushMessageEntity" >
<result property="pushMessage" column="push_message" jdbcType="VARCHAR"/>
<result property="warningAppCode" column="warning_app_code" jdbcType="VARCHAR"/>
<result property="warningApiCode" column="warning_api_code" jdbcType="VARCHAR"/>
<result property="appType" column="app_type" jdbcType="VARCHAR"/>
<result property="recipientIdList" column="recipient_id_list" jdbcType="VARCHAR"/>
<result property="sendAppName" column="send_app_name" jdbcType="VARCHAR"/>
<result property="receiveAppName" column="receive_app_name" jdbcType="VARCHAR"/>
<result property="receiveApiName" column="receive_api_name" jdbcType="VARCHAR"/>
<result property="receiveApiCode" column="receive_api_code" jdbcType="VARCHAR"/>
<result property="returnData" column="return_data" jdbcType="VARCHAR"/>
<result property="status" column="status" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-PushMessageEntity-result" parameterType = "com.hzya.frame.plugin.pushMessage.entity.PushMessageEntity">
SELECT
warning_config.push_method,
warning_config.sendAppid AS warning_app_code,
warning_config.endApiCode AS warning_api_code,
warning_config.app_type,
warning_config.recipient_id AS recipient_id_list,
log.send_app_name,
log.receive_app_name,
receive_api_name,
log.receive_api_code,
log.return_data,
log.STATUS
FROM
v_hzya_sys_warning warning_config
LEFT JOIN v_hzya_sys_send_message_log log ON warning_config.api_code = log.receive_api_code
WHERE
log.STATUS = '4'
AND warning_config.push_method = '定时'
</select>
</mapper>

View File

@ -0,0 +1,77 @@
package com.hzya.frame.plugin.pushMessage.plugin;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.base.PluginBaseEntity;
import com.hzya.frame.plugin.pushMessage.dao.IPushMessageDao;
import com.hzya.frame.plugin.pushMessage.entity.PushMessageEntity;
import com.hzya.frame.sysnew.comparison.masterData.service.IMasterDataService;
import com.hzya.frame.sysnew.pushMessage.dao.ISysPushMessageDao;
import com.hzya.frame.sysnew.pushMessage.entity.SysPushMessageEntity;
import com.hzya.frame.sysnew.pushMessage.service.ISysPushMessageService;
import com.hzya.frame.sysnew.sendMessageLog.service.ISysSendMessageLogService;
import com.hzya.frame.web.entity.BaseResult;
import com.hzya.frame.web.entity.JsonResultEntity;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
@Service("PushMessagePluginInitializer")
public class PushMessagePluginInitializer extends PluginBaseEntity {
Logger logger = LoggerFactory.getLogger(PushMessagePluginInitializer.class);
@Autowired
private ISysPushMessageDao sysPushMessageDao;
@Resource
public ISysSendMessageLogService sysSendMessageLogService;
@Override
public void initialize() {
logger.info(getPluginLabel() + "執行初始化方法initialize()");
}
@Override
public void destroy() {
logger.info(getPluginLabel() + "執行銷毀方法destroy()");
}
@Override
public String getPluginId() {
return "PushMessagePlugin";
}
@Override
public String getPluginName() {
return "PushMessagePlugin插件";
}
@Override
public String getPluginLabel() {
return "PushMessagePlugin";
}
@Override
public String getPluginType() {
return "1";
}
@Override
public JsonResultEntity executeBusiness(JSONObject requestJson) {
try {
logger.info("======开始执行定时消息推送========");
List<SysPushMessageEntity> list = sysPushMessageDao.getAll();
for(SysPushMessageEntity entity : list){
sysSendMessageLogService.sendMessage(entity);
}
return BaseResult.getSuccessMessageEntity("定时推送消息成功");
}catch (Exception e){
logger.info("======执行定时消息推送失败:{}========",e.getMessage());
e.printStackTrace();
}
return null;
}
}

View File

@ -0,0 +1,10 @@
package com.hzya.frame.plugin.pushMessage.service;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.basedao.service.IBaseService;
import com.hzya.frame.plugin.pushMessage.entity.PushMessageEntity;
import com.hzya.frame.web.entity.JsonResultEntity;
public interface IPushMessageService extends IBaseService<PushMessageEntity, String> {
}

View File

@ -0,0 +1,25 @@
package com.hzya.frame.plugin.pushMessage.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.basedao.service.impl.BaseService;
import com.hzya.frame.plugin.pushMessage.dao.IPushMessageDao;
import com.hzya.frame.plugin.pushMessage.entity.PushMessageEntity;
import com.hzya.frame.plugin.pushMessage.service.IPushMessageService;
import com.hzya.frame.web.entity.BaseResult;
import com.hzya.frame.web.entity.JsonResultEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
public class PushMessageServiceImpl extends BaseService<PushMessageEntity, String> implements IPushMessageService {
private IPushMessageDao pushMessageDao;
@Autowired
public void setPushMessageDao(IPushMessageDao dao) {
this.pushMessageDao = dao;
this.dao = dao;
}
}

View File

@ -1,23 +0,0 @@
#######################澳星环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: GBK
file:
# 日志保存路径
path: E:\yongansystem\log
spring:
datasource:
dynamic:
datasource:
master:
url: jdbc:mysql://127.0.0.1:3306/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: E:\yongansystem\file
zt:
url: http://127.0.0.1:9081/kangarooDataCenterV3/entranceController/externalCallInterface

View File

@ -1,35 +0,0 @@
#######################dev环境#######################
logging:
#日志级别 指定目录级别
level:
root: warn
encodings: UTF-8
file:
# 日志保存路径
path: /home/webservice/zt/log
spring:
datasource:
dynamic:
datasource:
master:
url: jdbc:mysql://ufidahz.com.cn:9014/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: /home/webservice/zt/file
cbs8:
appId: 1P4AGrpz
appSecret: 2c2369ae5dc04382844bbe3a5abf39e1bea9cd3a
url: https://cbs8-openapi-reprd.csuat.cmburl.cn
# 测试用这个 这个是银行给的,和下面的公钥不是一对密钥
ya_private_key: 83BA7EC821D35F4CB31FF9A51C1EFA520FC52AF828C2337F88E91CF119B07F44
# 这个私钥到时候上传到cbs和下面到是同一对
#ya_private_key: e1eacfdee9b8d4184437d5a2071e17ce31befc3d93395f9f05709ed562e8dc46
ya_public_key: 044fa399d2223760f17b81b863cb482b009294c4516f8a605dea1475ec09e720eaa98468715e5ad509a592a0b426061551c5a3df236966c23253a7d894eac0dcde
cbs_public_key: 0469146F06BF3B01236E84632441E826
#电子回单下载临时存放位置
elec_path: /Users/xiangerlin/Downloads/
OA:
data_source_code: yc_oa

View File

@ -1,27 +0,0 @@
#######################本地环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: D:\yongansystem\kangarooDataCenter\v3\logs
spring:
datasource:
dynamic:
datasource:
master:
# url: jdbc:mysql://hzya.ufyct.com:9096/businesscenternew?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
# username: root
# password: bd993088e8a7c3dc5f44441617f9b4bf
# driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
url: jdbc:mysql://hzya.ufyct.com:9014/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: D:\yongansystem\kangarooDataCenter\v3\logs
zt:
url: http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface

View File

@ -1,52 +0,0 @@
#######################本地环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: /Users/apple/Desktop/log/local
spring:
flyway:
# 启动flyway migration, 默认为true
enabled: false
datasource:
dynamic:
druid:
filters: stat,log4j2
datasource:
master:
# url: jdbc:dm://hzya.ufyct.com:9040?schema=businesscenter&zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8&compatibleMode=oracle
# username: hzyazt
# password: 62e4295b615a30dbf3b8ee96f41c820b
# driver-class-name: dm.jdbc.driver.DmDriver
# type: com.alibaba.druid.pool.DruidDataSource
url: jdbc:mysql://ufidahz.com.cn:9014/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
# url: jdbc:dm://hzya.ufyct.com:9040/businesscenter?zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8
# url: jdbc:dm://hzya.ufyct.com:9040?schema=businesscenter&zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8&compatibleMode=oracle
# username: hzyazt
# password: 62e4295b615a30dbf3b8ee96f41c820b
# driver-class-name: dm.jdbc.driver.DmDriver
savefile:
# 文件保存路径
path: /Users/apple/Desktop/log/local
zt:
url: http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface
cbs8:
appId: 1P4AGrpz
appSecret: 2c2369ae5dc04382844bbe3a5abf39e1bea9cd3a
url: https://cbs8-openapi-reprd.csuat.cmburl.cn
# 测试用这个 这个是银行给的,和下面的公钥不是一对密钥
ya_private_key: 83BA7EC821D35F4CB31FF9A51C1EFA520FC52AF828C2337F88E91CF119B07F44
# 这个私钥到时候上传到cbs和下面到是同一对
#ya_private_key: e1eacfdee9b8d4184437d5a2071e17ce31befc3d93395f9f05709ed562e8dc46
ya_public_key: 044fa399d2223760f17b81b863cb482b009294c4516f8a605dea1475ec09e720eaa98468715e5ad509a592a0b426061551c5a3df236966c23253a7d894eac0dcde
cbs_public_key: 0469146F06BF3B01236E84632441E826
#电子回单下载临时存放位置
elec_path: /Users/xiangerlin/Downloads/
OA:
data_source_code: djoatest

View File

@ -1,23 +0,0 @@
#######################本地环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: /Users/apple/Desktop/log/local
spring:
datasource:
dynamic:
datasource:
master:
url: jdbc:mysql://hzya.ufyct.com:9014/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: /Users/apple/Desktop/log/local
zt:
url: http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface

View File

@ -1,35 +0,0 @@
#######################本地环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: /Users/xiangerlin/work/app/logs/dongj
spring:
datasource:
dynamic:
datasource:
master:
url: jdbc:mysql://ufidahz.com.cn:9014/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: /Users/xiangerlin/work/app/logs/dongj
cbs8:
appId: 1P4AGrpz
appSecret: 2c2369ae5dc04382844bbe3a5abf39e1bea9cd3a
url: https://cbs8-openapi-reprd.csuat.cmburl.cn
# 测试用这个 这个是银行给的,和下面的公钥不是一对密钥
ya_private_key: 83BA7EC821D35F4CB31FF9A51C1EFA520FC52AF828C2337F88E91CF119B07F44
# 这个私钥到时候上传到cbs和下面到是同一对
#ya_private_key: e1eacfdee9b8d4184437d5a2071e17ce31befc3d93395f9f05709ed562e8dc46
ya_public_key: 044fa399d2223760f17b81b863cb482b009294c4516f8a605dea1475ec09e720eaa98468715e5ad509a592a0b426061551c5a3df236966c23253a7d894eac0dcde
cbs_public_key: 0469146F06BF3B01236E84632441E826F3067A6B93BC3839C836A06007869CD351FBBE388B51F742859388BBC1DE089923AAFBC69E448F15141DDF30EE6CE90185
#电子回单下载临时存放位置
elec_path: /Users/xiangerlin/Downloads/
OA:
data_source_code: djoatest

View File

@ -1,90 +0,0 @@
#logging:
# #日志级别 指定目录级别
# level:
# root: info
# encodings: UTF-8
# file:
# # 日志保存路径
# path: /zt/log
#spring:
# flyway:
# # 启动flyway migration, 默认为true
# enabled: false
# datasource:
# dynamic:
# druid:
# filters: stat,log4j2
# datasource:
# master:
# url: jdbc:dm://10.75.51.82:5238?schema=businesscenter&zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8&compatibleMode=oracle
# username: businesscenter
# password: 6842568689469adad597d144ee104063
# driver-class-name: dm.jdbc.driver.DmDriver
#savefile:
# # 文件保存路径
# path: /zt/file
#公司mysql
#ax:
# url: http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface
#logging:
# #日志级别 指定目录级别warn
# level:
# root: info
# encodings: UTF-8
# file:
# # 日志保存路径
# path: /home/webservice/zt/log
#spring:
# datasource:
# dynamic:
# datasource:
# master:
# url: jdbc:mysql://hzya.ufyct.com:9014/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
# username: root
# password: 62e4295b615a30dbf3b8ee96f41c820b
# driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
#savefile:
# # 文件保存路径
# path: /home/webservice/zt/file
#公司服务器达梦
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: /zt/log
spring:
flyway:
# 启动flyway migration, 默认为true
enabled: false
datasource:
dynamic:
druid:
filters: stat,log4j2
datasource:
master:
url: jdbc:dm://hzya.ufyct.com:9040?schema=businesscenter&zeroDateTimeBehavior=convertToNull&useUnicode=true&characterEncoding=utf-8&compatibleMode=oracle
username: hzyazt
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: dm.jdbc.driver.DmDriver
savefile:
# 文件保存路径
path: /zt/file
cbs8:
appId: 1P4AGrpz
appSecret: 2c2369ae5dc04382844bbe3a5abf39e1bea9cd3a
url: https://cbs8-openapi-reprd.csuat.cmburl.cn
# 测试用这个 这个是银行给的,和下面的公钥不是一对密钥
ya_private_key: 83BA7EC821D35F4CB31FF9A51C1EFA520FC52AF828C2337F88E91CF119B07F44
# 这个私钥到时候上传到cbs和下面到是同一对
#ya_private_key: e1eacfdee9b8d4184437d5a2071e17ce31befc3d93395f9f05709ed562e8dc46
ya_public_key: 044fa399d2223760f17b81b863cb482b009294c4516f8a605dea1475ec09e720eaa98468715e5ad509a592a0b426061551c5a3df236966c23253a7d894eac0dcde
cbs_public_key: 0469146F06BF3B01236E84632441E826
#电子回单下载临时存放位置
elec_path: /zt/elecfile
OA:
data_source_code: yc_oa

View File

@ -1,21 +0,0 @@
#######################本地环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: /Users/xiangerlin/work/app/logs/ydc
spring:
datasource:
dynamic:
datasource:
master:
url: jdbc:mysql://hzya.ufyct.com:9096/businesscenternew?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: bd993088e8a7c3dc5f44441617f9b4bf
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: /Users/xiangerlin/work/app/logs/ydc

View File

@ -1,31 +0,0 @@
#######################本地环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: /Users/xiangerlin/work/app/logs/yuecheng
spring:
datasource:
dynamic:
datasource:
master:
url: jdbc:mysql://hzya.ufyct.com:9014/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: /Users/xiangerlin/work/app/logs/yuecheng
cbs8:
appId: 1P4AGrpz
appSecret: 2c2369ae5dc04382844bbe3a5abf39e1bea9cd3a
url: https://cbs8-openapi-reprd.csuat.cmburl.cn
# 测试用这个 这个是银行给的,和下面的公钥不是一对密钥
ya_private_key: 83BA7EC821D35F4CB31FF9A51C1EFA520FC52AF828C2337F88E91CF119B07F44
# 这个私钥到时候上传到cbs和下面到是同一对
#ya_private_key: e1eacfdee9b8d4184437d5a2071e17ce31befc3d93395f9f05709ed562e8dc46
ya_public_key: 044fa399d2223760f17b81b863cb482b009294c4516f8a605dea1475ec09e720eaa98468715e5ad509a592a0b426061551c5a3df236966c23253a7d894eac0dcde
cbs_public_key: 0469146F06BF3B01236E84632441E826F3067A6B93BC3839C836A06007869CD351FBBE388B51F742859388BBC1DE089923AAFBC69E448F15141DDF30EE6CE90185

View File

@ -1,23 +0,0 @@
#######################本地环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: E:\yongansystem\log
spring:
datasource:
dynamic:
datasource:
master:
url: jdbc:mysql://hzya.ufyct.com:9096/businesscenternew?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: bd993088e8a7c3dc5f44441617f9b4bf
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: E:\yongansystem\log
zt:
url: http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface

View File

@ -1,35 +0,0 @@
#######################dev环境#######################
logging:
#日志级别 指定目录级别
level:
root: info
encodings: UTF-8
file:
# 日志保存路径
path: D:\log
spring:
datasource:
dynamic:
datasource:
master:
url: jdbc:mysql://ufidahz.com.cn:9014/businesscenter?serverTimezone=UTC&useUnicode=true&characterEncoding=UTF8&serverTimezone=GMT%2B8&zeroDateTimeBehavior=convertToNull&useSSL=false&allowLoadLocalInfile=false&autoReconnect=true&failOverReadOnly=false&connectTimeout=30000&socketTimeout=30000&autoReconnectForPools=true
username: root
password: 62e4295b615a30dbf3b8ee96f41c820b
driver-class-name: com.mysql.jdbc.Driver # 3.2.0开始支持SPI可省略此配置
savefile:
# 文件保存路径
path: D:\log
cbs8:
appId: 1P4AGrpz
appSecret: 2c2369ae5dc04382844bbe3a5abf39e1bea9cd3a
url: https://cbs8-openapi-reprd.csuat.cmburl.cn
# 测试用这个 这个是银行给的,和下面的公钥不是一对密钥
ya_private_key: 83BA7EC821D35F4CB31FF9A51C1EFA520FC52AF828C2337F88E91CF119B07F44
# 这个私钥到时候上传到cbs和下面到是同一对
#ya_private_key: e1eacfdee9b8d4184437d5a2071e17ce31befc3d93395f9f05709ed562e8dc46
ya_public_key: 044fa399d2223760f17b81b863cb482b009294c4516f8a605dea1475ec09e720eaa98468715e5ad509a592a0b426061551c5a3df236966c23253a7d894eac0dcde
cbs_public_key: 0469146F06BF3B01236E84632441E826
#电子回单下载临时存放位置
elec_path: /Users/xiangerlin/Downloads/
OA:
data_source_code: djoatest

View File

@ -6,6 +6,8 @@ server:
tomcat:
uri-encoding: utf-8
spring:
autoconfigure:
exclude: org.springframework.boot.autoconfigure.mongo.MongoAutoConfiguration
flyway:
# 启动flyway migration, 默认为true
enabled: true
@ -91,7 +93,7 @@ mybatis-plus:
db-config:
id-type: auto # 主键策略
zt:
url: http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface
url: http://127.0.0.1:8901/kangarooDataCenterV3/entranceController/externalCallInterface
#JimuReport[minidao配置]
minidao :
base-package: org.jeecg.modules.jmreport.desreport.dao*
@ -123,4 +125,4 @@ jeecg :
minio_pass: ??
bucketName: ??
data:
use: true
use: true

View File

@ -1,4 +1,4 @@
INSERT INTO sys_application (id, app_logo, app_status, name, version_number, access_mode, affiliation_field, manufacturer, app_introduction, client_path, app_id, system_address, web_path, program_path, public_key, secret_key, interface_address, interface_status, app_type, db_status, sorts, org_id, sts, create_time, create_user_id, modify_time, modify_user_id) VALUES ('53936623a8bd451fb7f5fed09cb36fab', NULL, '1', '东进致远OA', '8.2', '[\"1\"]', '11', '致远', '越城区发展集团致远OA', 'http://hzya.ufyct.com:9955/', 800034, NULL, 'http://hzya.ufyct.com:9955/', 'http://hzya.ufyct.com:9955/', 'ZJYATW/MfYZX7zF0eAh4DJXbyTLwUtwSoSz5Y/o1ksAaN/dCe7eDIk+3zDUT+v578prj', '+5BUkLQh3iX3VHgEt5bE2IPh+ZeebGvDaEspsvVu739Ar6sFnwg+fpPod4t6XhoTj3JzOP8MtA1LSGvL+2BWG8c/o7DKi92S4mr3zcGearA=', 'http://115.239.174.22:9999', '1', '1', '1', 17, NULL, 'Y', '2024-07-16 10:15:14', '1', '2024-07-16 10:17:56', '1');
INSERT INTO sys_application (id, app_logo, app_status, name, version_number, access_mode, affiliation_field, manufacturer, app_introduction, client_path, app_id, system_address, web_path, program_path, public_key, secret_key, interface_address, interface_status, app_type, db_status, sorts, org_id, sts, create_time, create_user_id, modify_time, modify_user_id) VALUES ('53936623a8bd451fb7f5fed09cb36fab', NULL, '1', '东进致远OA', '8.2', '[\"1\"]', '11', '致远', '越城区发展集团致远OA', 'http://ufidahz.com.cn:9955/', 800034, NULL, 'http://ufidahz.com.cn:9955/', 'http://ufidahz.com.cn:9955/', 'ZJYATW/MfYZX7zF0eAh4DJXbyTLwUtwSoSz5Y/o1ksAaN/dCe7eDIk+3zDUT+v578prj', '+5BUkLQh3iX3VHgEt5bE2IPh+ZeebGvDaEspsvVu739Ar6sFnwg+fpPod4t6XhoTj3JzOP8MtA1LSGvL+2BWG8c/o7DKi92S4mr3zcGearA=', 'http://115.239.174.22:9999', '1', '1', '1', 17, NULL, 'Y', '2024-07-16 10:15:14', '1', '2024-07-16 10:17:56', '1');
INSERT INTO sys_application_api (id, api_code, api_path, api_status, app_id, catalogue_id, api_name, api_remark, need_Login, authentication_port, parameter_passing_mode, destination_address, request_coding, request_method, timeout_period, current_limiting, header_in, query_in, body_in_type, body_in, body_out, sorts, create_user_id, create_time, modify_user_id, modify_time, sts, org_id, bean_name, fun_name, extension_api, return_success_field, return_success_value, return_msg) VALUES ('23499f05d50b495d989208e124469eff', 8000340004, NULL, '1', '53936623a8bd451fb7f5fed09cb36fab', '33406ee83887421bb1cdeb728606dcbf', '按登录名取人员信息', '按登录名取人员信息', '2', NULL, '1', '/seeyon/rest/orgMember', '1', '2', '10000', '100', '[]', '[]', '1', '[{\"id\":\"c8620cd3-7ee3-47a9-8b1d-88d26f7c21d8\",\"parameterName\":\"body\",\"first\":true}]', '[]', 228, '1', '2024-07-16 10:15:14', '1', '2024-07-16 10:15:14', 'Y', NULL, NULL, NULL, '2', 'enabled', 'true', 'enabled');
INSERT INTO sys_application_api (id, api_code, api_path, api_status, app_id, catalogue_id, api_name, api_remark, need_Login, authentication_port, parameter_passing_mode, destination_address, request_coding, request_method, timeout_period, current_limiting, header_in, query_in, body_in_type, body_in, body_out, sorts, create_user_id, create_time, modify_user_id, modify_time, sts, org_id, bean_name, fun_name, extension_api, return_success_field, return_success_value, return_msg) VALUES ('539a319b80224ce6a39106324bb68ef9', 8000340005, NULL, '1', '53936623a8bd451fb7f5fed09cb36fab', '81333abd92ac40d7b15b080d6d3750a9', '附件上传', '假的', '2', NULL, '1', '/seeyon/rest/attachment', '1', '1', '10000', '100', '[]', '[]', '1', '[{\"id\":\"03521015-0cf3-4b9f-b0d6-41d13b5578e4\",\"parameterName\":\"body\",\"first\":true}]', '[]', 235, '1', '2024-07-16 10:15:14', '1', '2024-07-16 10:15:14', 'Y', NULL, NULL, NULL, '1', '1', '1', '1');

View File

@ -1,4 +1,4 @@
INSERT INTO sys_application (id, app_logo, app_status, name, version_number, access_mode, affiliation_field, manufacturer, app_introduction, client_path, app_id, system_address, web_path, program_path, public_key, secret_key, interface_address, interface_status, app_type, db_status, sorts, org_id, sts, create_time, create_user_id, modify_time, modify_user_id) VALUES ('82bd4293fda94d6896217509f11b6c4c', '-7421991978796695038', '1', '数智中台', '1.0', '[\"1\"]', '1', '用安', '默认应用', NULL, 800004, NULL, NULL, NULL, 'ZJYAWb7lhAUTYqekPkU+uHJv1/ObJxb7dT7sD8HPRDGAgyhCe7eDIk+3zDUT+v578prj', 'fviZnLBsQUAGF8w8FSOdJi7XlIm/XAZclMxRagDLfTyJFlvnIBF3w66Hrpfzs8cYj3JzOP8MtA1LSGvL+2BWG8c/o7DKi92S4mr3zcGearA=', 'http://hzya.ufyct.com:9067/', '1', '', '2', 6, NULL, 'Y', '2023-10-20 11:49:23', 'c796fd9ba4c9f5ff3cc2fa41a040e443', '2024-06-21 10:35:03', '1');
INSERT INTO sys_application (id, app_logo, app_status, name, version_number, access_mode, affiliation_field, manufacturer, app_introduction, client_path, app_id, system_address, web_path, program_path, public_key, secret_key, interface_address, interface_status, app_type, db_status, sorts, org_id, sts, create_time, create_user_id, modify_time, modify_user_id) VALUES ('82bd4293fda94d6896217509f11b6c4c', '-7421991978796695038', '1', '数智中台', '1.0', '[\"1\"]', '1', '用安', '默认应用', NULL, 800004, NULL, NULL, NULL, 'ZJYAWb7lhAUTYqekPkU+uHJv1/ObJxb7dT7sD8HPRDGAgyhCe7eDIk+3zDUT+v578prj', 'fviZnLBsQUAGF8w8FSOdJi7XlIm/XAZclMxRagDLfTyJFlvnIBF3w66Hrpfzs8cYj3JzOP8MtA1LSGvL+2BWG8c/o7DKi92S4mr3zcGearA=', 'http://ufidahz.com.cn:9067/', '1', '', '2', 6, NULL, 'Y', '2023-10-20 11:49:23', 'c796fd9ba4c9f5ff3cc2fa41a040e443', '2024-06-21 10:35:03', '1');
INSERT INTO sys_application_api (id, api_code, api_path, api_status, app_id, catalogue_id, api_name, api_remark, need_Login, authentication_port, parameter_passing_mode, destination_address, request_coding, request_method, timeout_period, current_limiting, header_in, query_in, body_in_type, body_in, body_out, sorts, create_user_id, create_time, modify_user_id, modify_time, sts, org_id, bean_name, fun_name, extension_api, return_success_field, return_success_value, return_msg) VALUES ('01b8d8e2bc724e22a511afda7c12a610', 8000040010, NULL, '1', '82bd4293fda94d6896217509f11b6c4c', '56c766d53d9f4de2846a16b1383c5374', '客商删除', NULL, '2', NULL, '1', 'kangarooDataCenterV3/entranceController/platformInterface', '1', '1', '10000', '100', '[]', '[]', '1', '[{\"id\":\"a7be5a9e-62eb-47f2-ab86-72bcf75b0396\",\"parameterName\":\"body\",\"first\":true}]', '[]', 181, '1', '2024-04-26 10:20:30', '1', '2024-04-26 10:20:30', 'Y', NULL, NULL, NULL, NULL, NULL, NULL, NULL);
INSERT INTO sys_application_api (id, api_code, api_path, api_status, app_id, catalogue_id, api_name, api_remark, need_Login, authentication_port, parameter_passing_mode, destination_address, request_coding, request_method, timeout_period, current_limiting, header_in, query_in, body_in_type, body_in, body_out, sorts, create_user_id, create_time, modify_user_id, modify_time, sts, org_id, bean_name, fun_name, extension_api, return_success_field, return_success_value, return_msg) VALUES ('0bddf53ab22c48d288384f3fa1b06c22', 8000040015, NULL, '1', '82bd4293fda94d6896217509f11b6c4c', '56c766d53d9f4de2846a16b1383c5374', '存货分类修改', NULL, '2', NULL, '1', 'kangarooDataCenterV3/entranceController/platformInterface', '1', '1', '10000', '100', '[]', '[]', '1', '[{\"id\":\"41255cc5-66cd-4d43-a21d-8d0f504e5e60\",\"parameterName\":\"body\",\"first\":true}]', '[]', 186, '1', '2024-04-28 13:56:06', '1', '2024-04-28 13:56:06', 'Y', NULL, NULL, NULL, NULL, NULL, NULL, NULL);
@ -35,7 +35,7 @@ INSERT INTO sys_application_api_type (id, app_id, name, sorts, org_id, sts, crea
INSERT INTO sys_application_api_type (id, app_id, name, sorts, org_id, sts, create_time, create_user_id, modify_time, modify_user_id) VALUES ('a15437331f7a4cb4895545742547d192', '82bd4293fda94d6896217509f11b6c4c', '档案对照', 52, NULL, 'Y', '2024-05-08 09:22:13', '1', '2024-05-08 09:22:13', '1');
INSERT INTO sys_application_database (id, app_id, source_code, source_name, source_type, source_ip, source_port, login_name, password, db_name, service_name, db_status, sorts, create_user_id, create_time, modify_user_id, modify_time, sts, org_id) VALUES ('c11bfa04c7384bd98d3e08566130fc4b', '82bd4293fda94d6896217509f11b6c4c', 'oldData', 'V2数据源', '3', 'hzya.ufyct.com', '9096', 'root', 'bd993088e8a7c3dc5f44441617f9b4bf', 'businesscenter', NULL, '2', 1, '1', '2024-05-13 13:54:12', '1', '2024-06-21 10:35:03', 'Y', NULL);
INSERT INTO sys_application_database (id, app_id, source_code, source_name, source_type, source_ip, source_port, login_name, password, db_name, service_name, db_status, sorts, create_user_id, create_time, modify_user_id, modify_time, sts, org_id) VALUES ('c11bfa04c7384bd98d3e08566130fc4b', '82bd4293fda94d6896217509f11b6c4c', 'oldData', 'V2数据源', '3', 'ufidahz.com.cn', '9096', 'root', 'bd993088e8a7c3dc5f44441617f9b4bf', 'businesscenter', NULL, '2', 1, '1', '2024-05-13 13:54:12', '1', '2024-06-21 10:35:03', 'Y', NULL);
INSERT INTO sys_application_plugin (id, app_id, plugin_name, plugin_code, plugin_version, plugin_remark, release_date, plugin_status, sorts, create_user_id, create_time, modify_user_id, modify_time, sts, org_id) VALUES ('11fb9d8434c04660a88527cf097c579b', '82bd4293fda94d6896217509f11b6c4c', '测试定时任务', 'SysMessageManageLogPlugin', '1.0', '测试定时任务', '2024-05-01 00:00:00', '1', 3, '1', '2024-05-07 14:32:57', '1', '2024-05-07 14:32:57', 'Y', NULL);
INSERT INTO sys_application_plugin (id, app_id, plugin_name, plugin_code, plugin_version, plugin_remark, release_date, plugin_status, sorts, create_user_id, create_time, modify_user_id, modify_time, sts, org_id) VALUES ('b7e0020d9ff7435196862bfa62d9ff40', '82bd4293fda94d6896217509f11b6c4c', '主数据抽取', 'MdmCustomerPlugin', '1', NULL, '2024-06-25 00:00:00', '1', 15, '1', '2024-06-25 14:45:47', '1', '2024-06-25 14:45:47', 'Y', NULL);

View File

@ -0,0 +1,57 @@
package com.hzya.frame;
import org.springframework.data.annotation.Id;
import java.io.Serializable;
public class TestUser implements Serializable {
private static final long serialVersionUID = -3258839839160856614L;
@Id
private String id;
private String name;
private String code;
@Override
public String toString() {
return "TestUser{" +
"id='" + id + '\'' +
", name='" + name + '\'' +
", code='" + code + '\'' +
'}';
}
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public String getCode() {
return code;
}
public void setCode(String code) {
this.code = code;
}
public TestUser() {
}
public TestUser(String id, String name, String code) {
this.id = id;
this.name = name;
this.code = code;
}
}

23
pom.xml
View File

@ -62,7 +62,8 @@
<minio.version>8.0.3</minio.version>
<postgresql.version>42.2.6</postgresql.version>
<jimureport.version>1.7.4</jimureport.version>
<dingtalk-stream-sdk.version>1.3.7</dingtalk-stream-sdk.version>
<dingtalk-sdk.version>2.1.46</dingtalk-sdk.version>
<!-- <groovy.version>4.0.15</groovy.version>-->
</properties>
<parent>
@ -379,7 +380,25 @@
<artifactId>tlog-all-spring-boot-starter</artifactId>
<version>1.5.2</version>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-mongodb</artifactId>
</dependency>
<dependency>
<groupId>com.dingtalk.open</groupId>
<artifactId>app-stream-client</artifactId>
<version>${dingtalk-stream-sdk.version}</version>
</dependency>
<dependency>
<groupId>com.aliyun</groupId>
<artifactId>dingtalk</artifactId>
<version>${dingtalk-sdk.version}</version>
</dependency>
<dependency>
<groupId>com.aliyun</groupId>
<artifactId>alibaba-dingtalk-service-sdk</artifactId>
<version>2.0.0</version>
</dependency>
</dependencies>
<build>

View File

@ -22,7 +22,7 @@ public class BipUtil {
*/
public static String sendU9cTOBipEsb(String parm, String apiCode,String token){
String baseUrl = "http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface";
String baseUrl = "http://127.0.0.1:8901/kangarooDataCenterV3/entranceController/externalCallInterface";
System.out.println("推送参数"+parm);
String result = HttpRequest.post(baseUrl)
.header("appId", "800023")//头信息多个头信息多次调用此方法即可
@ -40,7 +40,7 @@ public class BipUtil {
return null;
}
public static String getBipToken(String userCode, String apiCode){
String baseUrl = "http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface";
String baseUrl = "http://127.0.0.1:8901/kangarooDataCenterV3/entranceController/externalCallInterface";
String result = HttpRequest.post(baseUrl)
.header("appId", "800023")//头信息多个头信息多次调用此方法即可
.header("apiCode", apiCode)//头信息多个头信息多次调用此方法即可
@ -59,7 +59,7 @@ public class BipUtil {
return null;
}
public static String sendOaToU8c(String parm, String apiCode){
String baseUrl = "http://127.0.0.1:9999/kangarooDataCenterV3/entranceController/externalCallInterface";
String baseUrl = "http://127.0.0.1:8901/kangarooDataCenterV3/entranceController/externalCallInterface";
System.out.println("推送参数"+parm);
String result = HttpRequest.post(baseUrl)
.header("appId", "800035")//头信息多个头信息多次调用此方法即可

View File

@ -0,0 +1,48 @@
package com.hzya.frame.dingtalk.enums;
/**
* @Description 通讯录事件类型
* @Author xiangerlin
* @Date 2024/8/27 15:58
**/
public enum OrgEventEnum {
USER_ADD_ORG("user_add_org","通讯录用户新增"),
USER_MODIFY_ORG("user_modify_org","通讯录用户更改"),
USER_LEAVE_ORG("user_leave_org","通讯录用户离职"),
USER_ACTIVE_ORG("user_active_org","加入企业后用户激活"),
ORG_DEPT_CREATE("org_dept_create","通讯录企业部门创建"),
ORG_DEPT_MODIFY("org_dept_modify","通讯录企业部门更改"),
ORG_DEPT_REMOVE("org_dept_remove","通讯录企业部门删除"),
;
private String code;
private String explain;
OrgEventEnum(String code, String explain) {
this.code = code;
this.explain = explain;
}
public String getCode() {
return code;
}
public String getExplain() {
return explain;
}
/**
* 根据code获取事件类型
* @param code
* @return
*/
public static OrgEventEnum getByCode(String code){
for (OrgEventEnum org : OrgEventEnum.values()) {
if (org.getCode().equals(code)){
return org;
}
}
return null;
}
}

View File

@ -0,0 +1,32 @@
package com.hzya.frame.dingtalk.service;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.sysnew.application.entity.SysApplicationEntity;
import com.hzya.frame.sysnew.application.entity.SysExtensionApiEntity;
/**
* @Description 钉钉集成扩展类
* @Author xiangerlin
* @Date 2024/8/28 14:25
**/
public interface IDingTalkExtService {
/**
* 调用这个方法初始化钉钉参数
* @param entity
* @return
*/
SysExtensionApiEntity init(SysExtensionApiEntity entity);
/**
* 查询配置在应用上的钉钉参数
* @param sysApplication
* @return
*/
JSONObject getDingTalkConfig(SysApplicationEntity sysApplication);
/**
* 清空配置缓存
*/
void clearDingTalkConfigCatch();
}

View File

@ -0,0 +1,66 @@
package com.hzya.frame.dingtalk.service;
import com.dingtalk.api.request.OapiV2UserListRequest;
import com.dingtalk.api.response.OapiV2DepartmentGetResponse;
import com.dingtalk.api.response.OapiV2DepartmentListsubResponse;
import com.dingtalk.api.response.OapiV2UserGetResponse;
import com.dingtalk.api.response.OapiV2UserListResponse;
import java.util.List;
/**
* @Description 钉钉service
* @Author xiangerlin
* @Date 2024/8/27 16:17
**/
public interface IDingTalkService {
/**
* 根据userid获取用户详情
* @param userId 钉钉userid
* @param appKey
* @param appSecret
* @return
*/
OapiV2UserGetResponse.UserGetResponse getUserById(String userId,String appKey,String appSecret);
/**
* 根据userid获取用户详情
* @param userId
* @return
*/
OapiV2UserGetResponse.UserGetResponse getUserById(String userId);
/**
* 获取部门用户列表
* @param req 请求参数
* @param appKey
* @param appSecret
* @return
*/
OapiV2UserListResponse.PageResult getUserListByDeptId(OapiV2UserListRequest req, String appKey, String appSecret);
/**
* 根据部门id获取部门详情
* @param deptId 钉钉部门id
* @param appKey
* @param appSecret
* @return
*/
OapiV2DepartmentGetResponse.DeptGetResponse getDeptById(Long deptId,String appKey,String appSecret);
/**
* 根据部门id获取部门详情
* @param deptId
* @return
*/
OapiV2DepartmentGetResponse.DeptGetResponse getDeptById(Long deptId);
/**
* 获取部门列表此接口只会返回下一级部门信息
* @param deptId 部门id如果不传则查询一级部门
* @param appKey
* @param appSecret
* @return
*/
List<OapiV2DepartmentListsubResponse.DeptBaseResponse> getDeptList(Long deptId,String appKey,String appSecret);
}

View File

@ -0,0 +1,100 @@
package com.hzya.frame.dingtalk.service.impl;
import cn.hutool.core.util.StrUtil;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.dingtalk.service.IDingTalkExtService;
import com.hzya.frame.dingtalk.util.DingTalkAccessToken;
import com.hzya.frame.sysnew.application.api.entity.SysApplicationApiEntity;
import com.hzya.frame.sysnew.application.apiPara.dao.ISysApplicationApiParaDao;
import com.hzya.frame.sysnew.application.apiPara.entity.SysApplicationApiParaEntity;
import com.hzya.frame.sysnew.application.apiPara.service.ISysApplicationApiParaService;
import com.hzya.frame.sysnew.application.entity.SysApplicationEntity;
import com.hzya.frame.sysnew.application.entity.SysExtensionApiEntity;
import org.apache.commons.collections.CollectionUtils;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;
import java.util.stream.Collectors;
import java.util.stream.Stream;
/**
* @Description 钉钉集成扩展类
* @Author xiangerlin
* @Date 2024/8/28 14:25
**/
@Service(value = "dingTalkExtService")
public class DingTalkExtServiceImpl implements IDingTalkExtService {
@Resource
private ISysApplicationApiParaDao sysApplicationApiParaDao;
private final ConcurrentHashMap<String, JSONObject> dingTalkMap = new ConcurrentHashMap<>();
/**
* 调用这个方法初始化钉钉参数
*
* @param entity
* @return
*/
@Override
public SysExtensionApiEntity init(SysExtensionApiEntity entity) {
Map<String, String> headers = entity.getHeaders();
if (null == headers){
headers = new HashMap<>();
}
SysApplicationEntity receiveApp = entity.getReceiveApp();
//查询应用上配置的参数
JSONObject dingTalkConfig = getDingTalkConfig(receiveApp);
//给token赋值
entity.setQuerys("access_token="+DingTalkAccessToken.getAccessToken(dingTalkConfig.getString("appKey"),dingTalkConfig.getString("appSecret")));
return entity;
}
/**
* 查询配置在应用上的钉钉参数
*
* @param sysApplication
* @return
*/
@Override
public JSONObject getDingTalkConfig(SysApplicationEntity sysApplication) {
if (null != sysApplication && StrUtil.isNotEmpty(sysApplication.getId()) && null != sysApplication.getAppId()){
JSONObject jsonObject = new JSONObject();
String key = sysApplication.getAppId()+"dingTalk";
if (null != dingTalkMap.get(key)){
return dingTalkMap.get(key);
}else {
//查询应用上配置的参数
SysApplicationApiParaEntity paraEntity = new SysApplicationApiParaEntity();
paraEntity.setAppId(sysApplication.getId());
List<SysApplicationApiParaEntity> paraList = sysApplicationApiParaDao.query(paraEntity);
if (CollectionUtils.isNotEmpty(paraList)) {
List<SysApplicationApiParaEntity> appKeyList = paraList.stream().filter(p -> p.getInterfaceKey().equals("appKey")).collect(Collectors.toList());
if (CollectionUtils.isNotEmpty(appKeyList)) {
jsonObject.put("appKey", appKeyList.get(0).getInterfaceValue());
}
List<SysApplicationApiParaEntity> appSecretList = paraList.stream().filter(p -> p.getInterfaceKey().equals("appSecret")).collect(Collectors.toList());
if (CollectionUtils.isNotEmpty(appSecretList)) {
jsonObject.put("appSecret", appSecretList.get(0).getInterfaceValue());
}
dingTalkMap.put(key,jsonObject);
return dingTalkMap.get(key);
}
}
}
return null;
}
/**
* 清空配置缓存
*/
@Override
public void clearDingTalkConfigCatch() {
dingTalkMap.clear();
}
}

View File

@ -0,0 +1,164 @@
package com.hzya.frame.dingtalk.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.dingtalk.api.DefaultDingTalkClient;
import com.dingtalk.api.DingTalkClient;
import com.dingtalk.api.request.OapiV2DepartmentGetRequest;
import com.dingtalk.api.request.OapiV2DepartmentListsubRequest;
import com.dingtalk.api.request.OapiV2UserGetRequest;
import com.dingtalk.api.request.OapiV2UserListRequest;
import com.dingtalk.api.response.OapiV2DepartmentGetResponse;
import com.dingtalk.api.response.OapiV2DepartmentListsubResponse;
import com.dingtalk.api.response.OapiV2UserGetResponse;
import com.dingtalk.api.response.OapiV2UserListResponse;
import com.hzya.frame.dingtalk.service.IDingTalkService;
import com.hzya.frame.dingtalk.util.DingTalkAccessToken;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* @Description 钉钉service
* @Author xiangerlin
* @Date 2024/8/27 16:17
**/
@Service
public class DingTalkServiceImpl implements IDingTalkService {
Logger logger = LoggerFactory.getLogger(getClass());
@Value("${dingtalk.appKey:}")
private String dAppKey;
@Value("${dingtalk.appSecret:}")
private String dAppSecret;
/**
* 根据userid获取用户详情
*
* @param userId 钉钉userid
* @param appKey
* @param appSecret
* @return
*/
@Override
public OapiV2UserGetResponse.UserGetResponse getUserById(String userId, String appKey, String appSecret) {
DingTalkClient client = new DefaultDingTalkClient("https://oapi.dingtalk.com/topapi/v2/user/get");
OapiV2UserGetRequest req = new OapiV2UserGetRequest();
req.setUserid(userId);
req.setLanguage("zh_CN");
try {
OapiV2UserGetResponse rsp = client.execute(req, DingTalkAccessToken.getAccessToken(appKey,appSecret));
if (rsp.isSuccess()){
OapiV2UserGetResponse.UserGetResponse result = rsp.getResult();
String s = JSONObject.toJSONString(result);
logger.info("人员详情信息:{}",s);
return result;
}
}catch (Exception e){
logger.error("根据部门id获取钉钉用户详情出错{}",e);
}
return null;
}
/**
* 根据userid获取用户详情
*
* @param userId
* @return
*/
@Override
public OapiV2UserGetResponse.UserGetResponse getUserById(String userId) {
return getUserById(userId,dAppKey,dAppSecret);
}
/**
* 获取部门用户列表
*
* @param req 请求参数
* @param appKey
* @param appSecret
* @return
*/
@Override
public OapiV2UserListResponse.PageResult getUserListByDeptId(OapiV2UserListRequest req, String appKey, String appSecret) {
try {
DingTalkClient client = new DefaultDingTalkClient("https://oapi.dingtalk.com/topapi/v2/user/list");
req.setSize(100L);//每页最大只能查100条
req.setOrderField("modify_desc");
req.setContainAccessLimit(false);
req.setLanguage("zh_CN");
OapiV2UserListResponse rsp = client.execute(req, DingTalkAccessToken.getAccessToken(appKey,appSecret));
OapiV2UserListResponse.PageResult result = rsp.getResult();
return result;
}catch (Exception e){
e.printStackTrace();
}
return null;
}
/**
* 根据部门id获取部门详情
*
* @param deptId 钉钉部门id
* @param appKey
* @param appSecret
* @return
*/
@Override
public OapiV2DepartmentGetResponse.DeptGetResponse getDeptById(Long deptId, String appKey, String appSecret) {
DingTalkClient client = new DefaultDingTalkClient("https://oapi.dingtalk.com/topapi/v2/department/get");
OapiV2DepartmentGetRequest req = new OapiV2DepartmentGetRequest();
req.setDeptId(deptId);
req.setLanguage("zh_CN");
try {
OapiV2DepartmentGetResponse rsp = client.execute(req, DingTalkAccessToken.getAccessToken(appKey,appSecret));
if (rsp.isSuccess()){
OapiV2DepartmentGetResponse.DeptGetResponse result = rsp.getResult();
String s = JSONObject.toJSONString(result);
logger.info("部门详情信息:{}",s);
return result;
}
}catch(Exception e){
logger.error("根据部门id获取钉钉部门出错{}",e);
}
return null;
}
/**
* 根据部门id获取部门详情
*
* @param deptId
* @return
*/
@Override
public OapiV2DepartmentGetResponse.DeptGetResponse getDeptById(Long deptId) {
return getDeptById(deptId,dAppKey,dAppSecret);
}
/**
* 获取部门列表此接口只会返回下一级部门信息
* @param deptId 部门id如果不传则查询一级部门
* @param appKey
* @param appSecret
* @return
*/
@Override
public List<OapiV2DepartmentListsubResponse.DeptBaseResponse> getDeptList(Long deptId,String appKey,String appSecret) {
try {
DingTalkClient client = new DefaultDingTalkClient("https://oapi.dingtalk.com/topapi/v2/department/listsub");
OapiV2DepartmentListsubRequest req = new OapiV2DepartmentListsubRequest();
req.setDeptId(deptId);
req.setLanguage("zh_CN");
OapiV2DepartmentListsubResponse rsp = client.execute(req, DingTalkAccessToken.getAccessToken(appKey,appSecret));
if (rsp.isSuccess()){
List<OapiV2DepartmentListsubResponse.DeptBaseResponse> result = rsp.getResult();
return result;
}
}catch (Exception e){
logger.error("获取部门列表接口出错:{}",e);
}
return null;
}
}

View File

@ -0,0 +1,103 @@
package com.hzya.frame.dingtalk.util;
import cn.hutool.core.util.StrUtil;
import com.aliyun.dingtalkoauth2_1_0.models.GetAccessTokenResponse;
import com.aliyun.tea.TeaException;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Value;
import java.time.Instant;
/**
* @Description 钉钉获取accessToken
* @Author xiangerlin
* @Date 2024/8/27 14:05
**/
public class DingTalkAccessToken {
static Logger logger = LoggerFactory.getLogger(DingTalkAccessToken.class);
//token
private static String accessToken;
//过期时间
private static Instant expireTime;
private static final Long CACHE_EXPIRY_TIME = 7000L; // 缓存有效时间
//应用key
private static String appKey;
//应用密钥
private static String appSecret;
@Value("${dingtalk.appKey:}")
public static void setAppKey(String appKey) {
DingTalkAccessToken.appKey = appKey;
}
@Value("${dingtalk.appSecret:}")
public static void setAppSecret(String appSecret) {
DingTalkAccessToken.appSecret = appSecret;
}
/**
* 获取token
* @return
*/
public static String getAccessToken(){
return getAccessToken(appKey,appSecret);
}
/**
* 获取accessToken
*
* @param appKey
* @param appSecret
* @return
*/
public static String getAccessToken(String appKey,String appSecret) {
//判断是否过期 如果没过期直接返回
if (null != accessToken && expireTime != null && Instant.now().isBefore(expireTime)) {
return accessToken;
}
//获取新的accessToken
accessToken = fetchNewAccessToken(appKey,appSecret);
//过期时间设置成当前事件+7000s预留200s的时间
expireTime = Instant.now().plusSeconds(CACHE_EXPIRY_TIME);
return accessToken;
}
/**
* 获取新的accessToken
*
* @return
*/
private static String fetchNewAccessToken(String appKey,String appSecret) {
try {
//查询应用上配置的钉钉信息
if (StrUtil.isNotEmpty(appKey) && StrUtil.isNotEmpty(appSecret)) {
//查询应用上的信息
com.aliyun.dingtalkoauth2_1_0.Client client = DingTalkAccessToken.createClient();
com.aliyun.dingtalkoauth2_1_0.models.GetAccessTokenRequest getAccessTokenRequest = new com.aliyun.dingtalkoauth2_1_0.models.GetAccessTokenRequest()
.setAppKey(appKey)
.setAppSecret(appSecret);
GetAccessTokenResponse accessToken = client.getAccessToken(getAccessTokenRequest);
String accessToken1 = accessToken.getBody().getAccessToken();
return accessToken1;
}
} catch (Exception _err) {
TeaException err = new TeaException(_err.getMessage(), _err);
if (!com.aliyun.teautil.Common.empty(err.code) && !com.aliyun.teautil.Common.empty(err.message)) {
// err 中含有 code message 属性可帮助开发定位问题
}
logger.error("获取钉钉token出错:{}", _err);
}
return null;
}
/**
* 使用 Token 初始化账号Client
*
* @return Client
* @throws Exception
*/
private static com.aliyun.dingtalkoauth2_1_0.Client createClient() throws Exception {
com.aliyun.teaopenapi.models.Config config = new com.aliyun.teaopenapi.models.Config();
config.protocol = "https";
config.regionId = "central";
return new com.aliyun.dingtalkoauth2_1_0.Client(config);
}
}

View File

@ -0,0 +1,15 @@
package com.hzya.frame.excel.template.dao;
import com.hzya.frame.excel.template.entity.ExcelTemplateEntity;
import com.hzya.frame.basedao.dao.IBaseDao;
/**
* excel模版表(excel_template: table)表数据库访问层
*
* @author makejava
* @since 2024-08-12 16:42:49
*/
public interface IExcelTemplateDao extends IBaseDao<ExcelTemplateEntity, String> {
}

View File

@ -0,0 +1,17 @@
package com.hzya.frame.excel.template.dao.impl;
import com.hzya.frame.excel.template.entity.ExcelTemplateEntity;
import com.hzya.frame.excel.template.dao.IExcelTemplateDao;
import org.springframework.stereotype.Repository;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
/**
* excel模版表(ExcelTemplate)表数据库访问层
*
* @author makejava
* @since 2024-08-12 16:42:50
*/
@Repository(value = "ExcelTemplateDaoImpl")
public class ExcelTemplateDaoImpl extends MybatisGenericDao<ExcelTemplateEntity, String> implements IExcelTemplateDao{
}

View File

@ -0,0 +1,76 @@
package com.hzya.frame.excel.template.entity;
import java.util.Date;
import com.hzya.frame.web.entity.BaseEntity;
/**
* excel模版表(ExcelTemplate)实体类
*
* @author makejava
* @since 2024-08-12 16:42:50
*/
public class ExcelTemplateEntity extends BaseEntity {
/** 模版名称 */
private String templateName;
/** 应用id */
private String appId;
/** 模版编码 */
private String templateCode;
/** 绑定菜单 */
private String menuBind;
/** 菜单按钮 */
private String menuButton;
/** 公司id */
private String companyId;
public String getTemplateName() {
return templateName;
}
public void setTemplateName(String templateName) {
this.templateName = templateName;
}
public String getAppId() {
return appId;
}
public void setAppId(String appId) {
this.appId = appId;
}
public String getTemplateCode() {
return templateCode;
}
public void setTemplateCode(String templateCode) {
this.templateCode = templateCode;
}
public String getMenuBind() {
return menuBind;
}
public void setMenuBind(String menuBind) {
this.menuBind = menuBind;
}
public String getMenuButton() {
return menuButton;
}
public void setMenuButton(String menuButton) {
this.menuButton = menuButton;
}
public String getCompanyId() {
return companyId;
}
public void setCompanyId(String companyId) {
this.companyId = companyId;
}
}

View File

@ -0,0 +1,261 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.excel.template.dao.impl.ExcelTemplateDaoImpl">
<resultMap id="get-ExcelTemplateEntity-result" type="com.hzya.frame.excel.template.entity.ExcelTemplateEntity" >
<result property="templateName" column="template_name" jdbcType="VARCHAR"/>
<result property="appId" column="app_id" jdbcType="VARCHAR"/>
<result property="templateCode" column="template_code" jdbcType="VARCHAR"/>
<result property="menuBind" column="menu_bind" jdbcType="VARCHAR"/>
<result property="menuButton" column="menu_button" jdbcType="VARCHAR"/>
<result property="sorts" column="sorts" jdbcType="INTEGER"/>
<result property="id" column="id" jdbcType="VARCHAR"/>
<result property="create_user_id" column="create_user_id" jdbcType="VARCHAR"/>
<result property="create_time" column="create_time" jdbcType="TIMESTAMP"/>
<result property="modify_time" column="modify_time" jdbcType="TIMESTAMP"/>
<result property="modify_user_id" column="modify_user_id" jdbcType="VARCHAR"/>
<result property="org_id" column="org_id" jdbcType="VARCHAR"/>
<result property="companyId" column="company_id" jdbcType="VARCHAR"/>
<result property="sts" column="sts" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询的字段-->
<sql id = "ExcelTemplateEntity_Base_Column_List">
template_name
,app_id
,template_code
,menu_bind
,menu_button
,sorts
,id
,create_user_id
,create_time
,modify_time
,modify_user_id
,org_id
,company_id
,sts
</sql>
<!--通过ID获取数据 -->
<select id="entity_get" resultMap="get-ExcelTemplateEntity-result">
select
<include refid="ExcelTemplateEntity_Base_Column_List" />
from excel_template where sts = 'Y' and id = #{id}
</select>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-ExcelTemplateEntity-result" parameterType = "com.hzya.frame.excel.template.entity.ExcelTemplateEntity">
select
<include refid="ExcelTemplateEntity_Base_Column_List" />
from excel_template
<trim prefix="where" prefixOverrides="and">
<if test="templateName != null and templateName != ''"> and template_name = #{templateName} </if>
<if test="appId != null and appId != ''"> and app_id = #{appId} </if>
<if test="templateCode != null and templateCode != ''"> and template_code = #{templateCode} </if>
<if test="menuBind != null and menuBind != ''"> and menu_bind = #{menuBind} </if>
<if test="menuButton != null and menuButton != ''"> and menu_button = #{menuButton} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id = #{create_user_id} </if>
<if test="create_time != null"> and create_time = #{create_time} </if>
<if test="modify_time != null"> and modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> and org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!-- 查询符合条件的数量 -->
<select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.excel.template.entity.ExcelTemplateEntity">
select count(1) from excel_template
<trim prefix="where" prefixOverrides="and">
<if test="templateName != null and templateName != ''"> and template_name = #{templateName} </if>
<if test="appId != null and appId != ''"> and app_id = #{appId} </if>
<if test="templateCode != null and templateCode != ''"> and template_code = #{templateCode} </if>
<if test="menuBind != null and menuBind != ''"> and menu_bind = #{menuBind} </if>
<if test="menuButton != null and menuButton != ''"> and menu_button = #{menuButton} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id = #{create_user_id} </if>
<if test="create_time != null"> and create_time = #{create_time} </if>
<if test="modify_time != null"> and modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> and org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null "> order by ${sort} ${order}</if>
</select>
<!-- 分页查询列表 采用like格式 -->
<select id="entity_list_like" resultMap="get-ExcelTemplateEntity-result" parameterType = "com.hzya.frame.excel.template.entity.ExcelTemplateEntity">
select
<include refid="ExcelTemplateEntity_Base_Column_List" />
from excel_template
<trim prefix="where" prefixOverrides="and">
<if test="templateName != null and templateName != ''"> and template_name like concat('%',#{templateName},'%') </if>
<if test="appId != null and appId != ''"> and app_id like concat('%',#{appId},'%') </if>
<if test="templateCode != null and templateCode != ''"> and template_code like concat('%',#{templateCode},'%') </if>
<if test="menuBind != null and menuBind != ''"> and menu_bind like concat('%',#{menuBind},'%') </if>
<if test="menuButton != null and menuButton != ''"> and menu_button like concat('%',#{menuButton},'%') </if>
<if test="sorts != null"> and sorts like concat('%',#{sorts},'%') </if>
<if test="id != null and id != ''"> and id like concat('%',#{id},'%') </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id like concat('%',#{create_user_id},'%') </if>
<if test="create_time != null"> and create_time like concat('%',#{create_time},'%') </if>
<if test="modify_time != null"> and modify_time like concat('%',#{modify_time},'%') </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id like concat('%',#{modify_user_id},'%') </if>
<if test="org_id != null and org_id != ''"> and org_id like concat('%',#{org_id},'%') </if>
<if test="companyId != null and companyId != ''"> and company_id like concat('%',#{companyId},'%') </if>
<if test="sts != null and sts != ''"> and sts like concat('%',#{sts},'%') </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!-- 查询列表 字段采用or格式 -->
<select id="ExcelTemplateentity_list_or" resultMap="get-ExcelTemplateEntity-result" parameterType = "com.hzya.frame.excel.template.entity.ExcelTemplateEntity">
select
<include refid="ExcelTemplateEntity_Base_Column_List" />
from excel_template
<trim prefix="where" prefixOverrides="and">
<if test="templateName != null and templateName != ''"> or template_name = #{templateName} </if>
<if test="appId != null and appId != ''"> or app_id = #{appId} </if>
<if test="templateCode != null and templateCode != ''"> or template_code = #{templateCode} </if>
<if test="menuBind != null and menuBind != ''"> or menu_bind = #{menuBind} </if>
<if test="menuButton != null and menuButton != ''"> or menu_button = #{menuButton} </if>
<if test="sorts != null"> or sorts = #{sorts} </if>
<if test="id != null and id != ''"> or id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> or create_user_id = #{create_user_id} </if>
<if test="create_time != null"> or create_time = #{create_time} </if>
<if test="modify_time != null"> or modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> or modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> or org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> or company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> or sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!--新增所有列-->
<insert id="entity_insert" parameterType = "com.hzya.frame.excel.template.entity.ExcelTemplateEntity" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template(
<trim suffix="" suffixOverrides=",">
<if test="templateName != null and templateName != ''"> template_name , </if>
<if test="appId != null and appId != ''"> app_id , </if>
<if test="templateCode != null and templateCode != ''"> template_code , </if>
<if test="menuBind != null and menuBind != ''"> menu_bind , </if>
<if test="menuButton != null and menuButton != ''"> menu_button , </if>
<if test="sorts != null"> sorts , </if>
<if test="id != null and id != ''"> id , </if>
<if test="create_user_id != null and create_user_id != ''"> create_user_id , </if>
<if test="create_time != null"> create_time , </if>
<if test="modify_time != null"> modify_time , </if>
<if test="modify_user_id != null and modify_user_id != ''"> modify_user_id , </if>
<if test="org_id != null and org_id != ''"> org_id , </if>
<if test="companyId != null and companyId != ''"> company_id , </if>
<if test="sts != null and sts != ''"> sts , </if>
<if test="sts == null ">sts,</if>
</trim>
)values(
<trim suffix="" suffixOverrides=",">
<if test="templateName != null and templateName != ''"> #{templateName} ,</if>
<if test="appId != null and appId != ''"> #{appId} ,</if>
<if test="templateCode != null and templateCode != ''"> #{templateCode} ,</if>
<if test="menuBind != null and menuBind != ''"> #{menuBind} ,</if>
<if test="menuButton != null and menuButton != ''"> #{menuButton} ,</if>
<if test="sorts != null"> #{sorts} ,</if>
<if test="id != null and id != ''"> #{id} ,</if>
<if test="create_user_id != null and create_user_id != ''"> #{create_user_id} ,</if>
<if test="create_time != null"> #{create_time} ,</if>
<if test="modify_time != null"> #{modify_time} ,</if>
<if test="modify_user_id != null and modify_user_id != ''"> #{modify_user_id} ,</if>
<if test="org_id != null and org_id != ''"> #{org_id} ,</if>
<if test="companyId != null and companyId != ''"> #{companyId} ,</if>
<if test="sts != null and sts != ''"> #{sts} ,</if>
<if test="sts == null ">'Y',</if>
</trim>
)
</insert>
<!-- 批量新增 -->
<insert id="entityInsertBatch" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template(template_name, app_id, template_code, menu_bind, menu_button, create_user_id, create_time, modify_time, modify_user_id, org_id, company_id, sts, sts)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.templateName},#{entity.appId},#{entity.templateCode},#{entity.menuBind},#{entity.menuButton},#{entity.create_user_id},#{entity.create_time},#{entity.modify_time},#{entity.modify_user_id},#{entity.org_id},#{entity.companyId},#{entity.sts}, 'Y')
</foreach>
</insert>
<!-- 批量新增或者修改-->
<insert id="entityInsertOrUpdateBatch" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template(template_name, app_id, template_code, menu_bind, menu_button, create_user_id, create_time, modify_time, modify_user_id, org_id, company_id, sts)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.templateName},#{entity.appId},#{entity.templateCode},#{entity.menuBind},#{entity.menuButton},#{entity.create_user_id},#{entity.create_time},#{entity.modify_time},#{entity.modify_user_id},#{entity.org_id},#{entity.companyId},#{entity.sts})
</foreach>
on duplicate key update
template_name = values(template_name),
app_id = values(app_id),
template_code = values(template_code),
menu_bind = values(menu_bind),
menu_button = values(menu_button),
create_user_id = values(create_user_id),
create_time = values(create_time),
modify_time = values(modify_time),
modify_user_id = values(modify_user_id),
org_id = values(org_id),
company_id = values(company_id),
sts = values(sts)</insert>
<!--通过主键修改方法-->
<update id="entity_update" parameterType = "com.hzya.frame.excel.template.entity.ExcelTemplateEntity" >
update excel_template set
<trim suffix="" suffixOverrides=",">
<if test="templateName != null and templateName != ''"> template_name = #{templateName},</if>
<if test="appId != null and appId != ''"> app_id = #{appId},</if>
<if test="templateCode != null and templateCode != ''"> template_code = #{templateCode},</if>
<if test="menuBind != null and menuBind != ''"> menu_bind = #{menuBind},</if>
<if test="menuButton != null and menuButton != ''"> menu_button = #{menuButton},</if>
<if test="create_user_id != null and create_user_id != ''"> create_user_id = #{create_user_id},</if>
<if test="create_time != null"> create_time = #{create_time},</if>
<if test="modify_time != null"> modify_time = #{modify_time},</if>
<if test="modify_user_id != null and modify_user_id != ''"> modify_user_id = #{modify_user_id},</if>
<if test="org_id != null and org_id != ''"> org_id = #{org_id},</if>
<if test="companyId != null and companyId != ''"> company_id = #{companyId},</if>
<if test="sts != null and sts != ''"> sts = #{sts},</if>
</trim>
where sorts = #{sorts}
</update>
<!-- 逻辑删除 -->
<update id="entity_logicDelete" parameterType = "com.hzya.frame.excel.template.entity.ExcelTemplateEntity" >
update excel_template set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id}
where sorts = #{sorts}
</update>
<!-- 多条件逻辑删除 -->
<update id="entity_logicDelete_Multi_Condition" parameterType = "com.hzya.frame.excel.template.entity.ExcelTemplateEntity" >
update excel_template set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id}
<trim prefix="where" prefixOverrides="and">
<if test="templateName != null and templateName != ''"> and template_name = #{templateName} </if>
<if test="appId != null and appId != ''"> and app_id = #{appId} </if>
<if test="templateCode != null and templateCode != ''"> and template_code = #{templateCode} </if>
<if test="menuBind != null and menuBind != ''"> and menu_bind = #{menuBind} </if>
<if test="menuButton != null and menuButton != ''"> and menu_button = #{menuButton} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
</update>
<!--通过主键删除-->
<delete id="entity_delete">
delete from excel_template where sorts = #{sorts}
</delete>
</mapper>

View File

@ -0,0 +1,12 @@
package com.hzya.frame.excel.template.service;
import com.hzya.frame.excel.template.entity.ExcelTemplateEntity;
import com.hzya.frame.basedao.service.IBaseService;
/**
* excel模版表(ExcelTemplate)表服务接口
*
* @author makejava
* @since 2024-08-12 16:42:50
*/
public interface IExcelTemplateService extends IBaseService<ExcelTemplateEntity, String>{
}

View File

@ -0,0 +1,26 @@
package com.hzya.frame.excel.template.service.impl;
import com.hzya.frame.excel.template.entity.ExcelTemplateEntity;
import com.hzya.frame.excel.template.dao.IExcelTemplateDao;
import com.hzya.frame.excel.template.service.IExcelTemplateService;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService;
/**
* excel模版表(ExcelTemplate)表服务实现类
*
* @author makejava
* @since 2024-08-12 16:42:50
*/
@Service(value = "excelTemplateService")
public class ExcelTemplateServiceImpl extends BaseService<ExcelTemplateEntity, String> implements IExcelTemplateService {
private IExcelTemplateDao excelTemplateDao;
@Autowired
public void setExcelTemplateDao(IExcelTemplateDao dao) {
this.excelTemplateDao = dao;
this.dao = dao;
}
}

View File

@ -0,0 +1,15 @@
package com.hzya.frame.excel.templateConfig.dao;
import com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity;
import com.hzya.frame.basedao.dao.IBaseDao;
/**
* excel模版配置表(excel_template_config: table)表数据库访问层
*
* @author makejava
* @since 2024-08-12 16:43:38
*/
public interface IExcelTemplateConfigDao extends IBaseDao<ExcelTemplateConfigEntity, String> {
}

View File

@ -0,0 +1,17 @@
package com.hzya.frame.excel.templateConfig.dao.impl;
import com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity;
import com.hzya.frame.excel.templateConfig.dao.IExcelTemplateConfigDao;
import org.springframework.stereotype.Repository;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
/**
* excel模版配置表(ExcelTemplateConfig)表数据库访问层
*
* @author makejava
* @since 2024-08-12 16:43:38
*/
@Repository(value = "ExcelTemplateConfigDaoImpl")
public class ExcelTemplateConfigDaoImpl extends MybatisGenericDao<ExcelTemplateConfigEntity, String> implements IExcelTemplateConfigDao{
}

View File

@ -0,0 +1,66 @@
package com.hzya.frame.excel.templateConfig.entity;
import java.util.Date;
import com.hzya.frame.web.entity.BaseEntity;
/**
* excel模版配置表(ExcelTemplateConfig)实体类
*
* @author makejava
* @since 2024-08-12 16:43:38
*/
public class ExcelTemplateConfigEntity extends BaseEntity {
/** 模版id */
private String templateId;
/** 类型(数据库表/语句) */
private String type;
/** 表类型(主表/明细) */
private String tableType;
/** 数据字典id */
private String dataDictionaryId;
/** 公司id */
private String companyId;
public String getTemplateId() {
return templateId;
}
public void setTemplateId(String templateId) {
this.templateId = templateId;
}
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
public String getTableType() {
return tableType;
}
public void setTableType(String tableType) {
this.tableType = tableType;
}
public String getDataDictionaryId() {
return dataDictionaryId;
}
public void setDataDictionaryId(String dataDictionaryId) {
this.dataDictionaryId = dataDictionaryId;
}
public String getCompanyId() {
return companyId;
}
public void setCompanyId(String companyId) {
this.companyId = companyId;
}
}

View File

@ -0,0 +1,243 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.excel.templateConfig.dao.impl.ExcelTemplateConfigDaoImpl">
<resultMap id="get-ExcelTemplateConfigEntity-result" type="com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity" >
<result property="templateId" column="template_id" jdbcType="VARCHAR"/>
<result property="type" column="type" jdbcType="VARCHAR"/>
<result property="tableType" column="table_type" jdbcType="VARCHAR"/>
<result property="dataDictionaryId" column="data_dictionary_id" jdbcType="VARCHAR"/>
<result property="sorts" column="sorts" jdbcType="INTEGER"/>
<result property="id" column="id" jdbcType="VARCHAR"/>
<result property="create_user_id" column="create_user_id" jdbcType="VARCHAR"/>
<result property="create_time" column="create_time" jdbcType="TIMESTAMP"/>
<result property="modify_time" column="modify_time" jdbcType="TIMESTAMP"/>
<result property="modify_user_id" column="modify_user_id" jdbcType="VARCHAR"/>
<result property="org_id" column="org_id" jdbcType="VARCHAR"/>
<result property="companyId" column="company_id" jdbcType="VARCHAR"/>
<result property="sts" column="sts" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询的字段-->
<sql id = "ExcelTemplateConfigEntity_Base_Column_List">
template_id
,type
,table_type
,data_dictionary_id
,sorts
,id
,create_user_id
,create_time
,modify_time
,modify_user_id
,org_id
,company_id
,sts
</sql>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-ExcelTemplateConfigEntity-result" parameterType = "com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity">
select
<include refid="ExcelTemplateConfigEntity_Base_Column_List" />
from excel_template_config
<trim prefix="where" prefixOverrides="and">
<if test="templateId != null and templateId != ''"> and template_id = #{templateId} </if>
<if test="type != null and type != ''"> and type = #{type} </if>
<if test="tableType != null and tableType != ''"> and table_type = #{tableType} </if>
<if test="dataDictionaryId != null and dataDictionaryId != ''"> and data_dictionary_id = #{dataDictionaryId} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id = #{create_user_id} </if>
<if test="create_time != null"> and create_time = #{create_time} </if>
<if test="modify_time != null"> and modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> and org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!-- 查询符合条件的数量 -->
<select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity">
select count(1) from excel_template_config
<trim prefix="where" prefixOverrides="and">
<if test="templateId != null and templateId != ''"> and template_id = #{templateId} </if>
<if test="type != null and type != ''"> and type = #{type} </if>
<if test="tableType != null and tableType != ''"> and table_type = #{tableType} </if>
<if test="dataDictionaryId != null and dataDictionaryId != ''"> and data_dictionary_id = #{dataDictionaryId} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id = #{create_user_id} </if>
<if test="create_time != null"> and create_time = #{create_time} </if>
<if test="modify_time != null"> and modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> and org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null "> order by ${sort} ${order}</if>
</select>
<!-- 分页查询列表 采用like格式 -->
<select id="entity_list_like" resultMap="get-ExcelTemplateConfigEntity-result" parameterType = "com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity">
select
<include refid="ExcelTemplateConfigEntity_Base_Column_List" />
from excel_template_config
<trim prefix="where" prefixOverrides="and">
<if test="templateId != null and templateId != ''"> and template_id like concat('%',#{templateId},'%') </if>
<if test="type != null and type != ''"> and type like concat('%',#{type},'%') </if>
<if test="tableType != null and tableType != ''"> and table_type like concat('%',#{tableType},'%') </if>
<if test="dataDictionaryId != null and dataDictionaryId != ''"> and data_dictionary_id like concat('%',#{dataDictionaryId},'%') </if>
<if test="sorts != null"> and sorts like concat('%',#{sorts},'%') </if>
<if test="id != null and id != ''"> and id like concat('%',#{id},'%') </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id like concat('%',#{create_user_id},'%') </if>
<if test="create_time != null"> and create_time like concat('%',#{create_time},'%') </if>
<if test="modify_time != null"> and modify_time like concat('%',#{modify_time},'%') </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id like concat('%',#{modify_user_id},'%') </if>
<if test="org_id != null and org_id != ''"> and org_id like concat('%',#{org_id},'%') </if>
<if test="companyId != null and companyId != ''"> and company_id like concat('%',#{companyId},'%') </if>
<if test="sts != null and sts != ''"> and sts like concat('%',#{sts},'%') </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!-- 查询列表 字段采用or格式 -->
<select id="ExcelTemplateConfigentity_list_or" resultMap="get-ExcelTemplateConfigEntity-result" parameterType = "com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity">
select
<include refid="ExcelTemplateConfigEntity_Base_Column_List" />
from excel_template_config
<trim prefix="where" prefixOverrides="and">
<if test="templateId != null and templateId != ''"> or template_id = #{templateId} </if>
<if test="type != null and type != ''"> or type = #{type} </if>
<if test="tableType != null and tableType != ''"> or table_type = #{tableType} </if>
<if test="dataDictionaryId != null and dataDictionaryId != ''"> or data_dictionary_id = #{dataDictionaryId} </if>
<if test="sorts != null"> or sorts = #{sorts} </if>
<if test="id != null and id != ''"> or id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> or create_user_id = #{create_user_id} </if>
<if test="create_time != null"> or create_time = #{create_time} </if>
<if test="modify_time != null"> or modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> or modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> or org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> or company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> or sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!--新增所有列-->
<insert id="entity_insert" parameterType = "com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template_config(
<trim suffix="" suffixOverrides=",">
<if test="templateId != null and templateId != ''"> template_id , </if>
<if test="type != null and type != ''"> type , </if>
<if test="tableType != null and tableType != ''"> table_type , </if>
<if test="dataDictionaryId != null and dataDictionaryId != ''"> data_dictionary_id , </if>
<if test="sorts != null"> sorts , </if>
<if test="id != null and id != ''"> id , </if>
<if test="create_user_id != null and create_user_id != ''"> create_user_id , </if>
<if test="create_time != null"> create_time , </if>
<if test="modify_time != null"> modify_time , </if>
<if test="modify_user_id != null and modify_user_id != ''"> modify_user_id , </if>
<if test="org_id != null and org_id != ''"> org_id , </if>
<if test="companyId != null and companyId != ''"> company_id , </if>
<if test="sts != null and sts != ''"> sts , </if>
<if test="sts == null ">sts,</if>
</trim>
)values(
<trim suffix="" suffixOverrides=",">
<if test="templateId != null and templateId != ''"> #{templateId} ,</if>
<if test="type != null and type != ''"> #{type} ,</if>
<if test="tableType != null and tableType != ''"> #{tableType} ,</if>
<if test="dataDictionaryId != null and dataDictionaryId != ''"> #{dataDictionaryId} ,</if>
<if test="sorts != null"> #{sorts} ,</if>
<if test="id != null and id != ''"> #{id} ,</if>
<if test="create_user_id != null and create_user_id != ''"> #{create_user_id} ,</if>
<if test="create_time != null"> #{create_time} ,</if>
<if test="modify_time != null"> #{modify_time} ,</if>
<if test="modify_user_id != null and modify_user_id != ''"> #{modify_user_id} ,</if>
<if test="org_id != null and org_id != ''"> #{org_id} ,</if>
<if test="companyId != null and companyId != ''"> #{companyId} ,</if>
<if test="sts != null and sts != ''"> #{sts} ,</if>
<if test="sts == null ">'Y',</if>
</trim>
)
</insert>
<!-- 批量新增 -->
<insert id="entityInsertBatch" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template_config(template_id, type, table_type, data_dictionary_id, create_user_id, create_time, modify_time, modify_user_id, org_id, company_id, sts, sts)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.templateId},#{entity.type},#{entity.tableType},#{entity.dataDictionaryId},#{entity.create_user_id},#{entity.create_time},#{entity.modify_time},#{entity.modify_user_id},#{entity.org_id},#{entity.companyId},#{entity.sts}, 'Y')
</foreach>
</insert>
<!-- 批量新增或者修改-->
<insert id="entityInsertOrUpdateBatch" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template_config(template_id, type, table_type, data_dictionary_id, create_user_id, create_time, modify_time, modify_user_id, org_id, company_id, sts)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.templateId},#{entity.type},#{entity.tableType},#{entity.dataDictionaryId},#{entity.create_user_id},#{entity.create_time},#{entity.modify_time},#{entity.modify_user_id},#{entity.org_id},#{entity.companyId},#{entity.sts})
</foreach>
on duplicate key update
template_id = values(template_id),
type = values(type),
table_type = values(table_type),
data_dictionary_id = values(data_dictionary_id),
create_user_id = values(create_user_id),
create_time = values(create_time),
modify_time = values(modify_time),
modify_user_id = values(modify_user_id),
org_id = values(org_id),
company_id = values(company_id),
sts = values(sts)</insert>
<!--通过主键修改方法-->
<update id="entity_update" parameterType = "com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity" >
update excel_template_config set
<trim suffix="" suffixOverrides=",">
<if test="templateId != null and templateId != ''"> template_id = #{templateId},</if>
<if test="type != null and type != ''"> type = #{type},</if>
<if test="tableType != null and tableType != ''"> table_type = #{tableType},</if>
<if test="dataDictionaryId != null and dataDictionaryId != ''"> data_dictionary_id = #{dataDictionaryId},</if>
<if test="create_user_id != null and create_user_id != ''"> create_user_id = #{create_user_id},</if>
<if test="create_time != null"> create_time = #{create_time},</if>
<if test="modify_time != null"> modify_time = #{modify_time},</if>
<if test="modify_user_id != null and modify_user_id != ''"> modify_user_id = #{modify_user_id},</if>
<if test="org_id != null and org_id != ''"> org_id = #{org_id},</if>
<if test="companyId != null and companyId != ''"> company_id = #{companyId},</if>
<if test="sts != null and sts != ''"> sts = #{sts},</if>
</trim>
where sorts = #{sorts}
</update>
<!-- 逻辑删除 -->
<update id="entity_logicDelete" parameterType = "com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity" >
update excel_template_config set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id}
where sorts = #{sorts}
</update>
<!-- 多条件逻辑删除 -->
<update id="entity_logicDelete_Multi_Condition" parameterType = "com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity" >
update excel_template_config set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id}
<trim prefix="where" prefixOverrides="and">
<if test="templateId != null and templateId != ''"> and template_id = #{templateId} </if>
<if test="type != null and type != ''"> and type = #{type} </if>
<if test="tableType != null and tableType != ''"> and table_type = #{tableType} </if>
<if test="dataDictionaryId != null and dataDictionaryId != ''"> and data_dictionary_id = #{dataDictionaryId} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
</update>
<!--通过主键删除-->
<delete id="entity_delete">
delete from excel_template_config where sorts = #{sorts}
</delete>
</mapper>

View File

@ -0,0 +1,12 @@
package com.hzya.frame.excel.templateConfig.service;
import com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity;
import com.hzya.frame.basedao.service.IBaseService;
/**
* excel模版配置表(ExcelTemplateConfig)表服务接口
*
* @author makejava
* @since 2024-08-12 16:43:38
*/
public interface IExcelTemplateConfigService extends IBaseService<ExcelTemplateConfigEntity, String>{
}

View File

@ -0,0 +1,26 @@
package com.hzya.frame.excel.templateConfig.service.impl;
import com.hzya.frame.excel.templateConfig.entity.ExcelTemplateConfigEntity;
import com.hzya.frame.excel.templateConfig.dao.IExcelTemplateConfigDao;
import com.hzya.frame.excel.templateConfig.service.IExcelTemplateConfigService;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService;
/**
* excel模版配置表(ExcelTemplateConfig)表服务实现类
*
* @author makejava
* @since 2024-08-12 16:43:38
*/
@Service(value = "excelTemplateConfigService")
public class ExcelTemplateConfigServiceImpl extends BaseService<ExcelTemplateConfigEntity, String> implements IExcelTemplateConfigService {
private IExcelTemplateConfigDao excelTemplateConfigDao;
@Autowired
public void setExcelTemplateConfigDao(IExcelTemplateConfigDao dao) {
this.excelTemplateConfigDao = dao;
this.dao = dao;
}
}

View File

@ -0,0 +1,15 @@
package com.hzya.frame.excel.templateConfigDetial.dao;
import com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity;
import com.hzya.frame.basedao.dao.IBaseDao;
/**
* excel模版配置明细表(excel_template_config_detail: table)表数据库访问层
*
* @author makejava
* @since 2024-08-13 08:39:02
*/
public interface IExcelTemplateConfigDetailDao extends IBaseDao<ExcelTemplateConfigDetailEntity, String> {
}

View File

@ -0,0 +1,17 @@
package com.hzya.frame.excel.templateConfigDetial.dao.impl;
import com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity;
import com.hzya.frame.excel.templateConfigDetial.dao.IExcelTemplateConfigDetailDao;
import org.springframework.stereotype.Repository;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
/**
* excel模版配置明细表(ExcelTemplateConfigDetail)表数据库访问层
*
* @author makejava
* @since 2024-08-13 08:39:02
*/
@Repository(value = "ExcelTemplateConfigDetailDaoImpl")
public class ExcelTemplateConfigDetailDaoImpl extends MybatisGenericDao<ExcelTemplateConfigDetailEntity, String> implements IExcelTemplateConfigDetailDao{
}

View File

@ -0,0 +1,96 @@
package com.hzya.frame.excel.templateConfigDetial.entity;
import java.util.Date;
import com.hzya.frame.web.entity.BaseEntity;
/**
* excel模版配置明细表(ExcelTemplateConfigDetail)实体类
*
* @author makejava
* @since 2024-08-13 08:39:02
*/
public class ExcelTemplateConfigDetailEntity extends BaseEntity {
/** 字段名称 */
private String fieldName;
/** 字段编码 */
private String fieldCode;
/** 字段类型 */
private String fieldType;
/** 应用数据字典明细表id */
private String dictionaryDetailId;
/** 显示名称 */
private String showName;
/** 序号 */
private Long templateSort;
/** 开关 */
private String templateSwitch;
/** 公司id */
private String companyId;
public String getFieldName() {
return fieldName;
}
public void setFieldName(String fieldName) {
this.fieldName = fieldName;
}
public String getFieldCode() {
return fieldCode;
}
public void setFieldCode(String fieldCode) {
this.fieldCode = fieldCode;
}
public String getFieldType() {
return fieldType;
}
public void setFieldType(String fieldType) {
this.fieldType = fieldType;
}
public String getDictionaryDetailId() {
return dictionaryDetailId;
}
public void setDictionaryDetailId(String dictionaryDetailId) {
this.dictionaryDetailId = dictionaryDetailId;
}
public String getShowName() {
return showName;
}
public void setShowName(String showName) {
this.showName = showName;
}
public Long getTemplateSort() {
return templateSort;
}
public void setTemplateSort(Long templateSort) {
this.templateSort = templateSort;
}
public String getTemplateSwitch() {
return templateSwitch;
}
public void setTemplateSwitch(String templateSwitch) {
this.templateSwitch = templateSwitch;
}
public String getCompanyId() {
return companyId;
}
public void setCompanyId(String companyId) {
this.companyId = companyId;
}
}

View File

@ -0,0 +1,278 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.excel.templateConfigDetial.dao.impl.ExcelTemplateConfigDetailDaoImpl">
<resultMap id="get-ExcelTemplateConfigDetailEntity-result" type="com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity" >
<result property="fieldName" column="field_name" jdbcType="VARCHAR"/>
<result property="fieldCode" column="field_code" jdbcType="VARCHAR"/>
<result property="fieldType" column="field_type" jdbcType="VARCHAR"/>
<result property="dictionaryDetailId" column="dictionary_detail_id" jdbcType="VARCHAR"/>
<result property="showName" column="show_name" jdbcType="VARCHAR"/>
<result property="templateSort" column="template_sort" jdbcType="INTEGER"/>
<result property="templateSwitch" column="template_switch" jdbcType="VARCHAR"/>
<result property="sorts" column="sorts" jdbcType="INTEGER"/>
<result property="id" column="id" jdbcType="VARCHAR"/>
<result property="create_user_id" column="create_user_id" jdbcType="VARCHAR"/>
<result property="create_time" column="create_time" jdbcType="TIMESTAMP"/>
<result property="modify_time" column="modify_time" jdbcType="TIMESTAMP"/>
<result property="modify_user_id" column="modify_user_id" jdbcType="VARCHAR"/>
<result property="org_id" column="org_id" jdbcType="VARCHAR"/>
<result property="companyId" column="company_id" jdbcType="VARCHAR"/>
<result property="sts" column="sts" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询的字段-->
<sql id = "ExcelTemplateConfigDetailEntity_Base_Column_List">
field_name
,field_code
,field_type
,dictionary_detail_id
,show_name
,template_sort
,template_switch
,sorts
,id
,create_user_id
,create_time
,modify_time
,modify_user_id
,org_id
,company_id
,sts
</sql>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-ExcelTemplateConfigDetailEntity-result" parameterType = "com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity">
select
<include refid="ExcelTemplateConfigDetailEntity_Base_Column_List" />
from excel_template_config_detail
<trim prefix="where" prefixOverrides="and">
<if test="fieldName != null and fieldName != ''"> and field_name = #{fieldName} </if>
<if test="fieldCode != null and fieldCode != ''"> and field_code = #{fieldCode} </if>
<if test="fieldType != null and fieldType != ''"> and field_type = #{fieldType} </if>
<if test="dictionaryDetailId != null and dictionaryDetailId != ''"> and dictionary_detail_id = #{dictionaryDetailId} </if>
<if test="showName != null and showName != ''"> and show_name = #{showName} </if>
<if test="templateSort != null"> and template_sort = #{templateSort} </if>
<if test="templateSwitch != null and templateSwitch != ''"> and template_switch = #{templateSwitch} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id = #{create_user_id} </if>
<if test="create_time != null"> and create_time = #{create_time} </if>
<if test="modify_time != null"> and modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> and org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!-- 查询符合条件的数量 -->
<select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity">
select count(1) from excel_template_config_detail
<trim prefix="where" prefixOverrides="and">
<if test="fieldName != null and fieldName != ''"> and field_name = #{fieldName} </if>
<if test="fieldCode != null and fieldCode != ''"> and field_code = #{fieldCode} </if>
<if test="fieldType != null and fieldType != ''"> and field_type = #{fieldType} </if>
<if test="dictionaryDetailId != null and dictionaryDetailId != ''"> and dictionary_detail_id = #{dictionaryDetailId} </if>
<if test="showName != null and showName != ''"> and show_name = #{showName} </if>
<if test="templateSort != null"> and template_sort = #{templateSort} </if>
<if test="templateSwitch != null and templateSwitch != ''"> and template_switch = #{templateSwitch} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id = #{create_user_id} </if>
<if test="create_time != null"> and create_time = #{create_time} </if>
<if test="modify_time != null"> and modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> and org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null "> order by ${sort} ${order}</if>
</select>
<!-- 分页查询列表 采用like格式 -->
<select id="entity_list_like" resultMap="get-ExcelTemplateConfigDetailEntity-result" parameterType = "com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity">
select
<include refid="ExcelTemplateConfigDetailEntity_Base_Column_List" />
from excel_template_config_detail
<trim prefix="where" prefixOverrides="and">
<if test="fieldName != null and fieldName != ''"> and field_name like concat('%',#{fieldName},'%') </if>
<if test="fieldCode != null and fieldCode != ''"> and field_code like concat('%',#{fieldCode},'%') </if>
<if test="fieldType != null and fieldType != ''"> and field_type like concat('%',#{fieldType},'%') </if>
<if test="dictionaryDetailId != null and dictionaryDetailId != ''"> and dictionary_detail_id like concat('%',#{dictionaryDetailId},'%') </if>
<if test="showName != null and showName != ''"> and show_name like concat('%',#{showName},'%') </if>
<if test="templateSort != null"> and template_sort like concat('%',#{templateSort},'%') </if>
<if test="templateSwitch != null and templateSwitch != ''"> and template_switch like concat('%',#{templateSwitch},'%') </if>
<if test="sorts != null"> and sorts like concat('%',#{sorts},'%') </if>
<if test="id != null and id != ''"> and id like concat('%',#{id},'%') </if>
<if test="create_user_id != null and create_user_id != ''"> and create_user_id like concat('%',#{create_user_id},'%') </if>
<if test="create_time != null"> and create_time like concat('%',#{create_time},'%') </if>
<if test="modify_time != null"> and modify_time like concat('%',#{modify_time},'%') </if>
<if test="modify_user_id != null and modify_user_id != ''"> and modify_user_id like concat('%',#{modify_user_id},'%') </if>
<if test="org_id != null and org_id != ''"> and org_id like concat('%',#{org_id},'%') </if>
<if test="companyId != null and companyId != ''"> and company_id like concat('%',#{companyId},'%') </if>
<if test="sts != null and sts != ''"> and sts like concat('%',#{sts},'%') </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!-- 查询列表 字段采用or格式 -->
<select id="ExcelTemplateConfigDetailentity_list_or" resultMap="get-ExcelTemplateConfigDetailEntity-result" parameterType = "com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity">
select
<include refid="ExcelTemplateConfigDetailEntity_Base_Column_List" />
from excel_template_config_detail
<trim prefix="where" prefixOverrides="and">
<if test="fieldName != null and fieldName != ''"> or field_name = #{fieldName} </if>
<if test="fieldCode != null and fieldCode != ''"> or field_code = #{fieldCode} </if>
<if test="fieldType != null and fieldType != ''"> or field_type = #{fieldType} </if>
<if test="dictionaryDetailId != null and dictionaryDetailId != ''"> or dictionary_detail_id = #{dictionaryDetailId} </if>
<if test="showName != null and showName != ''"> or show_name = #{showName} </if>
<if test="templateSort != null"> or template_sort = #{templateSort} </if>
<if test="templateSwitch != null and templateSwitch != ''"> or template_switch = #{templateSwitch} </if>
<if test="sorts != null"> or sorts = #{sorts} </if>
<if test="id != null and id != ''"> or id = #{id} </if>
<if test="create_user_id != null and create_user_id != ''"> or create_user_id = #{create_user_id} </if>
<if test="create_time != null"> or create_time = #{create_time} </if>
<if test="modify_time != null"> or modify_time = #{modify_time} </if>
<if test="modify_user_id != null and modify_user_id != ''"> or modify_user_id = #{modify_user_id} </if>
<if test="org_id != null and org_id != ''"> or org_id = #{org_id} </if>
<if test="companyId != null and companyId != ''"> or company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> or sts = #{sts} </if>
and sts='Y'
</trim>
<if test=" sort == null or sort == ''.toString() "> order by sorts asc</if>
<if test=" sort !='' and sort!=null and order !='' and order!=null ">order by ${sort} ${order}</if>
</select>
<!--新增所有列-->
<insert id="entity_insert" parameterType = "com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template_config_detail(
<trim suffix="" suffixOverrides=",">
<if test="fieldName != null and fieldName != ''"> field_name , </if>
<if test="fieldCode != null and fieldCode != ''"> field_code , </if>
<if test="fieldType != null and fieldType != ''"> field_type , </if>
<if test="dictionaryDetailId != null and dictionaryDetailId != ''"> dictionary_detail_id , </if>
<if test="showName != null and showName != ''"> show_name , </if>
<if test="templateSort != null"> template_sort , </if>
<if test="templateSwitch != null and templateSwitch != ''"> template_switch , </if>
<if test="sorts != null"> sorts , </if>
<if test="id != null and id != ''"> id , </if>
<if test="create_user_id != null and create_user_id != ''"> create_user_id , </if>
<if test="create_time != null"> create_time , </if>
<if test="modify_time != null"> modify_time , </if>
<if test="modify_user_id != null and modify_user_id != ''"> modify_user_id , </if>
<if test="org_id != null and org_id != ''"> org_id , </if>
<if test="companyId != null and companyId != ''"> company_id , </if>
<if test="sts != null and sts != ''"> sts , </if>
<if test="sorts == null ">sorts,</if>
<if test="sts == null ">sts,</if>
</trim>
)values(
<trim suffix="" suffixOverrides=",">
<if test="fieldName != null and fieldName != ''"> #{fieldName} ,</if>
<if test="fieldCode != null and fieldCode != ''"> #{fieldCode} ,</if>
<if test="fieldType != null and fieldType != ''"> #{fieldType} ,</if>
<if test="dictionaryDetailId != null and dictionaryDetailId != ''"> #{dictionaryDetailId} ,</if>
<if test="showName != null and showName != ''"> #{showName} ,</if>
<if test="templateSort != null"> #{templateSort} ,</if>
<if test="templateSwitch != null and templateSwitch != ''"> #{templateSwitch} ,</if>
<if test="sorts != null"> #{sorts} ,</if>
<if test="id != null and id != ''"> #{id} ,</if>
<if test="create_user_id != null and create_user_id != ''"> #{create_user_id} ,</if>
<if test="create_time != null"> #{create_time} ,</if>
<if test="modify_time != null"> #{modify_time} ,</if>
<if test="modify_user_id != null and modify_user_id != ''"> #{modify_user_id} ,</if>
<if test="org_id != null and org_id != ''"> #{org_id} ,</if>
<if test="companyId != null and companyId != ''"> #{companyId} ,</if>
<if test="sts != null and sts != ''"> #{sts} ,</if>
<if test="sorts == null ">(select (max(IFNULL( a.sorts, 0 )) + 1) as sort from excel_template_config_detail a WHERE a.sts = 'Y' ),</if>
<if test="sts == null ">'Y',</if>
</trim>
)
</insert>
<!-- 批量新增 -->
<insert id="entityInsertBatch" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template_config_detail(field_name, field_code, field_type, dictionary_detail_id, show_name, template_sort, template_switch, create_user_id, create_time, modify_time, modify_user_id, org_id, company_id, sts, sts)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.fieldName},#{entity.fieldCode},#{entity.fieldType},#{entity.dictionaryDetailId},#{entity.showName},#{entity.templateSort},#{entity.templateSwitch},#{entity.create_user_id},#{entity.create_time},#{entity.modify_time},#{entity.modify_user_id},#{entity.org_id},#{entity.companyId},#{entity.sts}, 'Y')
</foreach>
</insert>
<!-- 批量新增或者修改-->
<insert id="entityInsertOrUpdateBatch" keyProperty="sorts" useGeneratedKeys="true">
insert into excel_template_config_detail(field_name, field_code, field_type, dictionary_detail_id, show_name, template_sort, template_switch, create_user_id, create_time, modify_time, modify_user_id, org_id, company_id, sts)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.fieldName},#{entity.fieldCode},#{entity.fieldType},#{entity.dictionaryDetailId},#{entity.showName},#{entity.templateSort},#{entity.templateSwitch},#{entity.create_user_id},#{entity.create_time},#{entity.modify_time},#{entity.modify_user_id},#{entity.org_id},#{entity.companyId},#{entity.sts})
</foreach>
on duplicate key update
field_name = values(field_name),
field_code = values(field_code),
field_type = values(field_type),
dictionary_detail_id = values(dictionary_detail_id),
show_name = values(show_name),
template_sort = values(template_sort),
template_switch = values(template_switch),
create_user_id = values(create_user_id),
create_time = values(create_time),
modify_time = values(modify_time),
modify_user_id = values(modify_user_id),
org_id = values(org_id),
company_id = values(company_id),
sts = values(sts)</insert>
<!--通过主键修改方法-->
<update id="entity_update" parameterType = "com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity" >
update excel_template_config_detail set
<trim suffix="" suffixOverrides=",">
<if test="fieldName != null and fieldName != ''"> field_name = #{fieldName},</if>
<if test="fieldCode != null and fieldCode != ''"> field_code = #{fieldCode},</if>
<if test="fieldType != null and fieldType != ''"> field_type = #{fieldType},</if>
<if test="dictionaryDetailId != null and dictionaryDetailId != ''"> dictionary_detail_id = #{dictionaryDetailId},</if>
<if test="showName != null and showName != ''"> show_name = #{showName},</if>
<if test="templateSort != null"> template_sort = #{templateSort},</if>
<if test="templateSwitch != null and templateSwitch != ''"> template_switch = #{templateSwitch},</if>
<if test="create_user_id != null and create_user_id != ''"> create_user_id = #{create_user_id},</if>
<if test="create_time != null"> create_time = #{create_time},</if>
<if test="modify_time != null"> modify_time = #{modify_time},</if>
<if test="modify_user_id != null and modify_user_id != ''"> modify_user_id = #{modify_user_id},</if>
<if test="org_id != null and org_id != ''"> org_id = #{org_id},</if>
<if test="companyId != null and companyId != ''"> company_id = #{companyId},</if>
<if test="sts != null and sts != ''"> sts = #{sts},</if>
</trim>
where sorts = #{sorts}
</update>
<!-- 逻辑删除 -->
<update id="entity_logicDelete" parameterType = "com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity" >
update excel_template_config_detail set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id}
where sorts = #{sorts}
</update>
<!-- 多条件逻辑删除 -->
<update id="entity_logicDelete_Multi_Condition" parameterType = "com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity" >
update excel_template_config_detail set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id}
<trim prefix="where" prefixOverrides="and">
<if test="fieldName != null and fieldName != ''"> and field_name = #{fieldName} </if>
<if test="fieldCode != null and fieldCode != ''"> and field_code = #{fieldCode} </if>
<if test="fieldType != null and fieldType != ''"> and field_type = #{fieldType} </if>
<if test="dictionaryDetailId != null and dictionaryDetailId != ''"> and dictionary_detail_id = #{dictionaryDetailId} </if>
<if test="showName != null and showName != ''"> and show_name = #{showName} </if>
<if test="templateSort != null"> and template_sort = #{templateSort} </if>
<if test="templateSwitch != null and templateSwitch != ''"> and template_switch = #{templateSwitch} </if>
<if test="sorts != null"> and sorts = #{sorts} </if>
<if test="id != null and id != ''"> and id = #{id} </if>
<if test="companyId != null and companyId != ''"> and company_id = #{companyId} </if>
<if test="sts != null and sts != ''"> and sts = #{sts} </if>
and sts='Y'
</trim>
</update>
<!--通过主键删除-->
<delete id="entity_delete">
delete from excel_template_config_detail where sorts = #{sorts}
</delete>
</mapper>

View File

@ -0,0 +1,12 @@
package com.hzya.frame.excel.templateConfigDetial.service;
import com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity;
import com.hzya.frame.basedao.service.IBaseService;
/**
* excel模版配置明细表(ExcelTemplateConfigDetail)表服务接口
*
* @author makejava
* @since 2024-08-13 08:39:02
*/
public interface IExcelTemplateConfigDetailService extends IBaseService<ExcelTemplateConfigDetailEntity, String>{
}

View File

@ -0,0 +1,26 @@
package com.hzya.frame.excel.templateConfigDetial.service.impl;
import com.hzya.frame.excel.templateConfigDetial.entity.ExcelTemplateConfigDetailEntity;
import com.hzya.frame.excel.templateConfigDetial.dao.IExcelTemplateConfigDetailDao;
import com.hzya.frame.excel.templateConfigDetial.service.IExcelTemplateConfigDetailService;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService;
/**
* excel模版配置明细表(ExcelTemplateConfigDetail)表服务实现类
*
* @author makejava
* @since 2024-08-13 08:39:02
*/
@Service(value = "excelTemplateConfigDetailService")
public class ExcelTemplateConfigDetailServiceImpl extends BaseService<ExcelTemplateConfigDetailEntity, String> implements IExcelTemplateConfigDetailService {
private IExcelTemplateConfigDetailDao excelTemplateConfigDetailDao;
@Autowired
public void setExcelTemplateConfigDetailDao(IExcelTemplateConfigDetailDao dao) {
this.excelTemplateConfigDetailDao = dao;
this.dao = dao;
}
}

View File

@ -0,0 +1,19 @@
package com.hzya.frame.grpU8.acctVouchInfo.dao;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntityVo;
import java.util.List;
/**
* 子表(acct_vouch_info: table)表数据库访问层
*
* @author makejava
* @since 2024-07-09 11:25:15
*/
public interface IAcctVouchInfoDao extends IBaseDao<AcctVouchInfoEntity, String> {
List<AcctVouchInfoEntityVo> queryData(AcctVouchInfoEntity entity);
}

View File

@ -0,0 +1,31 @@
package com.hzya.frame.grpU8.acctVouchInfo.dao.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.mdm.mdmModule.entity.MdmModuleEntity;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity;
import com.hzya.frame.grpU8.acctVouchInfo.dao.IAcctVouchInfoDao;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntityVo;
import org.springframework.stereotype.Repository;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import java.util.List;
/**
* 子表(AcctVouchInfo)表数据库访问层
*
* @author makejava
* @since 2024-07-09 11:25:15
*/
@Repository(value = "AcctVouchInfoDaoImpl")
public class AcctVouchInfoDaoImpl extends MybatisGenericDao<AcctVouchInfoEntity, String> implements IAcctVouchInfoDao {
@DS("#entity.dataSourceCode")
@Override
public List<AcctVouchInfoEntityVo> queryData(AcctVouchInfoEntity entity) {
List<AcctVouchInfoEntityVo> o = (List<AcctVouchInfoEntityVo>) super.selectList(getSqlIdPrifx() + "queryData", entity);
return o;
}
}

View File

@ -0,0 +1,194 @@
package com.hzya.frame.grpU8.acctVouchInfo.entity;
import java.util.Date;
import com.hzya.frame.web.entity.BaseEntity;
/**
* 子表(AcctVouchInfo)实体类
*
* @author makejava
* @since 2024-07-09 11:25:15
*/
public class AcctVouchInfoEntity extends BaseEntity {
/** 年度 */
private String acct_year;
/** 月份 */
private String acct_month;
/** 科室编码 */
private String dept_code;
/** 科室名称 */
private String dept_name;
/** 会计科目编码 */
private String acct_subj_code;
/** 会计科目名称 */
private String acct_subj_name;
/** 辅助核算项编码 */
private String check_type_code;
/** 辅助核算项名称 */
private String check_type_name;
/** 借贷方向 */
private String direction;
/** 金额 */
private Double amount;
/** 资金来源编码 */
private String fund_source_code;
/** 凭证号 */
private String vouch_no;
/** 摘要 */
private String summary;
/** 记账人 */
private String bookkeeper;
/** 单位编码 */
private String org_code;
/** 单位名称 */
private String org_name;
/** 院区编码 */
private String branch_code;
/** 院区名称 */
private String branch_name;
public String getAcct_year() {
return acct_year;
}
public void setAcct_year(String acct_year) {
this.acct_year = acct_year;
}
public String getAcct_month() {
return acct_month;
}
public void setAcct_month(String acct_month) {
this.acct_month = acct_month;
}
public String getDept_code() {
return dept_code;
}
public void setDept_code(String dept_code) {
this.dept_code = dept_code;
}
public String getDept_name() {
return dept_name;
}
public void setDept_name(String dept_name) {
this.dept_name = dept_name;
}
public String getAcct_subj_code() {
return acct_subj_code;
}
public void setAcct_subj_code(String acct_subj_code) {
this.acct_subj_code = acct_subj_code;
}
public String getAcct_subj_name() {
return acct_subj_name;
}
public void setAcct_subj_name(String acct_subj_name) {
this.acct_subj_name = acct_subj_name;
}
public String getCheck_type_code() {
return check_type_code;
}
public void setCheck_type_code(String check_type_code) {
this.check_type_code = check_type_code;
}
public String getCheck_type_name() {
return check_type_name;
}
public void setCheck_type_name(String check_type_name) {
this.check_type_name = check_type_name;
}
public String getDirection() {
return direction;
}
public void setDirection(String direction) {
this.direction = direction;
}
public Double getAmount() {
return amount;
}
public void setAmount(Double amount) {
this.amount = amount;
}
public String getFund_source_code() {
return fund_source_code;
}
public void setFund_source_code(String fund_source_code) {
this.fund_source_code = fund_source_code;
}
public String getVouch_no() {
return vouch_no;
}
public void setVouch_no(String vouch_no) {
this.vouch_no = vouch_no;
}
public String getSummary() {
return summary;
}
public void setSummary(String summary) {
this.summary = summary;
}
public String getBookkeeper() {
return bookkeeper;
}
public void setBookkeeper(String bookkeeper) {
this.bookkeeper = bookkeeper;
}
public String getOrg_code() {
return org_code;
}
public void setOrg_code(String org_code) {
this.org_code = org_code;
}
public String getOrg_name() {
return org_name;
}
public void setOrg_name(String org_name) {
this.org_name = org_name;
}
public String getBranch_code() {
return branch_code;
}
public void setBranch_code(String branch_code) {
this.branch_code = branch_code;
}
public String getBranch_name() {
return branch_name;
}
public void setBranch_name(String branch_name) {
this.branch_name = branch_name;
}
}

View File

@ -0,0 +1,198 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.grpU8.acctVouchInfo.dao.impl.AcctVouchInfoDaoImpl">
<resultMap id="get-AcctVouchInfoEntity-result" type="com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity" >
<result property="acct_year" column="acct_year" jdbcType="VARCHAR"/>
<result property="acct_month" column="acct_month" jdbcType="VARCHAR"/>
<result property="dept_code" column="dept_code" jdbcType="VARCHAR"/>
<result property="dept_name" column="dept_name" jdbcType="VARCHAR"/>
<result property="acct_subj_code" column="acct_subj_code" jdbcType="VARCHAR"/>
<result property="acct_subj_name" column="acct_subj_name" jdbcType="VARCHAR"/>
<result property="check_type_code" column="check_type_code" jdbcType="VARCHAR"/>
<result property="check_type_name" column="check_type_name" jdbcType="VARCHAR"/>
<result property="direction" column="direction" jdbcType="VARCHAR"/>
<result property="amount" column="amount" jdbcType="NUMERIC"/>
<result property="fund_source_code" column="fund_source_code" jdbcType="VARCHAR"/>
<result property="vouch_no" column="vouch_no" jdbcType="VARCHAR"/>
<result property="summary" column="summary" jdbcType="VARCHAR"/>
<result property="bookkeeper" column="bookkeeper" jdbcType="VARCHAR"/>
<result property="org_code" column="org_code" jdbcType="VARCHAR"/>
<result property="org_name" column="org_name" jdbcType="VARCHAR"/>
<result property="branch_code" column="branch_code" jdbcType="VARCHAR"/>
<result property="branch_name" column="branch_name" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询的字段-->
<sql id = "AcctVouchInfoEntity_Base_Column_List">
acct_year
,acct_month
,dept_code
,dept_name
,acct_subj_code
,acct_subj_name
,check_type_code
,check_type_name
,direction
,amount
,fund_source_code
,vouch_no
,summary
,bookkeeper
,org_code
,org_name
,branch_code
,branch_name
</sql>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-AcctVouchInfoEntity-result" parameterType = "com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity">
select
<include refid="AcctVouchInfoEntity_Base_Column_List" />
from acct_vouch_info
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> and acct_year = #{acct_year} </if>
<if test="acct_month != null and acct_month != ''"> and acct_month = #{acct_month} </if>
<if test="dept_code != null and dept_code != ''"> and dept_code = #{dept_code} </if>
<if test="dept_name != null and dept_name != ''"> and dept_name = #{dept_name} </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> and acct_subj_code = #{acct_subj_code} </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> and acct_subj_name = #{acct_subj_name} </if>
<if test="check_type_code != null and check_type_code != ''"> and check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name = #{check_type_name} </if>
<if test="direction != null and direction != ''"> and direction = #{direction} </if>
<if test="amount != null"> and amount = #{amount} </if>
<if test="fund_source_code != null and fund_source_code != ''"> and fund_source_code = #{fund_source_code} </if>
<if test="vouch_no != null"> and vouch_no = #{vouch_no} </if>
<if test="summary != null and summary != ''"> and summary = #{summary} </if>
<if test="bookkeeper != null and bookkeeper != ''"> and bookkeeper = #{bookkeeper} </if>
<if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> and org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> and branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> and branch_name = #{branch_name} </if>
</trim>
</select>
<!-- 查询符合条件的数量 -->
<select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity">
select count(1) from acct_vouch_info
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> and acct_year = #{acct_year} </if>
<if test="acct_month != null and acct_month != ''"> and acct_month = #{acct_month} </if>
<if test="dept_code != null and dept_code != ''"> and dept_code = #{dept_code} </if>
<if test="dept_name != null and dept_name != ''"> and dept_name = #{dept_name} </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> and acct_subj_code = #{acct_subj_code} </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> and acct_subj_name = #{acct_subj_name} </if>
<if test="check_type_code != null and check_type_code != ''"> and check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name = #{check_type_name} </if>
<if test="direction != null and direction != ''"> and direction = #{direction} </if>
<if test="amount != null"> and amount = #{amount} </if>
<if test="fund_source_code != null and fund_source_code != ''"> and fund_source_code = #{fund_source_code} </if>
<if test="vouch_no != null"> and vouch_no = #{vouch_no} </if>
<if test="summary != null and summary != ''"> and summary = #{summary} </if>
<if test="bookkeeper != null and bookkeeper != ''"> and bookkeeper = #{bookkeeper} </if>
<if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> and org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> and branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> and branch_name = #{branch_name} </if>
</trim>
</select>
<!-- 分页查询列表 采用like格式 -->
<select id="entity_list_like" resultMap="get-AcctVouchInfoEntity-result" parameterType = "com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity">
select
<include refid="AcctVouchInfoEntity_Base_Column_List" />
from acct_vouch_info
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> and acct_year like concat('%',#{acct_year},'%') </if>
<if test="acct_month != null and acct_month != ''"> and acct_month like concat('%',#{acct_month},'%') </if>
<if test="dept_code != null and dept_code != ''"> and dept_code like concat('%',#{dept_code},'%') </if>
<if test="dept_name != null and dept_name != ''"> and dept_name like concat('%',#{dept_name},'%') </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> and acct_subj_code like concat('%',#{acct_subj_code},'%') </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> and acct_subj_name like concat('%',#{acct_subj_name},'%') </if>
<if test="check_type_code != null and check_type_code != ''"> and check_type_code like concat('%',#{check_type_code},'%') </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name like concat('%',#{check_type_name},'%') </if>
<if test="direction != null and direction != ''"> and direction like concat('%',#{direction},'%') </if>
<if test="amount != null"> and amount like concat('%',#{amount},'%') </if>
<if test="fund_source_code != null and fund_source_code != ''"> and fund_source_code like concat('%',#{fund_source_code},'%') </if>
<if test="vouch_no != null"> and vouch_no like concat('%',#{vouch_no},'%') </if>
<if test="summary != null and summary != ''"> and summary like concat('%',#{summary},'%') </if>
<if test="bookkeeper != null and bookkeeper != ''"> and bookkeeper like concat('%',#{bookkeeper},'%') </if>
<if test="org_code != null and org_code != ''"> and org_code like concat('%',#{org_code},'%') </if>
<if test="org_name != null and org_name != ''"> and org_name like concat('%',#{org_name},'%') </if>
<if test="branch_code != null and branch_code != ''"> and branch_code like concat('%',#{branch_code},'%') </if>
<if test="branch_name != null and branch_name != ''"> and branch_name like concat('%',#{branch_name},'%') </if>
</trim>
</select>
<!-- 查询列表 字段采用or格式 -->
<select id="AcctVouchInfoentity_list_or" resultMap="get-AcctVouchInfoEntity-result" parameterType = "com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity">
select
<include refid="AcctVouchInfoEntity_Base_Column_List" />
from acct_vouch_info
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> or acct_year = #{acct_year} </if>
<if test="acct_month != null and acct_month != ''"> or acct_month = #{acct_month} </if>
<if test="dept_code != null and dept_code != ''"> or dept_code = #{dept_code} </if>
<if test="dept_name != null and dept_name != ''"> or dept_name = #{dept_name} </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> or acct_subj_code = #{acct_subj_code} </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> or acct_subj_name = #{acct_subj_name} </if>
<if test="check_type_code != null and check_type_code != ''"> or check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> or check_type_name = #{check_type_name} </if>
<if test="direction != null and direction != ''"> or direction = #{direction} </if>
<if test="amount != null"> or amount = #{amount} </if>
<if test="fund_source_code != null and fund_source_code != ''"> or fund_source_code = #{fund_source_code} </if>
<if test="vouch_no != null"> or vouch_no = #{vouch_no} </if>
<if test="summary != null and summary != ''"> or summary = #{summary} </if>
<if test="bookkeeper != null and bookkeeper != ''"> or bookkeeper = #{bookkeeper} </if>
<if test="org_code != null and org_code != ''"> or org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> or org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> or branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> or branch_name = #{branch_name} </if>
</trim>
</select>
<resultMap id="get-AcctVouchInfoEntityVo-result" type="com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntityVo" >
<result property="acct_year" column="acct_year" jdbcType="VARCHAR"/>
<result property="acct_month" column="acct_month" jdbcType="VARCHAR"/>
<result property="dept_code" column="dept_code" jdbcType="VARCHAR"/>
<result property="dept_name" column="dept_name" jdbcType="VARCHAR"/>
<result property="acct_subj_code" column="acct_subj_code" jdbcType="VARCHAR"/>
<result property="acct_subj_name" column="acct_subj_name" jdbcType="VARCHAR"/>
<result property="check_type_code" column="check_type_code" jdbcType="VARCHAR"/>
<result property="check_type_name" column="check_type_name" jdbcType="VARCHAR"/>
<result property="direction" column="direction" jdbcType="VARCHAR"/>
<result property="amount" column="amount" jdbcType="NUMERIC"/>
<result property="fund_source_code" column="fund_source_code" jdbcType="VARCHAR"/>
<result property="vouch_no" column="vouch_no" jdbcType="VARCHAR"/>
<result property="summary" column="summary" jdbcType="VARCHAR"/>
<result property="bookkeeper" column="bookkeeper" jdbcType="VARCHAR"/>
<result property="org_code" column="org_code" jdbcType="VARCHAR"/>
<result property="org_name" column="org_name" jdbcType="VARCHAR"/>
<result property="branch_code" column="branch_code" jdbcType="VARCHAR"/>
<result property="branch_name" column="branch_name" jdbcType="VARCHAR"/>
</resultMap>
<select id="queryData" resultMap="get-AcctVouchInfoEntityVo-result" parameterType = "com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity">
select
<include refid="AcctVouchInfoEntity_Base_Column_List" />
from acct_vouch_info
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> and acct_year = '${acct_year}' </if>
<if test="acct_month != null and acct_month != ''"> and acct_month = '${acct_month}' </if>
<if test="dept_code != null and dept_code != ''"> and dept_code like '%${dept_code}%' </if>
<if test="dept_name != null and dept_name != ''"> and dept_name like '%${dept_name}%' </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> and acct_subj_code like '%${acct_subj_code}%' </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> and acct_subj_name like '%${acct_subj_name}%' </if>
<if test="check_type_code != null and check_type_code != ''"> and check_type_code like '%${check_type_code}%' </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name like '%${check_type_name}%' </if>
<if test="direction != null and direction != ''"> and direction like '%${direction}%' </if>
<if test="amount != null"> and amount like '%${amount}%' </if>
<if test="fund_source_code != null and fund_source_code != ''"> and fund_source_code like '%${fund_source_code}%' </if>
<if test="vouch_no != null"> and vouch_no like '%${vouch_no}%' </if>
<if test="summary != null and summary != ''"> and summary like '%${summary}%' </if>
<if test="bookkeeper != null and bookkeeper != ''"> and bookkeeper like '%${bookkeeper}%' </if>
<if test="org_code != null and org_code != ''"> and org_code like '%${org_code}%' </if>
<if test="org_name != null and org_name != ''"> and org_name like '%${org_name}%' </if>
<if test="branch_code != null and branch_code != ''"> and branch_code like '%${branch_code}%' </if>
<if test="branch_name != null and branch_name != ''"> and branch_name like '%${branch_name}%' </if>
</trim>
</select>
</mapper>

View File

@ -0,0 +1,194 @@
package com.hzya.frame.grpU8.acctVouchInfo.entity;
import com.hzya.frame.web.entity.BaseEntity;
/**
* 子表(AcctVouchInfo)实体类
*
* @author makejava
* @since 2024-07-09 11:25:15
*/
public class AcctVouchInfoEntityVo {
/** 年度 */
private String acct_year;
/** 月份 */
private String acct_month;
/** 科室编码 */
private String dept_code;
/** 科室名称 */
private String dept_name;
/** 会计科目编码 */
private String acct_subj_code;
/** 会计科目名称 */
private String acct_subj_name;
/** 辅助核算项编码 */
private String check_type_code;
/** 辅助核算项名称 */
private String check_type_name;
/** 借贷方向 */
private String direction;
/** 金额 */
private Double amount;
/** 资金来源编码 */
private String fund_source_code;
/** 凭证号 */
private String vouch_no;
/** 摘要 */
private String summary;
/** 记账人 */
private String bookkeeper;
/** 单位编码 */
private String org_code;
/** 单位名称 */
private String org_name;
/** 院区编码 */
private String branch_code;
/** 院区名称 */
private String branch_name;
public String getAcct_year() {
return acct_year;
}
public void setAcct_year(String acct_year) {
this.acct_year = acct_year;
}
public String getAcct_month() {
return acct_month;
}
public void setAcct_month(String acct_month) {
this.acct_month = acct_month;
}
public String getDept_code() {
return dept_code;
}
public void setDept_code(String dept_code) {
this.dept_code = dept_code;
}
public String getDept_name() {
return dept_name;
}
public void setDept_name(String dept_name) {
this.dept_name = dept_name;
}
public String getAcct_subj_code() {
return acct_subj_code;
}
public void setAcct_subj_code(String acct_subj_code) {
this.acct_subj_code = acct_subj_code;
}
public String getAcct_subj_name() {
return acct_subj_name;
}
public void setAcct_subj_name(String acct_subj_name) {
this.acct_subj_name = acct_subj_name;
}
public String getCheck_type_code() {
return check_type_code;
}
public void setCheck_type_code(String check_type_code) {
this.check_type_code = check_type_code;
}
public String getCheck_type_name() {
return check_type_name;
}
public void setCheck_type_name(String check_type_name) {
this.check_type_name = check_type_name;
}
public String getDirection() {
return direction;
}
public void setDirection(String direction) {
this.direction = direction;
}
public Double getAmount() {
return amount;
}
public void setAmount(Double amount) {
this.amount = amount;
}
public String getFund_source_code() {
return fund_source_code;
}
public void setFund_source_code(String fund_source_code) {
this.fund_source_code = fund_source_code;
}
public String getVouch_no() {
return vouch_no;
}
public void setVouch_no(String vouch_no) {
this.vouch_no = vouch_no;
}
public String getSummary() {
return summary;
}
public void setSummary(String summary) {
this.summary = summary;
}
public String getBookkeeper() {
return bookkeeper;
}
public void setBookkeeper(String bookkeeper) {
this.bookkeeper = bookkeeper;
}
public String getOrg_code() {
return org_code;
}
public void setOrg_code(String org_code) {
this.org_code = org_code;
}
public String getOrg_name() {
return org_name;
}
public void setOrg_name(String org_name) {
this.org_name = org_name;
}
public String getBranch_code() {
return branch_code;
}
public void setBranch_code(String branch_code) {
this.branch_code = branch_code;
}
public String getBranch_name() {
return branch_name;
}
public void setBranch_name(String branch_name) {
this.branch_name = branch_name;
}
}

View File

@ -0,0 +1,32 @@
package com.hzya.frame.grpU8.acctVouchInfo.service;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.sysnew.application.entity.SysExtensionApiEntity;
import com.hzya.frame.web.entity.JsonResultEntity;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity;
import com.hzya.frame.basedao.service.IBaseService;
/**
* 子表(AcctVouchInfo)表服务接口
*
* @author makejava
* @since 2024-07-09 11:25:15
*/
public interface IAcctVouchInfoService extends IBaseService<AcctVouchInfoEntity, String>{
/**
* @param jsonObject
* @return com.hzya.frame.web.entity.JsonResultEntity
* @Author lvleigang
* @Description 数据表
* @Date 11:52 上午 2024/3/27
**/
Object queryData(JSONObject jsonObject);
/**
* @param jsonObject
* @return com.hzya.frame.web.entity.JsonResultEntity
* @Author lvleigang
* @Description 数据表
* @Date 11:52 上午 2024/3/27
**/
SysExtensionApiEntity addDataSourceCode(SysExtensionApiEntity jsonObject);
}

View File

@ -0,0 +1,105 @@
package com.hzya.frame.grpU8.acctVouchInfo.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.hzya.frame.sysnew.application.database.dao.ISysApplicationDatabaseDao;
import com.hzya.frame.sysnew.application.database.entity.SysApplicationDatabaseEntity;
import com.hzya.frame.sysnew.application.entity.SysApplicationEntity;
import com.hzya.frame.sysnew.application.entity.SysExtensionApiEntity;
import com.hzya.frame.sysnew.user.entity.SysUserEntity;
import com.hzya.frame.util.bipV3.SHA256Util;
import com.hzya.frame.web.entity.BaseResult;
import com.hzya.frame.web.entity.JsonResultEntity;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity;
import com.hzya.frame.grpU8.acctVouchInfo.dao.IAcctVouchInfoDao;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntityVo;
import com.hzya.frame.grpU8.acctVouchInfo.service.IAcctVouchInfoService;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService;
import java.util.List;
import java.util.Map;
/**
* 子表(AcctVouchInfo)表服务实现类
*
* @author makejava
* @since 2024-07-09 11:25:15
*/
@Service(value = "acctVouchInfoService")
public class AcctVouchInfoServiceImpl extends BaseService<AcctVouchInfoEntity, String> implements IAcctVouchInfoService {
private IAcctVouchInfoDao acctVouchInfoDao;
@Resource
private ISysApplicationDatabaseDao sysApplicationDatabaseDao;
@Autowired
public void setAcctVouchInfoDao(IAcctVouchInfoDao dao) {
this.acctVouchInfoDao = dao;
this.dao = dao;
}
/**
* @param jsonObject
* @return com.hzya.frame.web.entity.JsonResultEntity
* @Author lvleigang
* @Description 数据表
* @Date 11:52 上午 2024/3/27
**/
@Override
public Object queryData(JSONObject jsonObject) {
AcctVouchInfoEntity entity = getData("jsonStr", jsonObject, AcctVouchInfoEntity.class);
if(entity == null ){
entity = new AcctVouchInfoEntity();
}
//判断分页
if (entity.getPageNum() != null && entity.getPageSize() != null) {
PageHelper.startPage(entity.getPageNum(), entity.getPageSize());
List<AcctVouchInfoEntityVo> list = acctVouchInfoDao.queryData(entity);
PageInfo pageInfo = new PageInfo(list);
JSONObject object = new JSONObject();
object.put("status","success");
object.put("data",pageInfo);
return object;
}else {
List<AcctVouchInfoEntityVo> list = acctVouchInfoDao.queryData(entity);
JSONObject object = new JSONObject();
object.put("status","success");
object.put("data",list);
return object; }
}
/**
* @param entity
* @return com.hzya.frame.web.entity.JsonResultEntity
* @Author lvleigang
* @Description 数据表
* @Date 11:52 上午 2024/3/27
**/
@Override
public SysExtensionApiEntity addDataSourceCode(SysExtensionApiEntity entity) {
try {
SysApplicationEntity applicationEntity = entity.getReceiveApp();
SysApplicationDatabaseEntity sysApplicationDatabaseEntity = new SysApplicationDatabaseEntity();
sysApplicationDatabaseEntity.setSts("Y");
sysApplicationDatabaseEntity.setDbStatus("1");
sysApplicationDatabaseEntity.setAppId(applicationEntity.getId());
sysApplicationDatabaseEntity.setDataSourceCode("master");
List<SysApplicationDatabaseEntity> sysDataSourceEntities = sysApplicationDatabaseDao.queryDSBase(sysApplicationDatabaseEntity);
if(sysDataSourceEntities != null && sysDataSourceEntities.size() > 0){
String parm = entity.getBodys();
JSONObject jsonObject = JSONObject.parseObject(parm);
jsonObject.put("dataSourceCode",sysDataSourceEntities.get(0).getSourceCode());
entity.setBodys(jsonObject.toJSONString());
}
} catch (Exception e) {
e.printStackTrace();
}
return entity;
}
}

View File

@ -0,0 +1,19 @@
package com.hzya.frame.grpU8.dictAcctSubj.dao;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntityVo;
import java.util.List;
/**
* 子表(dict_acct_subj: table)表数据库访问层
*
* @author makejava
* @since 2024-07-09 11:23:36
*/
public interface IDictAcctSubjDao extends IBaseDao<DictAcctSubjEntity, String> {
List<DictAcctSubjEntityVo> queryData(DictAcctSubjEntity entity);
}

View File

@ -0,0 +1,30 @@
package com.hzya.frame.grpU8.dictAcctSubj.dao.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntityVo;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity;
import com.hzya.frame.grpU8.dictAcctSubj.dao.IDictAcctSubjDao;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntityVo;
import org.springframework.stereotype.Repository;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import java.util.List;
/**
* 子表(DictAcctSubj)表数据库访问层
*
* @author makejava
* @since 2024-07-09 11:23:36
*/
@Repository(value = "DictAcctSubjDaoImpl")
public class DictAcctSubjDaoImpl extends MybatisGenericDao<DictAcctSubjEntity, String> implements IDictAcctSubjDao{
@DS("#entity.dataSourceCode")
@Override
public List<DictAcctSubjEntityVo> queryData(DictAcctSubjEntity entity) {
List<DictAcctSubjEntityVo> o = (List<DictAcctSubjEntityVo>) super.selectList(getSqlIdPrifx() + "queryData", entity);
return o;
}
}

View File

@ -0,0 +1,284 @@
package com.hzya.frame.grpU8.dictAcctSubj.entity;
import java.util.Date;
import com.hzya.frame.web.entity.BaseEntity;
/**
* 子表(DictAcctSubj)实体类
*
* @author makejava
* @since 2024-07-09 11:23:36
*/
public class DictAcctSubjEntity extends BaseEntity {
/** 年度 */
private String acct_year;
/** 会计科目编码 */
private String acct_subj_code;
/** 会计科目名称 */
private String acct_subj_name;
/** 上级编码 */
private String supper_code;
/** 科目级次 */
private String subj_level;
/** 是否末级 */
private String is_last;
/** 科目类型编码 */
private String subj_type_code;
/** 科目类型名称 */
private String subj_type_name;
/** 借贷方向 */
private String direction;
/** 是否现金 */
private String is_cash;
/** 科目性质 */
private String subj_nature_code;
/** 是否辅助核算 */
private String is_check;
/** 是否停用 */
private String is_stop;
/** 预算会计科目编码 */
private String budg_subj_code;
/** 预算会计科目名称 */
private String budg_subj_name;
/** 辅助核算项1 */
private String check_type_name1;
/** 辅助核算项2 */
private String check_type_name2;
/** 辅助核算项3 */
private String check_type_name3;
/** 辅助核算项4 */
private String check_type_name4;
/** 辅助核算项5 */
private String check_type_name5;
/** 辅助核算项6 */
private String check_type_name6;
/** 辅助核算项7 */
private String check_type_name7;
/** 辅助核算项8 */
private String check_type_name8;
/** 单位编码 */
private String org_code;
/** 单位名称 */
private String org_name;
/** 院区编码 */
private String branch_code;
/** 院区名称 */
private String branch_name;
public String getAcct_year() {
return acct_year;
}
public void setAcct_year(String acct_year) {
this.acct_year = acct_year;
}
public String getAcct_subj_code() {
return acct_subj_code;
}
public void setAcct_subj_code(String acct_subj_code) {
this.acct_subj_code = acct_subj_code;
}
public String getAcct_subj_name() {
return acct_subj_name;
}
public void setAcct_subj_name(String acct_subj_name) {
this.acct_subj_name = acct_subj_name;
}
public String getSupper_code() {
return supper_code;
}
public void setSupper_code(String supper_code) {
this.supper_code = supper_code;
}
public String getSubj_level() {
return subj_level;
}
public void setSubj_level(String subj_level) {
this.subj_level = subj_level;
}
public String getIs_last() {
return is_last;
}
public void setIs_last(String is_last) {
this.is_last = is_last;
}
public String getSubj_type_code() {
return subj_type_code;
}
public void setSubj_type_code(String subj_type_code) {
this.subj_type_code = subj_type_code;
}
public String getSubj_type_name() {
return subj_type_name;
}
public void setSubj_type_name(String subj_type_name) {
this.subj_type_name = subj_type_name;
}
public String getDirection() {
return direction;
}
public void setDirection(String direction) {
this.direction = direction;
}
public String getIs_cash() {
return is_cash;
}
public void setIs_cash(String is_cash) {
this.is_cash = is_cash;
}
public String getSubj_nature_code() {
return subj_nature_code;
}
public void setSubj_nature_code(String subj_nature_code) {
this.subj_nature_code = subj_nature_code;
}
public String getIs_check() {
return is_check;
}
public void setIs_check(String is_check) {
this.is_check = is_check;
}
public String getIs_stop() {
return is_stop;
}
public void setIs_stop(String is_stop) {
this.is_stop = is_stop;
}
public String getBudg_subj_code() {
return budg_subj_code;
}
public void setBudg_subj_code(String budg_subj_code) {
this.budg_subj_code = budg_subj_code;
}
public String getBudg_subj_name() {
return budg_subj_name;
}
public void setBudg_subj_name(String budg_subj_name) {
this.budg_subj_name = budg_subj_name;
}
public String getCheck_type_name1() {
return check_type_name1;
}
public void setCheck_type_name1(String check_type_name1) {
this.check_type_name1 = check_type_name1;
}
public String getCheck_type_name2() {
return check_type_name2;
}
public void setCheck_type_name2(String check_type_name2) {
this.check_type_name2 = check_type_name2;
}
public String getCheck_type_name3() {
return check_type_name3;
}
public void setCheck_type_name3(String check_type_name3) {
this.check_type_name3 = check_type_name3;
}
public String getCheck_type_name4() {
return check_type_name4;
}
public void setCheck_type_name4(String check_type_name4) {
this.check_type_name4 = check_type_name4;
}
public String getCheck_type_name5() {
return check_type_name5;
}
public void setCheck_type_name5(String check_type_name5) {
this.check_type_name5 = check_type_name5;
}
public String getCheck_type_name6() {
return check_type_name6;
}
public void setCheck_type_name6(String check_type_name6) {
this.check_type_name6 = check_type_name6;
}
public String getCheck_type_name7() {
return check_type_name7;
}
public void setCheck_type_name7(String check_type_name7) {
this.check_type_name7 = check_type_name7;
}
public String getCheck_type_name8() {
return check_type_name8;
}
public void setCheck_type_name8(String check_type_name8) {
this.check_type_name8 = check_type_name8;
}
public String getOrg_code() {
return org_code;
}
public void setOrg_code(String org_code) {
this.org_code = org_code;
}
public String getOrg_name() {
return org_name;
}
public void setOrg_name(String org_name) {
this.org_name = org_name;
}
public String getBranch_code() {
return branch_code;
}
public void setBranch_code(String branch_code) {
this.branch_code = branch_code;
}
public String getBranch_name() {
return branch_name;
}
public void setBranch_name(String branch_name) {
this.branch_name = branch_name;
}
}

View File

@ -0,0 +1,270 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.grpU8.dictAcctSubj.dao.impl.DictAcctSubjDaoImpl">
<resultMap id="get-DictAcctSubjEntity-result" type="com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity" >
<result property="acct_year" column="acct_year" jdbcType="VARCHAR"/>
<result property="acct_subj_code" column="acct_subj_code" jdbcType="VARCHAR"/>
<result property="acct_subj_name" column="acct_subj_name" jdbcType="VARCHAR"/>
<result property="supper_code" column="supper_code" jdbcType="VARCHAR"/>
<result property="subj_level" column="subj_level" jdbcType="VARCHAR"/>
<result property="is_last" column="is_last" jdbcType="VARCHAR"/>
<result property="subj_type_code" column="subj_type_code" jdbcType="VARCHAR"/>
<result property="subj_type_name" column="subj_type_name" jdbcType="VARCHAR"/>
<result property="direction" column="direction" jdbcType="VARCHAR"/>
<result property="is_cash" column="is_cash" jdbcType="VARCHAR"/>
<result property="subj_nature_code" column="subj_nature_code" jdbcType="VARCHAR"/>
<result property="is_check" column="is_check" jdbcType="VARCHAR"/>
<result property="is_stop" column="is_stop" jdbcType="VARCHAR"/>
<result property="budg_subj_code" column="budg_subj_code" jdbcType="VARCHAR"/>
<result property="budg_subj_name" column="budg_subj_name" jdbcType="VARCHAR"/>
<result property="check_type_name1" column="check_type_name1" jdbcType="VARCHAR"/>
<result property="check_type_name2" column="check_type_name2" jdbcType="VARCHAR"/>
<result property="check_type_name3" column="check_type_name3" jdbcType="VARCHAR"/>
<result property="check_type_name4" column="check_type_name4" jdbcType="VARCHAR"/>
<result property="check_type_name5" column="check_type_name5" jdbcType="VARCHAR"/>
<result property="check_type_name6" column="check_type_name6" jdbcType="VARCHAR"/>
<result property="check_type_name7" column="check_type_name7" jdbcType="VARCHAR"/>
<result property="check_type_name8" column="check_type_name8" jdbcType="VARCHAR"/>
<result property="org_code" column="org_code" jdbcType="VARCHAR"/>
<result property="org_name" column="org_name" jdbcType="VARCHAR"/>
<result property="branch_code" column="branch_code" jdbcType="VARCHAR"/>
<result property="branch_name" column="branch_name" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询的字段-->
<sql id = "DictAcctSubjEntity_Base_Column_List">
acct_year
,acct_subj_code
,acct_subj_name
,supper_code
,subj_level
,is_last
,subj_type_code
,subj_type_name
,direction
,is_cash
,subj_nature_code
,is_check
,is_stop
,budg_subj_code
,budg_subj_name
,check_type_name1
,check_type_name2
,check_type_name3
,check_type_name4
,check_type_name5
,check_type_name6
,check_type_name7
,check_type_name8
,org_code
,org_name
,branch_code
,branch_name
</sql>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-DictAcctSubjEntity-result" parameterType = "com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity">
select
<include refid="DictAcctSubjEntity_Base_Column_List" />
from dict_acct_subj
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> and acct_year = #{acct_year} </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> and acct_subj_code = #{acct_subj_code} </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> and acct_subj_name = #{acct_subj_name} </if>
<if test="supper_code != null and supper_code != ''"> and supper_code = #{supper_code} </if>
<if test="subj_level != null and subj_level != ''"> and subj_level = #{subj_level} </if>
<if test="is_last != null and is_last != ''"> and is_last = #{is_last} </if>
<if test="subj_type_code != null and subj_type_code != ''"> and subj_type_code = #{subj_type_code} </if>
<if test="subj_type_name != null and subj_type_name != ''"> and subj_type_name = #{subj_type_name} </if>
<if test="direction != null and direction != ''"> and direction = #{direction} </if>
<if test="is_cash != null and is_cash != ''"> and is_cash = #{is_cash} </if>
<if test="subj_nature_code != null and subj_nature_code != ''"> and subj_nature_code = #{subj_nature_code} </if>
<if test="is_check != null and is_check != ''"> and is_check = #{is_check} </if>
<if test="is_stop != null and is_stop != ''"> and is_stop = #{is_stop} </if>
<if test="budg_subj_code != null and budg_subj_code != ''"> and budg_subj_code = #{budg_subj_code} </if>
<if test="budg_subj_name != null and budg_subj_name != ''"> and budg_subj_name = #{budg_subj_name} </if>
<if test="check_type_name1 != null and check_type_name1 != ''"> and check_type_name1 = #{check_type_name1} </if>
<if test="check_type_name2 != null and check_type_name2 != ''"> and check_type_name2 = #{check_type_name2} </if>
<if test="check_type_name3 != null and check_type_name3 != ''"> and check_type_name3 = #{check_type_name3} </if>
<if test="check_type_name4 != null and check_type_name4 != ''"> and check_type_name4 = #{check_type_name4} </if>
<if test="check_type_name5 != null and check_type_name5 != ''"> and check_type_name5 = #{check_type_name5} </if>
<if test="check_type_name6 != null and check_type_name6 != ''"> and check_type_name6 = #{check_type_name6} </if>
<if test="check_type_name7 != null and check_type_name7 != ''"> and check_type_name7 = #{check_type_name7} </if>
<if test="check_type_name8 != null and check_type_name8 != ''"> and check_type_name8 = #{check_type_name8} </if>
<if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> and org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> and branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> and branch_name = #{branch_name} </if>
</trim>
</select>
<!-- 查询符合条件的数量 -->
<select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity">
select count(1) from dict_acct_subj
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> and acct_year = #{acct_year} </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> and acct_subj_code = #{acct_subj_code} </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> and acct_subj_name = #{acct_subj_name} </if>
<if test="supper_code != null and supper_code != ''"> and supper_code = #{supper_code} </if>
<if test="subj_level != null and subj_level != ''"> and subj_level = #{subj_level} </if>
<if test="is_last != null and is_last != ''"> and is_last = #{is_last} </if>
<if test="subj_type_code != null and subj_type_code != ''"> and subj_type_code = #{subj_type_code} </if>
<if test="subj_type_name != null and subj_type_name != ''"> and subj_type_name = #{subj_type_name} </if>
<if test="direction != null and direction != ''"> and direction = #{direction} </if>
<if test="is_cash != null and is_cash != ''"> and is_cash = #{is_cash} </if>
<if test="subj_nature_code != null and subj_nature_code != ''"> and subj_nature_code = #{subj_nature_code} </if>
<if test="is_check != null and is_check != ''"> and is_check = #{is_check} </if>
<if test="is_stop != null and is_stop != ''"> and is_stop = #{is_stop} </if>
<if test="budg_subj_code != null and budg_subj_code != ''"> and budg_subj_code = #{budg_subj_code} </if>
<if test="budg_subj_name != null and budg_subj_name != ''"> and budg_subj_name = #{budg_subj_name} </if>
<if test="check_type_name1 != null and check_type_name1 != ''"> and check_type_name1 = #{check_type_name1} </if>
<if test="check_type_name2 != null and check_type_name2 != ''"> and check_type_name2 = #{check_type_name2} </if>
<if test="check_type_name3 != null and check_type_name3 != ''"> and check_type_name3 = #{check_type_name3} </if>
<if test="check_type_name4 != null and check_type_name4 != ''"> and check_type_name4 = #{check_type_name4} </if>
<if test="check_type_name5 != null and check_type_name5 != ''"> and check_type_name5 = #{check_type_name5} </if>
<if test="check_type_name6 != null and check_type_name6 != ''"> and check_type_name6 = #{check_type_name6} </if>
<if test="check_type_name7 != null and check_type_name7 != ''"> and check_type_name7 = #{check_type_name7} </if>
<if test="check_type_name8 != null and check_type_name8 != ''"> and check_type_name8 = #{check_type_name8} </if>
<if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> and org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> and branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> and branch_name = #{branch_name} </if>
</trim>
</select>
<!-- 分页查询列表 采用like格式 -->
<select id="entity_list_like" resultMap="get-DictAcctSubjEntity-result" parameterType = "com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity">
select
<include refid="DictAcctSubjEntity_Base_Column_List" />
from dict_acct_subj
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> and acct_year like concat('%',#{acct_year},'%') </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> and acct_subj_code like concat('%',#{acct_subj_code},'%') </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> and acct_subj_name like concat('%',#{acct_subj_name},'%') </if>
<if test="supper_code != null and supper_code != ''"> and supper_code like concat('%',#{supper_code},'%') </if>
<if test="subj_level != null and subj_level != ''"> and subj_level like concat('%',#{subj_level},'%') </if>
<if test="is_last != null and is_last != ''"> and is_last like concat('%',#{is_last},'%') </if>
<if test="subj_type_code != null and subj_type_code != ''"> and subj_type_code like concat('%',#{subj_type_code},'%') </if>
<if test="subj_type_name != null and subj_type_name != ''"> and subj_type_name like concat('%',#{subj_type_name},'%') </if>
<if test="direction != null and direction != ''"> and direction like concat('%',#{direction},'%') </if>
<if test="is_cash != null and is_cash != ''"> and is_cash like concat('%',#{is_cash},'%') </if>
<if test="subj_nature_code != null and subj_nature_code != ''"> and subj_nature_code like concat('%',#{subj_nature_code},'%') </if>
<if test="is_check != null and is_check != ''"> and is_check like concat('%',#{is_check},'%') </if>
<if test="is_stop != null and is_stop != ''"> and is_stop like concat('%',#{is_stop},'%') </if>
<if test="budg_subj_code != null and budg_subj_code != ''"> and budg_subj_code like concat('%',#{budg_subj_code},'%') </if>
<if test="budg_subj_name != null and budg_subj_name != ''"> and budg_subj_name like concat('%',#{budg_subj_name},'%') </if>
<if test="check_type_name1 != null and check_type_name1 != ''"> and check_type_name1 like concat('%',#{check_type_name1},'%') </if>
<if test="check_type_name2 != null and check_type_name2 != ''"> and check_type_name2 like concat('%',#{check_type_name2},'%') </if>
<if test="check_type_name3 != null and check_type_name3 != ''"> and check_type_name3 like concat('%',#{check_type_name3},'%') </if>
<if test="check_type_name4 != null and check_type_name4 != ''"> and check_type_name4 like concat('%',#{check_type_name4},'%') </if>
<if test="check_type_name5 != null and check_type_name5 != ''"> and check_type_name5 like concat('%',#{check_type_name5},'%') </if>
<if test="check_type_name6 != null and check_type_name6 != ''"> and check_type_name6 like concat('%',#{check_type_name6},'%') </if>
<if test="check_type_name7 != null and check_type_name7 != ''"> and check_type_name7 like concat('%',#{check_type_name7},'%') </if>
<if test="check_type_name8 != null and check_type_name8 != ''"> and check_type_name8 like concat('%',#{check_type_name8},'%') </if>
<if test="org_code != null and org_code != ''"> and org_code like concat('%',#{org_code},'%') </if>
<if test="org_name != null and org_name != ''"> and org_name like concat('%',#{org_name},'%') </if>
<if test="branch_code != null and branch_code != ''"> and branch_code like concat('%',#{branch_code},'%') </if>
<if test="branch_name != null and branch_name != ''"> and branch_name like concat('%',#{branch_name},'%') </if>
</trim>
</select>
<!-- 查询列表 字段采用or格式 -->
<select id="DictAcctSubjentity_list_or" resultMap="get-DictAcctSubjEntity-result" parameterType = "com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity">
select
<include refid="DictAcctSubjEntity_Base_Column_List" />
from dict_acct_subj
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> or acct_year = #{acct_year} </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> or acct_subj_code = #{acct_subj_code} </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> or acct_subj_name = #{acct_subj_name} </if>
<if test="supper_code != null and supper_code != ''"> or supper_code = #{supper_code} </if>
<if test="subj_level != null and subj_level != ''"> or subj_level = #{subj_level} </if>
<if test="is_last != null and is_last != ''"> or is_last = #{is_last} </if>
<if test="subj_type_code != null and subj_type_code != ''"> or subj_type_code = #{subj_type_code} </if>
<if test="subj_type_name != null and subj_type_name != ''"> or subj_type_name = #{subj_type_name} </if>
<if test="direction != null and direction != ''"> or direction = #{direction} </if>
<if test="is_cash != null and is_cash != ''"> or is_cash = #{is_cash} </if>
<if test="subj_nature_code != null and subj_nature_code != ''"> or subj_nature_code = #{subj_nature_code} </if>
<if test="is_check != null and is_check != ''"> or is_check = #{is_check} </if>
<if test="is_stop != null and is_stop != ''"> or is_stop = #{is_stop} </if>
<if test="budg_subj_code != null and budg_subj_code != ''"> or budg_subj_code = #{budg_subj_code} </if>
<if test="budg_subj_name != null and budg_subj_name != ''"> or budg_subj_name = #{budg_subj_name} </if>
<if test="check_type_name1 != null and check_type_name1 != ''"> or check_type_name1 = #{check_type_name1} </if>
<if test="check_type_name2 != null and check_type_name2 != ''"> or check_type_name2 = #{check_type_name2} </if>
<if test="check_type_name3 != null and check_type_name3 != ''"> or check_type_name3 = #{check_type_name3} </if>
<if test="check_type_name4 != null and check_type_name4 != ''"> or check_type_name4 = #{check_type_name4} </if>
<if test="check_type_name5 != null and check_type_name5 != ''"> or check_type_name5 = #{check_type_name5} </if>
<if test="check_type_name6 != null and check_type_name6 != ''"> or check_type_name6 = #{check_type_name6} </if>
<if test="check_type_name7 != null and check_type_name7 != ''"> or check_type_name7 = #{check_type_name7} </if>
<if test="check_type_name8 != null and check_type_name8 != ''"> or check_type_name8 = #{check_type_name8} </if>
<if test="org_code != null and org_code != ''"> or org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> or org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> or branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> or branch_name = #{branch_name} </if>
</trim>
</select>
<resultMap id="get-DictAcctSubjEntityVo-result" type="com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntityVo" >
<result property="acct_year" column="acct_year" jdbcType="VARCHAR"/>
<result property="acct_subj_code" column="acct_subj_code" jdbcType="VARCHAR"/>
<result property="acct_subj_name" column="acct_subj_name" jdbcType="VARCHAR"/>
<result property="supper_code" column="supper_code" jdbcType="VARCHAR"/>
<result property="subj_level" column="subj_level" jdbcType="VARCHAR"/>
<result property="is_last" column="is_last" jdbcType="VARCHAR"/>
<result property="subj_type_code" column="subj_type_code" jdbcType="VARCHAR"/>
<result property="subj_type_name" column="subj_type_name" jdbcType="VARCHAR"/>
<result property="direction" column="direction" jdbcType="VARCHAR"/>
<result property="is_cash" column="is_cash" jdbcType="VARCHAR"/>
<result property="subj_nature_code" column="subj_nature_code" jdbcType="VARCHAR"/>
<result property="is_check" column="is_check" jdbcType="VARCHAR"/>
<result property="is_stop" column="is_stop" jdbcType="VARCHAR"/>
<result property="budg_subj_code" column="budg_subj_code" jdbcType="VARCHAR"/>
<result property="budg_subj_name" column="budg_subj_name" jdbcType="VARCHAR"/>
<result property="check_type_name1" column="check_type_name1" jdbcType="VARCHAR"/>
<result property="check_type_name2" column="check_type_name2" jdbcType="VARCHAR"/>
<result property="check_type_name3" column="check_type_name3" jdbcType="VARCHAR"/>
<result property="check_type_name4" column="check_type_name4" jdbcType="VARCHAR"/>
<result property="check_type_name5" column="check_type_name5" jdbcType="VARCHAR"/>
<result property="check_type_name6" column="check_type_name6" jdbcType="VARCHAR"/>
<result property="check_type_name7" column="check_type_name7" jdbcType="VARCHAR"/>
<result property="check_type_name8" column="check_type_name8" jdbcType="VARCHAR"/>
<result property="org_code" column="org_code" jdbcType="VARCHAR"/>
<result property="org_name" column="org_name" jdbcType="VARCHAR"/>
<result property="branch_code" column="branch_code" jdbcType="VARCHAR"/>
<result property="branch_name" column="branch_name" jdbcType="VARCHAR"/>
</resultMap>
<!-- 分页查询列表 采用like格式 -->
<select id="queryData" resultMap="get-DictAcctSubjEntityVo-result" parameterType = "com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity">
select
<include refid="DictAcctSubjEntity_Base_Column_List" />
from dict_acct_subj
<trim prefix="where" prefixOverrides="and">
<if test="acct_year != null and acct_year != ''"> and acct_year like '%${acct_year}%' </if>
<if test="acct_subj_code != null and acct_subj_code != ''"> and acct_subj_code like '%${acct_subj_code}%' </if>
<if test="acct_subj_name != null and acct_subj_name != ''"> and acct_subj_name like '%${acct_subj_name}%' </if>
<if test="supper_code != null and supper_code != ''"> and supper_code like '%${supper_code}%' </if>
<if test="subj_level != null and subj_level != ''"> and subj_level like '%${subj_level}%' </if>
<if test="is_last != null and is_last != ''"> and is_last like '%${is_last}%' </if>
<if test="subj_type_code != null and subj_type_code != ''"> and subj_type_code like '%${subj_type_code}%' </if>
<if test="subj_type_name != null and subj_type_name != ''"> and subj_type_name like '%${subj_type_name}%' </if>
<if test="direction != null and direction != ''"> and direction like '%${direction}%' </if>
<if test="is_cash != null and is_cash != ''"> and is_cash like '%${is_cash}%' </if>
<if test="subj_nature_code != null and subj_nature_code != ''"> and subj_nature_code like '%${subj_nature_code}%' </if>
<if test="is_check != null and is_check != ''"> and is_check like '%${is_check}%' </if>
<if test="is_stop != null and is_stop != ''"> and is_stop like '%${is_stop}%' </if>
<if test="budg_subj_code != null and budg_subj_code != ''"> and budg_subj_code like '%${budg_subj_code}%' </if>
<if test="budg_subj_name != null and budg_subj_name != ''"> and budg_subj_name like '%${budg_subj_name}%' </if>
<if test="check_type_name1 != null and check_type_name1 != ''"> and check_type_name1 like '%${check_type_name1}%' </if>
<if test="check_type_name2 != null and check_type_name2 != ''"> and check_type_name2 like '%${check_type_name2}%' </if>
<if test="check_type_name3 != null and check_type_name3 != ''"> and check_type_name3 like '%${check_type_name3}%' </if>
<if test="check_type_name4 != null and check_type_name4 != ''"> and check_type_name4 like '%${check_type_name4}%' </if>
<if test="check_type_name5 != null and check_type_name5 != ''"> and check_type_name5 like '%${check_type_name5}%' </if>
<if test="check_type_name6 != null and check_type_name6 != ''"> and check_type_name6 like '%${check_type_name6}%' </if>
<if test="check_type_name7 != null and check_type_name7 != ''"> and check_type_name7 like '%${check_type_name7}%' </if>
<if test="check_type_name8 != null and check_type_name8 != ''"> and check_type_name8 like '%${check_type_name8}%' </if>
<if test="org_code != null and org_code != ''"> and org_code like '%${org_code}%' </if>
<if test="org_name != null and org_name != ''"> and org_name like '%${org_name}%' </if>
<if test="branch_code != null and branch_code != ''"> and branch_code like '%${branch_code}%' </if>
<if test="branch_name != null and branch_name != ''"> and branch_name like '%${branch_name}%' </if>
</trim>
</select>
</mapper>

View File

@ -0,0 +1,284 @@
package com.hzya.frame.grpU8.dictAcctSubj.entity;
import com.hzya.frame.web.entity.BaseEntity;
/**
* 子表(DictAcctSubj)实体类
*
* @author makejava
* @since 2024-07-09 11:23:36
*/
public class DictAcctSubjEntityVo {
/** 年度 */
private String acct_year;
/** 会计科目编码 */
private String acct_subj_code;
/** 会计科目名称 */
private String acct_subj_name;
/** 上级编码 */
private String supper_code;
/** 科目级次 */
private String subj_level;
/** 是否末级 */
private String is_last;
/** 科目类型编码 */
private String subj_type_code;
/** 科目类型名称 */
private String subj_type_name;
/** 借贷方向 */
private String direction;
/** 是否现金 */
private String is_cash;
/** 科目性质 */
private String subj_nature_code;
/** 是否辅助核算 */
private String is_check;
/** 是否停用 */
private String is_stop;
/** 预算会计科目编码 */
private String budg_subj_code;
/** 预算会计科目名称 */
private String budg_subj_name;
/** 辅助核算项1 */
private String check_type_name1;
/** 辅助核算项2 */
private String check_type_name2;
/** 辅助核算项3 */
private String check_type_name3;
/** 辅助核算项4 */
private String check_type_name4;
/** 辅助核算项5 */
private String check_type_name5;
/** 辅助核算项6 */
private String check_type_name6;
/** 辅助核算项7 */
private String check_type_name7;
/** 辅助核算项8 */
private String check_type_name8;
/** 单位编码 */
private String org_code;
/** 单位名称 */
private String org_name;
/** 院区编码 */
private String branch_code;
/** 院区名称 */
private String branch_name;
public String getAcct_year() {
return acct_year;
}
public void setAcct_year(String acct_year) {
this.acct_year = acct_year;
}
public String getAcct_subj_code() {
return acct_subj_code;
}
public void setAcct_subj_code(String acct_subj_code) {
this.acct_subj_code = acct_subj_code;
}
public String getAcct_subj_name() {
return acct_subj_name;
}
public void setAcct_subj_name(String acct_subj_name) {
this.acct_subj_name = acct_subj_name;
}
public String getSupper_code() {
return supper_code;
}
public void setSupper_code(String supper_code) {
this.supper_code = supper_code;
}
public String getSubj_level() {
return subj_level;
}
public void setSubj_level(String subj_level) {
this.subj_level = subj_level;
}
public String getIs_last() {
return is_last;
}
public void setIs_last(String is_last) {
this.is_last = is_last;
}
public String getSubj_type_code() {
return subj_type_code;
}
public void setSubj_type_code(String subj_type_code) {
this.subj_type_code = subj_type_code;
}
public String getSubj_type_name() {
return subj_type_name;
}
public void setSubj_type_name(String subj_type_name) {
this.subj_type_name = subj_type_name;
}
public String getDirection() {
return direction;
}
public void setDirection(String direction) {
this.direction = direction;
}
public String getIs_cash() {
return is_cash;
}
public void setIs_cash(String is_cash) {
this.is_cash = is_cash;
}
public String getSubj_nature_code() {
return subj_nature_code;
}
public void setSubj_nature_code(String subj_nature_code) {
this.subj_nature_code = subj_nature_code;
}
public String getIs_check() {
return is_check;
}
public void setIs_check(String is_check) {
this.is_check = is_check;
}
public String getIs_stop() {
return is_stop;
}
public void setIs_stop(String is_stop) {
this.is_stop = is_stop;
}
public String getBudg_subj_code() {
return budg_subj_code;
}
public void setBudg_subj_code(String budg_subj_code) {
this.budg_subj_code = budg_subj_code;
}
public String getBudg_subj_name() {
return budg_subj_name;
}
public void setBudg_subj_name(String budg_subj_name) {
this.budg_subj_name = budg_subj_name;
}
public String getCheck_type_name1() {
return check_type_name1;
}
public void setCheck_type_name1(String check_type_name1) {
this.check_type_name1 = check_type_name1;
}
public String getCheck_type_name2() {
return check_type_name2;
}
public void setCheck_type_name2(String check_type_name2) {
this.check_type_name2 = check_type_name2;
}
public String getCheck_type_name3() {
return check_type_name3;
}
public void setCheck_type_name3(String check_type_name3) {
this.check_type_name3 = check_type_name3;
}
public String getCheck_type_name4() {
return check_type_name4;
}
public void setCheck_type_name4(String check_type_name4) {
this.check_type_name4 = check_type_name4;
}
public String getCheck_type_name5() {
return check_type_name5;
}
public void setCheck_type_name5(String check_type_name5) {
this.check_type_name5 = check_type_name5;
}
public String getCheck_type_name6() {
return check_type_name6;
}
public void setCheck_type_name6(String check_type_name6) {
this.check_type_name6 = check_type_name6;
}
public String getCheck_type_name7() {
return check_type_name7;
}
public void setCheck_type_name7(String check_type_name7) {
this.check_type_name7 = check_type_name7;
}
public String getCheck_type_name8() {
return check_type_name8;
}
public void setCheck_type_name8(String check_type_name8) {
this.check_type_name8 = check_type_name8;
}
public String getOrg_code() {
return org_code;
}
public void setOrg_code(String org_code) {
this.org_code = org_code;
}
public String getOrg_name() {
return org_name;
}
public void setOrg_name(String org_name) {
this.org_name = org_name;
}
public String getBranch_code() {
return branch_code;
}
public void setBranch_code(String branch_code) {
this.branch_code = branch_code;
}
public String getBranch_name() {
return branch_name;
}
public void setBranch_name(String branch_name) {
this.branch_name = branch_name;
}
}

View File

@ -0,0 +1,22 @@
package com.hzya.frame.grpU8.dictAcctSubj.service;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.web.entity.JsonResultEntity;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity;
import com.hzya.frame.basedao.service.IBaseService;
/**
* 子表(DictAcctSubj)表服务接口
*
* @author makejava
* @since 2024-07-09 11:23:36
*/
public interface IDictAcctSubjService extends IBaseService<DictAcctSubjEntity, String>{
/**
* @param jsonObject
* @return com.hzya.frame.web.entity.JsonResultEntity
* @Author lvleigang
* @Description 数据表
* @Date 11:52 上午 2024/3/27
**/
Object queryData(JSONObject jsonObject);
}

View File

@ -0,0 +1,66 @@
package com.hzya.frame.grpU8.dictAcctSubj.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.hzya.frame.web.entity.BaseResult;
import com.hzya.frame.web.entity.JsonResultEntity;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntity;
import com.hzya.frame.grpU8.acctVouchInfo.entity.AcctVouchInfoEntityVo;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity;
import com.hzya.frame.grpU8.dictAcctSubj.dao.IDictAcctSubjDao;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntityVo;
import com.hzya.frame.grpU8.dictAcctSubj.service.IDictAcctSubjService;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService;
import java.util.List;
/**
* 子表(DictAcctSubj)表服务实现类
*
* @author makejava
* @since 2024-07-09 11:23:36
*/
@Service(value = "dictAcctSubjService")
public class DictAcctSubjServiceImpl extends BaseService<DictAcctSubjEntity, String> implements IDictAcctSubjService {
private IDictAcctSubjDao dictAcctSubjDao;
@Autowired
public void setDictAcctSubjDao(IDictAcctSubjDao dao) {
this.dictAcctSubjDao = dao;
this.dao = dao;
}
/**
* @param jsonObject
* @return com.hzya.frame.web.entity.JsonResultEntity
* @Author lvleigang
* @Description 数据表
* @Date 11:52 上午 2024/3/27
**/
@Override
public Object queryData(JSONObject jsonObject) {
DictAcctSubjEntity entity = getData("jsonStr", jsonObject, DictAcctSubjEntity.class);
if(entity == null ){
entity = new DictAcctSubjEntity();
}
//判断分页
if (entity.getPageNum() != null && entity.getPageSize() != null) {
PageHelper.startPage(entity.getPageNum(), entity.getPageSize());
List<DictAcctSubjEntityVo> list = dictAcctSubjDao.queryData(entity);
PageInfo pageInfo = new PageInfo(list);
JSONObject object = new JSONObject();
object.put("status","success");
object.put("data",pageInfo);
return object;
}else {
List<DictAcctSubjEntityVo> list = dictAcctSubjDao.queryData(entity);
JSONObject object = new JSONObject();
object.put("status","success");
object.put("data",list);
return object; }
}
}

View File

@ -0,0 +1,19 @@
package com.hzya.frame.grpU8.dictCheckType.dao;
import com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntityVo;
import java.util.List;
/**
* 子表(dict_check_type: table)表数据库访问层
*
* @author makejava
* @since 2024-07-09 11:24:25
*/
public interface IDictCheckTypeDao extends IBaseDao<DictCheckTypeEntity, String> {
List<DictCheckTypeEntityVo> queryData(DictCheckTypeEntity entity);
}

View File

@ -0,0 +1,30 @@
package com.hzya.frame.grpU8.dictCheckType.dao.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntityVo;
import com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity;
import com.hzya.frame.grpU8.dictCheckType.dao.IDictCheckTypeDao;
import com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntityVo;
import org.springframework.stereotype.Repository;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import java.util.List;
/**
* 子表(DictCheckType)表数据库访问层
*
* @author makejava
* @since 2024-07-09 11:24:25
*/
@Repository(value = "DictCheckTypeDaoImpl")
public class DictCheckTypeDaoImpl extends MybatisGenericDao<DictCheckTypeEntity, String> implements IDictCheckTypeDao{
@DS("#entity.dataSourceCode")
@Override
public List<DictCheckTypeEntityVo> queryData(DictCheckTypeEntity entity) {
List<DictCheckTypeEntityVo> o = (List<DictCheckTypeEntityVo>) super.selectList(getSqlIdPrifx() + "queryData", entity);
return o;
}
}

View File

@ -0,0 +1,74 @@
package com.hzya.frame.grpU8.dictCheckType.entity;
import java.util.Date;
import com.hzya.frame.web.entity.BaseEntity;
/**
* 子表(DictCheckType)实体类
*
* @author makejava
* @since 2024-07-09 11:24:25
*/
public class DictCheckTypeEntity extends BaseEntity {
/** 辅助核算项编码 */
private String check_type_code;
/** 辅助核算项名称 */
private String check_type_name;
/** 单位编码 */
private String org_code;
/** 单位名称 */
private String org_name;
/** 院区编码 */
private String branch_code;
/** 院区名称 */
private String branch_name;
public String getCheck_type_code() {
return check_type_code;
}
public void setCheck_type_code(String check_type_code) {
this.check_type_code = check_type_code;
}
public String getCheck_type_name() {
return check_type_name;
}
public void setCheck_type_name(String check_type_name) {
this.check_type_name = check_type_name;
}
public String getOrg_code() {
return org_code;
}
public void setOrg_code(String org_code) {
this.org_code = org_code;
}
public String getOrg_name() {
return org_name;
}
public void setOrg_name(String org_name) {
this.org_name = org_name;
}
public String getBranch_code() {
return branch_code;
}
public void setBranch_code(String branch_code) {
this.branch_code = branch_code;
}
public String getBranch_name() {
return branch_name;
}
public void setBranch_name(String branch_name) {
this.branch_name = branch_name;
}
}

View File

@ -0,0 +1,103 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.grpU8.dictCheckType.dao.impl.DictCheckTypeDaoImpl">
<resultMap id="get-DictCheckTypeEntity-result" type="com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity" >
<result property="check_type_code" column="check_type_code" jdbcType="VARCHAR"/>
<result property="check_type_name" column="check_type_name" jdbcType="VARCHAR"/>
<result property="org_code" column="org_code" jdbcType="VARCHAR"/>
<result property="org_name" column="org_name" jdbcType="VARCHAR"/>
<result property="branch_code" column="branch_code" jdbcType="VARCHAR"/>
<result property="branch_name" column="branch_name" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询的字段-->
<sql id = "DictCheckTypeEntity_Base_Column_List">
check_type_code
,check_type_name
,org_code
,org_name
,branch_code
,branch_name
</sql>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-DictCheckTypeEntity-result" parameterType = "com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity">
select
<include refid="DictCheckTypeEntity_Base_Column_List" />
from dict_check_type
<trim prefix="where" prefixOverrides="and">
<if test="check_type_code != null and check_type_code != ''"> and check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name = #{check_type_name} </if>
<if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> and org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> and branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> and branch_name = #{branch_name} </if>
</trim>
</select>
<!-- 查询符合条件的数量 -->
<select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity">
select count(1) from dict_check_type
<trim prefix="where" prefixOverrides="and">
<if test="check_type_code != null and check_type_code != ''"> and check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name = #{check_type_name} </if>
<if test="org_code != null and org_code != ''"> and org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> and org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> and branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> and branch_name = #{branch_name} </if>
</trim>
</select>
<!-- 分页查询列表 采用like格式 -->
<select id="entity_list_like" resultMap="get-DictCheckTypeEntity-result" parameterType = "com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity">
select
<include refid="DictCheckTypeEntity_Base_Column_List" />
from dict_check_type
<trim prefix="where" prefixOverrides="and">
<if test="check_type_code != null and check_type_code != ''"> and check_type_code like concat('%',#{check_type_code},'%') </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name like concat('%',#{check_type_name},'%') </if>
<if test="org_code != null and org_code != ''"> and org_code like concat('%',#{org_code},'%') </if>
<if test="org_name != null and org_name != ''"> and org_name like concat('%',#{org_name},'%') </if>
<if test="branch_code != null and branch_code != ''"> and branch_code like concat('%',#{branch_code},'%') </if>
<if test="branch_name != null and branch_name != ''"> and branch_name like concat('%',#{branch_name},'%') </if>
</trim>
</select>
<!-- 查询列表 字段采用or格式 -->
<select id="DictCheckTypeentity_list_or" resultMap="get-DictCheckTypeEntity-result" parameterType = "com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity">
select
<include refid="DictCheckTypeEntity_Base_Column_List" />
from dict_check_type
<trim prefix="where" prefixOverrides="and">
<if test="check_type_code != null and check_type_code != ''"> or check_type_code = #{check_type_code} </if>
<if test="check_type_name != null and check_type_name != ''"> or check_type_name = #{check_type_name} </if>
<if test="org_code != null and org_code != ''"> or org_code = #{org_code} </if>
<if test="org_name != null and org_name != ''"> or org_name = #{org_name} </if>
<if test="branch_code != null and branch_code != ''"> or branch_code = #{branch_code} </if>
<if test="branch_name != null and branch_name != ''"> or branch_name = #{branch_name} </if>
</trim>
</select>
<resultMap id="get-DictCheckTypeEntityVo-result" type="com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntityVo" >
<result property="check_type_code" column="check_type_code" jdbcType="VARCHAR"/>
<result property="check_type_name" column="check_type_name" jdbcType="VARCHAR"/>
<result property="org_code" column="org_code" jdbcType="VARCHAR"/>
<result property="org_name" column="org_name" jdbcType="VARCHAR"/>
<result property="branch_code" column="branch_code" jdbcType="VARCHAR"/>
<result property="branch_name" column="branch_name" jdbcType="VARCHAR"/>
</resultMap>
<!-- 分页查询列表 采用like格式 -->
<select id="queryData" resultMap="get-DictCheckTypeEntityVo-result" parameterType = "com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity">
select
<include refid="DictCheckTypeEntity_Base_Column_List" />
from dict_check_type
<trim prefix="where" prefixOverrides="and">
<if test="check_type_code != null and check_type_code != ''"> and check_type_code like '%${check_type_code}%' </if>
<if test="check_type_name != null and check_type_name != ''"> and check_type_name like '%${check_type_name}%' </if>
<if test="org_code != null and org_code != ''"> and org_code like '%${org_code}%' </if>
<if test="org_name != null and org_name != ''"> and org_name like '%${org_name}%' </if>
<if test="branch_code != null and branch_code != ''"> and branch_code like '%${branch_code}%' </if>
<if test="branch_name != null and branch_name != ''"> and branch_name like '%${branch_name}%' </if>
</trim>
</select>
</mapper>

View File

@ -0,0 +1,74 @@
package com.hzya.frame.grpU8.dictCheckType.entity;
import com.hzya.frame.web.entity.BaseEntity;
/**
* 子表(DictCheckType)实体类
*
* @author makejava
* @since 2024-07-09 11:24:25
*/
public class DictCheckTypeEntityVo {
/** 辅助核算项编码 */
private String check_type_code;
/** 辅助核算项名称 */
private String check_type_name;
/** 单位编码 */
private String org_code;
/** 单位名称 */
private String org_name;
/** 院区编码 */
private String branch_code;
/** 院区名称 */
private String branch_name;
public String getCheck_type_code() {
return check_type_code;
}
public void setCheck_type_code(String check_type_code) {
this.check_type_code = check_type_code;
}
public String getCheck_type_name() {
return check_type_name;
}
public void setCheck_type_name(String check_type_name) {
this.check_type_name = check_type_name;
}
public String getOrg_code() {
return org_code;
}
public void setOrg_code(String org_code) {
this.org_code = org_code;
}
public String getOrg_name() {
return org_name;
}
public void setOrg_name(String org_name) {
this.org_name = org_name;
}
public String getBranch_code() {
return branch_code;
}
public void setBranch_code(String branch_code) {
this.branch_code = branch_code;
}
public String getBranch_name() {
return branch_name;
}
public void setBranch_name(String branch_name) {
this.branch_name = branch_name;
}
}

View File

@ -0,0 +1,22 @@
package com.hzya.frame.grpU8.dictCheckType.service;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.web.entity.JsonResultEntity;
import com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity;
import com.hzya.frame.basedao.service.IBaseService;
/**
* 子表(DictCheckType)表服务接口
*
* @author makejava
* @since 2024-07-09 11:24:25
*/
public interface IDictCheckTypeService extends IBaseService<DictCheckTypeEntity, String>{
/**
* @param jsonObject
* @return com.hzya.frame.web.entity.JsonResultEntity
* @Author lvleigang
* @Description 数据表
* @Date 11:52 上午 2024/3/27
**/
Object queryData(JSONObject jsonObject);
}

View File

@ -0,0 +1,67 @@
package com.hzya.frame.grpU8.dictCheckType.service.impl;
import com.alibaba.fastjson.JSONObject;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.hzya.frame.web.entity.BaseResult;
import com.hzya.frame.web.entity.JsonResultEntity;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntity;
import com.hzya.frame.grpU8.dictAcctSubj.entity.DictAcctSubjEntityVo;
import com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntity;
import com.hzya.frame.grpU8.dictCheckType.dao.IDictCheckTypeDao;
import com.hzya.frame.grpU8.dictCheckType.entity.DictCheckTypeEntityVo;
import com.hzya.frame.grpU8.dictCheckType.service.IDictCheckTypeService;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService;
import java.util.List;
/**
* 子表(DictCheckType)表服务实现类
*
* @author makejava
* @since 2024-07-09 11:24:25
*/
@Service(value = "dictCheckTypeService")
public class DictCheckTypeServiceImpl extends BaseService<DictCheckTypeEntity, String> implements IDictCheckTypeService {
private IDictCheckTypeDao dictCheckTypeDao;
@Autowired
public void setDictCheckTypeDao(IDictCheckTypeDao dao) {
this.dictCheckTypeDao = dao;
this.dao = dao;
}
/**
* @param jsonObject
* @return com.hzya.frame.web.entity.JsonResultEntity
* @Author lvleigang
* @Description 数据表
* @Date 11:52 上午 2024/3/27
**/
@Override
public Object queryData(JSONObject jsonObject) {
DictCheckTypeEntity entity = getData("jsonStr", jsonObject, DictCheckTypeEntity.class);
if(entity == null ){
entity = new DictCheckTypeEntity();
}
//判断分页
if (entity.getPageNum() != null && entity.getPageSize() != null) {
PageHelper.startPage(entity.getPageNum(), entity.getPageSize());
List<DictCheckTypeEntityVo> list = dictCheckTypeDao.queryData(entity);
PageInfo pageInfo = new PageInfo(list);
JSONObject object = new JSONObject();
object.put("status","success");
object.put("data",pageInfo);
return object;
}else {
List<DictCheckTypeEntityVo> list = dictCheckTypeDao.queryData(entity);
JSONObject object = new JSONObject();
object.put("status","success");
object.put("data",list);
return object;
}
}
}

View File

@ -0,0 +1,13 @@
package com.hzya.frame.grpU8.nxproof.attachment.dao;/*
* @Description 附件
* @Author xiangerlin
@Date 2022-10-26 11:17
*/
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity;
public interface IAttachmentFileDao extends IBaseDao<AttachmentFileEntity, String> {
Integer saveData(AttachmentFileEntity entity);
}

View File

@ -0,0 +1,23 @@
package com.hzya.frame.grpU8.nxproof.attachment.dao.impl;/*
* @Description 附件
* @Author xiangerlin
@Date 2022-10-26 11:18
*/
import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import com.hzya.frame.grpU8.nxproof.attachment.dao.IAttachmentFileDao;
import com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity;
import com.hzya.frame.grpU8.nxproof.oerannex.entity.OerAnnexEntity;
import org.springframework.stereotype.Repository;
@Repository
public class AttachmentFileDaoImpl extends MybatisGenericDao<AttachmentFileEntity, String> implements IAttachmentFileDao {
@DS("#entity.dataSourceCode")
@Override
public Integer saveData(AttachmentFileEntity entity) {
Integer o = super.insert("com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity.AttachmentFileEntity_insert", entity);
return o;
}
}

View File

@ -0,0 +1,120 @@
package com.hzya.frame.grpU8.nxproof.attachment.entity;/*
* @Description 附件表
* @Author xiangerlin
@Date 2022-10-26 10:40
*/
import com.hzya.frame.web.entity.BaseEntity;
public class AttachmentFileEntity extends BaseEntity {
private String aTGuid;//主键id
private String createDate;//创建日期
private String createID;//创建人id
private String updateDate;//更新日期
private String updateID;//更新人id
private String deleteDate;//删除日期
private String deleteID;//删除人
private String aTFileName;//附件名
private String aTExtName;//附件后缀名
private byte[] aTFile;//附件 二进制文件
private String relationApp;//固定传 OER
private String isDELETE;//删除标记 0是未删除
public String getaTGuid() {
return aTGuid;
}
public void setaTGuid(String aTGuid) {
this.aTGuid = aTGuid;
}
public String getCreateDate() {
return createDate;
}
public void setCreateDate(String createDate) {
this.createDate = createDate;
}
public String getCreateID() {
return createID;
}
public void setCreateID(String createID) {
this.createID = createID;
}
public String getUpdateDate() {
return updateDate;
}
public void setUpdateDate(String updateDate) {
this.updateDate = updateDate;
}
public String getUpdateID() {
return updateID;
}
public void setUpdateID(String updateID) {
this.updateID = updateID;
}
public String getDeleteDate() {
return deleteDate;
}
public void setDeleteDate(String deleteDate) {
this.deleteDate = deleteDate;
}
public String getDeleteID() {
return deleteID;
}
public void setDeleteID(String deleteID) {
this.deleteID = deleteID;
}
public String getaTFileName() {
return aTFileName;
}
public void setaTFileName(String aTFileName) {
this.aTFileName = aTFileName;
}
public String getaTExtName() {
return aTExtName;
}
public void setaTExtName(String aTExtName) {
this.aTExtName = aTExtName;
}
public byte[] getaTFile() {
return aTFile;
}
public void setaTFile(byte[] aTFile) {
this.aTFile = aTFile;
}
public String getRelationApp() {
return relationApp;
}
public void setRelationApp(String relationApp) {
this.relationApp = relationApp;
}
public String getIsDELETE() {
return isDELETE;
}
public void setIsDELETE(String isDELETE) {
this.isDELETE = isDELETE;
}
}

View File

@ -0,0 +1,86 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity">
<resultMap id="get-AttachmentFileEntity-result" type="com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity">
<result property="aTGuid" column="aTGuid" />
<result property="createDate" column="createDate" />
<result property="createID" column="createID" />
<result property="updateDate" column="updateDate" />
<result property="updateID" column="updateID" />
<result property="deleteDate" column="deleteDate" />
<result property="deleteID" column="deleteID" />
<result property="aTFileName" column="aTFileName" />
<result property="aTExtName" column="aTExtName" />
<result column="aTFile" property="aTFile" jdbcType="BLOB" typeHandler="org.apache.ibatis.type.BlobTypeHandler" />
<result property="relationApp" column="relationApp" />
<result property="isDELETE" column="isDELETE" />
</resultMap>
<sql id="AttachmentFileEntity_Base_Column_List">
ATGuid,
CreateDate,
CreateID,
UpdateDate,
UpdateID,
DeleteDate,
DeleteID,
ATFileName,
ATExtName,
ATFile,
RelationApp,
ISDELETE
</sql>
<!-- 查询 采用==查询 -->
<select id="AttachmentFileEntity_list_base" resultMap="get-AttachmentFileEntity-result" parameterType="com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity">
select
<include refid="AttachmentFileEntity_Base_Column_List" />
FROM
AT_AttachmentFile
<trim prefix="where" prefixOverrides="and">
<if test="aTGuid != null and aTGuid !='' "> aTGuid = #{aTGuid} </if>
<if test="aTFileName != null and aTFileName !='' ">and aTFileName = #{aTFileName} </if>
</trim>
</select>
<insert id="AttachmentFileEntity_insert" parameterType="com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity">
insert into AT_AttachmentFile(
<trim suffix="" suffixOverrides=",">
<if test="aTGuid != null and aTGuid !='' ">aTGuid,</if>
<if test="createDate != null and createDate !='' "> createDate, </if>
<if test="createID != null and createID !='' "> createID, </if>
<if test="updateDate != null and updateDate !='' "> updateDate ,</if>
<if test="updateID != null and updateID !='' ">updateID,</if>
<if test="deleteDate != null and deleteDate !='' ">deleteDate,</if>
<if test="deleteID != null and deleteID !='' ">deleteID,</if>
<if test="aTFileName != null and aTFileName !='' ">aTFileName,</if>
<if test="aTExtName != null and aTExtName !='' ">aTExtName,</if>
<if test="aTFile != null and aTFile !='' ">aTFile,</if>
relationApp,
isDELETE
</trim>
)values
(
<trim suffix="" suffixOverrides=",">
<if test="aTGuid != null and aTGuid !='' ">#{aTGuid},</if>
<if test="createDate != null and createDate !='' "> #{createDate}, </if>
<if test="createID != null and createID !='' "> #{createID}, </if>
<if test="updateDate != null and updateDate !='' "> #{updateDate} ,</if>
<if test="updateID != null and updateID !='' ">#{updateID},</if>
<if test="deleteDate != null and deleteDate !='' ">#{deleteDate},</if>
<if test="deleteID != null and deleteID !='' ">#{deleteID},</if>
<if test="aTFileName != null and aTFileName !='' ">#{aTFileName},</if>
<if test="aTExtName != null and aTExtName !='' ">#{aTExtName},</if>
<if test="aTFile != null and aTFile !='' ">#{aTFile,typeHandler=org.apache.ibatis.type.BlobTypeHandler},</if>
'OER',
0
</trim>
)
</insert>
</mapper>

View File

@ -0,0 +1,37 @@
package com.hzya.frame.grpU8.nxproof.attachment.service;/*
* @Description
* @Author xiangerlin
@Date 2022-10-26 11:19
*/
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity;
import java.util.List;
public interface IAttachmentFileService {
/**
* 保存附件
* @param entity
*/
void saveAttachment(AttachmentFileEntity entity);
List<AttachmentFileEntity> queryFile(AttachmentFileEntity entity)throws Exception;
/**
* 调用http接口查询单据附件
* @param billCode
* @return
* @throws Exception
*/
List<JSONObject> queryFileByCode(String billCode)throws Exception;
/**
* 附件上传
* @param fileList
* @param mlid
* @param kjnd
*/
void uploadAttachment(List<JSONObject> fileList,String mlid,String kjnd);
}

View File

@ -0,0 +1,229 @@
package com.hzya.frame.grpU8.nxproof.attachment.service.impl;/*
* @Description
* @Author xiangerlin
@Date 2022-10-26 11:20
*/
import cn.hutool.core.convert.Convert;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.util.IdUtil;
import cn.hutool.core.util.StrUtil;
import cn.hutool.http.HttpRequest;
import cn.hutool.http.HttpUtil;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.basedao.service.impl.BaseService;
import com.hzya.frame.grpU8.nxproof.attachment.dao.IAttachmentFileDao;
import com.hzya.frame.grpU8.nxproof.attachment.entity.AttachmentFileEntity;
import com.hzya.frame.grpU8.nxproof.attachment.service.IAttachmentFileService;
import com.hzya.frame.grpU8.nxproof.oerannex.entity.OerAnnexEntity;
import com.hzya.frame.grpU8.nxproof.oerannex.service.IOerAnnexService;
import com.hzya.frame.grpU8.nxproof.oerdjml.dto.FileInfoDTO;
import org.apache.commons.collections.CollectionUtils;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.io.*;
import java.net.URLDecoder;
import java.nio.charset.Charset;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.zip.ZipEntry;
import java.util.zip.ZipOutputStream;
@Service
public class AttachmentFileServiceImpl extends BaseService<AttachmentFileEntity,String> implements IAttachmentFileService {
Logger logger = LogManager.getLogger(getClass());
protected IAttachmentFileDao attachmentFileDao;
@Autowired
public void setBillLogDao(IAttachmentFileDao dao) {
this.attachmentFileDao = dao;
this.dao=dao;
}
@Autowired
private IOerAnnexService oerAnnexService;
/**
* 保存附件
* @param entity
*/
@Override
public void saveAttachment(AttachmentFileEntity entity) {
entity.setaTGuid("A1:"+IdUtil.fastUUID());
String date = DateUtil.format(new Date(), "yyyyMMdd HH:mm:ss");
entity.setCreateDate(date);
entity.setUpdateDate(date);
String fileName = entity.getaTFileName();
if (StrUtil.isNotEmpty(fileName)){
int index = fileName.lastIndexOf(".");
if (index > 0){
String suffix = fileName.substring(index);
entity.setaTExtName(suffix);
String prefix = fileName.substring(0,index);
entity.setaTFileName(prefix);
}
}
attachmentFileDao.save("AttachmentFileEntity_insert",entity);
}
@Override
public List<AttachmentFileEntity> queryFile(AttachmentFileEntity entity) throws Exception {
List<AttachmentFileEntity> list = attachmentFileDao.query(entity);
return list;
}
/**
* 调用http接口查询单据附件
*
* @param billCode 单据号
* @return
* @throws Exception
*/
@Override
public List<JSONObject> queryFileByCode(String billCode) throws Exception {
List<JSONObject> list = new ArrayList<>();
if (StrUtil.isNotEmpty(billCode)){
JSONObject params = new JSONObject();
params.put("billNo",billCode);
String res = HttpRequest.post("/grp/af/findFilesBB").body(params.toString()).execute().body();
logger.info("根据单号:{},查询到到附件列表为:{}",billCode,res);
if (StrUtil.isNotEmpty(res)){
JSONObject resJson = JSONObject.parseObject(res);
int pageCount = resJson.getIntValue("pageCount");
boolean success = resJson.getBoolean("success");
if (success){
String dataStr = resJson.getString("data");
list = JSONObject.parseArray(dataStr,JSONObject.class);
if (null != list && list.size() >0){
for (JSONObject jsonObject : list) {
String fileName = jsonObject.getString("fileName");
if (StrUtil.isNotEmpty(fileName)){
// 使用indexOf找到"."的位置
int dotIndex = fileName.lastIndexOf('.');
// 确保找到了"."防止indexOf返回-1的情况
if (dotIndex != -1){
String ext_name = fileName.substring(dotIndex);
jsonObject.put("Ext",ext_name);
}
}
}
}
}
}
}
return list;
}
/**
* 附件上传
*
* @param fileList
* @param mlid
* @param kjnd
*/
@Override
public void uploadAttachment(List<JSONObject> fileList, String mlid, String kjnd) {
if (CollectionUtils.isNotEmpty(fileList) && StrUtil.isNotEmpty(mlid) && StrUtil.isNotEmpty(kjnd)){
try {
//附件下载
List<FileInfoDTO> fileInfoList = fileDownload(fileList);
//附件保存到grp库里
if (CollectionUtils.isNotEmpty(fileInfoList)){
//保存前先删一下历史附件
OerAnnexEntity delete = new OerAnnexEntity();
//delete.setGsdm(Constant.CONFIGMAP.get("gsdm"));
delete.setKjnd(kjnd);
delete.setMlid(mlid);
//oerAnnexService.deleteAnnex(delete);
int no = 1;
for (FileInfoDTO fileInfo : fileInfoList) {
try {
AttachmentFileEntity fileEntity = new AttachmentFileEntity();
String fileName = URLDecoder.decode(fileInfo.getFile_name(), "UTF-8");
fileEntity.setaTFileName(fileName);
fileEntity.setaTFile(fileInfo.getData());
this.saveAttachment(fileEntity);
//保存附件关系
OerAnnexEntity annexEntity = new OerAnnexEntity();
annexEntity.setMlid(mlid);
annexEntity.setKjnd(kjnd);
annexEntity.setAnnexName(fileName);
annexEntity.setAnnexSize(Convert.toLong(fileInfo.getFile_size()));
annexEntity.setOnlyid(fileEntity.getaTGuid());
annexEntity.setXh(String.valueOf(no));
oerAnnexService.saveAnnex(annexEntity);
no++;
}catch (Exception e){
logger.error("保存附件到grp出错:{}",e);
}
}
}
}catch (Exception e){
logger.error("保存附件到grp出错:{}",e);
}
}
}
private List<FileInfoDTO> fileDownload(List<JSONObject> fileList){
String dir = "1";
List<FileInfoDTO> files = new ArrayList<>();
//1下载附件
for (JSONObject fileObj : fileList) {
try {
FileInfoDTO fileInfoDTO = new FileInfoDTO();
String url = fileObj.getString("url");
String fileName = URLDecoder.decode(fileObj.getString("fileName"));
File file = HttpUtil.downloadFileFromUrl(url, dir);
if (null != file){
String zipPath = dir + File.separator + fileName.split("\\.")[0] + ".zip";
ZipOutputStream zos = new ZipOutputStream(new FileOutputStream(zipPath), Charset.forName("GBK"));
writeZipFile(file, zos,fileName);
zos.close();
// 获取压缩文件的字节数组
File zipFile = new File(zipPath);
ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream((int) zipFile.length());
BufferedInputStream bufferedInputStream = new BufferedInputStream(new FileInputStream(zipFile));
int buf_size = 1024;
byte[] buffer = new byte[buf_size];
int len = 0;
while (-1 != (len = bufferedInputStream.read(buffer, 0, buf_size))) {
byteArrayOutputStream.write(buffer, 0, len);
}
byte[] fileByte = byteArrayOutputStream.toByteArray();
fileInfoDTO.setData(fileByte);
fileInfoDTO.setFile_size(fileObj.getString("size"));
fileInfoDTO.setFile_name(fileName);
files.add(fileInfoDTO);
}
}catch (Exception e){
logger.error("上传附件出错:{}",e);
}
}
return files;
}
private void writeZipFile(File file,ZipOutputStream zos,String fileName){
if (null != file && null !=zos){
try {
logger.info("=====压缩文件=====");
zos.putNextEntry(new ZipEntry(fileName));
FileInputStream fos = new FileInputStream(file);
BufferedInputStream bis = new BufferedInputStream(fos);
int len;
byte[] buf = new byte[1024];
while ((len = bis.read(buf, 0, 1024)) != -1) {
zos.write(buf, 0, len);
}
bis.close();
fos.close();
logger.info("=====压缩完成=====");
}catch (Exception e){
e.printStackTrace();
logger.error("=====压缩文件出错=====");
}
}
}
}

View File

@ -0,0 +1,14 @@
package com.hzya.frame.grpU8.nxproof.controlindex.dao;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity;
import java.util.List;
public interface IControlIndexDao extends IBaseDao<ControlIndexEntity,String> {
//根据状态查询数据
List<ControlIndexEntity> queryControlIndexByStatus(ControlIndexEntity controlIndexEntity);
}

View File

@ -0,0 +1,18 @@
package com.hzya.frame.grpU8.nxproof.controlindex.dao.impl;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import com.hzya.frame.grpU8.nxproof.controlindex.dao.IControlIndexDao;
import com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity;
import org.springframework.stereotype.Repository;
import java.util.List;
@Repository(value = "controlIndexDaoImpl")
public class ControlIndexDaoImpl extends MybatisGenericDao<ControlIndexEntity,String> implements IControlIndexDao {
@Override
public List<ControlIndexEntity> queryControlIndexByStatus(ControlIndexEntity controlIndexEntity) {
List<ControlIndexEntity> list =(List<ControlIndexEntity>) super.selectList("ControlIndexEntity_list_base", controlIndexEntity);
return list;
}
}

View File

@ -0,0 +1,71 @@
package com.hzya.frame.grpU8.nxproof.controlindex.entity;
import com.hzya.frame.web.entity.BaseEntity;
public class ControlIndexEntity extends BaseEntity {
private String YSDH;
private String ZBID;
private int JE;
private String KJND;
private String ZT;
private String ZCMC;
private String ZBTBZT;
public String getZBTBZT() {
return ZBTBZT;
}
public void setZBTBZT(String ZBTBZT) {
this.ZBTBZT = ZBTBZT;
}
public String getYSDH() {
return YSDH;
}
public void setYSDH(String YSDH) {
this.YSDH = YSDH;
}
public String getZBID() {
return ZBID;
}
public void setZBID(String ZBID) {
this.ZBID = ZBID;
}
public int getJE() {
return JE;
}
public void setJE(int JE) {
this.JE = JE;
}
public String getKJND() {
return KJND;
}
public void setKJND(String KJND) {
this.KJND = KJND;
}
public String getZT() {
return ZT;
}
public void setZT(String ZT) {
this.ZT = ZT;
}
public String getZCMC() {
return ZCMC;
}
public void setZCMC(String ZCMC) {
this.ZCMC = ZCMC;
}
}

View File

@ -0,0 +1,158 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.grpU8.nxproof.controlindex.dao.impl.ControlIndexDaoImpl">
<resultMap id="get-ControlIndexEntity-result" type="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
<result property="YSDH" column="YSDH" />
<result property="ZBID" column="ZBID" />
<result property="JE" column="JE" />
<result property="KJND" column="KJND" />
<result property="ZT" column="ZT" />
<result property="ZCMC" column="ZCMC"/>
<result property="ZBTBZT" column="ZBTBZT"/>
</resultMap>
<sql id="ControlIndexEntity_Base_Column_List">
YSDH,ZBID,JE,KJND,ZT,ZCMC,ZBTBZT
</sql>
<!--根据状态查询数据-->
<select id="ControlIndexEntity_list_base" resultMap="get-ControlIndexEntity-result" parameterType="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
select
YSDH,ZBID,JE,KJND,ZT,ZCMC,ZBTBZT
from T_ZCCW_CONTROLINDEX where ZT= #{ZT}
</select>
<!-- 查询最大单据编号+1-->
<select id="ControlIndexEntity_list_base_djbhMax" resultMap="get-ControlIndexEntity-result" parameterType="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
select
case when
len(isnull(max(right(DJBH,'4')), '0')+1)=2 then
concat(#{fph}+'BXD'+#{djdate}+'00',isnull(max(right(DJBH,'4')), '0')+1)
when len(isnull(max(right(DJBH,'4')), '0')+1)=1 then
concat(#{fph}+'BXD'+#{djdate}+'000',isnull(max(right(DJBH,'4')), '0')+1)
when len(isnull(max(right(DJBH,'4')), '0')+1)=3 then
concat(#{fph}+'BXD'+#{djdate}+'0',isnull(max(right(DJBH,'4')), '0')+1)
else concat(#{fph}+'BXD'+#{djdate}+'',isnull(max(right(DJBH,'4')), '0')+1) end
as djbh from T_ZCCW_CONTROLINDEX where GSDM=#{gsdm} and DJBH like '%BXD'+#{djdate}+'%';
</select>
<!-- 查询最大mlid+1-->
<!--<select id="ControlIndexEntity_list_base_mlidMax" resultMap="get-ControlIndexEntity-result" parameterType="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
select
case when
length(ifnull(max(right(mlid,'4')), '0')+1)=2 then
concat(concat(substring(replace(DATE_FORMAT(now(),'%Y-%m-%d'),'-',''),1,6),'00'),ifnull(max(right(mlid,'4')), '0')+1)
when length(ifnull(max(right(mlid,'4')), '0')+1)=1 then
concat(concat(substring(replace(DATE_FORMAT(now(),'%Y-%m-%d'),'-',''),1,6),'000'),ifnull(max(right(mlid,'4')), '0')+1)
when length(ifnull(max(right(mlid,'4')), '0')+1)=3 then
concat(concat(substring(replace(DATE_FORMAT(now(),'%Y-%m-%d'),'-',''),1,6),'0'),ifnull(max(right(mlid,'4')), '0')+1)
else concat(substring(replace(DATE_FORMAT(now(),'%Y-%m-%d'),'-',''),1,6),ifnull(max(right(mlid,'4')), '0')+1) end
as mlId from T_ZCCW_CONTROLINDEX where GSDM=#{gsdm} and mlid like concat(substring(replace(DATE_FORMAT(now(),'%Y-%m-%d'),'-',''),1,6),'%')
</select>-->
<select id="ControlIndexEntity_list_base_mlidMax" resultMap="get-ControlIndexEntity-result" parameterType="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
select (isnull(max(MLID),concat(substring(#{djdate},0,7),0000)) + 1) as mlId
from T_ZCCW_CONTROLINDEX where 1=1 and GSDM=#{gsdm} and MLID like concat(substring(#{djdate},0,7),'%')
</select>
<insert id="ControlIndexEntity_insert" parameterType="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
insert into T_ZCCW_CONTROLINDEX(
<if test="gsdm != null and gsdm !='' "> GSDM, </if>
<if test="kjnd != null and kjnd !='' "> KJND, </if>
<if test="djlxId != null and djlxId !='' "> DJLXID, </if>
<if test="mlId != null and mlId !='' "> MLID, </if>
<if test="zt != null and zt !='' "> ZT, </if>
<if test="crerdm != null and crerdm !=''"> CRerDM, </if>
<if test="crermc != null and crermc !='' "> CRerMC, </if>
<if test="crerdate != null and crerdate !='' "> CRerDate, </if>
<if test="flowcode != null and flowcode !='' "> FlowCode,</if>
<if test="curshjd != null and curshjd !='' "> CurSHJD, </if>
<if test="nextshjd != null and nextshjd !='' "> NextSHJD,</if>
<if test="shrs != null and shrs !='' "> SHR,</if>
<if test="shrId != null and shrId !=''"> SHRID, </if>
<if test="shrq != null and shrq !='' "> SHRQ, </if>
<if test="jsfs != null and jsfs !='' "> JSFS, </if>
<if test="djbh != null and djbh !='' "> DJBH, </if>
<if test="djdate != null and djdate !='' "> DJDate, </if>
<if test="fjs != null and fjs !='' "> FJS,</if>
<if test="bmdm != null and bmdm !='' "> BMDM, </if>
<if test="bmmc != null and bmmc !='' "> BMMC,</if>
<if test="grdm != null and grdm !='' ">GRDM, </if>
<if test="grmc != null and grmc !='' ">GRMC,</if>
<if test="tel != null and tel !='' "> TEL, </if>
<if test="yjje != null and yjje !='' "> YJJE, </if>
<if test="thje != null and thje !='' "> THJE,</if>
<if test="blje != null and blje !='' "> BLJE, </if>
<if test="je != null and je !='' "> JE, </if>
<if test="whje != null and whje !='' "> WHJE,</if>
<if test="jedx != null and jedx !='' "> JEDX </if>
)
values (
<if test="gsdm != null and gsdm !='' "> #{gsdm}, </if>
<if test="kjnd != null and kjnd !='' "> #{kjnd}, </if>
<if test="djlxId != null and djlxId !='' "> ${djlxId}, </if>
<if test="mlId != null and mlId !='' "> ${mlId}, </if>
<if test="zt != null and zt !='' "> #{zt}, </if>
<if test="crerdm != null and crerdm !=''"> #{crerdm}, </if>
<if test="crermc != null and crermc !='' "> #{crermc}, </if>
<if test="crerdate != null and crerdate !='' "> #{crerdate}, </if>
<if test="flowcode != null and flowcode !='' "> #{flowcode},</if>
<if test="curshjd != null and curshjd !='' "> ${curshjd}, </if>
<if test="nextshjd != null and nextshjd !='' "> ${nextshjd},</if>
<if test="shrs != null and shrs !='' "> #{shrs}, </if>
<if test="shrId != null and shrId !='' "> #{shrId}, </if>
<if test="shrq != null and shrq !='' "> #{shrq}, </if>
<if test="jsfs != null and jsfs !='' "> #{jsfs}, </if>
<if test="djbh != null and djbh !='' "> #{djbh}, </if>
<if test="djdate != null and djdate !='' "> #{djdate}, </if>
<if test="fjs != null and fjs !='' "> ${fjs},</if>
<if test="bmdm != null and bmdm !='' "> #{bmdm}, </if>
<if test="bmmc != null and bmmc !='' "> #{bmmc},</if>
<if test="grdm != null and grdm !='' "> #{grdm}, </if>
<if test="grmc != null and grmc !='' "> #{grmc},</if>
<if test="tel != null and tel !='' "> #{tel}, </if>
<if test="yjje != null and yjje !='' "> #{yjje}, </if>
<if test="thje != null and thje !='' "> #{thje},</if>
<if test="blje != null and blje !='' "> #{blje}, </if>
<if test="je != null and je !='' "> #{je}, </if>
<if test="whje != null and whje !='' "> #{whje},</if>
<if test="jedx != null and jedx !='' "> #{jedx} </if>
)
</insert>
<update id="ControlIndexEntity_update" parameterType="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
update T_ZCCW_CONTROLINDEX set ZBTBZT= #{ZBTBZT}
where KJND = #{KJND} and YSDH=#{YSDH} and ZBID=${ZBID}
</update>
<!--删除,用于单据删除时使用-->
<delete id="ControlIndexEntity_delete" parameterType="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
DELETE
FROM
T_ZCCW_CONTROLINDEX
WHERE
GSDM = #{gsdm}
AND KJND = #{kjnd}
AND DJLXID = #{djlxId}
AND MLID = #{mlId}
</delete>
<!--修改 用于单据送审和审批时使用-->
<update id="ControlIndexEntity_update_songs" parameterType="com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity">
UPDATE T_ZCCW_CONTROLINDEX
SET ZT = #{zt},
FlowCode = #{flowcode},
CurSHJD =#{curshjd},
NextSHJD = #{nextshjd},
SHRID =#{shrId},
SHR = #{shrs},
SHRQ = #{shrq}
WHERE
gsdm = #{gsdm}
AND kjnd = #{kjnd}
AND djlxid = #{djlxId}
AND mlid = #{mlId}
</update>
</mapper>

View File

@ -0,0 +1,7 @@
package com.hzya.frame.grpU8.nxproof.controlindex.service;
public interface IControlIndexService {
//查询数据库表状态为1的数据写入指标执行表
String queryControlIndexByStatus(String status);
}

View File

@ -0,0 +1,158 @@
package com.hzya.frame.grpU8.nxproof.controlindex.service.impl;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.date.DateUtil;
import com.hzya.frame.grpU8.nxproof.controlindex.entity.ControlIndexEntity;
import com.hzya.frame.grpU8.nxproof.controlindex.service.IControlIndexService;
import com.hzya.frame.grpU8.nxproof.gbizbsyrec.dao.IGbiZbsyrecDao;
import com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity;
import com.hzya.frame.grpU8.nxproof.oerdjml.dao.IOerDjmlDao;
import com.hzya.frame.grpU8.nxproof.oerdjml.entity.OerDjmlEntity;
import com.hzya.frame.web.exception.BaseSystemException;
import org.apache.ibatis.session.SqlSession;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;
import java.util.Date;
import java.util.List;
@Service(value = "controlIndexServiceImpl")
public class ControlIndexServiceImpl implements IControlIndexService {
private static Logger logger= LogManager.getLogger(ControlIndexServiceImpl.class);
@Autowired
private IGbiZbsyrecDao gbiZbsyrecDao;
@Autowired
private IOerDjmlDao oerDjmlDao;
/*@Autowired
@Qualifier("sqlSessionMaster")
private SqlSession sqlSession;*/
//查询数据库表状态为1的数据写入指标执行表
@Override
public String queryControlIndexByStatus(String stauts) {
ControlIndexEntity controlIndexEntity=new ControlIndexEntity();
List<ControlIndexEntity> controlIndexEntities=null;
OerDjmlEntity oerDjmlEntity=new OerDjmlEntity();
oerDjmlEntity.setGsdm("001");
oerDjmlEntity.setDjlxId("102");
switch (stauts){
case "1":
logger.info("========开始查询数据库表状态为1的数据========");
controlIndexEntity.setZT("1");
// controlIndexEntities= sqlSession.selectList("ControlIndexEntity_list_base", controlIndexEntity);
logger.info("根据状态为1查询出来的数据有{}条",controlIndexEntities.size());
if(CollUtil.isNotEmpty(controlIndexEntities) && controlIndexEntities.size()>0){
for (ControlIndexEntity indexEntity : controlIndexEntities) {
logger.info("循环遍历中得验收单号为:{}",indexEntity.getYSDH());
if(null == indexEntity.getYSDH() || null ==indexEntity.getZBID()){
throw new BaseSystemException("验收单号或者指标id不能为空");
}
//将查询出来的状态为1的数据写入到指标占用表中
GbiZbsyrecEntity gbiZbsyrecEntity=new GbiZbsyrecEntity();
gbiZbsyrecEntity.setDjId(indexEntity.getYSDH());//单据id
logger.info("开始根据编号查询指标占用表的数据");
//根据编号查询指标占用表里面是否存在数据如果存在则不新增
GbiZbsyrecEntity gbiZbsyrecEntityOne =(GbiZbsyrecEntity) gbiZbsyrecDao.selectOne("GbiZbsyrecEntity_list_base_one", gbiZbsyrecEntity);
if(null ==gbiZbsyrecEntityOne || !indexEntity.getYSDH().equals(gbiZbsyrecEntityOne.getDjId())) {
logger.info("验收单号:{}在指标占用表中不存在,开始保存到占用表中",indexEntity.getYSDH());
try {
gbiZbsyrecEntity.setJhId(indexEntity.getZBID());//指标id
gbiZbsyrecEntity.setDjje(String.valueOf(indexEntity.getJE()));//金额
gbiZbsyrecEntity.setKjnd(indexEntity.getKJND());
gbiZbsyrecEntity.setGsdm("001");//公司代码
gbiZbsyrecEntity.setModule("OER");//模块
gbiZbsyrecEntity.setDjlx("102");//单据类型
gbiZbsyrecEntity.setDjflh("148001");//单据分录数
gbiZbsyrecEntity.setDjzt(indexEntity.getZT());
gbiZbsyrecEntity.setSzfx("1");
gbiZbsyrecEntity.setJdzb("0");
gbiZbsyrecEntity.setCzlx("0");
gbiZbsyrecEntity.setDjflmx(indexEntity.getYSDH());
gbiZbsyrecDao.save(gbiZbsyrecEntity);
//保存报销单
oerDjmlEntity.setDjdate(DateUtil.formatDate(new Date()).replace("-",""));
String djbh = oerDjmlDao.getMaxDjbgByGsdmZy(oerDjmlEntity);
oerDjmlEntity.setDjbh(djbh);
oerDjmlEntity.setMlId(indexEntity.getYSDH());
oerDjmlEntity.setKjnd(indexEntity.getKJND());
oerDjmlEntity.setZt("1");
oerDjmlEntity.setJe(String.valueOf(indexEntity.getJE()));
oerDjmlEntity.setGrdm("123456");
oerDjmlEntity.setGrmc("占用测试");
//oerDjmlEntity.setJedx(AmountConvert.toChinese(String.valueOf(indexEntity.getJE())));
OerDjmlEntity save = oerDjmlDao.save(oerDjmlEntity);
logger.info("验收单号:{}在指标占用表中占用成功",indexEntity.getYSDH());
if(save!=null){
//修改T_ZCCW_CONTROLINDEX的指标同步状态为1
indexEntity.setZBTBZT("1");
logger.info("保存中开始根据验收单号:{},会计年度:{},指标id{}更新指标同步状态",indexEntity.getYSDH(),indexEntity.getKJND(),indexEntity.getZBID());
// sqlSession.update("ControlIndexEntity_update",indexEntity);
}
}catch (Exception e){
logger.info("指标占用失败:{}",e.getMessage());
}
}else{
logger.info("验收单号:{}在指标占用表中已经存在,不再保存到占用表中",indexEntity.getYSDH());
}
}
}else {
logger.info("========没有查询到状态为1需要写入指标占用表的数据========");
return null;
}
break;
case "3":
logger.info("========开始查询数据库表状态为3的数据========");
controlIndexEntity.setZT("3");
// controlIndexEntities= sqlSession.selectList("ControlIndexEntity_list_base", controlIndexEntity);
logger.info("根据状态为3查询出来的数据有{}条",controlIndexEntities.size());
if(CollUtil.isNotEmpty(controlIndexEntities) && controlIndexEntities.size()>0){
for (ControlIndexEntity indexEntity : controlIndexEntities) {
if(null == indexEntity.getYSDH() || null ==indexEntity.getZBID()){
throw new BaseSystemException("验收单号或者指标id不能为空");
}
GbiZbsyrecEntity gbiZbsyrecEntity=new GbiZbsyrecEntity();
gbiZbsyrecEntity.setDjId(indexEntity.getYSDH());
//根据编号查询指标占用表中是否存在存在就删除
GbiZbsyrecEntity gbiZbsyrecEntityOne =(GbiZbsyrecEntity) gbiZbsyrecDao.selectOne("GbiZbsyrecEntity_list_base_one", gbiZbsyrecEntity);
if(null !=gbiZbsyrecEntityOne && indexEntity.getYSDH().equals(gbiZbsyrecEntityOne.getDjId())) {
logger.info("验收单号:{}在指标占用表中存在,开始删除指标占用表",indexEntity.getYSDH());
try {
//根据编号删除指标占用表
gbiZbsyrecEntity.setKjnd(indexEntity.getKJND());
logger.info("指标占用表中的djid为:{},会计年度为:{}",gbiZbsyrecEntity.getDjId(),gbiZbsyrecEntity.getKjnd());
gbiZbsyrecDao.delete("GbiZbsyrecEntity_delete",gbiZbsyrecEntity);
//根据编号删除报销单
oerDjmlEntity.setKjnd(indexEntity.getKJND());
oerDjmlEntity.setMlId(indexEntity.getYSDH());
logger.info("报销单中的mlid为{},会计年度为:{},公司代码为:{}单据类型id为{}",oerDjmlEntity.getMlId(),oerDjmlEntity.getKjnd(),oerDjmlEntity.getGsdm(),oerDjmlEntity.getDjlxId());
int delete = oerDjmlDao.delete("OerDjmlEntity_delete", oerDjmlEntity);
logger.info("根据验收单号:{}在指标占用表中已删除",indexEntity.getYSDH());
if(delete>0){
//修改T_ZCCW_CONTROLINDEX的指标同步状态为1
indexEntity.setZBTBZT("1");
logger.info("删除中开始根据验收单号:{},会计年度:{},指标id{}更新指标同步状态",indexEntity.getYSDH(),indexEntity.getKJND(),indexEntity.getZBID());
// sqlSession.update("ControlIndexEntity_update",indexEntity);
}
}catch (Exception e){
logger.info("指标删除失败:{}",e.getMessage());
}
}else {
logger.info("验收单号:{}在指标占用表中不存在",indexEntity.getYSDH());
}
}
}else {
logger.info("========没有查询到状态为3需要删除指标占用表的数据========");
return null;
}
break;
default:
break;
}
return null;
}
}

View File

@ -0,0 +1,18 @@
package com.hzya.frame.grpU8.nxproof.gbizbsyrec.dao;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity;
/**
* @Author:hecan
* @Description:
* @params:
* @return:
* @Date: 2023/6/19 14:47
*/
public interface IGbiZbsyrecDao extends IBaseDao<GbiZbsyrecEntity,String> {
Integer deleteData(GbiZbsyrecEntity oeryszb);
Integer saveData(GbiZbsyrecEntity oeryszb);
}

View File

@ -0,0 +1,31 @@
package com.hzya.frame.grpU8.nxproof.gbizbsyrec.dao.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import com.hzya.frame.grpU8.nxproof.gbizbsyrec.dao.IGbiZbsyrecDao;
import com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity;
import org.springframework.stereotype.Repository;
/**
* @Author:hecan
* @Description:
* @params:
* @return:
* @Date: 2023/6/19 14:48
*/
@Repository(value = "gbiZbsyrecDao")
public class GbiZbsyrecDaoImpl extends MybatisGenericDao<GbiZbsyrecEntity,String> implements IGbiZbsyrecDao {
@DS("#entity.dataSourceCode")
@Override
public Integer deleteData( GbiZbsyrecEntity entity) {
Integer o = super.delete(getSqlIdPrifx() + "GbiZbsyrecEntity_delete_mlid", entity);
return o;
}
@DS("#entity.dataSourceCode")
@Override
public Integer saveData( GbiZbsyrecEntity entity) {
Integer o = super.insert(getSqlIdPrifx() + "GbiZbsyrecEntity_insert", entity);
return o;
}
}

View File

@ -0,0 +1,186 @@
package com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity;
import com.hzya.frame.web.entity.BaseEntity;
import lombok.*;
/**
* @Author:hecan
* @Description:指标使用记录表
* @params:
* @return:
* @Date: 2023/6/16 22:04
*/
public class GbiZbsyrecEntity extends BaseEntity {
private String gsdm;//公司代码
private String kjnd;//会计年度
private String module;
private String djlx;
private String djId;
private String djflh;
private String djflmx;
private String djywrq;//单据日期
private String djzt;
private String jhId;//计划id
private String djje;//金额
private String sl;
private String djzy;//摘要
private String szfx;
private String zblb;
private String jdzb;
private String czlx;
private String zzbz;
private String ywdjId;
public String getGsdm() {
return gsdm;
}
public void setGsdm(String gsdm) {
this.gsdm = gsdm;
}
public String getKjnd() {
return kjnd;
}
public void setKjnd(String kjnd) {
this.kjnd = kjnd;
}
public String getModule() {
return module;
}
public void setModule(String module) {
this.module = module;
}
public String getDjlx() {
return djlx;
}
public void setDjlx(String djlx) {
this.djlx = djlx;
}
public String getDjId() {
return djId;
}
public void setDjId(String djId) {
this.djId = djId;
}
public String getDjflh() {
return djflh;
}
public void setDjflh(String djflh) {
this.djflh = djflh;
}
public String getDjflmx() {
return djflmx;
}
public void setDjflmx(String djflmx) {
this.djflmx = djflmx;
}
public String getDjywrq() {
return djywrq;
}
public void setDjywrq(String djywrq) {
this.djywrq = djywrq;
}
public String getDjzt() {
return djzt;
}
public void setDjzt(String djzt) {
this.djzt = djzt;
}
public String getJhId() {
return jhId;
}
public void setJhId(String jhId) {
this.jhId = jhId;
}
public String getDjje() {
return djje;
}
public void setDjje(String djje) {
this.djje = djje;
}
public String getSl() {
return sl;
}
public void setSl(String sl) {
this.sl = sl;
}
public String getDjzy() {
return djzy;
}
public void setDjzy(String djzy) {
this.djzy = djzy;
}
public String getSzfx() {
return szfx;
}
public void setSzfx(String szfx) {
this.szfx = szfx;
}
public String getZblb() {
return zblb;
}
public void setZblb(String zblb) {
this.zblb = zblb;
}
public String getJdzb() {
return jdzb;
}
public void setJdzb(String jdzb) {
this.jdzb = jdzb;
}
public String getCzlx() {
return czlx;
}
public void setCzlx(String czlx) {
this.czlx = czlx;
}
public String getZzbz() {
return zzbz;
}
public void setZzbz(String zzbz) {
this.zzbz = zzbz;
}
public String getYwdjId() {
return ywdjId;
}
public void setYwdjId(String ywdjId) {
this.ywdjId = ywdjId;
}
}

View File

@ -0,0 +1,173 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.grpU8.nxproof.gbizbsyrec.dao.impl.GbiZbsyrecDaoImpl">
<resultMap id="get-GbiZbsyrecEntity-result" type="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
<result property="module" column="module" jdbcType="VARCHAR"/>
<result property="djlx" column="djlx" />
<result property="gsdm" column="gsdm" />
<result property="kjnd" column="kjnd" />
<result property="djId" column="djId" />
<result property="djflh" column="djflh"/>
<result property="djflmx" column="djflmx" />
<result property="djywrq" column="djywrq" />
<result property="djzt" column="djzt" />
<result property="jhId" column="jhId" />
<result property="djje" column="djje" />
<result property="sl" column="sl" />
<result property="djzy" column="djzy" />
<result property="szfx" column="szfx" />
<result property="zblb" column="zblb" />
<result property="jdzb" column="jdzb" />
<result property="czlx" column="czlx" />
<result property="zzbz" column="zzbz" />
<result property="ywdjId" column="ywdjId" />
</resultMap>
<sql id="gbiZbsyrecEntity_Base_Column_List">
GSDM,KJND
</sql>
<select id="GbiZbsyrecEntity_list_base" resultMap="get-GbiZbsyrecEntity-result" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
select
*
from
GBI_ZBSYREC
<trim prefix="where" prefixOverrides="and">
<if test="gsdm != null and gsdm !='' "> GSDM = #{gsdm} </if>
<if test="kjnd != null and kjnd !='' "> and KJND = #{kjnd} </if>
<if test="module != null and module !='' "> and MODULE = #{module} </if>
<if test="djlx != null and djlx !='' "> and DJLX = #{djlx} </if>
<if test="djId != null and djId !='' ">and DJID =#{djId} </if>
<if test="djflh != null and djflh !=''"> and DJFLH =#{djflh} </if>
<if test="djflmx != null and djflmx !='' ">and DJFLMX =#{djflmx}</if>
<if test="djywrq != null and djywrq !='' ">and DJYWRQ =#{djywrq} </if>
<if test="djzt != null and djzt !='' ">and DJZT =#{djzt}</if>
<if test="jhId != null and jhId !='' ">and JHID =#{jhId} </if>
<if test="djje != null and djje !='' ">and DJJE =#{djje}</if>
<if test="sl != null and sl !=''">and SL =#{sl} </if>
<if test="djzy != null and djzy !='' ">and DJZY =#{djzy} </if>
<if test="szfx != null and szfx !='' ">and SZFX =#{szfx} </if>
<if test="zblb != null and zblb !='' ">and ZBLB =#{zblb} </if>
<if test="jdzb != null and jdzb !='' ">and JDBZ =#{jdzb} </if>
<if test="czlx != null and czlx !='' ">and CZLX =#{czlx} </if>
<if test="zzbz != null and zzbz !='' ">and ZZBZ =#{zzbz}</if>
<if test="ywdjId != null and ywdjId !='' ">and YWDJID =#{ywdjId} </if>
</trim>
</select>
<!--根据业务参考号查询单个数据-->
<select id="GbiZbsyrecEntity_list_base_one" resultMap="get-GbiZbsyrecEntity-result" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
select
*
from
GBI_ZBSYREC
where DJID= #{djId}
</select>
<insert id="GbiZbsyrecEntity_insert" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
insert into GBI_ZBSYREC(
<if test="ywdjId != null and ywdjId !='' "> YWDJID,</if>
<if test="kjnd != null and kjnd !='' "> KJND, </if>
<if test="module != null and module !='' "> MODULE, </if>
<if test="djlx != null and djlx !='' "> DJLX, </if>
<if test="djId != null and djId !='' "> DJID, </if>
<if test="djflh != null and djflh !=''"> DJFLH, </if>
<if test="djflmx != null and djflmx !='' "> DJFLMX, </if>
<if test="djywrq != null and djywrq !='' "> DJYWRQ, </if>
<if test="djzt != null and djzt !='' "> DJZT,</if>
<if test="jhId != null and jhId !='' "> JHID, </if>
<if test="djje != null and djje !='' "> DJJE ,</if>
<if test="sl != null and sl !=''"> SL, </if>
<if test="djzy != null and djzy !='' "> DJZY, </if>
<if test="szfx != null and szfx !='' "> SZFX, </if>
<if test="zblb != null and zblb !='' "> ZBLB, </if>
<if test="jdzb != null and jdzb !='' "> JDBZ, </if>
<if test="czlx != null and czlx !='' "> CZLX, </if>
<if test="zzbz != null and zzbz !='' "> ZZBZ,</if>
<if test="gsdm != null and gsdm !='' "> GSDM</if>
)
values (
<if test="ywdjId != null and ywdjId !='' "> #{ywdjId},</if>
<if test="kjnd != null and kjnd !='' "> #{kjnd}, </if>
<if test="module != null and module !='' "> #{module}, </if>
<if test="djlx != null and djlx !='' "> #{djlx}, </if>
<if test="djId != null and djId !='' "> #{djId}, </if>
<if test="djflh != null and djflh !=''"> #{djflh}, </if>
<if test="djflmx != null and djflmx !='' "> #{djflmx}, </if>
<if test="djywrq != null and djywrq !='' "> #{djywrq}, </if>
<if test="djzt != null and djzt !='' "> #{djzt},</if>
<if test="jhId != null and jhId !='' "> #{jhId}, </if>
<if test="djje != null and djje !='' "> #{djje},</if>
<if test="sl != null and sl !=''"> #{sl}, </if>
<if test="djzy != null and djzy !='' "> #{djzy}, </if>
<if test="szfx != null and szfx !='' "> #{szfx}, </if>
<if test="zblb != null and zblb !='' "> #{zblb}, </if>
<if test="jdzb != null and jdzb !='' "> #{jdzb}, </if>
<if test="czlx != null and czlx !='' "> #{czlx}, </if>
<if test="zzbz != null and zzbz !='' "> #{zzbz},</if>
<if test="gsdm != null and gsdm !='' "> #{gsdm}</if>
)
</insert>
<delete id="GbiZbsyrecEntity_delete" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
delete from GBI_ZBSYREC where KJND=#{kjnd} and DJID= #{djId}
</delete>
<delete id="GbiZbsyrecEntity_delete_gsp" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
delete FROM gbi_zbsyrec where GSDM =#{gsdm} and KJND=#{kjnd} and MODULE='GSP' and abs(DJFLMX)=${djflmx} AND DJJE > 0
</delete>
<delete id="GbiZbsyrecEntity_delete_oer" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
delete FROM gbi_zbsyrec where GSDM =#{gsdm} and KJND=#{kjnd} and MODULE='OER' and djlx=#{djlx} and djid=#{djId} AND DJFLMX=#{djflmx}
</delete>
<delete id="GbiZbsyrecEntity_delete_mlid" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
delete FROM gbi_zbsyrec where GSDM =#{gsdm} and KJND=#{kjnd} and djid=#{djId}
</delete>
<!--删除 单据删除时使用-->
<delete id="GbiZbsyrecEntity_delete_del" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
DELETE
FROM
gbi_zbsyrec
WHERE
GSDM = #{gsdm}
AND KJND = #{kjnd}
AND (
(
MODULE = #{module}
AND DJFLMX = #{djflmx}
)
OR (
MODULE = #{module}
AND DJFLMX =#{djflmx}
)
);
</delete>
<!--删除 单据删除时使用-->
<delete id="GbiZbsyrecEntity_delete_dels" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
DELETE
FROM
gbi_zbsyrec
WHERE
GSDM = #{gsdm}
AND KJND = #{kjnd}
AND (MODULE = #{module} OR MODULE = #{module})
AND abs(DJFLMX) = #{djflmx}
</delete>
<!-- 修改 单据送审时使用 -->
<update id="GbiZbsyrecEntity_update" parameterType="com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity">
UPDATE GBI_ZBSYREC
SET DJZT = '1'
WHERE
GSDM = #{gsdm}
AND KJND = #{kjnd}
AND MODULE = #{module}
AND DJLX = #{djlx}
AND DJID = #{djId}
AND (DJFLMX = #{djflmx})
</update>
</mapper>

View File

@ -0,0 +1,11 @@
package com.hzya.frame.grpU8.nxproof.gbizbsyrec.service;
/**
* @Author:hecan
* @Description:指标使用记录
* @params:
* @return:
* @Date: 2023/6/19 14:27
*/
public interface IGbiZbsyrecService {
}

View File

@ -0,0 +1,15 @@
package com.hzya.frame.grpU8.nxproof.gbizbsyrec.service.impl;
import com.hzya.frame.grpU8.nxproof.gbizbsyrec.service.IGbiZbsyrecService;
import org.springframework.stereotype.Service;
/**
* @Author:hecan
* @Description:指标使用记录
* @params:
* @return:
* @Date: 2023/6/19 14:30
*/
@Service(value = "gbiZbsyrecService")
public class GbiZbsyrecServiceImpl implements IGbiZbsyrecService {
}

View File

@ -0,0 +1,41 @@
package com.hzya.frame.grpU8.nxproof.gbizbxmb.dao;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.grpU8.nxproof.gbizbsyrec.entity.GbiZbsyrecEntity;
import com.hzya.frame.grpU8.nxproof.gbizbxmb.entity.GbiZbxmbEntity;
import java.util.List;
public interface IGbiZbxmbDao extends IBaseDao<GbiZbxmbEntity, String> {
/**
*
* @content 查询指标id最大值加一和取指标代码 长度为8位不够用0补
* @Param
* @Return
* @Author hecan
* @Date 2024/8/6 11:52
* **/
GbiZbxmbEntity queryZbidAndZbdm(GbiZbxmbEntity gbiZbxmbEntity);
/**
*
* @content 部门修改时候修改指标项目表的部门名称
* @Param
* @Return
* @Author hecan
* @Date 2024/8/8 16:59
* **/
Integer updateZbmxBmmc(GbiZbxmbEntity gbiZbxmbEntity);
/**
*
* @content 根据idpzh查询指标id和指标金额
* @Param
* @Return
* @Author hecan
* @Date 2024/8/14 17:15
* **/
List<GbiZbxmbEntity> queryZbxmbByIdpzh(GbiZbxmbEntity gbiZbxmbEntity);
}

View File

@ -0,0 +1,40 @@
package com.hzya.frame.grpU8.nxproof.gbizbxmb.dao.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.grpU8.nxproof.gbizbxmb.entity.GbiZbxmbEntity;
import com.hzya.frame.grpU8.nxproof.gbizbxmb.dao.IGbiZbxmbDao;
import org.springframework.stereotype.Repository;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import java.util.List;
/**
* (GbiZbxmb)表数据库访问层
*
* @author makejava
* @since 2024-08-14 16:58:43
*/
@Repository(value = "GbiZbxmbDaoImpl")
public class GbiZbxmbDaoImpl extends MybatisGenericDao<GbiZbxmbEntity, String> implements IGbiZbxmbDao{
@Override
@DS("#gbiZbxmbEntity.dataSourceCode")
public GbiZbxmbEntity queryZbidAndZbdm(GbiZbxmbEntity gbiZbxmbEntity) {
return (GbiZbxmbEntity) super.selectOne("queryZbidAndZbdm", gbiZbxmbEntity);
}
@Override
@DS("#gbiZbxmbEntity.dataSourceCode")
public Integer updateZbmxBmmc(GbiZbxmbEntity gbiZbxmbEntity) {
int update = super.update("updateZbmxBmmc", gbiZbxmbEntity);
return update;
}
@Override
@DS("#gbiZbxmbEntity.dataSourceCode")
public List<GbiZbxmbEntity> queryZbxmbByIdpzh(GbiZbxmbEntity gbiZbxmbEntity) {
return (List<GbiZbxmbEntity>)super.selectList("queryZbxmbByIdpzh",gbiZbxmbEntity);
}
}

View File

@ -0,0 +1,42 @@
package com.hzya.frame.grpU8.nxproof.gbizbxmb.service;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.grpU8.nxproof.gbizbxmb.entity.GbiZbxmbEntity;
import com.hzya.frame.basedao.service.IBaseService;
/**
* (GbiZbxmb)表服务接口
*
* @author makejava
* @since 2024-08-14 16:58:44
*/
public interface IGbiZbxmbService extends IBaseService<GbiZbxmbEntity, String>{
/**
*
* @content 项目指标新增
* @Param
* @Return
* @Author hecan
* @Date 2024/8/6 11:39
* **/
Object saveGbiZbxmb(JSONObject jsonObject);
/**
*
* @content 项目指标更新
* @Param
* @Return
* @Author hecan
* @Date 2024/8/7 11:37
* **/
Object updateGbiZbxmb(JSONObject jsonObject);
/**
*
* @content 项目指标删除
* @Param
* @Return
* @Author hecan
* @Date 2024/8/7 14:50
* **/
Object deleteGbiZbxmb(JSONObject jsonObject);
}

View File

@ -0,0 +1,339 @@
package com.hzya.frame.grpU8.nxproof.gbizbxmb.service.impl;
import cn.hutool.core.util.StrUtil;
import com.alibaba.fastjson.JSONObject;
import com.hzya.frame.grpU8.nxproof.gbizbxmb.entity.GbiZbxmbEntity;
import com.hzya.frame.grpU8.nxproof.gbizbxmb.dao.IGbiZbxmbDao;
import com.hzya.frame.grpU8.nxproof.gbizbxmb.service.IGbiZbxmbService;
import com.hzya.frame.grpU8.nxproof.glczrz.dao.IGlCzrzDao;
import com.hzya.frame.grpU8.nxproof.glczrz.entity.GlCzrzEntity;
import com.hzya.frame.grpU8.nxproof.glfzxzl.dao.IGlFzxzlDao;
import com.hzya.frame.grpU8.nxproof.glfzxzl.entity.GlFzxzlEntity;
import com.hzya.frame.grpU8.nxproof.glxmzl.dao.ISenderGlXmzlDao;
import com.hzya.frame.grpU8.nxproof.glxmzl.entity.SenderGlXmzlEntity;
import com.hzya.frame.grpU8.nxproof.pubbmxx.dao.ISenderPubbmxxDao;
import com.hzya.frame.grpU8.nxproof.pubbmxx.entity.SenderPubbmxxEntity;
import com.hzya.frame.grpU8.nxproof.zbwhsz.dao.IZbWhszDao;
import com.hzya.frame.grpU8.nxproof.zbwhsz.entity.ZbWhszEntity;
import com.hzya.frame.grpU8.nxproof.zbzbly.dao.IZbZblyDao;
import com.hzya.frame.grpU8.nxproof.zbzbly.entity.ZbZblyEntity;
import com.hzya.frame.web.entity.BaseResult;
import com.hzya.frame.web.entity.JsonResultEntity;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService;
import java.util.UUID;
/**
* (GbiZbxmb)表服务实现类
*
* @author makejava
* @since 2024-08-14 16:58:44
*/
@Service(value = "gbiZbxmbService")
public class GbiZbxmbServiceImpl extends BaseService<GbiZbxmbEntity, String> implements IGbiZbxmbService {
private IGbiZbxmbDao gbiZbxmbDao;
@Autowired
private ISenderPubbmxxDao pubbmxxDao;
@Autowired
private ISenderGlXmzlDao glXmzlDao;
@Autowired
private IZbWhszDao zbWhszDao;
@Autowired
private IZbZblyDao zbZblyDao;
@Autowired
private IGlFzxzlDao glFzxzlDao;
@Autowired
private IGlCzrzDao glCzrzDao;
@Autowired
public void setGbiZbxmbDao(IGbiZbxmbDao dao) {
this.gbiZbxmbDao = dao;
this.dao = dao;
}
//保存项目指标
@Override
public Object saveGbiZbxmb(JSONObject json) {
JSONObject jsonObject = json.getJSONObject("jsonStr");
if(!checkStr(jsonObject.getString("gsdm"))){
return BaseResult.getFailureMessageEntity("请传递公司代码");
}
if(!checkStr(jsonObject.getString("kjnd"))){
return BaseResult.getFailureMessageEntity("请传递会计年度");
}
if(!checkStr(jsonObject.getString("zblb"))){
return BaseResult.getFailureMessageEntity("请传递指标类别");
}
GbiZbxmbEntity gbiZbxmbEntity = jsonObject.toJavaObject(GbiZbxmbEntity.class);
try {
//查询指标id最大值和指标代码最大值
GbiZbxmbEntity gbiZbxmbEntityZbid = gbiZbxmbDao.queryZbidAndZbdm(gbiZbxmbEntity);
gbiZbxmbEntity.setZbid(gbiZbxmbEntityZbid.getZbid());
gbiZbxmbEntity.setZbdm(gbiZbxmbEntityZbid.getZbdm());
}catch (Exception e){
logger.info("根据会计年度:{},公司代码:{},指标类别:{}获取指标id和指标代码失败:{}",
jsonObject.getString("kjnd"),jsonObject.getString("gsdm"),jsonObject.getString("zblb"),e.getMessage());
return BaseResult.getFailureMessageEntity("获取指标id和指标代码失败");
}
//更新其他表得使用状态
JsonResultEntity jsonResultEntity = updateOtherTable(gbiZbxmbEntity);
//保存指标项目表
try {
gbiZbxmbEntity.setZt("1");//状态为1为保存
gbiZbxmbEntity.setIdzbbh(String.valueOf(UUID.randomUUID()));//IDZBBH
gbiZbxmbEntity.setSfjz("0");//是否结转
gbiZbxmbEntity.setCyskzfs("0");//超预算控制方式
gbiZbxmbEntity.setYjbfb(100.00);//预警百分比
gbiZbxmbEntity.setPfrid(-1);//批复人id
gbiZbxmbEntity.setShrid(-1);//审核人id
gbiZbxmbEntity.setSjly(1);//数据来源
gbiZbxmbEntity.setXfzt("0");//下发状态
gbiZbxmbEntity.setNcysy(0.00);//年初已使用
gbiZbxmbEntity.setSjzbid(0);//上级指标id
logger.info("=========开始保存指标项目表=========");
GbiZbxmbEntity save = gbiZbxmbDao.save(gbiZbxmbEntity);
logger.info("==========指标项目表保存完毕======");
GlCzrzEntity glCzrzEntity=new GlCzrzEntity();
glCzrzEntity.setStation("yusuanzhibiaobaocun");
logger.info("==========开始查询操作日志的最大值no======");
GlCzrzEntity glCzrzEntityNo = glCzrzDao.queryCzrzNo(glCzrzEntity);
logger.info("根据station为:{}查询出来的no值为:{}",glCzrzEntity.getStation(),glCzrzEntityNo.getNo());
glCzrzEntity.setNo(glCzrzEntityNo.getNo());
glCzrzEntity.setName("0.指标保存");
glCzrzEntity.setCznr("增加指标"+gbiZbxmbEntity.getZbid()+"(MXZB)");
logger.info("==========开始保存操作日志======");
glCzrzDao.save(glCzrzEntity);
logger.info("==========操作日志保存完毕======");
JSONObject jsonObjectSave=new JSONObject();
jsonObjectSave.put("status","200");
jsonObjectSave.put("zbxm",save);
return jsonObjectSave;
}catch (Exception e){
logger.info("保存预算指标失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("保存指标失败");
}
}
@Override
public Object updateGbiZbxmb(JSONObject json) {
JSONObject jsonObject = json.getJSONObject("jsonStr");
if(!checkStr(jsonObject.getString("gsdm"))){
return BaseResult.getFailureMessageEntity("请传递公司代码");
}
if(!checkStr(jsonObject.getString("kjnd"))){
return BaseResult.getFailureMessageEntity("请传递会计年度");
}
if(!checkStr(jsonObject.getString("zblb"))){
return BaseResult.getFailureMessageEntity("请传递指标类别");
}
if(!checkStr(jsonObject.getString("zbid"))){
return BaseResult.getFailureMessageEntity("请传递指标id");
}
GbiZbxmbEntity gbiZbxmbEntity = jsonObject.toJavaObject(GbiZbxmbEntity.class);
try {
JsonResultEntity jsonResultEntity = updateOtherTable(gbiZbxmbEntity);
gbiZbxmbEntity.setZt("1");
gbiZbxmbEntity.setNcysy(0.00);//年初已使用
logger.info("=========开始更新指标项目表=========");
GbiZbxmbEntity save = gbiZbxmbDao.update(gbiZbxmbEntity);
logger.info("==========指标项目表更新完毕======");
GlCzrzEntity glCzrzEntity=new GlCzrzEntity();
glCzrzEntity.setStation("yusuanzhibiaobaocun");
logger.info("==========开始查询操作日志的最大值no======");
GlCzrzEntity glCzrzEntityNo = glCzrzDao.queryCzrzNo(glCzrzEntity);
logger.info("根据station为:{}查询出来的no值为:{}",glCzrzEntity.getStation(),glCzrzEntityNo.getNo());
glCzrzEntity.setNo(glCzrzEntityNo.getNo());
glCzrzEntity.setName("0.指标修改");
glCzrzEntity.setCznr("修改指标"+gbiZbxmbEntity.getZbid()+"(MXZB)");
logger.info("==========开始保存操作日志======");
glCzrzDao.save(glCzrzEntity);
logger.info("==========操作日志保存完毕======");
JSONObject jsonObjectUpdate =new JSONObject();
jsonObjectUpdate.put("status","200");
jsonObjectUpdate.put("zbxm",save);
return jsonObjectUpdate;
}catch (Exception e){
logger.info("更新预算指标失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("修改指标失败");
}
}
@Override
public Object deleteGbiZbxmb(JSONObject json) {
JSONObject jsonObject = json.getJSONObject("jsonStr");
if(!checkStr(jsonObject.getString("gsdm"))){
return BaseResult.getFailureMessageEntity("请传递公司代码");
}
if(!checkStr(jsonObject.getString("kjnd"))){
return BaseResult.getFailureMessageEntity("请传递会计年度");
}
if(!checkStr(jsonObject.getString("zblb"))){
return BaseResult.getFailureMessageEntity("请传递指标类别");
}
if(!checkStr(jsonObject.getString("zbid"))){
return BaseResult.getFailureMessageEntity("请传递指标id");
}
GbiZbxmbEntity gbiZbxmbEntity = jsonObject.toJavaObject(GbiZbxmbEntity.class);
try {
gbiZbxmbEntity.setZt("1");
logger.info("=========开始删除指标项目表=========");
int delete = gbiZbxmbDao.delete("entity_delete", gbiZbxmbEntity);
logger.info("==========指标项目表删除完毕======");
GlCzrzEntity glCzrzEntity=new GlCzrzEntity();
glCzrzEntity.setStation("yusuanzhibiaobaocun");
logger.info("==========开始查询操作日志的最大值no======");
GlCzrzEntity glCzrzEntityNo = glCzrzDao.queryCzrzNo(glCzrzEntity);
logger.info("根据station为:{}查询出来的no值为:{}",glCzrzEntity.getStation(),glCzrzEntityNo.getNo());
glCzrzEntity.setNo(glCzrzEntityNo.getNo());
glCzrzEntity.setName("0.指标删除");
glCzrzEntity.setCznr("删除指标"+gbiZbxmbEntity.getZbid()+"(MXZB)");
logger.info("==========开始保存操作日志======");
glCzrzDao.save(glCzrzEntity);
logger.info("==========操作日志保存完毕======");
JSONObject jsonObjectDelete =new JSONObject();
jsonObjectDelete.put("status","200");
jsonObjectDelete.put("zbxm",delete);
return jsonObjectDelete;
}catch (Exception e){
logger.info("删除指标项目失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("删除指标失败");
}
}
private JsonResultEntity updateOtherTable(GbiZbxmbEntity gbiZbxmbEntity){
try {
if(StrUtil.isNotEmpty(gbiZbxmbEntity.getBmdm()) && StrUtil.isNotEmpty(gbiZbxmbEntity.getBmmc()) ){
logger.info("===========开始更新部门信息得使用状态=========");
//根据部门代码会计年度公司代码更新部门使用状态为1
SenderPubbmxxEntity pubbmxxEntity=new SenderPubbmxxEntity();
pubbmxxEntity.setGsdm(gbiZbxmbEntity.getGsdm());
pubbmxxEntity.setKjnd(gbiZbxmbEntity.getKjnd());
pubbmxxEntity.setBmdm(gbiZbxmbEntity.getBmdm());
pubbmxxEntity.setSyzt("1");
pubbmxxDao.update(pubbmxxEntity);
logger.info("===========更新部门信息得使用状态完毕=========");
}
}catch (Exception e){
logger.info("更新部门信息得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新部门信息得使用状态失败");
}
try {
if(StrUtil.isNotEmpty(gbiZbxmbEntity.getXmdm()) && StrUtil.isNotEmpty(gbiZbxmbEntity.getXmmc())) {
//根据部门代码会计年度公司代码更新项目使用状态为1
SenderGlXmzlEntity glXmzlEntity = new SenderGlXmzlEntity();
glXmzlEntity.setGsdm(gbiZbxmbEntity.getGsdm());
glXmzlEntity.setKjnd(gbiZbxmbEntity.getKjnd());
glXmzlEntity.setXmdm(gbiZbxmbEntity.getXmdm());
glXmzlEntity.setSyzt("1");
logger.info("===========开始更新项目资料得使用状态=========");
glXmzlDao.update(glXmzlEntity);
logger.info("===========更新项目资料得使用状态完毕=========");
}
}catch (Exception e){
logger.info("更新项目资料得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新项目资料得使用状态失败");
}
try {
if(StrUtil.isNotEmpty(gbiZbxmbEntity.getWhdm()) && StrUtil.isNotEmpty(gbiZbxmbEntity.getWhmc())){
//根据部门代码会计年度公司代码更新文号使用状态为1
ZbWhszEntity zbWhszEntity=new ZbWhszEntity();
zbWhszEntity.setGsdm(gbiZbxmbEntity.getGsdm());
zbWhszEntity.setKjnd(gbiZbxmbEntity.getKjnd());
zbWhszEntity.setWhdm(gbiZbxmbEntity.getWhdm());
zbWhszEntity.setSyzt("1");
logger.info("===========开始更新文号得使用状态=========");
zbWhszDao.update(zbWhszEntity);
logger.info("===========更新文号得使用状态完毕=========");
}
}catch (Exception e){
logger.info("更新文号得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新文号得使用状态失败");
}
try {
if(StrUtil.isNotEmpty(gbiZbxmbEntity.getZblydm()) && StrUtil.isNotEmpty(gbiZbxmbEntity.getZblymc())) {
//根据部门代码会计年度公司代码更新指标来源使用状态为1
ZbZblyEntity zblyEntity = new ZbZblyEntity();
zblyEntity.setGsdm(gbiZbxmbEntity.getGsdm());
zblyEntity.setKjnd(gbiZbxmbEntity.getKjnd());
zblyEntity.setZblydm(gbiZbxmbEntity.getZblydm());
zblyEntity.setSyzt("1");
logger.info("===========开始更新指标来源得使用状态=========");
zbZblyDao.update(zblyEntity);
logger.info("===========更新指标来源得使用状态完毕=========");
}
}catch (Exception e){
logger.info("更新指标来源得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新指标来源得使用状态失败");
}
try {
//根据类别代码会计年度公司代码,辅助代码更新使用状态
//部门经济科目
GlFzxzlEntity glFzxzlEntity=new GlFzxzlEntity();
glFzxzlEntity.setGsdm(gbiZbxmbEntity.getGsdm());
glFzxzlEntity.setKjnd(gbiZbxmbEntity.getKjnd());
glFzxzlEntity.setSyzt("1");
try {
if(StrUtil.isNotEmpty(gbiZbxmbEntity.getJjkmdm()) && StrUtil.isNotEmpty(gbiZbxmbEntity.getJjkmmc())) {
logger.info("===========开始更新辅助项资料(部门经济科目)得使用状态=========");
glFzxzlEntity.setFzdm(gbiZbxmbEntity.getJjkmdm());
glFzxzlEntity.setLbdm("5");
glFzxzlDao.update(glFzxzlEntity);
logger.info("===========更新辅助项资料(部门经济科目)得使用状态完毕=========");
}
}catch (Exception e){
logger.info("更新辅助项资料(部门经济科目)得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新辅助项资料(部门经济科目)得使用状态");
}
try {
if(StrUtil.isNotEmpty(gbiZbxmbEntity.getFz6dm()) && StrUtil.isNotEmpty(gbiZbxmbEntity.getFz6mc())){
//资金性质
glFzxzlEntity.setLbdm("6");
glFzxzlEntity.setFzdm(gbiZbxmbEntity.getFz6dm());
logger.info("===========开始更新辅助项资料(资金性质)得使用状态=========");
glFzxzlDao.update(glFzxzlEntity);
logger.info("===========更新辅助项资料(资金性质)得使用状态完毕=========");
}
}catch (Exception e){
logger.info("更新辅助项资料(资金性质)得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新辅助项资料(资金性质)得使用状态失败");
}
try {
if(StrUtil.isNotEmpty(gbiZbxmbEntity.getFz8dm()) && StrUtil.isNotEmpty(gbiZbxmbEntity.getFz8mc())) {
//国库项目
glFzxzlEntity.setLbdm("8");
glFzxzlEntity.setFzdm(gbiZbxmbEntity.getFz8dm());
logger.info("===========开始更新辅助项资料(国库项目)得使用状态=========");
glFzxzlDao.update(glFzxzlEntity);
logger.info("===========更新辅助项资料(国库项目)得使用状态完毕=========");
}
}catch (Exception e){
logger.info("更新辅助项资料(国库项目)得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新辅助项资料(国库项目)得使用状态失败");
}
try {
if(StrUtil.isNotEmpty(gbiZbxmbEntity.getFz9dm()) && StrUtil.isNotEmpty(gbiZbxmbEntity.getFz9mc())){
//经费类型I
glFzxzlEntity.setLbdm("9");
glFzxzlEntity.setFzdm(gbiZbxmbEntity.getFz9dm());
logger.info("===========开始更新辅助项资料(经费类型I)得使用状态=========");
glFzxzlDao.update(glFzxzlEntity);
logger.info("===========更新辅助项资料(经费类型I)得使用状态完毕=========");
}
}catch (Exception e){
logger.info("更新辅助项资料(经费类型I)得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新辅助项资料(经费类型I)得使用状态失败");
}
}catch (Exception e){
logger.info("更新辅助项资料得使用状态失败:{}",e.getMessage());
return BaseResult.getFailureMessageEntity("更新辅助项资料得使用状态失败");
}
return BaseResult.getSuccessMessageEntity("相关得表状态都已修改");
}
}

View File

@ -0,0 +1,100 @@
package com.hzya.frame.grpU8.nxproof.glPzml.dao;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity;
import java.util.List;
import java.util.Map;
/**
* (gl_pzml: table)表数据库访问层
*
* @author makejava
* @since 2024-06-20 10:02:06
*/
public interface ISenderGlPzmlDao extends IBaseDao<SenderGlPzmlEntity, String> {
/**
*
* @content 查询凭证目录 卫生院
* @Param
* @Return
* @Author hecan
* @Date 2024/6/20 10:11
* **/
List<SenderGlPzmlEntity> querySenderGlPzmlEntity(SenderGlPzmlEntity senderGlPzmlEntity);
/**
*
* @content 保存凭证目录到凭证目录日志表中 卫生院
* @Param
* @Return
* @Author hecan
* @Date 2024/6/27 16:29
* **/
SenderGlPzmlEntity saveSenderGlPzmlEntity(SenderGlPzmlEntity senderGlPzmlEntity);
/**
*
* @content 更新凭证目录到凭证目录日志表中 卫生院
* @Param
* @Return
* @Author hecan
* @Date 2024/6/27 16:30
* **/
SenderGlPzmlEntity updateSenderGlPzmlEntity(SenderGlPzmlEntity senderGlPzmlEntity);
/**
*
* @content 查询凭证目录 卫生局
* @Param
* @Return
* @Author hecan
* @Date 2024/6/20 10:11
* **/
List<SenderGlPzmlEntity> queryGlPzmlHealthBureau(SenderGlPzmlEntity senderGlPzmlEntity);
/**
*
* @content 保存凭证目录 卫生局
* @Param
* @Return
* @Author hecan
* @Date 2024/6/27 16:29
* **/
SenderGlPzmlEntity saveGlPzmlHealthBureau(SenderGlPzmlEntity senderGlPzmlEntity);
/**
*
* @content 更新凭证目录 卫生局
* @Param
* @Return
* @Author hecan
* @Date 2024/6/27 16:30
* **/
SenderGlPzmlEntity updateGlPzmlHealthBureau(SenderGlPzmlEntity senderGlPzmlEntity);
/**
*
* @content 删除凭证目录 卫生局
* @Param
* @Return
* @Author hecan
* @Date 2024/8/9 17:44
* **/
Integer deleteGlPzmlHealthBureau(SenderGlPzmlEntity senderGlPzmlEntity);
/**
*
* @content 查询凭证 商学院
* @Param
* @Return
* @Author hecan
* @Date 2024/8/14 16:25
* **/
List<SenderGlPzmlEntity> queryGlPzmlSxy(SenderGlPzmlEntity senderGlPzmlEntity);
}

View File

@ -0,0 +1,71 @@
package com.hzya.frame.grpU8.nxproof.glPzml.dao.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import com.hzya.frame.grpU8.nxproof.glPzml.dao.ISenderGlPzmlDao;
import com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity;
import org.springframework.stereotype.Repository;
import java.util.List;
import java.util.Map;
/**
* (GlPzml)表数据库访问层
*
* @author makejava
* @since 2024-06-20 10:02:06
*/
@Repository(value = "SenderGlPzmlDaoImpl")
public class SenderGlPzmlDaoImpl extends MybatisGenericDao<SenderGlPzmlEntity, String> implements ISenderGlPzmlDao {
@Override
@DS("#senderGlPzmlEntity.dataSourceCode")
public List<SenderGlPzmlEntity> querySenderGlPzmlEntity(SenderGlPzmlEntity senderGlPzmlEntity) {
return super.queryByLike(senderGlPzmlEntity);
}
@Override
@DS("#senderGlPzmlEntity.dataSourceCode")
public SenderGlPzmlEntity saveSenderGlPzmlEntity(SenderGlPzmlEntity senderGlPzmlEntity) {
return super.save(senderGlPzmlEntity);
}
@Override
@DS("#senderGlPzmlEntity.dataSourceCode")
public SenderGlPzmlEntity updateSenderGlPzmlEntity(SenderGlPzmlEntity senderGlPzmlEntity) {
return super.update(senderGlPzmlEntity);
}
@Override
@DS("#senderGlPzmlEntity.dataSourceCode")
public List<SenderGlPzmlEntity> queryGlPzmlHealthBureau(SenderGlPzmlEntity senderGlPzmlEntity) {
return super.query(senderGlPzmlEntity);
}
@Override
@DS("#senderGlPzmlEntity.dataSourceCode")
public SenderGlPzmlEntity saveGlPzmlHealthBureau(SenderGlPzmlEntity senderGlPzmlEntity) {
return super.save(senderGlPzmlEntity);
}
@Override
@DS("#senderGlPzmlEntity.dataSourceCode")
public SenderGlPzmlEntity updateGlPzmlHealthBureau(SenderGlPzmlEntity senderGlPzmlEntity) {
return super.update(senderGlPzmlEntity);
}
@Override
@DS("#senderGlPzmlEntity.dataSourceCode")
public Integer deleteGlPzmlHealthBureau(SenderGlPzmlEntity senderGlPzmlEntity) {
return super.delete("SenderGlPzmlEntity_delete_pzml",senderGlPzmlEntity);
}
@Override
@DS("#senderGlPzmlEntity.dataSourceCode")
public List<SenderGlPzmlEntity> queryGlPzmlSxy(SenderGlPzmlEntity senderGlPzmlEntity) {
return (List<SenderGlPzmlEntity>) super.selectList("queryGlPzmlSxy",senderGlPzmlEntity);
}
}

View File

@ -0,0 +1,381 @@
package com.hzya.frame.grpU8.nxproof.glPzml.entity;
import com.hzya.frame.web.entity.BaseEntity;
/**
* (GlPzml)实体类
*
* @author makejava
* @since 2024-06-20 10:02:06
*/
public class SenderGlPzmlEntity extends BaseEntity {
private String gsdm;
private String zth;
private String kjqj;
private String pzly;
private String pzh;
private String pzrq;
private Integer fjzs;
private Integer srid;
private String sr;
private Integer shid;
private String sh;
private String jsr;
private Integer jzrid;
private String jzr;
private String srrq;
private String shrq;
private String jzrq;
private String pzhzkmdy;
private String pzhzbz;
private Integer zt;
private String pzzy;
private String pzje;
private String cn;
private String bz;
private String kjzg;
private String idpzh;
private String dyzt;
private String qzrq;
private Integer gdid;
private String gdname;
private String gdrqsj;
private Integer gdcs;
private String gdbz;
private Integer yspzzs;
private String kjtxdm;
private String pzlxdm;
private String pzsbm;
private String stamp;
private String yspzje;
private String bmdm;
public String getBmdm() {
return bmdm;
}
public void setBmdm(String bmdm) {
this.bmdm = bmdm;
}
public String getPzsbm() {
return pzsbm;
}
public void setPzsbm(String pzsbm) {
this.pzsbm = pzsbm;
}
public String getStamp() {
return stamp;
}
public void setStamp(String stamp) {
this.stamp = stamp;
}
public String getYspzje() {
return yspzje;
}
public void setYspzje(String yspzje) {
this.yspzje = yspzje;
}
public String getKjtxdm() {
return kjtxdm;
}
public void setKjtxdm(String kjtxdm) {
this.kjtxdm = kjtxdm;
}
public String getPzlxdm() {
return pzlxdm;
}
public void setPzlxdm(String pzlxdm) {
this.pzlxdm = pzlxdm;
}
public String getGsdm() {
return gsdm;
}
public void setGsdm(String gsdm) {
this.gsdm = gsdm;
}
public String getZth() {
return zth;
}
public void setZth(String zth) {
this.zth = zth;
}
public String getKjqj() {
return kjqj;
}
public void setKjqj(String kjqj) {
this.kjqj = kjqj;
}
public String getPzly() {
return pzly;
}
public void setPzly(String pzly) {
this.pzly = pzly;
}
public String getPzh() {
return pzh;
}
public void setPzh(String pzh) {
this.pzh = pzh;
}
public String getPzrq() {
return pzrq;
}
public void setPzrq(String pzrq) {
this.pzrq = pzrq;
}
public Integer getFjzs() {
return fjzs;
}
public void setFjzs(Integer fjzs) {
this.fjzs = fjzs;
}
public Integer getSrid() {
return srid;
}
public void setSrid(Integer srid) {
this.srid = srid;
}
public String getSr() {
return sr;
}
public void setSr(String sr) {
this.sr = sr;
}
public Integer getShid() {
return shid;
}
public void setShid(Integer shid) {
this.shid = shid;
}
public String getSh() {
return sh;
}
public void setSh(String sh) {
this.sh = sh;
}
public String getJsr() {
return jsr;
}
public void setJsr(String jsr) {
this.jsr = jsr;
}
public Integer getJzrid() {
return jzrid;
}
public void setJzrid(Integer jzrid) {
this.jzrid = jzrid;
}
public String getJzr() {
return jzr;
}
public void setJzr(String jzr) {
this.jzr = jzr;
}
public String getSrrq() {
return srrq;
}
public void setSrrq(String srrq) {
this.srrq = srrq;
}
public String getShrq() {
return shrq;
}
public void setShrq(String shrq) {
this.shrq = shrq;
}
public String getJzrq() {
return jzrq;
}
public void setJzrq(String jzrq) {
this.jzrq = jzrq;
}
public String getPzhzkmdy() {
return pzhzkmdy;
}
public void setPzhzkmdy(String pzhzkmdy) {
this.pzhzkmdy = pzhzkmdy;
}
public String getPzhzbz() {
return pzhzbz;
}
public void setPzhzbz(String pzhzbz) {
this.pzhzbz = pzhzbz;
}
public Integer getZt() {
return zt;
}
public void setZt(Integer zt) {
this.zt = zt;
}
public String getPzzy() {
return pzzy;
}
public void setPzzy(String pzzy) {
this.pzzy = pzzy;
}
public String getPzje() {
return pzje;
}
public void setPzje(String pzje) {
this.pzje = pzje;
}
public String getCn() {
return cn;
}
public void setCn(String cn) {
this.cn = cn;
}
public String getBz() {
return bz;
}
public void setBz(String bz) {
this.bz = bz;
}
public String getKjzg() {
return kjzg;
}
public void setKjzg(String kjzg) {
this.kjzg = kjzg;
}
public String getIdpzh() {
return idpzh;
}
public void setIdpzh(String idpzh) {
this.idpzh = idpzh;
}
public String getDyzt() {
return dyzt;
}
public void setDyzt(String dyzt) {
this.dyzt = dyzt;
}
public String getQzrq() {
return qzrq;
}
public void setQzrq(String qzrq) {
this.qzrq = qzrq;
}
public Integer getGdid() {
return gdid;
}
public void setGdid(Integer gdid) {
this.gdid = gdid;
}
public String getGdname() {
return gdname;
}
public void setGdname(String gdname) {
this.gdname = gdname;
}
public String getGdrqsj() {
return gdrqsj;
}
public void setGdrqsj(String gdrqsj) {
this.gdrqsj = gdrqsj;
}
public Integer getGdcs() {
return gdcs;
}
public void setGdcs(Integer gdcs) {
this.gdcs = gdcs;
}
public String getGdbz() {
return gdbz;
}
public void setGdbz(String gdbz) {
this.gdbz = gdbz;
}
public Integer getYspzzs() {
return yspzzs;
}
public void setYspzzs(Integer yspzzs) {
this.yspzzs = yspzzs;
}
}

View File

@ -0,0 +1,536 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.grpU8.nxproof.glPzml.dao.impl.SenderGlPzmlDaoImpl">
<resultMap id="get-SenderGlPzmlEntity-result" type="com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity" >
<result property="gsdm" column="gsdm" jdbcType="VARCHAR"/>
<result property="zth" column="ZTH" jdbcType="VARCHAR"/>
<result property="kjqj" column="kjqj" jdbcType="VARCHAR"/>
<result property="pzly" column="pzly" jdbcType="VARCHAR"/>
<result property="pzh" column="pzh" jdbcType="VARCHAR"/>
<result property="pzrq" column="pzrq" jdbcType="VARCHAR"/>
<result property="fjzs" column="fjzs" jdbcType="INTEGER"/>
<result property="srid" column="srID" jdbcType="INTEGER"/>
<result property="sr" column="sr" jdbcType="VARCHAR"/>
<result property="shid" column="shID" jdbcType="INTEGER"/>
<result property="sh" column="sh" jdbcType="VARCHAR"/>
<result property="jsr" column="jsr" jdbcType="VARCHAR"/>
<result property="jzrid" column="jzrID" jdbcType="INTEGER"/>
<result property="jzr" column="jzr" jdbcType="VARCHAR"/>
<result property="srrq" column="srrq" jdbcType="VARCHAR"/>
<result property="shrq" column="shrq" jdbcType="VARCHAR"/>
<result property="jzrq" column="jzrq" jdbcType="VARCHAR"/>
<result property="pzhzkmdy" column="pzhzkmdy" jdbcType="VARCHAR"/>
<result property="pzhzbz" column="pzhzbz" jdbcType="VARCHAR"/>
<result property="zt" column="zt" jdbcType="INTEGER"/>
<result property="pzzy" column="pzzy" jdbcType="VARCHAR"/>
<result property="pzje" column="pzje" jdbcType="VARCHAR"/>
<result property="cn" column="CN" jdbcType="VARCHAR"/>
<result property="bz" column="BZ" jdbcType="VARCHAR"/>
<result property="kjzg" column="kjzg" jdbcType="VARCHAR"/>
<result property="idpzh" column="idpzh" jdbcType="VARCHAR"/>
<result property="dyzt" column="dyzt" jdbcType="VARCHAR"/>
<result property="qzrq" column="QZRQ" jdbcType="VARCHAR"/>
<result property="gdid" column="GDID" jdbcType="INTEGER"/>
<result property="gdname" column="GDName" jdbcType="VARCHAR"/>
<result property="gdrqsj" column="GDRQSJ" jdbcType="VARCHAR"/>
<result property="gdcs" column="GDCS" jdbcType="INTEGER"/>
<result property="gdbz" column="GDBZ" jdbcType="VARCHAR"/>
<result property="yspzzs" column="yspzzs" jdbcType="INTEGER"/>
<result property="kjtxdm" column="kjtxdm" jdbcType="VARCHAR"/>
<result property="pzlxdm" column="pzlxdm" jdbcType="VARCHAR"/>
<result property="pzsbm" column="pzsbm" jdbcType="VARCHAR"/>
<result property="stamp" column="stamp" jdbcType="VARCHAR"/>
<result property="yspzje" column="yspzje" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询的字段-->
<sql id = "SenderGlPzmlEntity_Base_Column_List">
gsdm
, ZTH
, kjqj
, pzly
,pzlxdm
,kjtxdm
, pzh
, pzrq
, fjzs
, srID
, sr
, shID
, sh
, jsr
, jzrID
, jzr
, srrq
, shrq
, jzrq
, pzhzkmdy
, pzhzbz
, zt
, pzzy
, pzje
, CN
, BZ
, kjzg
, idpzh
, dyzt
, QZRQ
, GDID
, GDName
, GDRQSJ
, GDCS
, GDBZ
, yspzzs
, pzsbm
, stamp
, yspzje
</sql>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-SenderGlPzmlEntity-result" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity">
select
<include refid="SenderGlPzmlEntity_Base_Column_List" />
from gl_pzml
<trim prefix="where" prefixOverrides="and">
<if test="gsdm != null and gsdm != ''"> and gsdm = #{gsdm} </if>
<if test="zth != null and zth != ''"> and ZTH = #{zth} </if>
<if test="kjqj != null and kjqj != ''"> and kjqj = #{kjqj} </if>
<if test="pzly != null and pzly != ''"> and pzly = #{pzly} </if>
<if test="pzh != null and pzh != ''"> and pzh = #{pzh} </if>
<if test="pzrq != null and pzrq != ''"> and pzrq >= #{pzrq} </if>
<if test="fjzs != null"> and fjzs = #{fjzs} </if>
<if test="srid != null"> and srID = #{srid} </if>
<if test="sr != null and sr != ''"> and sr = #{sr} </if>
<if test="shid != null"> and shID = #{shid} </if>
<if test="sh != null and sh != ''"> and sh = #{sh} </if>
<if test="jsr != null and jsr != ''"> and jsr = #{jsr} </if>
<if test="jzrid != null"> and jzrID = #{jzrid} </if>
<if test="jzr != null and jzr != ''"> and jzr = #{jzr} </if>
<if test="srrq != null and srrq != ''"> and srrq = #{srrq} </if>
<if test="shrq != null and shrq != ''"> and shrq = #{shrq} </if>
<if test="jzrq != null and jzrq != ''"> and jzrq = #{jzrq} </if>
<if test="pzhzkmdy != null and pzhzkmdy != ''"> and pzhzkmdy = #{pzhzkmdy} </if>
<if test="pzhzbz != null and pzhzbz != ''"> and pzhzbz = #{pzhzbz} </if>
<if test="zt != null"> and zt = #{zt} </if>
<if test="pzzy != null and pzzy != ''"> and pzzy = #{pzzy} </if>
<if test="pzje != null"> and pzje = #{pzje} </if>
<if test="cn != null and cn != ''"> and CN = #{cn} </if>
<if test="bz != null and bz != ''"> and BZ = #{bz} </if>
<if test="kjzg != null and kjzg != ''"> and kjzg = #{kjzg} </if>
<if test="idpzh != null and idpzh != ''"> and idpzh = #{idpzh} </if>
<if test="dyzt != null and dyzt != ''"> and dyzt = #{dyzt} </if>
<if test="qzrq != null and qzrq != ''"> and QZRQ = #{qzrq} </if>
<if test="gdid != null"> and GDID = #{gdid} </if>
<if test="gdname != null and gdname != ''"> and GDName = #{gdname} </if>
<if test="gdrqsj != null and gdrqsj != ''"> and GDRQSJ = #{gdrqsj} </if>
<if test="gdcs != null"> and GDCS = #{gdcs} </if>
<if test="gdbz != null and gdbz != ''"> and GDBZ = #{gdbz} </if>
<if test="yspzzs != null"> and yspzzs = #{yspzzs} </if>
<if test="pzsbm != null and pzsbm!=''"> and pzsbm = #{pzsbm} </if>
<if test="stamp != null and stamp!=''"> and stamp = #{stamp} </if>
<if test="yspzje != null and yspzje!=''"> and yspzje = #{yspzje} </if>
-- and zth in('004','005','009','010','011','012','014')
</trim>
</select>
<!-- 查询符合条件的数量 -->
<select id="entity_count" resultType="Integer" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity">
select count(1) from gl_pzml
<trim prefix="where" prefixOverrides="and">
<if test="gsdm != null and gsdm != ''"> and gsdm = #{gsdm} </if>
<if test="zth != null and zth != ''"> and ZTH = #{zth} </if>
<if test="kjqj != null and kjqj != ''"> and kjqj = #{kjqj} </if>
<if test="pzly != null and pzly != ''"> and pzly = #{pzly} </if>
<if test="pzh != null and pzh != ''"> and pzh = #{pzh} </if>
<if test="pzrq != null and pzrq != ''"> and pzrq = #{pzrq} </if>
<if test="fjzs != null"> and fjzs = #{fjzs} </if>
<if test="srid != null"> and srID = #{srid} </if>
<if test="sr != null and sr != ''"> and sr = #{sr} </if>
<if test="shid != null"> and shID = #{shid} </if>
<if test="sh != null and sh != ''"> and sh = #{sh} </if>
<if test="jsr != null and jsr != ''"> and jsr = #{jsr} </if>
<if test="jzrid != null"> and jzrID = #{jzrid} </if>
<if test="jzr != null and jzr != ''"> and jzr = #{jzr} </if>
<if test="srrq != null and srrq != ''"> and srrq = #{srrq} </if>
<if test="shrq != null and shrq != ''"> and shrq = #{shrq} </if>
<if test="jzrq != null and jzrq != ''"> and jzrq = #{jzrq} </if>
<if test="pzhzkmdy != null and pzhzkmdy != ''"> and pzhzkmdy = #{pzhzkmdy} </if>
<if test="pzhzbz != null and pzhzbz != ''"> and pzhzbz = #{pzhzbz} </if>
<if test="zt != null"> and zt = #{zt} </if>
<if test="pzzy != null and pzzy != ''"> and pzzy = #{pzzy} </if>
<if test="pzje != null"> and pzje = #{pzje} </if>
<if test="cn != null and cn != ''"> and CN = #{cn} </if>
<if test="bz != null and bz != ''"> and BZ = #{bz} </if>
<if test="kjzg != null and kjzg != ''"> and kjzg = #{kjzg} </if>
<if test="idpzh != null and idpzh != ''"> and idpzh = #{idpzh} </if>
<if test="dyzt != null and dyzt != ''"> and dyzt = #{dyzt} </if>
<if test="qzrq != null and qzrq != ''"> and QZRQ = #{qzrq} </if>
<if test="gdid != null"> and GDID = #{gdid} </if>
<if test="gdname != null and gdname != ''"> and GDName = #{gdname} </if>
<if test="gdrqsj != null and gdrqsj != ''"> and GDRQSJ = #{gdrqsj} </if>
<if test="gdcs != null"> and GDCS = #{gdcs} </if>
<if test="gdbz != null and gdbz != ''"> and GDBZ = #{gdbz} </if>
<if test="yspzzs != null"> and yspzzs = #{yspzzs} </if>
</trim>
</select>
<!-- 分页查询列表 采用like格式 -->
<select id="entity_list_like" resultMap="get-SenderGlPzmlEntity-result" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity">
select
<include refid="SenderGlPzmlEntity_Base_Column_List" />
from gl_pzml
<trim prefix="where" prefixOverrides="and">
<if test="gsdm != null and gsdm != ''"> and gsdm like concat('%',#{gsdm},'%') </if>
<if test="zth != null and zth != ''"> and ZTH like concat('%',#{zth},'%') </if>
<if test="kjqj != null and kjqj != ''"> and kjqj like concat('%',#{kjqj},'%') </if>
<if test="pzly != null and pzly != ''"> and pzly like concat('%',#{pzly},'%') </if>
<if test="pzh != null and pzh != ''"> and pzh like concat('%',#{pzh},'%') </if>
<if test="pzrq != null and pzrq != ''"> and pzrq like concat('%',#{pzrq},'%') </if>
<if test="fjzs != null"> and fjzs like concat('%',#{fjzs},'%') </if>
<if test="srid != null"> and srID like concat('%',#{srid},'%') </if>
<if test="sr != null and sr != ''"> and sr like concat('%',#{sr},'%') </if>
<if test="shid != null"> and shID like concat('%',#{shid},'%') </if>
<if test="sh != null and sh != ''"> and sh like concat('%',#{sh},'%') </if>
<if test="jsr != null and jsr != ''"> and jsr like concat('%',#{jsr},'%') </if>
<if test="jzrid != null"> and jzrID like concat('%',#{jzrid},'%') </if>
<if test="jzr != null and jzr != ''"> and jzr like concat('%',#{jzr},'%') </if>
<if test="srrq != null and srrq != ''"> and srrq like concat('%',#{srrq},'%') </if>
<if test="shrq != null and shrq != ''"> and shrq like concat('%',#{shrq},'%') </if>
<if test="jzrq != null and jzrq != ''"> and jzrq like concat('%',#{jzrq},'%') </if>
<if test="pzhzkmdy != null and pzhzkmdy != ''"> and pzhzkmdy like concat('%',#{pzhzkmdy},'%') </if>
<if test="pzhzbz != null and pzhzbz != ''"> and pzhzbz like concat('%',#{pzhzbz},'%') </if>
<if test="zt != null"> and zt like concat('%',#{zt},'%') </if>
<if test="pzzy != null and pzzy != ''"> and pzzy like concat('%',#{pzzy},'%') </if>
<if test="pzje != null"> and pzje like concat('%',#{pzje},'%') </if>
<if test="cn != null and cn != ''"> and CN like concat('%',#{cn},'%') </if>
<if test="bz != null and bz != ''"> and BZ like concat('%',#{bz},'%') </if>
<if test="kjzg != null and kjzg != ''"> and kjzg like concat('%',#{kjzg},'%') </if>
<if test="idpzh != null and idpzh != ''"> and idpzh like concat('%',#{idpzh},'%') </if>
<if test="dyzt != null and dyzt != ''"> and dyzt like concat('%',#{dyzt},'%') </if>
<if test="qzrq != null and qzrq != ''"> and QZRQ like concat('%',#{qzrq},'%') </if>
<if test="gdid != null"> and GDID like concat('%',#{gdid},'%') </if>
<if test="gdname != null and gdname != ''"> and GDName like concat('%',#{gdname},'%') </if>
<if test="gdrqsj != null and gdrqsj != ''"> and GDRQSJ like concat('%',#{gdrqsj},'%') </if>
<if test="gdcs != null"> and GDCS like concat('%',#{gdcs},'%') </if>
<if test="gdbz != null and gdbz != ''"> and GDBZ like concat('%',#{gdbz},'%') </if>
<if test="yspzzs != null"> and yspzzs like concat('%',#{yspzzs},'%') </if>
</trim>
</select>
<!-- 查询列表 字段采用or格式 -->
<select id="SenderGlPzmlEntity_list_or" resultMap="get-SenderGlPzmlEntity-result" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity">
select
<include refid="SenderGlPzmlEntity_Base_Column_List" />
from gl_pzml
<trim prefix="where" prefixOverrides="and">
<if test="gsdm != null and gsdm != ''"> or gsdm = #{gsdm} </if>
<if test="zth != null and zth != ''"> or ZTH = #{zth} </if>
<if test="kjqj != null and kjqj != ''"> or kjqj = #{kjqj} </if>
<if test="pzly != null and pzly != ''"> or pzly = #{pzly} </if>
<if test="pzh != null and pzh != ''"> or pzh = #{pzh} </if>
<if test="pzrq != null and pzrq != ''"> or pzrq = #{pzrq} </if>
<if test="fjzs != null"> or fjzs = #{fjzs} </if>
<if test="srid != null"> or srID = #{srid} </if>
<if test="sr != null and sr != ''"> or sr = #{sr} </if>
<if test="shid != null"> or shID = #{shid} </if>
<if test="sh != null and sh != ''"> or sh = #{sh} </if>
<if test="jsr != null and jsr != ''"> or jsr = #{jsr} </if>
<if test="jzrid != null"> or jzrID = #{jzrid} </if>
<if test="jzr != null and jzr != ''"> or jzr = #{jzr} </if>
<if test="srrq != null and srrq != ''"> or srrq = #{srrq} </if>
<if test="shrq != null and shrq != ''"> or shrq = #{shrq} </if>
<if test="jzrq != null and jzrq != ''"> or jzrq = #{jzrq} </if>
<if test="pzhzkmdy != null and pzhzkmdy != ''"> or pzhzkmdy = #{pzhzkmdy} </if>
<if test="pzhzbz != null and pzhzbz != ''"> or pzhzbz = #{pzhzbz} </if>
<if test="zt != null"> or zt = #{zt} </if>
<if test="pzzy != null and pzzy != ''"> or pzzy = #{pzzy} </if>
<if test="pzje != null"> or pzje = #{pzje} </if>
<if test="cn != null and cn != ''"> or CN = #{cn} </if>
<if test="bz != null and bz != ''"> or BZ = #{bz} </if>
<if test="kjzg != null and kjzg != ''"> or kjzg = #{kjzg} </if>
<if test="idpzh != null and idpzh != ''"> or idpzh = #{idpzh} </if>
<if test="dyzt != null and dyzt != ''"> or dyzt = #{dyzt} </if>
<if test="qzrq != null and qzrq != ''"> or QZRQ = #{qzrq} </if>
<if test="gdid != null"> or GDID = #{gdid} </if>
<if test="gdname != null and gdname != ''"> or GDName = #{gdname} </if>
<if test="gdrqsj != null and gdrqsj != ''"> or GDRQSJ = #{gdrqsj} </if>
<if test="gdcs != null"> or GDCS = #{gdcs} </if>
<if test="gdbz != null and gdbz != ''"> or GDBZ = #{gdbz} </if>
<if test="yspzzs != null"> or yspzzs = #{yspzzs} </if>
</trim>
</select>
<!-- 查询列表 商学院所需要的凭证数据-->
<select id="queryGlPzmlSxy" resultMap="get-SenderGlPzmlEntity-result" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity">
select
pzml.idpzh as idpzh,
pzml.kjqj as kjqj,
pzml.srrq as srrq,
pzml.srID as srID,
pznr.bmdm as bmdm,
pzml.pzzy as pzzy,
sum(pznr.je) as pzje,
pzml.gsdm,pzml.zth,pzml.kjqj,pzml.pzh
from GL_Pzml pzml
left join gl_pznr pznr on pznr.idpzh=pzml.idpzh and pzml.kjqj=pznr.kjqj
<trim prefix="where" prefixOverrides="and">
<if test="idpzh !=null and idpzh!='' "> and pzml.idpzh = #{idpzh} </if>
and pzml.kjqj =#{kjqj} and pznr.kjqj =#{kjqj} and pznr.zbid!=0
</trim>
group by pzml.idpzh,
pzml.kjqj,
pzml.srrq,
pzml.pzzy,
pzml.gsdm,pzml.zth,pzml.kjqj,pzml.pzh,pzml.srID,pznr.bmdm
</select>
<!--新增所有列-->
<insert id="entity_insert" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity" keyProperty="" useGeneratedKeys="true">
insert into gl_pzml(
<trim suffix="" suffixOverrides=",">
<if test="gsdm != null and gsdm != ''"> gsdm , </if>
<if test="kjqj != null and kjqj != ''"> kjqj , </if>
<if test="pzly != null and pzly != ''"> pzly , </if>
<if test="pzh != null and pzh != ''"> pzh , </if>
<if test="kjtxdm != null "> kjtxdm , </if>
<if test="pzlxdm != null and pzlxdm != ''"> pzlxdm , </if>
<if test="pzrq != null and pzrq != ''"> pzrq , </if>
<if test="fjzs != null"> fjzs , </if>
<if test="srid != null"> srID , </if>
<if test="sr != null and sr != ''"> sr , </if>
<if test="shid != null"> shID , </if>
<if test="sh != null and sh != ''"> sh , </if>
<if test="jsr != null and jsr != ''"> jsr , </if>
<if test="jzrid != null"> jzrID , </if>
<if test="jzr != null and jzr != ''"> jzr , </if>
<if test="srrq != null and srrq != ''"> srrq , </if>
<if test="shrq != null "> shrq , </if>
<if test="jzrq != null "> jzrq , </if>
<if test="pzhzkmdy != null and pzhzkmdy != ''"> pzhzkmdy , </if>
<if test="pzhzbz != null and pzhzbz != ''"> pzhzbz , </if>
<if test="zt != null"> zt , </if>
<if test="pzzy != null and pzzy != ''"> pzzy , </if>
<if test="pzje != null"> pzje , </if>
<if test="cn != null and cn != ''"> CN , </if>
<if test="bz != null and bz != ''"> BZ , </if>
<if test="kjzg != null and kjzg != ''"> kjzg , </if>
<if test="idpzh != null and idpzh != ''"> idpzh , </if>
<if test="dyzt != null and dyzt != ''"> dyzt , </if>
<if test="qzrq != null and qzrq != ''"> QZRQ , </if>
<if test="gdid != null"> GDID , </if>
<if test="gdname != null and gdname != ''"> GDName , </if>
<if test="gdrqsj != null and gdrqsj != ''"> GDRQSJ , </if>
<if test="gdcs != null"> GDCS , </if>
<if test="gdbz != null and gdbz != ''"> GDBZ , </if>
<if test="yspzzs != null"> yspzzs , </if>
<if test="pzsbm != null and pzsbm != ''"> pzsbm, </if>
<if test="stamp != null and stamp != ''"> stamp, </if>
<if test="yspzje != null and yspzje != ''"> yspzje, </if>
<if test="zth != null and zth != ''"> ZTH </if>
</trim>
)values(
<trim suffix="" suffixOverrides=",">
<if test="gsdm != null and gsdm != ''"> #{gsdm} ,</if>
<if test="kjqj != null and kjqj != ''"> #{kjqj} ,</if>
<if test="pzly != null and pzly != ''"> #{pzly} ,</if>
<if test="pzh != null and pzh != ''"> #{pzh} ,</if>
<if test="kjtxdm != null "> #{kjtxdm} , </if>
<if test="pzlxdm != null and pzlxdm != ''"> #{pzlxdm} , </if>
<if test="pzrq != null and pzrq != ''"> #{pzrq} ,</if>
<if test="fjzs != null"> #{fjzs} ,</if>
<if test="srid != null"> #{srid} ,</if>
<if test="sr != null and sr != ''"> #{sr} ,</if>
<if test="shid != null"> #{shid} ,</if>
<if test="sh != null and sh != ''"> #{sh} ,</if>
<if test="jsr != null and jsr != ''"> #{jsr} ,</if>
<if test="jzrid != null"> #{jzrid} ,</if>
<if test="jzr != null and jzr != ''"> #{jzr} ,</if>
<if test="srrq != null and srrq != ''"> #{srrq} ,</if>
<if test="shrq != null "> #{shrq} ,</if>
<if test="jzrq != null "> #{jzrq} ,</if>
<if test="pzhzkmdy != null and pzhzkmdy != ''"> #{pzhzkmdy} ,</if>
<if test="pzhzbz != null and pzhzbz != ''"> #{pzhzbz} ,</if>
<if test="zt != null"> #{zt} ,</if>
<if test="pzzy != null and pzzy != ''"> #{pzzy} ,</if>
<if test="pzje != null"> #{pzje} ,</if>
<if test="cn != null and cn != ''"> #{cn} ,</if>
<if test="bz != null and bz != ''"> #{bz} ,</if>
<if test="kjzg != null and kjzg != ''"> #{kjzg} ,</if>
<if test="idpzh != null and idpzh != ''"> #{idpzh} ,</if>
<if test="dyzt != null and dyzt != ''"> #{dyzt} ,</if>
<if test="qzrq != null and qzrq != ''"> #{qzrq} ,</if>
<if test="gdid != null"> #{gdid} ,</if>
<if test="gdname != null and gdname != ''"> #{gdname} ,</if>
<if test="gdrqsj != null and gdrqsj != ''"> #{gdrqsj} ,</if>
<if test="gdcs != null"> #{gdcs} ,</if>
<if test="gdbz != null and gdbz != ''"> #{gdbz} ,</if>
<if test="yspzzs != null"> #{yspzzs} ,</if>
<if test="pzsbm != null and pzsbm != ''"> #{pzsbm}, </if>
<if test="stamp != null and stamp != ''"> #{stamp}, </if>
<if test="yspzje != null and yspzje != ''"> #{yspzje}, </if>
<if test="zth != null and zth != ''"> #{zth} </if>
</trim>
)
</insert>
<!-- 批量新增 -->
<insert id="entityInsertBatch" keyProperty="" useGeneratedKeys="true">
insert into gl_pzml(gsdm, ZTH, kjqj, pzly, pzh, pzrq, fjzs, srID, sr, shID, sh, jsr, jzrID, jzr, srrq, shrq, jzrq, pzhzkmdy, pzhzbz, zt, pzzy, pzje, CN, BZ, kjzg, idpzh, dyzt, QZRQ, GDID, GDName, GDRQSJ, GDCS, GDBZ, yspzzs)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.gsdm},#{entity.zth},#{entity.kjqj},#{entity.pzly},#{entity.pzh},#{entity.pzrq},#{entity.fjzs},#{entity.srid},#{entity.sr},#{entity.shid},#{entity.sh},#{entity.jsr},#{entity.jzrid},#{entity.jzr},#{entity.srrq},#{entity.shrq},#{entity.jzrq},#{entity.pzhzkmdy},#{entity.pzhzbz},#{entity.zt},#{entity.pzzy},#{entity.pzje},#{entity.cn},#{entity.bz},#{entity.kjzg},#{entity.idpzh},#{entity.dyzt},#{entity.qzrq},#{entity.gdid},#{entity.gdname},#{entity.gdrqsj},#{entity.gdcs},#{entity.gdbz},#{entity.yspzzs})
</foreach>
</insert>
<!-- 批量新增或者修改-->
<insert id="entityInsertOrUpdateBatch" keyProperty="" useGeneratedKeys="true">
insert into gl_pzml(gsdm, ZTH, kjqj, pzly, pzh, pzrq, fjzs, srID, sr, shID, sh, jsr, jzrID, jzr, srrq, shrq, jzrq, pzhzkmdy, pzhzbz, zt, pzzy, pzje, CN, BZ, kjzg, idpzh, dyzt, QZRQ, GDID, GDName, GDRQSJ, GDCS, GDBZ, yspzzs)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.gsdm},#{entity.zth},#{entity.kjqj},#{entity.pzly},#{entity.pzh},#{entity.pzrq},#{entity.fjzs},#{entity.srid},#{entity.sr},#{entity.shid},#{entity.sh},#{entity.jsr},#{entity.jzrid},#{entity.jzr},#{entity.srrq},#{entity.shrq},#{entity.jzrq},#{entity.pzhzkmdy},#{entity.pzhzbz},#{entity.zt},#{entity.pzzy},#{entity.pzje},#{entity.cn},#{entity.bz},#{entity.kjzg},#{entity.idpzh},#{entity.dyzt},#{entity.qzrq},#{entity.gdid},#{entity.gdname},#{entity.gdrqsj},#{entity.gdcs},#{entity.gdbz},#{entity.yspzzs})
</foreach>
on duplicate key update
gsdm = values(gsdm),
ZTH = values(ZTH),
kjqj = values(kjqj),
pzly = values(pzly),
pzh = values(pzh),
pzrq = values(pzrq),
fjzs = values(fjzs),
srID = values(srID),
sr = values(sr),
shID = values(shID),
sh = values(sh),
jsr = values(jsr),
jzrID = values(jzrID),
jzr = values(jzr),
srrq = values(srrq),
shrq = values(shrq),
jzrq = values(jzrq),
pzhzkmdy = values(pzhzkmdy),
pzhzbz = values(pzhzbz),
zt = values(zt),
pzzy = values(pzzy),
pzje = values(pzje),
CN = values(CN),
BZ = values(BZ),
kjzg = values(kjzg),
idpzh = values(idpzh),
dyzt = values(dyzt),
QZRQ = values(QZRQ),
GDID = values(GDID),
GDName = values(GDName),
GDRQSJ = values(GDRQSJ),
GDCS = values(GDCS),
GDBZ = values(GDBZ),
yspzzs = values(yspzzs)</insert>
<!--通过主键修改方法-->
<update id="entity_update" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity" >
update gl_pzml set
<trim suffix="" suffixOverrides=",">
<if test="gsdm != null and gsdm != ''"> gsdm = #{gsdm},</if>
<if test="zth != null and zth != ''"> ZTH = #{zth},</if>
<if test="kjqj != null and kjqj != ''"> kjqj = #{kjqj},</if>
<if test="pzly != null and pzly != ''"> pzly = #{pzly},</if>
<if test="pzh != null and pzh != ''"> pzh = #{pzh},</if>
<if test="kjtxdm != null "> kjtxdm = #{kjtxdm},</if>
<if test="pzlxdm != null and pzlxdm != ''"> pzlxdm = #{pzlxdm},</if>
<if test="pzrq != null and pzrq != ''"> pzrq = #{pzrq},</if>
<if test="fjzs != null"> fjzs = #{fjzs},</if>
<if test="srid != null"> srID = #{srid},</if>
<if test="sr != null and sr != ''"> sr = #{sr},</if>
<if test="shid != null"> shID = #{shid},</if>
<if test="sh != null and sh != ''"> sh = #{sh},</if>
<if test="jsr != null and jsr != ''"> jsr = #{jsr},</if>
<if test="jzrid != null"> jzrID = #{jzrid},</if>
<if test="jzr != null and jzr != ''"> jzr = #{jzr},</if>
<if test="srrq != null and srrq != ''"> srrq = #{srrq},</if>
<if test="shrq != null and shrq != ''"> shrq = #{shrq},</if>
<if test="jzrq != null and jzrq != ''"> jzrq = #{jzrq},</if>
<if test="pzhzkmdy != null and pzhzkmdy != ''"> pzhzkmdy = #{pzhzkmdy},</if>
<if test="pzhzbz != null and pzhzbz != ''"> pzhzbz = #{pzhzbz},</if>
<if test="zt != null"> zt = #{zt},</if>
<if test="pzzy != null and pzzy != ''"> pzzy = #{pzzy},</if>
<if test="pzje != null"> pzje = #{pzje},</if>
<if test="cn != null and cn != ''"> CN = #{cn},</if>
<if test="bz != null and bz != ''"> BZ = #{bz},</if>
<if test="kjzg != null and kjzg != ''"> kjzg = #{kjzg},</if>
<if test="dyzt != null and dyzt != ''"> dyzt = #{dyzt},</if>
<if test="qzrq != null and qzrq != ''"> QZRQ = #{qzrq},</if>
<if test="gdid != null"> GDID = #{gdid},</if>
<if test="gdname != null and gdname != ''"> GDName = #{gdname},</if>
<if test="gdrqsj != null and gdrqsj != ''"> GDRQSJ = #{gdrqsj},</if>
<if test="gdcs != null"> GDCS = #{gdcs},</if>
<if test="gdbz != null and gdbz != ''"> GDBZ = #{gdbz},</if>
<if test="yspzzs != null"> yspzzs = #{yspzzs},</if>
<if test="pzsbm != null and pzsbm!=''"> pzsbm = #{pzsbm},</if>
<if test="stamp != null and stamp!=''"> stamp = #{stamp},</if>
<if test="yspzje != null and yspzje !='' "> yspzje = #{yspzje}</if>
</trim>
where idpzh= #{idpzh}
</update>
<!-- 逻辑删除 -->
<update id="SenderGlPzmlEntity_logicDelete" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity" >
update gl_pzml set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id}
where idpzh= #{idpzh}
</update>
<!-- 多条件逻辑删除 -->
<update id="SenderGlPzmlEntity_logicDelete_Multi_Condition" parameterType = "com.hzya.frame.grpU8.nxproof.glPzml.entity.SenderGlPzmlEntity" >
update gl_pzml set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id}
<trim prefix="where" prefixOverrides="and">
<if test="gsdm != null and gsdm != ''"> and gsdm = #{gsdm} </if>
<if test="zth != null and zth != ''"> and ZTH = #{zth} </if>
<if test="kjqj != null and kjqj != ''"> and kjqj = #{kjqj} </if>
<if test="pzly != null and pzly != ''"> and pzly = #{pzly} </if>
<if test="pzh != null and pzh != ''"> and pzh = #{pzh} </if>
<if test="kjtxdm != null and kjtxdm != ''"> and kjtxdm = #{kjtxdm}</if>
<if test="pzlxdm != null and pzlxdm != ''"> and pzh = #{pzlxdm}</if>
<if test="pzrq != null and pzrq != ''"> and pzrq = #{pzrq} </if>
<if test="fjzs != null"> and fjzs = #{fjzs} </if>
<if test="srid != null"> and srID = #{srid} </if>
<if test="sr != null and sr != ''"> and sr = #{sr} </if>
<if test="shid != null"> and shID = #{shid} </if>
<if test="sh != null and sh != ''"> and sh = #{sh} </if>
<if test="jsr != null and jsr != ''"> and jsr = #{jsr} </if>
<if test="jzrid != null"> and jzrID = #{jzrid} </if>
<if test="jzr != null and jzr != ''"> and jzr = #{jzr} </if>
<if test="srrq != null and srrq != ''"> and srrq = #{srrq} </if>
<if test="shrq != null and shrq != ''"> and shrq = #{shrq} </if>
<if test="jzrq != null and jzrq != ''"> and jzrq = #{jzrq} </if>
<if test="pzhzkmdy != null and pzhzkmdy != ''"> and pzhzkmdy = #{pzhzkmdy} </if>
<if test="pzhzbz != null and pzhzbz != ''"> and pzhzbz = #{pzhzbz} </if>
<if test="zt != null"> and zt = #{zt} </if>
<if test="pzzy != null and pzzy != ''"> and pzzy = #{pzzy} </if>
<if test="pzje != null"> and pzje = #{pzje} </if>
<if test="cn != null and cn != ''"> and CN = #{cn} </if>
<if test="bz != null and bz != ''"> and BZ = #{bz} </if>
<if test="kjzg != null and kjzg != ''"> and kjzg = #{kjzg} </if>
<if test="dyzt != null and dyzt != ''"> and dyzt = #{dyzt} </if>
<if test="qzrq != null and qzrq != ''"> and QZRQ = #{qzrq} </if>
<if test="gdid != null"> and GDID = #{gdid} </if>
<if test="gdname != null and gdname != ''"> and GDName = #{gdname} </if>
<if test="gdrqsj != null and gdrqsj != ''"> and GDRQSJ = #{gdrqsj} </if>
<if test="gdcs != null"> and GDCS = #{gdcs} </if>
<if test="gdbz != null and gdbz != ''"> and GDBZ = #{gdbz} </if>
<if test="yspzzs != null"> and yspzzs = #{yspzzs} </if>
and sts='Y'
</trim>
</update>
<!--通过主键删除-->
<delete id="entity_delete">
delete from gl_pzml where idpzh= #{idpzh}
</delete>
<!--通过主键删除-->
<delete id="SenderGlPzmlEntity_delete_pzml">
delete from gl_pzml where gsdm= #{gsdm} and zth=#{zth}
<if test="kjqj != null and kjqj!=''"> and kjqj=#{kjqj}</if>
<if test="pzh != null and pzh!=''"> and pzh = #{pzh} </if>
<if test="idpzh != null and idpzh!=''"> and idpzh = #{idpzh} </if>
</delete>
</mapper>

Some files were not shown because too many files have changed in this diff Show More