diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/controller/BipApiController.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/controller/BipApiController.java new file mode 100644 index 00000000..07c72545 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/controller/BipApiController.java @@ -0,0 +1,41 @@ +package com.hzya.frame.finance.bip.controller; + +import cn.hutool.json.JSONObject; +import cn.hutool.json.JSONUtil; +import com.hzya.frame.finance.bip.service.IBipApiService; +import com.hzya.frame.web.action.DefaultController; +import com.hzya.frame.web.entity.JsonResultEntity; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestMethod; +import org.springframework.web.bind.annotation.RestController; + +/** + * Created by zydd on 2025-08-22 14:17 + */ +@RestController +@RequestMapping("/fe/bip/api") +public class BipApiController extends DefaultController { + + @Autowired + private IBipApiService bipApiService; + + @RequestMapping(value = "/getToken", method = RequestMethod.POST) + public JsonResultEntity getToken() { + try { + String bipToken = bipApiService.getToekn(); + JSONObject jsonObject = JSONUtil.parseObj(bipToken); + boolean success = (boolean) jsonObject.get("success"); + + if (success) { + return getSuccessMessageEntity(bipToken); + } else { + return getFailureMessageEntity(bipToken); + } + } catch (Exception e) { + e.printStackTrace(); + return getFailureMessageEntity("获取token失败,失败原因:{}。", e.getMessage()); + } + } + +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/service/IBipApiService.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/service/IBipApiService.java new file mode 100644 index 00000000..54c09a7a --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/service/IBipApiService.java @@ -0,0 +1,9 @@ +package com.hzya.frame.finance.bip.service; + +/** + * Created by zydd on 2025-08-22 14:19 + */ +public interface IBipApiService { + String getToekn() throws Exception; + +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/service/impl/IBipApiServiceImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/service/impl/IBipApiServiceImpl.java new file mode 100644 index 00000000..a38c158d --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/bip/service/impl/IBipApiServiceImpl.java @@ -0,0 +1,388 @@ +package com.hzya.frame.finance.bip.service.impl; + +import cn.hutool.core.lang.Assert; +import com.google.gson.Gson; +import com.hzya.frame.finance.bip.service.IBipApiService; +import com.hzya.frame.finance.utils.*; +import org.apache.commons.lang3.StringUtils; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.stereotype.Service; + +import java.io.*; +import java.net.HttpURLConnection; +import java.net.URL; +import java.net.URLEncoder; +import java.nio.charset.Charset; +import java.util.HashMap; +import java.util.Map; +import java.util.Properties; + +/** + * Created by zydd on 2025-08-22 14:19 + */ +@Service +public class IBipApiServiceImpl implements IBipApiService { + + + @Value("${spring.profiles.active}") + public String activeProfile; + // app_secret + private static String client_secret = null; + // 公钥 + private static String pubKey = null; + // app_id + private static String client_id = null; + // bip用户名 + private static String username = null; + private static String usercode = null; + // bip用户名密码 + private static String pwd = null; + // bip账套 + private static String busi_center = null; + private static String dsname = null; + // 获取token方式:client_credentials、password + private static String grant_type = null; + // 服务器ip:port + private static String baseUrl = null; + // 返回值压缩加密级别 + private static String secret_level = null; + // 请求参数 + private static String requestBody = null; + // openapi请求路径 + private static String apiUrl = null; + + // 访问api获取到的access_token + public static String token = null; + // 重复调用检查 + public static String repeat_check = null; + // 接口调用业务标识 + public static String busi_id = null; + + @Override + public String getToekn() throws Exception { + // 初始化数据 + init(); + //获取token + String token = getToken(); + return token; + } + + public String pushData(String url, String data, String bipUserCode) throws Exception { + Assert.notNull(url, "请求地址不能为空"); + Assert.notNull(data, "请求参数不能为空(需要JSON格式)"); + + // 初始化相关参数 + if (pubKey == null) { + init(); + } + if (bipUserCode == null) { + token = getTokenByPWD(); + } else { + token = getTokenByClient(bipUserCode); + } + // 发起api接口 + return sendApi(token, url, data); + } + + + + private void init() { + + Properties properties = new Properties(); + String filepath = "application-" + activeProfile + ".properties"; + ClassLoader classloader = Thread.currentThread().getContextClassLoader(); + InputStream inputStream = classloader.getResourceAsStream(filepath); + try { + InputStreamReader reader = new InputStreamReader(inputStream, "UTF-8"); + properties.load(reader); + + client_secret = new String(properties.getProperty("client_secret").getBytes("utf-8"), "utf-8"); + client_id = properties.getProperty("client_id"); + pubKey = properties.getProperty("pubKey"); + username = properties.getProperty("username"); + usercode = properties.getProperty("usercode"); + pwd = properties.getProperty("pwd"); + busi_center = properties.getProperty("busi_center"); + dsname = properties.getProperty("dsname"); + baseUrl = properties.getProperty("baseUrl"); + requestBody = new String(properties.getProperty("requestBody").getBytes("utf-8"), "utf-8"); +// apiUrl = properties.getProperty("apiUrl"); + grant_type = properties.getProperty("grant_type"); + secret_level = properties.getProperty("secret_level"); + repeat_check = properties.getProperty("repeat_check"); + busi_id = properties.getProperty("busi_id"); + } catch (IOException e) { + e.printStackTrace(); + } + } + + private static String getToken() throws Exception { + String token = null; + if ("password".equals(grant_type)) { + // 密码模式 + token = getTokenByPWD(); + } else if ("client_credentials".equals(grant_type)) { +// // 客户端模式 +// token = getTokenByClient(); + } + return token; + } + + private static String getTokenByClient(String userCode) throws Exception { + Map paramMap = new HashMap(); + // 密码模式认证 + paramMap.put("grant_type", "client_credentials"); + // 第三方应用id + paramMap.put("client_id", client_id); + // 第三方应用secret 公钥加密 + String secret_entryption = Encryption.pubEncrypt(pubKey, client_secret); +// System.out.println("secret_entryption::" + secret_entryption); + paramMap.put("client_secret", URLEncoder.encode(secret_entryption, "utf-8")); + // 账套编码 + paramMap.put("biz_center", busi_center); + paramMap.put("usercode", userCode); + // 签名 + String sign = SHA256Util.getSHA256(client_id + client_secret + pubKey, pubKey); + paramMap.put("signature", sign); +// System.out.println("##gettoken sign::" + sign); + + String url = baseUrl + "/biploud/opm/accesstoken"; + String mediaType = "application/x-www-form-urlencoded"; + String token = doPost(url, paramMap, mediaType, null, ""); + return token; + } + + private static String getTokenByPWD() throws Exception { + Map paramMap = new HashMap(); + // 密码模式认证 + paramMap.put("grant_type", "password"); + // 第三方应用id + paramMap.put("client_id", client_id); + // 第三方应用secret 公钥加密 + paramMap.put("client_secret", URLEncoder.encode(Encryption.pubEncrypt(pubKey, client_secret), "utf-8")); +// paramMap.put("client_secret", client_secret); + // bip用户名 + paramMap.put("username", username); + // 密码 公钥加密 + paramMap.put("password", URLEncoder.encode(Encryption.pubEncrypt(pubKey, pwd), "utf-8")); +// paramMap.put("password", pwd); + // 账套编码 + paramMap.put("biz_center", busi_center); + // 签名 + String sign = SHA256Util.getSHA256(client_id + client_secret + username + pwd + pubKey, pubKey); +// System.out.println("sign_getToken::" + sign); + paramMap.put("signature", sign); + + String url = baseUrl + "/biploud/opm/accesstoken"; + String mediaType = "application/x-www-form-urlencoded"; + String token = doPost(url, paramMap, mediaType, null, ""); + return token; + } + + private static String doPost(String baseUrl, Map paramMap, String mediaType, + Map headers, String json) throws Exception { + + HttpURLConnection urlConnection = null; + InputStream in = null; + OutputStream out = null; + BufferedReader bufferedReader = null; + String result = null; + try { + StringBuffer sb = new StringBuffer(); + sb.append(baseUrl); + if (paramMap != null) { + sb.append("?"); + for (Map.Entry entry : paramMap.entrySet()) { + String key = entry.getKey(); + String value = entry.getValue(); + sb.append(key + "=" + value).append("&"); + } + baseUrl = sb.toString().substring(0, sb.toString().length() - 1); + } + + URL urlObj = new URL(baseUrl); + urlConnection = (HttpURLConnection) urlObj.openConnection(); + urlConnection.setConnectTimeout(50000); + urlConnection.setRequestMethod("POST"); + urlConnection.setDoOutput(true); + urlConnection.setDoInput(true); + urlConnection.setUseCaches(false); + urlConnection.addRequestProperty("content-type", mediaType); + if (headers != null) { + for (String key : headers.keySet()) { + urlConnection.addRequestProperty(key, headers.get(key)); + } + } + out = urlConnection.getOutputStream(); + out.write(json.getBytes("utf-8")); + out.flush(); + int resCode = urlConnection.getResponseCode(); +// System.out.println("状态码::" + resCode); +// if (resCode == HttpURLConnection.HTTP_OK || resCode == HttpURLConnection.HTTP_CREATED || resCode == HttpURLConnection.HTTP_ACCEPTED) { + in = urlConnection.getInputStream(); +// } else { +// in = urlConnection.getErrorStream(); +// } + bufferedReader = new BufferedReader(new InputStreamReader(in, "utf-8")); + StringBuffer temp = new StringBuffer(); + String line = bufferedReader.readLine(); + while (line != null) { + temp.append(line).append("\r\n"); + line = bufferedReader.readLine(); + } + String ecod = urlConnection.getContentEncoding(); + if (ecod == null) { + ecod = Charset.forName("utf-8").name(); + } + result = new String(temp.toString().getBytes("utf-8"), ecod); +// System.out.println(result); + } catch (Exception e) { + System.out.println(e); + throw e; + } finally { + if (null != bufferedReader) { + try { + bufferedReader.close(); + } catch (IOException e) { + e.printStackTrace(); + } + } + if (null != out) { + try { + out.close(); + } catch (IOException e) { + e.printStackTrace(); + } + } + if (null != in) { + try { + in.close(); + } catch (IOException e) { + e.printStackTrace(); + } + } + urlConnection.disconnect(); + } + return result; + } + + private String sendApi(String token, String apiUrl, String putParameter) throws Exception { + // token转对象,获取api访问所用token和secret + ResultMessageUtil returnData = new Gson().fromJson(token, ResultMessageUtil.class); + Map data = (Map) returnData.getData(); + String access_token = (String) data.get("access_token"); + String security_key = (String) data.get("security_key"); + String refresh_token = (String) data.get("refresh_token"); + long expire_in = new Double((double) data.get("expires_in")).longValue(); + long ts = new Double((double) data.get("ts")).longValue(); + if (ts + expire_in < System.currentTimeMillis()) { + token = getTokenByPWD(); + returnData = new Gson().fromJson(token, ResultMessageUtil.class); + data = (Map) returnData.getData(); + access_token = (String) data.get("access_token"); + security_key = (String) data.get("security_key"); + refresh_token = (String) data.get("refresh_token"); + } +// System.out.println("ACCESS_TOKEN:" + access_token); + + // 请求路径 + String url = apiUrl; + // header 参数 + Map headermap = new HashMap<>(); + headermap.put("access_token", access_token); + headermap.put("client_id", client_id); + + StringBuffer sb = new StringBuffer(); + sb.append(client_id); + if (StringUtils.isNotBlank(putParameter)) { + // sb.append(requestBody.replaceAll("\\s*|\t|\r|\n", "").trim()); + sb.append(putParameter); + } + sb.append(pubKey); + String sign = SHA256Util.getSHA256(sb.toString(), pubKey); + headermap.put("signature", sign); + + if (StringUtils.isNotBlank(busi_id)) { + headermap.put("busi_id", busi_id); + } + if (StringUtils.isNotBlank(repeat_check)) { + headermap.put("repeat_check", repeat_check); + } + // headermap.put("ucg_flag", "y"); + + String mediaType = "application/json;charset=utf-8"; + + // 表体数据json + // 根据安全级别选择加密或压缩请求表体参数 + String json = dealRequestBody(putParameter, security_key, secret_level); + + // 返回值 + String result = doPost(url, null, mediaType, headermap, json); + String result2 = dealResponseBody(result, security_key, secret_level); +// System.out.println("【RESULT】:" + result); +// System.out.println("result解密:" + result2); + + return result2; + } + private static String dealRequestBody(String source, String security_key, String level) throws Exception { + String result = null; + if (StringUtils.isEmpty(level) || SecretConst.LEVEL0.equals(level)) { + result = source; + } else if (SecretConst.LEVEL1.equals(level)) { + result = Encryption.symEncrypt(security_key, source); + } else if (SecretConst.LEVEL2.equals(level)) { + result = CompressUtil.gzipCompress(source); + } else if (SecretConst.LEVEL3.equals(level)) { + result = Encryption.symEncrypt(security_key, CompressUtil.gzipCompress(source)); + } else if (SecretConst.LEVEL4.equals(level)) { + result = CompressUtil.gzipCompress(Encryption.symEncrypt(security_key, source)); + } else { + throw new Exception("无效的安全等级"); + } + + return result; + } + + private static String dealResponseBody(String source, String security_key, String level) throws Exception { + String result = null; + + if (StringUtils.isEmpty(level) || SecretConst.LEVEL0.equals(level)) { + result = source; + } else if (SecretConst.LEVEL1.equals(level)) { + result = Decryption.symDecrypt(security_key, source); + } else if (SecretConst.LEVEL2.equals(level)) { + result = CompressUtil.gzipDecompress(source); + } else if (SecretConst.LEVEL3.equals(level)) { + result = CompressUtil.gzipDecompress(Decryption.symDecrypt(security_key, source)); + } else if (SecretConst.LEVEL4.equals(level)) { + result = Decryption.symDecrypt(security_key, CompressUtil.gzipDecompress(source)); + } else { + throw new Exception("无效的安全等级"); + } + + return result; + } + + class SecretConst { + /** + * LEVEL0 不压缩、不加密 + */ + public static final String LEVEL0 = "L0"; + /** + * LEVEL1 只加密、不压缩 + */ + public static final String LEVEL1 = "L1"; + /** + * LEVEL2 只压缩、不加密 + */ + public static final String LEVEL2 = "L2"; + /** + * LEVEL3 先压缩、后加密 + */ + public static final String LEVEL3 = "L3"; + /** + * LEVEL4 先加密、后压缩 + */ + public static final String LEVEL4 = "L4"; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/controller/ClaimSKController.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/controller/ClaimSKController.java index 1b022db1..a8bc3445 100644 --- a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/controller/ClaimSKController.java +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/controller/ClaimSKController.java @@ -18,6 +18,7 @@ import java.util.Map; /** * Created by zydd on 2025-08-20 17:07 + * 认领功能 */ @RestController @RequestMapping("/fe/sk/claim") diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeFkBillBDao.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeFkBillBDao.java new file mode 100644 index 00000000..482cf11a --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeFkBillBDao.java @@ -0,0 +1,15 @@ +package com.hzya.frame.finance.claim.dao; + +import com.hzya.frame.finance.claim.entity.FeFkBillBEntity; +import com.hzya.frame.basedao.dao.IBaseDao; + +/** + * 财资事项(finance_event)-付款认领单-b(fe_fk_bill_b: table)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 15:50:52 + */ +public interface IFeFkBillBDao extends IBaseDao { + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeFkBillHDao.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeFkBillHDao.java new file mode 100644 index 00000000..b02f92ca --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeFkBillHDao.java @@ -0,0 +1,15 @@ +package com.hzya.frame.finance.claim.dao; + +import com.hzya.frame.finance.claim.entity.FeFkBillHEntity; +import com.hzya.frame.basedao.dao.IBaseDao; + +/** + * 财资事项(finance_event)-付款认领单-h(fe_fk_bill_h: table)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 15:50:33 + */ +public interface IFeFkBillHDao extends IBaseDao { + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeSkBillBDao.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeSkBillBDao.java new file mode 100644 index 00000000..b1245f2c --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeSkBillBDao.java @@ -0,0 +1,15 @@ +package com.hzya.frame.finance.claim.dao; + +import com.hzya.frame.finance.claim.entity.FeSkBillBEntity; +import com.hzya.frame.basedao.dao.IBaseDao; + +/** + * 财资事项(finance_event)-收款认领单-b(fe_sk_bill_b: table)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 15:51:20 + */ +public interface IFeSkBillBDao extends IBaseDao { + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeSkBillHDao.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeSkBillHDao.java new file mode 100644 index 00000000..4946f232 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/IFeSkBillHDao.java @@ -0,0 +1,15 @@ +package com.hzya.frame.finance.claim.dao; + +import com.hzya.frame.finance.claim.entity.FeSkBillHEntity; +import com.hzya.frame.basedao.dao.IBaseDao; + +/** + * 财资事项(finance_event)-收款认领单-h(fe_sk_bill_h: table)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 15:51:06 + */ +public interface IFeSkBillHDao extends IBaseDao { + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeFkBillBDaoImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeFkBillBDaoImpl.java new file mode 100644 index 00000000..284bef02 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeFkBillBDaoImpl.java @@ -0,0 +1,17 @@ +package com.hzya.frame.finance.claim.dao.impl; + +import com.hzya.frame.finance.claim.entity.FeFkBillBEntity; +import com.hzya.frame.finance.claim.dao.IFeFkBillBDao; +import org.springframework.stereotype.Repository; +import com.hzya.frame.basedao.dao.MybatisGenericDao; +/** + * 财资事项(finance_event)-付款认领单-b(FeFkBillB)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 15:50:52 + */ +@Repository +public class FeFkBillBDaoImpl extends MybatisGenericDao implements IFeFkBillBDao{ + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeFkBillHDaoImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeFkBillHDaoImpl.java new file mode 100644 index 00000000..3c0ab204 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeFkBillHDaoImpl.java @@ -0,0 +1,17 @@ +package com.hzya.frame.finance.claim.dao.impl; + +import com.hzya.frame.finance.claim.entity.FeFkBillHEntity; +import com.hzya.frame.finance.claim.dao.IFeFkBillHDao; +import org.springframework.stereotype.Repository; +import com.hzya.frame.basedao.dao.MybatisGenericDao; +/** + * 财资事项(finance_event)-付款认领单-h(FeFkBillH)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 15:50:33 + */ +@Repository +public class FeFkBillHDaoImpl extends MybatisGenericDao implements IFeFkBillHDao{ + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeSkBillBDaoImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeSkBillBDaoImpl.java new file mode 100644 index 00000000..eb15f715 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeSkBillBDaoImpl.java @@ -0,0 +1,17 @@ +package com.hzya.frame.finance.claim.dao.impl; + +import com.hzya.frame.finance.claim.entity.FeSkBillBEntity; +import com.hzya.frame.finance.claim.dao.IFeSkBillBDao; +import org.springframework.stereotype.Repository; +import com.hzya.frame.basedao.dao.MybatisGenericDao; +/** + * 财资事项(finance_event)-收款认领单-b(FeSkBillB)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 15:51:20 + */ +@Repository +public class FeSkBillBDaoImpl extends MybatisGenericDao implements IFeSkBillBDao{ + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeSkBillHDaoImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeSkBillHDaoImpl.java new file mode 100644 index 00000000..734ec322 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/dao/impl/FeSkBillHDaoImpl.java @@ -0,0 +1,17 @@ +package com.hzya.frame.finance.claim.dao.impl; + +import com.hzya.frame.finance.claim.entity.FeSkBillHEntity; +import com.hzya.frame.finance.claim.dao.IFeSkBillHDao; +import org.springframework.stereotype.Repository; +import com.hzya.frame.basedao.dao.MybatisGenericDao; +/** + * 财资事项(finance_event)-收款认领单-h(FeSkBillH)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 15:51:06 + */ +@Repository +public class FeSkBillHDaoImpl extends MybatisGenericDao implements IFeSkBillHDao{ + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillBEntity.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillBEntity.java new file mode 100644 index 00000000..0e00a856 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillBEntity.java @@ -0,0 +1,80 @@ +package com.hzya.frame.finance.claim.entity; + +import java.util.Date; + +import com.hzya.frame.web.entity.BaseEntity; +import lombok.Data; + +/** + * 财资事项(finance_event)-付款认领单-b(FeFkBillB)实体类 + * + * @author zydd + * @since 2025-08-22 15:50:52 + */ +@Data +public class FeFkBillBEntity extends BaseEntity { + + /** + * 主表id + */ + private Long hId; + /** + * 摘要 + */ + private String zy; + /** + * 款项性质 + */ + private String nature; + /** + * 款项类别 + */ + private String type; + /** + * 币种 + */ + private String currencyId; + private String currencyCode; + private String currencyName; + /** + * 金额 + */ + private String money; + /** + * 表述说明 + */ + private String explain; + /** + * 关联流水表id + */ + private String sourceFlowId; + /** + * 关联银行流水id + */ + private String sourceFlowBankId; + /** + * 备注 + */ + private String remark; + private String def1; + private String def2; + private String def3; + private String def4; + private String def5; + private String def6; + private String def7; + private String def8; + private String def9; + private String def10; + /** + * 创建人 + */ + private String createUser; + /** + * 修改人 + */ + private String modifyUser; + + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillBEntity.xml b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillBEntity.xml new file mode 100644 index 00000000..e88ab485 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillBEntity.xml @@ -0,0 +1,437 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + id + ,h_id + ,abstract + ,nature + ,type + ,currency_id + ,currency_code + ,currency_name + ,money + ,explain + ,source_flow_id + ,source_flow_bank_id + ,remark + ,def1 + ,def2 + ,def3 + ,def4 + ,def5 + ,def6 + ,def7 + ,def8 + ,def9 + ,def10 + ,create_time + ,create_user + ,modify_time + ,modify_user + ,sts + + + + + + + + + + + + + + + + insert into fe_fk_bill_b( + + id , + h_id , + abstract , + nature , + type , + currency_id , + currency_code , + currency_name , + money , + explain , + source_flow_id , + source_flow_bank_id , + remark , + def1 , + def2 , + def3 , + def4 , + def5 , + def6 , + def7 , + def8 , + def9 , + def10 , + create_time , + create_user , + modify_time , + modify_user , + sts , + sts, + + )values( + + #{id} , + #{hId} , + #{abstract} , + #{nature} , + #{type} , + #{currencyId} , + #{currencyCode} , + #{currencyName} , + #{money} , + #{explain} , + #{sourceFlowId} , + #{sourceFlowBankId} , + #{remark} , + #{def1} , + #{def2} , + #{def3} , + #{def4} , + #{def5} , + #{def6} , + #{def7} , + #{def8} , + #{def9} , + #{def10} , + #{create_time} , + #{createUser} , + #{modify_time} , + #{modifyUser} , + #{sts} , + 'Y', + + ) + + + + insert into fe_fk_bill_b(h_id, abstract, nature, type, currency_id, currency_code, currency_name, money, + explain, source_flow_id, source_flow_bank_id, remark, def1, def2, def3, def4, def5, def6, def7, def8, def9, + def10, create_time, create_user, modify_time, modify_user, sts, sts) + values + + (#{entity.hId},#{entity.abstract},#{entity.nature},#{entity.type},#{entity.currencyId},#{entity.currencyCode},#{entity.currencyName},#{entity.money},#{entity.explain},#{entity.sourceFlowId},#{entity.sourceFlowBankId},#{entity.remark},#{entity.def1},#{entity.def2},#{entity.def3},#{entity.def4},#{entity.def5},#{entity.def6},#{entity.def7},#{entity.def8},#{entity.def9},#{entity.def10},#{entity.create_time},#{entity.createUser},#{entity.modify_time},#{entity.modifyUser},#{entity.sts}, + 'Y') + + + + + insert into fe_fk_bill_b(h_id, abstract, nature, type, currency_id, currency_code, currency_name, money, + explain, source_flow_id, source_flow_bank_id, remark, def1, def2, def3, def4, def5, def6, def7, def8, def9, + def10, create_time, create_user, modify_time, modify_user, sts) + values + + (#{entity.hId},#{entity.abstract},#{entity.nature},#{entity.type},#{entity.currencyId},#{entity.currencyCode},#{entity.currencyName},#{entity.money},#{entity.explain},#{entity.sourceFlowId},#{entity.sourceFlowBankId},#{entity.remark},#{entity.def1},#{entity.def2},#{entity.def3},#{entity.def4},#{entity.def5},#{entity.def6},#{entity.def7},#{entity.def8},#{entity.def9},#{entity.def10},#{entity.create_time},#{entity.createUser},#{entity.modify_time},#{entity.modifyUser},#{entity.sts}) + + on duplicate key update + h_id = values(h_id), + abstract = values(abstract), + nature = values(nature), + type = values(type), + currency_id = values(currency_id), + currency_code = values(currency_code), + currency_name = values(currency_name), + money = values(money), + explain = values(explain), + source_flow_id = values(source_flow_id), + source_flow_bank_id = values(source_flow_bank_id), + remark = values(remark), + def1 = values(def1), + def2 = values(def2), + def3 = values(def3), + def4 = values(def4), + def5 = values(def5), + def6 = values(def6), + def7 = values(def7), + def8 = values(def8), + def9 = values(def9), + def10 = values(def10), + create_time = values(create_time), + create_user = values(create_user), + modify_time = values(modify_time), + modify_user = values(modify_user), + sts = values(sts) + + + + update fe_fk_bill_b set + + h_id = #{hId}, + abstract = #{abstract}, + nature = #{nature}, + type = #{type}, + currency_id = #{currencyId}, + currency_code = #{currencyCode}, + currency_name = #{currencyName}, + money = #{money}, + explain = #{explain}, + source_flow_id = #{sourceFlowId}, + source_flow_bank_id = #{sourceFlowBankId}, + + remark = #{remark}, + def1 = #{def1}, + def2 = #{def2}, + def3 = #{def3}, + def4 = #{def4}, + def5 = #{def5}, + def6 = #{def6}, + def7 = #{def7}, + def8 = #{def8}, + def9 = #{def9}, + def10 = #{def10}, + create_time = #{create_time}, + create_user = #{createUser}, + modify_time = #{modify_time}, + modify_user = #{modifyUser}, + sts = #{sts}, + + where id = #{id} + + + + update fe_fk_bill_b + set sts= 'N', + modify_time = #{modify_time}, + modify_user_id = #{modify_user_id} + where id = #{id} + + + + update fe_fk_bill_b set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id} + + and id = #{id} + and h_id = #{hId} + and abstract = #{abstract} + and nature = #{nature} + and type = #{type} + and currency_id = #{currencyId} + and currency_code = #{currencyCode} + and currency_name = #{currencyName} + and money = #{money} + and explain = #{explain} + and source_flow_id = #{sourceFlowId} + and source_flow_bank_id = + #{sourceFlowBankId} + + and remark = #{remark} + and def1 = #{def1} + and def2 = #{def2} + and def3 = #{def3} + and def4 = #{def4} + and def5 = #{def5} + and def6 = #{def6} + and def7 = #{def7} + and def8 = #{def8} + and def9 = #{def9} + and def10 = #{def10} + and create_user = #{createUser} + and modify_user = #{modifyUser} + and sts = #{sts} + and sts='Y' + + + + + delete + from fe_fk_bill_b + where id = #{id} + + + + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillHEntity.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillHEntity.java new file mode 100644 index 00000000..b67f92c3 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillHEntity.java @@ -0,0 +1,308 @@ +package com.hzya.frame.finance.claim.entity; + +import java.util.Date; +import com.hzya.frame.web.entity.BaseEntity; +/** + * 财资事项(finance_event)-付款认领单-h(FeFkBillH)实体类 + * + * @author zydd + * @since 2025-08-22 15:50:33 + */ +public class FeFkBillHEntity extends BaseEntity { + + /** 认领单号 */ + private String billCode; + /** 认领日期 */ + private String billData; + /** 客户id */ + private String customerId; + private String customerCode; + private String customerName; + /** 是否自动认领 */ + private String isAutoClaim; + /** 认领人id */ + private String claimUserId; + /** 银行id */ + private String bankId; + private String bankCode; + private String bankName; + /** 收款银行账号 */ + private String bankNum; + /** 财务组织id */ + private String financeOrgId; + private String financeOrgCode; + private String financeOrgName; + /** 往来对象id */ + private String wldxId; + private String wldxCode; + private String wldxName; + /** 认领金额 */ + private String claimSum; + /** 备注 */ + private String remark; + private String def1; + private String def2; + private String def3; + private String def4; + private String def5; + private String def6; + private String def7; + private String def8; + private String def9; + private String def10; + /** 创建人 */ + private String createUser; + /** 修改人 */ + private String modifyUser; + + + public String getBillCode() { + return billCode; + } + + public void setBillCode(String billCode) { + this.billCode = billCode; + } + + public String getBillData() { + return billData; + } + + public void setBillData(String billData) { + this.billData = billData; + } + + public String getCustomerId() { + return customerId; + } + + public void setCustomerId(String customerId) { + this.customerId = customerId; + } + + public String getCustomerCode() { + return customerCode; + } + + public void setCustomerCode(String customerCode) { + this.customerCode = customerCode; + } + + public String getCustomerName() { + return customerName; + } + + public void setCustomerName(String customerName) { + this.customerName = customerName; + } + + public String getIsAutoClaim() { + return isAutoClaim; + } + + public void setIsAutoClaim(String isAutoClaim) { + this.isAutoClaim = isAutoClaim; + } + + public String getClaimUserId() { + return claimUserId; + } + + public void setClaimUserId(String claimUserId) { + this.claimUserId = claimUserId; + } + + public String getBankId() { + return bankId; + } + + public void setBankId(String bankId) { + this.bankId = bankId; + } + + public String getBankCode() { + return bankCode; + } + + public void setBankCode(String bankCode) { + this.bankCode = bankCode; + } + + public String getBankName() { + return bankName; + } + + public void setBankName(String bankName) { + this.bankName = bankName; + } + + public String getBankNum() { + return bankNum; + } + + public void setBankNum(String bankNum) { + this.bankNum = bankNum; + } + + public String getFinanceOrgId() { + return financeOrgId; + } + + public void setFinanceOrgId(String financeOrgId) { + this.financeOrgId = financeOrgId; + } + + public String getFinanceOrgCode() { + return financeOrgCode; + } + + public void setFinanceOrgCode(String financeOrgCode) { + this.financeOrgCode = financeOrgCode; + } + + public String getFinanceOrgName() { + return financeOrgName; + } + + public void setFinanceOrgName(String financeOrgName) { + this.financeOrgName = financeOrgName; + } + + public String getWldxId() { + return wldxId; + } + + public void setWldxId(String wldxId) { + this.wldxId = wldxId; + } + + public String getWldxCode() { + return wldxCode; + } + + public void setWldxCode(String wldxCode) { + this.wldxCode = wldxCode; + } + + public String getWldxName() { + return wldxName; + } + + public void setWldxName(String wldxName) { + this.wldxName = wldxName; + } + + public String getClaimSum() { + return claimSum; + } + + public void setClaimSum(String claimSum) { + this.claimSum = claimSum; + } + + public String getRemark() { + return remark; + } + + public void setRemark(String remark) { + this.remark = remark; + } + + public String getDef1() { + return def1; + } + + public void setDef1(String def1) { + this.def1 = def1; + } + + public String getDef2() { + return def2; + } + + public void setDef2(String def2) { + this.def2 = def2; + } + + public String getDef3() { + return def3; + } + + public void setDef3(String def3) { + this.def3 = def3; + } + + public String getDef4() { + return def4; + } + + public void setDef4(String def4) { + this.def4 = def4; + } + + public String getDef5() { + return def5; + } + + public void setDef5(String def5) { + this.def5 = def5; + } + + public String getDef6() { + return def6; + } + + public void setDef6(String def6) { + this.def6 = def6; + } + + public String getDef7() { + return def7; + } + + public void setDef7(String def7) { + this.def7 = def7; + } + + public String getDef8() { + return def8; + } + + public void setDef8(String def8) { + this.def8 = def8; + } + + public String getDef9() { + return def9; + } + + public void setDef9(String def9) { + this.def9 = def9; + } + + public String getDef10() { + return def10; + } + + public void setDef10(String def10) { + this.def10 = def10; + } + + public String getCreateUser() { + return createUser; + } + + public void setCreateUser(String createUser) { + this.createUser = createUser; + } + + public String getModifyUser() { + return modifyUser; + } + + public void setModifyUser(String modifyUser) { + this.modifyUser = modifyUser; + } + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillHEntity.xml b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillHEntity.xml new file mode 100644 index 00000000..f0684c32 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeFkBillHEntity.xml @@ -0,0 +1,492 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + id + ,bill_code + ,bill_data + ,customer_id + ,customer_code + ,customer_name + ,is_auto_claim + ,claim_user_id + ,bank_id + ,bank_code + ,bank_name + ,bank_num + ,finance_org_id + ,finance_org_code + ,finance_org_name + ,wldx_id + ,wldx_code + ,wldx_name + ,claim_sum + ,remark + ,def1 + ,def2 + ,def3 + ,def4 + ,def5 + ,def6 + ,def7 + ,def8 + ,def9 + ,def10 + ,create_time + ,create_user + ,modify_time + ,modify_user + ,sts + + + + + + + + + + + + + + + + insert into fe_fk_bill_h( + + id , + bill_code , + bill_data , + customer_id , + customer_code , + customer_name , + is_auto_claim , + claim_user_id , + bank_id , + bank_code , + bank_name , + bank_num , + finance_org_id , + finance_org_code , + finance_org_name , + wldx_id , + wldx_code , + wldx_name , + claim_sum , + remark , + def1 , + def2 , + def3 , + def4 , + def5 , + def6 , + def7 , + def8 , + def9 , + def10 , + create_time , + create_user , + modify_time , + modify_user , + sts , + sorts, + sts, + + )values( + + #{id} , + #{billCode} , + #{billData} , + #{customerId} , + #{customerCode} , + #{customerName} , + #{isAutoClaim} , + #{claimUserId} , + #{bankId} , + #{bankCode} , + #{bankName} , + #{bankNum} , + #{financeOrgId} , + #{financeOrgCode} , + #{financeOrgName} , + #{wldxId} , + #{wldxCode} , + #{wldxName} , + #{claimSum} , + #{remark} , + #{def1} , + #{def2} , + #{def3} , + #{def4} , + #{def5} , + #{def6} , + #{def7} , + #{def8} , + #{def9} , + #{def10} , + #{create_time} , + #{createUser} , + #{modify_time} , + #{modifyUser} , + #{sts} , + (select (max(IFNULL( a.sorts, 0 )) + 1) as sort from fe_fk_bill_h a WHERE a.sts = 'Y' ), + 'Y', + + ) + + + + insert into fe_fk_bill_h(bill_code, bill_data, customer_id, customer_code, customer_name, is_auto_claim, claim_user_id, bank_id, bank_code, bank_name, bank_num, finance_org_id, finance_org_code, finance_org_name, wldx_id, wldx_code, wldx_name, claim_sum, remark, def1, def2, def3, def4, def5, def6, def7, def8, def9, def10, create_time, create_user, modify_time, modify_user, sts, sts) + values + + (#{entity.billCode},#{entity.billData},#{entity.customerId},#{entity.customerCode},#{entity.customerName},#{entity.isAutoClaim},#{entity.claimUserId},#{entity.bankId},#{entity.bankCode},#{entity.bankName},#{entity.bankNum},#{entity.financeOrgId},#{entity.financeOrgCode},#{entity.financeOrgName},#{entity.wldxId},#{entity.wldxCode},#{entity.wldxName},#{entity.claimSum},#{entity.remark},#{entity.def1},#{entity.def2},#{entity.def3},#{entity.def4},#{entity.def5},#{entity.def6},#{entity.def7},#{entity.def8},#{entity.def9},#{entity.def10},#{entity.create_time},#{entity.createUser},#{entity.modify_time},#{entity.modifyUser},#{entity.sts}, 'Y') + + + + + insert into fe_fk_bill_h(bill_code, bill_data, customer_id, customer_code, customer_name, is_auto_claim, claim_user_id, bank_id, bank_code, bank_name, bank_num, finance_org_id, finance_org_code, finance_org_name, wldx_id, wldx_code, wldx_name, claim_sum, remark, def1, def2, def3, def4, def5, def6, def7, def8, def9, def10, create_time, create_user, modify_time, modify_user, sts) + values + + (#{entity.billCode},#{entity.billData},#{entity.customerId},#{entity.customerCode},#{entity.customerName},#{entity.isAutoClaim},#{entity.claimUserId},#{entity.bankId},#{entity.bankCode},#{entity.bankName},#{entity.bankNum},#{entity.financeOrgId},#{entity.financeOrgCode},#{entity.financeOrgName},#{entity.wldxId},#{entity.wldxCode},#{entity.wldxName},#{entity.claimSum},#{entity.remark},#{entity.def1},#{entity.def2},#{entity.def3},#{entity.def4},#{entity.def5},#{entity.def6},#{entity.def7},#{entity.def8},#{entity.def9},#{entity.def10},#{entity.create_time},#{entity.createUser},#{entity.modify_time},#{entity.modifyUser},#{entity.sts}) + + on duplicate key update + bill_code = values(bill_code), + bill_data = values(bill_data), + customer_id = values(customer_id), + customer_code = values(customer_code), + customer_name = values(customer_name), + is_auto_claim = values(is_auto_claim), + claim_user_id = values(claim_user_id), + bank_id = values(bank_id), + bank_code = values(bank_code), + bank_name = values(bank_name), + bank_num = values(bank_num), + finance_org_id = values(finance_org_id), + finance_org_code = values(finance_org_code), + finance_org_name = values(finance_org_name), + wldx_id = values(wldx_id), + wldx_code = values(wldx_code), + wldx_name = values(wldx_name), + claim_sum = values(claim_sum), + remark = values(remark), + def1 = values(def1), + def2 = values(def2), + def3 = values(def3), + def4 = values(def4), + def5 = values(def5), + def6 = values(def6), + def7 = values(def7), + def8 = values(def8), + def9 = values(def9), + def10 = values(def10), + create_time = values(create_time), + create_user = values(create_user), + modify_time = values(modify_time), + modify_user = values(modify_user), + sts = values(sts) + + +update fe_fk_bill_h set + + bill_code = #{billCode}, + bill_data = #{billData}, + customer_id = #{customerId}, + customer_code = #{customerCode}, + customer_name = #{customerName}, + is_auto_claim = #{isAutoClaim}, + claim_user_id = #{claimUserId}, + bank_id = #{bankId}, + bank_code = #{bankCode}, + bank_name = #{bankName}, + bank_num = #{bankNum}, + finance_org_id = #{financeOrgId}, + finance_org_code = #{financeOrgCode}, + finance_org_name = #{financeOrgName}, + wldx_id = #{wldxId}, + wldx_code = #{wldxCode}, + wldx_name = #{wldxName}, + claim_sum = #{claimSum}, + remark = #{remark}, + def1 = #{def1}, + def2 = #{def2}, + def3 = #{def3}, + def4 = #{def4}, + def5 = #{def5}, + def6 = #{def6}, + def7 = #{def7}, + def8 = #{def8}, + def9 = #{def9}, + def10 = #{def10}, + create_time = #{create_time}, + create_user = #{createUser}, + modify_time = #{modify_time}, + modify_user = #{modifyUser}, + sts = #{sts}, + +where id = #{id} + + + +update fe_fk_bill_h set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id} +where id = #{id} + + + +update fe_fk_bill_h set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id} + + and id = #{id} + and bill_code = #{billCode} + and bill_data = #{billData} + and customer_id = #{customerId} + and customer_code = #{customerCode} + and customer_name = #{customerName} + and is_auto_claim = #{isAutoClaim} + and claim_user_id = #{claimUserId} + and bank_id = #{bankId} + and bank_code = #{bankCode} + and bank_name = #{bankName} + and bank_num = #{bankNum} + and finance_org_id = #{financeOrgId} + and finance_org_code = #{financeOrgCode} + and finance_org_name = #{financeOrgName} + and wldx_id = #{wldxId} + and wldx_code = #{wldxCode} + and wldx_name = #{wldxName} + and claim_sum = #{claimSum} + and remark = #{remark} + and def1 = #{def1} + and def2 = #{def2} + and def3 = #{def3} + and def4 = #{def4} + and def5 = #{def5} + and def6 = #{def6} + and def7 = #{def7} + and def8 = #{def8} + and def9 = #{def9} + and def10 = #{def10} + and create_user = #{createUser} + and modify_user = #{modifyUser} + and sts = #{sts} + and sts='Y' + + + + + delete from fe_fk_bill_h where id = #{id} + + + + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillBEntity.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillBEntity.java new file mode 100644 index 00000000..19f8e81e --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillBEntity.java @@ -0,0 +1,80 @@ +package com.hzya.frame.finance.claim.entity; + +import java.util.Date; + +import com.hzya.frame.web.entity.BaseEntity; +import lombok.Data; + +/** + * 财资事项(finance_event)-收款认领单-b(FeSkBillB)实体类 + * + * @author zydd + * @since 2025-08-22 15:51:20 + */ +@Data +public class FeSkBillBEntity extends BaseEntity { + + /** + * 主表id + */ + private Long hId; + /** + * 摘要 + */ + private String zy; + /** + * 款项性质 + */ + private String nature; + /** + * 款项类别 + */ + private String type; + /** + * 币种 + */ + private String currencyId; + private String currencyCode; + private String currencyName; + /** + * 金额 + */ + private String money; + /** + * 表述说明 + */ + private String explain; + /** + * 关联流水表id + */ + private String sourceFlowId; + /** + * 关联银行流水id + */ + private String sourceFlowBankId; + /** + * 备注 + */ + private String remark; + private String def1; + private String def2; + private String def3; + private String def4; + private String def5; + private String def6; + private String def7; + private String def8; + private String def9; + private String def10; + /** + * 创建人 + */ + private String createUser; + /** + * 修改人 + */ + private String modifyUser; + + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillBEntity.xml b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillBEntity.xml new file mode 100644 index 00000000..3222f325 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillBEntity.xml @@ -0,0 +1,415 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + id + ,h_id + ,abstract + ,nature + ,type + ,currency_id + ,currency_code + ,currency_name + ,money + ,explain + ,source_flow_id + ,source_flow_bank_id + ,remark + ,def1 + ,def2 + ,def3 + ,def4 + ,def5 + ,def6 + ,def7 + ,def8 + ,def9 + ,def10 + ,create_time + ,create_user + ,modify_time + ,modify_user + ,sts + + + + + + + + + + + + + + + + insert into fe_sk_bill_b( + + id , + h_id , + abstract , + nature , + type , + currency_id , + currency_code , + currency_name , + money , + explain , + source_flow_id , + source_flow_bank_id , + remark , + def1 , + def2 , + def3 , + def4 , + def5 , + def6 , + def7 , + def8 , + def9 , + def10 , + create_time , + create_user , + modify_time , + modify_user , + sts , + sorts, + sts, + + )values( + + #{id} , + #{hId} , + #{abstract} , + #{nature} , + #{type} , + #{currencyId} , + #{currencyCode} , + #{currencyName} , + #{money} , + #{explain} , + #{sourceFlowId} , + #{sourceFlowBankId} , + #{remark} , + #{def1} , + #{def2} , + #{def3} , + #{def4} , + #{def5} , + #{def6} , + #{def7} , + #{def8} , + #{def9} , + #{def10} , + #{create_time} , + #{createUser} , + #{modify_time} , + #{modifyUser} , + #{sts} , + (select (max(IFNULL( a.sorts, 0 )) + 1) as sort from fe_sk_bill_b a WHERE a.sts = 'Y' ), + 'Y', + + ) + + + + insert into fe_sk_bill_b(h_id, abstract, nature, type, currency_id, currency_code, currency_name, money, explain, source_flow_id, source_flow_bank_id, remark, def1, def2, def3, def4, def5, def6, def7, def8, def9, def10, create_time, create_user, modify_time, modify_user, sts, sts) + values + + (#{entity.hId},#{entity.abstract},#{entity.nature},#{entity.type},#{entity.currencyId},#{entity.currencyCode},#{entity.currencyName},#{entity.money},#{entity.explain},#{entity.sourceFlowId},#{entity.sourceFlowBankId},#{entity.remark},#{entity.def1},#{entity.def2},#{entity.def3},#{entity.def4},#{entity.def5},#{entity.def6},#{entity.def7},#{entity.def8},#{entity.def9},#{entity.def10},#{entity.create_time},#{entity.createUser},#{entity.modify_time},#{entity.modifyUser},#{entity.sts}, 'Y') + + + + + insert into fe_sk_bill_b(h_id, abstract, nature, type, currency_id, currency_code, currency_name, money, explain, source_flow_id, source_flow_bank_id, remark, def1, def2, def3, def4, def5, def6, def7, def8, def9, def10, create_time, create_user, modify_time, modify_user, sts) + values + + (#{entity.hId},#{entity.abstract},#{entity.nature},#{entity.type},#{entity.currencyId},#{entity.currencyCode},#{entity.currencyName},#{entity.money},#{entity.explain},#{entity.sourceFlowId},#{entity.sourceFlowBankId},#{entity.remark},#{entity.def1},#{entity.def2},#{entity.def3},#{entity.def4},#{entity.def5},#{entity.def6},#{entity.def7},#{entity.def8},#{entity.def9},#{entity.def10},#{entity.create_time},#{entity.createUser},#{entity.modify_time},#{entity.modifyUser},#{entity.sts}) + + on duplicate key update + h_id = values(h_id), + abstract = values(abstract), + nature = values(nature), + type = values(type), + currency_id = values(currency_id), + currency_code = values(currency_code), + currency_name = values(currency_name), + money = values(money), + explain = values(explain), + source_flow_id = values(source_flow_id), + source_flow_bank_id = values(source_flow_bank_id), + remark = values(remark), + def1 = values(def1), + def2 = values(def2), + def3 = values(def3), + def4 = values(def4), + def5 = values(def5), + def6 = values(def6), + def7 = values(def7), + def8 = values(def8), + def9 = values(def9), + def10 = values(def10), + create_time = values(create_time), + create_user = values(create_user), + modify_time = values(modify_time), + modify_user = values(modify_user), + sts = values(sts) + + +update fe_sk_bill_b set + + h_id = #{hId}, + abstract = #{abstract}, + nature = #{nature}, + type = #{type}, + currency_id = #{currencyId}, + currency_code = #{currencyCode}, + currency_name = #{currencyName}, + money = #{money}, + explain = #{explain}, + source_flow_id = #{sourceFlowId}, + source_flow_bank_id = #{sourceFlowBankId}, + remark = #{remark}, + def1 = #{def1}, + def2 = #{def2}, + def3 = #{def3}, + def4 = #{def4}, + def5 = #{def5}, + def6 = #{def6}, + def7 = #{def7}, + def8 = #{def8}, + def9 = #{def9}, + def10 = #{def10}, + create_time = #{create_time}, + create_user = #{createUser}, + modify_time = #{modify_time}, + modify_user = #{modifyUser}, + sts = #{sts}, + +where id = #{id} + + + +update fe_sk_bill_b set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id} +where id = #{id} + + + +update fe_sk_bill_b set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id} + + and id = #{id} + and h_id = #{hId} + and abstract = #{abstract} + and nature = #{nature} + and type = #{type} + and currency_id = #{currencyId} + and currency_code = #{currencyCode} + and currency_name = #{currencyName} + and money = #{money} + and explain = #{explain} + and source_flow_id = #{sourceFlowId} + and source_flow_bank_id = #{sourceFlowBankId} + and remark = #{remark} + and def1 = #{def1} + and def2 = #{def2} + and def3 = #{def3} + and def4 = #{def4} + and def5 = #{def5} + and def6 = #{def6} + and def7 = #{def7} + and def8 = #{def8} + and def9 = #{def9} + and def10 = #{def10} + and create_user = #{createUser} + and modify_user = #{modifyUser} + and sts = #{sts} + and sts='Y' + + + + + delete from fe_sk_bill_b where id = #{id} + + + + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillHEntity.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillHEntity.java new file mode 100644 index 00000000..dbb6ef54 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillHEntity.java @@ -0,0 +1,308 @@ +package com.hzya.frame.finance.claim.entity; + +import java.util.Date; +import com.hzya.frame.web.entity.BaseEntity; +/** + * 财资事项(finance_event)-收款认领单-h(FeSkBillH)实体类 + * + * @author zydd + * @since 2025-08-22 15:51:06 + */ +public class FeSkBillHEntity extends BaseEntity { + + /** 认领单号 */ + private String billCode; + /** 认领日期 */ + private String billData; + /** 客户id */ + private String customerId; + private String customerCode; + private String customerName; + /** 是否自动认领 */ + private String isAutoClaim; + /** 认领人id */ + private String claimUserId; + /** 银行id */ + private String bankId; + private String bankCode; + private String bankName; + /** 收款银行账号 */ + private String bankNum; + /** 财务组织id */ + private String financeOrgId; + private String financeOrgCode; + private String financeOrgName; + /** 往来对象id */ + private String wldxId; + private String wldxCode; + private String wldxName; + /** 认领金额 */ + private String claimSum; + /** 备注 */ + private String remark; + private String def1; + private String def2; + private String def3; + private String def4; + private String def5; + private String def6; + private String def7; + private String def8; + private String def9; + private String def10; + /** 创建人 */ + private String createUser; + /** 修改人 */ + private String modifyUser; + + + public String getBillCode() { + return billCode; + } + + public void setBillCode(String billCode) { + this.billCode = billCode; + } + + public String getBillData() { + return billData; + } + + public void setBillData(String billData) { + this.billData = billData; + } + + public String getCustomerId() { + return customerId; + } + + public void setCustomerId(String customerId) { + this.customerId = customerId; + } + + public String getCustomerCode() { + return customerCode; + } + + public void setCustomerCode(String customerCode) { + this.customerCode = customerCode; + } + + public String getCustomerName() { + return customerName; + } + + public void setCustomerName(String customerName) { + this.customerName = customerName; + } + + public String getIsAutoClaim() { + return isAutoClaim; + } + + public void setIsAutoClaim(String isAutoClaim) { + this.isAutoClaim = isAutoClaim; + } + + public String getClaimUserId() { + return claimUserId; + } + + public void setClaimUserId(String claimUserId) { + this.claimUserId = claimUserId; + } + + public String getBankId() { + return bankId; + } + + public void setBankId(String bankId) { + this.bankId = bankId; + } + + public String getBankCode() { + return bankCode; + } + + public void setBankCode(String bankCode) { + this.bankCode = bankCode; + } + + public String getBankName() { + return bankName; + } + + public void setBankName(String bankName) { + this.bankName = bankName; + } + + public String getBankNum() { + return bankNum; + } + + public void setBankNum(String bankNum) { + this.bankNum = bankNum; + } + + public String getFinanceOrgId() { + return financeOrgId; + } + + public void setFinanceOrgId(String financeOrgId) { + this.financeOrgId = financeOrgId; + } + + public String getFinanceOrgCode() { + return financeOrgCode; + } + + public void setFinanceOrgCode(String financeOrgCode) { + this.financeOrgCode = financeOrgCode; + } + + public String getFinanceOrgName() { + return financeOrgName; + } + + public void setFinanceOrgName(String financeOrgName) { + this.financeOrgName = financeOrgName; + } + + public String getWldxId() { + return wldxId; + } + + public void setWldxId(String wldxId) { + this.wldxId = wldxId; + } + + public String getWldxCode() { + return wldxCode; + } + + public void setWldxCode(String wldxCode) { + this.wldxCode = wldxCode; + } + + public String getWldxName() { + return wldxName; + } + + public void setWldxName(String wldxName) { + this.wldxName = wldxName; + } + + public String getClaimSum() { + return claimSum; + } + + public void setClaimSum(String claimSum) { + this.claimSum = claimSum; + } + + public String getRemark() { + return remark; + } + + public void setRemark(String remark) { + this.remark = remark; + } + + public String getDef1() { + return def1; + } + + public void setDef1(String def1) { + this.def1 = def1; + } + + public String getDef2() { + return def2; + } + + public void setDef2(String def2) { + this.def2 = def2; + } + + public String getDef3() { + return def3; + } + + public void setDef3(String def3) { + this.def3 = def3; + } + + public String getDef4() { + return def4; + } + + public void setDef4(String def4) { + this.def4 = def4; + } + + public String getDef5() { + return def5; + } + + public void setDef5(String def5) { + this.def5 = def5; + } + + public String getDef6() { + return def6; + } + + public void setDef6(String def6) { + this.def6 = def6; + } + + public String getDef7() { + return def7; + } + + public void setDef7(String def7) { + this.def7 = def7; + } + + public String getDef8() { + return def8; + } + + public void setDef8(String def8) { + this.def8 = def8; + } + + public String getDef9() { + return def9; + } + + public void setDef9(String def9) { + this.def9 = def9; + } + + public String getDef10() { + return def10; + } + + public void setDef10(String def10) { + this.def10 = def10; + } + + public String getCreateUser() { + return createUser; + } + + public void setCreateUser(String createUser) { + this.createUser = createUser; + } + + public String getModifyUser() { + return modifyUser; + } + + public void setModifyUser(String modifyUser) { + this.modifyUser = modifyUser; + } + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillHEntity.xml b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillHEntity.xml new file mode 100644 index 00000000..5febb647 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/entity/FeSkBillHEntity.xml @@ -0,0 +1,492 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + id + ,bill_code + ,bill_data + ,customer_id + ,customer_code + ,customer_name + ,is_auto_claim + ,claim_user_id + ,bank_id + ,bank_code + ,bank_name + ,bank_num + ,finance_org_id + ,finance_org_code + ,finance_org_name + ,wldx_id + ,wldx_code + ,wldx_name + ,claim_sum + ,remark + ,def1 + ,def2 + ,def3 + ,def4 + ,def5 + ,def6 + ,def7 + ,def8 + ,def9 + ,def10 + ,create_time + ,create_user + ,modify_time + ,modify_user + ,sts + + + + + + + + + + + + + + + + insert into fe_sk_bill_h( + + id , + bill_code , + bill_data , + customer_id , + customer_code , + customer_name , + is_auto_claim , + claim_user_id , + bank_id , + bank_code , + bank_name , + bank_num , + finance_org_id , + finance_org_code , + finance_org_name , + wldx_id , + wldx_code , + wldx_name , + claim_sum , + remark , + def1 , + def2 , + def3 , + def4 , + def5 , + def6 , + def7 , + def8 , + def9 , + def10 , + create_time , + create_user , + modify_time , + modify_user , + sts , + sorts, + sts, + + )values( + + #{id} , + #{billCode} , + #{billData} , + #{customerId} , + #{customerCode} , + #{customerName} , + #{isAutoClaim} , + #{claimUserId} , + #{bankId} , + #{bankCode} , + #{bankName} , + #{bankNum} , + #{financeOrgId} , + #{financeOrgCode} , + #{financeOrgName} , + #{wldxId} , + #{wldxCode} , + #{wldxName} , + #{claimSum} , + #{remark} , + #{def1} , + #{def2} , + #{def3} , + #{def4} , + #{def5} , + #{def6} , + #{def7} , + #{def8} , + #{def9} , + #{def10} , + #{create_time} , + #{createUser} , + #{modify_time} , + #{modifyUser} , + #{sts} , + (select (max(IFNULL( a.sorts, 0 )) + 1) as sort from fe_sk_bill_h a WHERE a.sts = 'Y' ), + 'Y', + + ) + + + + insert into fe_sk_bill_h(bill_code, bill_data, customer_id, customer_code, customer_name, is_auto_claim, claim_user_id, bank_id, bank_code, bank_name, bank_num, finance_org_id, finance_org_code, finance_org_name, wldx_id, wldx_code, wldx_name, claim_sum, remark, def1, def2, def3, def4, def5, def6, def7, def8, def9, def10, create_time, create_user, modify_time, modify_user, sts, sts) + values + + (#{entity.billCode},#{entity.billData},#{entity.customerId},#{entity.customerCode},#{entity.customerName},#{entity.isAutoClaim},#{entity.claimUserId},#{entity.bankId},#{entity.bankCode},#{entity.bankName},#{entity.bankNum},#{entity.financeOrgId},#{entity.financeOrgCode},#{entity.financeOrgName},#{entity.wldxId},#{entity.wldxCode},#{entity.wldxName},#{entity.claimSum},#{entity.remark},#{entity.def1},#{entity.def2},#{entity.def3},#{entity.def4},#{entity.def5},#{entity.def6},#{entity.def7},#{entity.def8},#{entity.def9},#{entity.def10},#{entity.create_time},#{entity.createUser},#{entity.modify_time},#{entity.modifyUser},#{entity.sts}, 'Y') + + + + + insert into fe_sk_bill_h(bill_code, bill_data, customer_id, customer_code, customer_name, is_auto_claim, claim_user_id, bank_id, bank_code, bank_name, bank_num, finance_org_id, finance_org_code, finance_org_name, wldx_id, wldx_code, wldx_name, claim_sum, remark, def1, def2, def3, def4, def5, def6, def7, def8, def9, def10, create_time, create_user, modify_time, modify_user, sts) + values + + (#{entity.billCode},#{entity.billData},#{entity.customerId},#{entity.customerCode},#{entity.customerName},#{entity.isAutoClaim},#{entity.claimUserId},#{entity.bankId},#{entity.bankCode},#{entity.bankName},#{entity.bankNum},#{entity.financeOrgId},#{entity.financeOrgCode},#{entity.financeOrgName},#{entity.wldxId},#{entity.wldxCode},#{entity.wldxName},#{entity.claimSum},#{entity.remark},#{entity.def1},#{entity.def2},#{entity.def3},#{entity.def4},#{entity.def5},#{entity.def6},#{entity.def7},#{entity.def8},#{entity.def9},#{entity.def10},#{entity.create_time},#{entity.createUser},#{entity.modify_time},#{entity.modifyUser},#{entity.sts}) + + on duplicate key update + bill_code = values(bill_code), + bill_data = values(bill_data), + customer_id = values(customer_id), + customer_code = values(customer_code), + customer_name = values(customer_name), + is_auto_claim = values(is_auto_claim), + claim_user_id = values(claim_user_id), + bank_id = values(bank_id), + bank_code = values(bank_code), + bank_name = values(bank_name), + bank_num = values(bank_num), + finance_org_id = values(finance_org_id), + finance_org_code = values(finance_org_code), + finance_org_name = values(finance_org_name), + wldx_id = values(wldx_id), + wldx_code = values(wldx_code), + wldx_name = values(wldx_name), + claim_sum = values(claim_sum), + remark = values(remark), + def1 = values(def1), + def2 = values(def2), + def3 = values(def3), + def4 = values(def4), + def5 = values(def5), + def6 = values(def6), + def7 = values(def7), + def8 = values(def8), + def9 = values(def9), + def10 = values(def10), + create_time = values(create_time), + create_user = values(create_user), + modify_time = values(modify_time), + modify_user = values(modify_user), + sts = values(sts) + + +update fe_sk_bill_h set + + bill_code = #{billCode}, + bill_data = #{billData}, + customer_id = #{customerId}, + customer_code = #{customerCode}, + customer_name = #{customerName}, + is_auto_claim = #{isAutoClaim}, + claim_user_id = #{claimUserId}, + bank_id = #{bankId}, + bank_code = #{bankCode}, + bank_name = #{bankName}, + bank_num = #{bankNum}, + finance_org_id = #{financeOrgId}, + finance_org_code = #{financeOrgCode}, + finance_org_name = #{financeOrgName}, + wldx_id = #{wldxId}, + wldx_code = #{wldxCode}, + wldx_name = #{wldxName}, + claim_sum = #{claimSum}, + remark = #{remark}, + def1 = #{def1}, + def2 = #{def2}, + def3 = #{def3}, + def4 = #{def4}, + def5 = #{def5}, + def6 = #{def6}, + def7 = #{def7}, + def8 = #{def8}, + def9 = #{def9}, + def10 = #{def10}, + create_time = #{create_time}, + create_user = #{createUser}, + modify_time = #{modify_time}, + modify_user = #{modifyUser}, + sts = #{sts}, + +where id = #{id} + + + +update fe_sk_bill_h set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id} +where id = #{id} + + + +update fe_sk_bill_h set sts= 'N' ,modify_time = #{modify_time},modify_user_id = #{modify_user_id} + + and id = #{id} + and bill_code = #{billCode} + and bill_data = #{billData} + and customer_id = #{customerId} + and customer_code = #{customerCode} + and customer_name = #{customerName} + and is_auto_claim = #{isAutoClaim} + and claim_user_id = #{claimUserId} + and bank_id = #{bankId} + and bank_code = #{bankCode} + and bank_name = #{bankName} + and bank_num = #{bankNum} + and finance_org_id = #{financeOrgId} + and finance_org_code = #{financeOrgCode} + and finance_org_name = #{financeOrgName} + and wldx_id = #{wldxId} + and wldx_code = #{wldxCode} + and wldx_name = #{wldxName} + and claim_sum = #{claimSum} + and remark = #{remark} + and def1 = #{def1} + and def2 = #{def2} + and def3 = #{def3} + and def4 = #{def4} + and def5 = #{def5} + and def6 = #{def6} + and def7 = #{def7} + and def8 = #{def8} + and def9 = #{def9} + and def10 = #{def10} + and create_user = #{createUser} + and modify_user = #{modifyUser} + and sts = #{sts} + and sts='Y' + + + + + delete from fe_sk_bill_h where id = #{id} + + + + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeFkBillBService.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeFkBillBService.java new file mode 100644 index 00000000..615b82e0 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeFkBillBService.java @@ -0,0 +1,12 @@ +package com.hzya.frame.finance.claim.service; + +import com.hzya.frame.finance.claim.entity.FeFkBillBEntity; +import com.hzya.frame.basedao.service.IBaseService; +/** + * 财资事项(finance_event)-付款认领单-b(FeFkBillB)表服务接口 + * + * @author zydd + * @since 2025-08-22 15:50:52 + */ +public interface IFeFkBillBService extends IBaseService{ +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeFkBillHService.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeFkBillHService.java new file mode 100644 index 00000000..ff499444 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeFkBillHService.java @@ -0,0 +1,12 @@ +package com.hzya.frame.finance.claim.service; + +import com.hzya.frame.finance.claim.entity.FeFkBillHEntity; +import com.hzya.frame.basedao.service.IBaseService; +/** + * 财资事项(finance_event)-付款认领单-h(FeFkBillH)表服务接口 + * + * @author zydd + * @since 2025-08-22 15:50:33 + */ +public interface IFeFkBillHService extends IBaseService{ +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeSkBillBService.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeSkBillBService.java new file mode 100644 index 00000000..4d2224a7 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeSkBillBService.java @@ -0,0 +1,12 @@ +package com.hzya.frame.finance.claim.service; + +import com.hzya.frame.finance.claim.entity.FeSkBillBEntity; +import com.hzya.frame.basedao.service.IBaseService; +/** + * 财资事项(finance_event)-收款认领单-b(FeSkBillB)表服务接口 + * + * @author zydd + * @since 2025-08-22 15:51:20 + */ +public interface IFeSkBillBService extends IBaseService{ +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeSkBillHService.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeSkBillHService.java new file mode 100644 index 00000000..8ae4f596 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/IFeSkBillHService.java @@ -0,0 +1,12 @@ +package com.hzya.frame.finance.claim.service; + +import com.hzya.frame.finance.claim.entity.FeSkBillHEntity; +import com.hzya.frame.basedao.service.IBaseService; +/** + * 财资事项(finance_event)-收款认领单-h(FeSkBillH)表服务接口 + * + * @author zydd + * @since 2025-08-22 15:51:06 + */ +public interface IFeSkBillHService extends IBaseService{ +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeFkBillBServiceImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeFkBillBServiceImpl.java new file mode 100644 index 00000000..c86bfdbb --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeFkBillBServiceImpl.java @@ -0,0 +1,26 @@ +package com.hzya.frame.finance.claim.service.impl; + +import com.hzya.frame.finance.claim.entity.FeFkBillBEntity; +import com.hzya.frame.finance.claim.dao.IFeFkBillBDao; +import com.hzya.frame.finance.claim.service.IFeFkBillBService; +import org.springframework.stereotype.Service; +import org.springframework.beans.factory.annotation.Autowired; +import javax.annotation.Resource; +import com.hzya.frame.basedao.service.impl.BaseService; +/** + * 财资事项(finance_event)-付款认领单-b(FeFkBillB)表服务实现类 + * + * @author zydd + * @since 2025-08-22 15:50:52 + */ +@Service +public class FeFkBillBServiceImpl extends BaseService implements IFeFkBillBService { + + private IFeFkBillBDao feFkBillBDao; + + @Autowired + public void setFeFkBillBDao(IFeFkBillBDao dao) { + this.feFkBillBDao = dao; + this.dao = dao; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeFkBillHServiceImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeFkBillHServiceImpl.java new file mode 100644 index 00000000..98a40cf8 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeFkBillHServiceImpl.java @@ -0,0 +1,26 @@ +package com.hzya.frame.finance.claim.service.impl; + +import com.hzya.frame.finance.claim.entity.FeFkBillHEntity; +import com.hzya.frame.finance.claim.dao.IFeFkBillHDao; +import com.hzya.frame.finance.claim.service.IFeFkBillHService; +import org.springframework.stereotype.Service; +import org.springframework.beans.factory.annotation.Autowired; +import javax.annotation.Resource; +import com.hzya.frame.basedao.service.impl.BaseService; +/** + * 财资事项(finance_event)-付款认领单-h(FeFkBillH)表服务实现类 + * + * @author zydd + * @since 2025-08-22 15:50:33 + */ +@Service +public class FeFkBillHServiceImpl extends BaseService implements IFeFkBillHService { + + private IFeFkBillHDao feFkBillHDao; + + @Autowired + public void setFeFkBillHDao(IFeFkBillHDao dao) { + this.feFkBillHDao = dao; + this.dao = dao; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeSkBillBServiceImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeSkBillBServiceImpl.java new file mode 100644 index 00000000..16eceda9 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeSkBillBServiceImpl.java @@ -0,0 +1,26 @@ +package com.hzya.frame.finance.claim.service.impl; + +import com.hzya.frame.finance.claim.entity.FeSkBillBEntity; +import com.hzya.frame.finance.claim.dao.IFeSkBillBDao; +import com.hzya.frame.finance.claim.service.IFeSkBillBService; +import org.springframework.stereotype.Service; +import org.springframework.beans.factory.annotation.Autowired; +import javax.annotation.Resource; +import com.hzya.frame.basedao.service.impl.BaseService; +/** + * 财资事项(finance_event)-收款认领单-b(FeSkBillB)表服务实现类 + * + * @author zydd + * @since 2025-08-22 15:51:20 + */ +@Service +public class FeSkBillBServiceImpl extends BaseService implements IFeSkBillBService { + + private IFeSkBillBDao feSkBillBDao; + + @Autowired + public void setFeSkBillBDao(IFeSkBillBDao dao) { + this.feSkBillBDao = dao; + this.dao = dao; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeSkBillHServiceImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeSkBillHServiceImpl.java new file mode 100644 index 00000000..12139f86 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/FeSkBillHServiceImpl.java @@ -0,0 +1,26 @@ +package com.hzya.frame.finance.claim.service.impl; + +import com.hzya.frame.finance.claim.entity.FeSkBillHEntity; +import com.hzya.frame.finance.claim.dao.IFeSkBillHDao; +import com.hzya.frame.finance.claim.service.IFeSkBillHService; +import org.springframework.stereotype.Service; +import org.springframework.beans.factory.annotation.Autowired; +import javax.annotation.Resource; +import com.hzya.frame.basedao.service.impl.BaseService; +/** + * 财资事项(finance_event)-收款认领单-h(FeSkBillH)表服务实现类 + * + * @author zydd + * @since 2025-08-22 15:51:06 + */ +@Service +public class FeSkBillHServiceImpl extends BaseService implements IFeSkBillHService { + + private IFeSkBillHDao feSkBillHDao; + + @Autowired + public void setFeSkBillHDao(IFeSkBillHDao dao) { + this.feSkBillHDao = dao; + this.dao = dao; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/IClaimSKServiceImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/IClaimSKServiceImpl.java index d8401bd0..70bc8395 100644 --- a/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/IClaimSKServiceImpl.java +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/claim/service/impl/IClaimSKServiceImpl.java @@ -56,14 +56,14 @@ public class IClaimSKServiceImpl implements IClaimSKService { public MdmViewVo queryFlowFileds(MdmDBQueryVO entity) { CreateVoucherVO createVoucherVO = new CreateVoucherVO(); - createVoucherVO.setMdmId("60d0374c9fa743019b0c1488a4eac1fe"); + createVoucherVO.setMdmId("266e61002d7a4b0cadaf89fbcf30c7fd"); MdmViewVo mdmViewVo = aePushVoucherLogService.queryBillFileds(createVoucherVO); return mdmViewVo; } @Override public PageInfo queryFlowDatePaged(MdmDBQueryVO entity) { - entity.setTablename("mdm_kk_bankflow_ccb"); + entity.setTablename("mdm_kk_bankflow_gts"); if(entity.getBillstatus()!=null){ entity.setClaimstatus(entity.getBillstatus()); @@ -84,6 +84,12 @@ public class IClaimSKServiceImpl implements IClaimSKService { //prop7 对方账号 //prop8 对方行名 + //prop9 收款付款 outFlag=D/C + if(entity.getOutFlag()!=null&& !"".equals(entity.getOutFlag())){ + entity.setProp9("outFlag"); + entity.setPropValue1(entity.getOutFlag()); + } + PageHelper.startPage(entity.getPageNum(), entity.getPageSize()); List> maps= mdmDBQueryVODAO.queryMdmDateBySK(entity); PageInfo pageInfo = new PageInfo(maps); @@ -92,7 +98,7 @@ public class IClaimSKServiceImpl implements IClaimSKService { @Override public List> queryFlowDateIds(MdmDBQueryVO entity) { - entity.setTablename("mdm_kk_bankflow_ccb"); + entity.setTablename("mdm_kk_bankflow_gts"); List> maps= mdmDBQueryVODAO.queryMdmDateBySK(entity); diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/conf/fileeigen/service/impl/FeConfFileEigenServiceImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/conf/fileeigen/service/impl/FeConfFileEigenServiceImpl.java index c0e377b7..d3d17d9e 100644 --- a/base-buildpackage/src/main/java/com/hzya/frame/finance/conf/fileeigen/service/impl/FeConfFileEigenServiceImpl.java +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/conf/fileeigen/service/impl/FeConfFileEigenServiceImpl.java @@ -56,7 +56,7 @@ public class FeConfFileEigenServiceImpl extends BaseService queryAll(FeConfFileEigenEntity entity) { checkAssistNull("queryAll", entity); - List query = feConfFileEigenDao.query(entity); + List query = feConfFileEigenDao.queryByLike(entity); return query; } @@ -301,6 +301,24 @@ public class FeConfFileEigenServiceImpl extends BaseService mdmDbFiledVOList = mdmDbFiledVODAO.queryMdmDbFiledVOByMdmID(mdmDbFiledVO); + if(mdmDbFiledVOList==null||mdmDbFiledVOList.size()==0){ + Assert.state(false,"根据mdmId:{},查询字段名细失败",mdmId); + } + MdmDbFiledVO mdmDbFiled = mdmDbFiledVOList.get(0); + String fieldName = mdmDbFiled.getNamefieldname(); + if(fieldName==null){ + Assert.state(false,"根据mdmId:{},查询名称字段名细失败。",mdmId); + } + String mdmDataName = entity.getMdmDataName(); + if(mdmDataName!=null){ + mdmDBQueryVO.setProp1(fieldName); + mdmDBQueryVO.setPropValue1(mdmDataName); + } + + PageHelper.startPage(mdmDBQueryVO.getPageNum(), mdmDBQueryVO.getPageSize()); List> dataMapList = mdmDBQueryVODAO.queryMdmDb(mdmDBQueryVO); diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/controller/GTSController.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/controller/GTSController.java new file mode 100644 index 00000000..0bd8b5ab --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/controller/GTSController.java @@ -0,0 +1,33 @@ +package com.hzya.frame.finance.flow.controller; + +import com.hzya.frame.finance.flow.entity.MdmKkBankflowGtsEntity; +import com.hzya.frame.finance.flow.service.IMdmKkBankflowGtsService; +import com.hzya.frame.web.action.DefaultController; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.web.bind.annotation.RequestBody; +import org.springframework.web.bind.annotation.RequestMapping; +import org.springframework.web.bind.annotation.RequestMethod; +import org.springframework.web.bind.annotation.RestController; + +import java.util.UUID; + +/** + * Created by zydd on 2025-08-22 09:41 + */ +@RestController +@RequestMapping("/fe/flow/gts") +public class GTSController extends DefaultController { + + @Autowired + private IMdmKkBankflowGtsService bankflowGtsService; + + @RequestMapping(value = "/insert", method = RequestMethod.POST) + public void insert(@RequestBody MdmKkBankflowGtsEntity entity) throws Exception { + for (int i = 0; i < 4000; i++) { + MdmKkBankflowGtsEntity mdmKkBankflowGtsEntity = new MdmKkBankflowGtsEntity(); + mdmKkBankflowGtsEntity.setId(UUID.randomUUID().toString()); + bankflowGtsService.save(mdmKkBankflowGtsEntity); + } + } + +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/dao/IMdmKkBankflowGtsDao.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/dao/IMdmKkBankflowGtsDao.java new file mode 100644 index 00000000..4eb6928c --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/dao/IMdmKkBankflowGtsDao.java @@ -0,0 +1,15 @@ +package com.hzya.frame.finance.flow.dao; + +import com.hzya.frame.finance.flow.entity.MdmKkBankflowGtsEntity; +import com.hzya.frame.basedao.dao.IBaseDao; + +/** + * 账户明细查询(GTS)(mdm_kk_bankflow_gts: table)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 09:36:27 + */ +public interface IMdmKkBankflowGtsDao extends IBaseDao { + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/dao/impl/MdmKkBankflowGtsDaoImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/dao/impl/MdmKkBankflowGtsDaoImpl.java new file mode 100644 index 00000000..290f0313 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/dao/impl/MdmKkBankflowGtsDaoImpl.java @@ -0,0 +1,17 @@ +package com.hzya.frame.finance.flow.dao.impl; + +import com.hzya.frame.finance.flow.entity.MdmKkBankflowGtsEntity; +import com.hzya.frame.finance.flow.dao.IMdmKkBankflowGtsDao; +import org.springframework.stereotype.Repository; +import com.hzya.frame.basedao.dao.MybatisGenericDao; +/** + * 账户明细查询(GTS)(MdmKkBankflowGts)表数据库访问层 + * + * @author zydd + * @since 2025-08-22 09:36:27 + */ +@Repository +public class MdmKkBankflowGtsDaoImpl extends MybatisGenericDao implements IMdmKkBankflowGtsDao{ + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/entity/MdmKkBankflowGtsEntity.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/entity/MdmKkBankflowGtsEntity.java new file mode 100644 index 00000000..26071f5c --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/entity/MdmKkBankflowGtsEntity.java @@ -0,0 +1,84 @@ +package com.hzya.frame.finance.flow.entity; + +import java.util.Date; +import com.hzya.frame.web.entity.BaseEntity; +import lombok.Data; + +/** + * 账户明细查询(GTS)(MdmKkBankflowGts)实体类 + * + * @author zydd + * @since 2025-08-22 09:36:27 + */ +@Data +public class MdmKkBankflowGtsEntity extends BaseEntity { + + /** 单据规则 */ + private String documentRule; + /** 单据规则流水号 */ + private Long documentRuleNum; + /** 数据状态 Y正常 N删除 F修改 */ + private String dataStatus; + /** 新增数据状态 0待下发 1已下发 */ + private String addStatus; + /** 修改数据状态 0待下发 1已下发 */ + private String updateStatus; + /** 删除数据状态 0待下发 1已下发 */ + private String deleteStatus; + /** 公司id */ + private String companyId; + /** data_id */ + private String dataId; + /** mdm_up_id */ + private String mdmUpId; + /** 交易流水号 */ + private String transeqno1; + /** 对方户名 */ + private String cnteracctname; + /** 对方账户 */ + private String cnteracctno; + /** 对方开户行 */ + private String opnbnkinfo; + /** 交易金额 */ + private String tranamt; + /** 转入金额 */ + private String inamtlot; + /** 转出金额 */ + private String tfroutamt; + /** 币种 */ + private String ccy; + /** 余额 */ + private String balance; + /** 转入/转出标志 */ + private String outflag; + /** 企业流水 */ + private String bussseqno; + /** 银行流水 */ + private String bnkprchseqno; + /** 交易日期 */ + private String trandate; + /** 交易时间 */ + private String trantimep; + /** 用途 */ + private String yt; + /** 单据号 */ + private String deprecptid; + /** 交易类型 */ + private String trantpcdset; + /** 保留 */ + private String kpdmn; + /** 摘要 */ + private String zy; + /** 备注 */ + private String remark; + /** 附言 */ + private String postscript; + /** 流水类型 */ + private String rsrvfldnm; + /** 认领状态 */ + private String claimstatus; + /** 认领单号 */ + private String claimbillcode; + +} + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/entity/MdmKkBankflowGtsEntity.xml b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/entity/MdmKkBankflowGtsEntity.xml new file mode 100644 index 00000000..8747c93b --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/entity/MdmKkBankflowGtsEntity.xml @@ -0,0 +1,600 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + id + ,document_rule + ,document_rule_num + ,data_status + ,add_status + ,update_status + ,delete_status + ,sorts + ,create_user_id + ,create_time + ,modify_user_id + ,modify_time + ,sts + ,org_id + ,company_id + ,data_id + ,mdm_up_id + ,transeqno1 + ,cnteracctname + ,cnteracctno + ,opnbnkinfo + ,tranamt + ,inamtlot + ,tfroutamt + ,ccy + ,balance + ,outflag + ,bussseqno + ,bnkprchseqno + ,trandate + ,trantimep + ,yt + ,deprecptid + ,trantpcdset + ,kpdmn + ,zy + ,remark + ,postscript + ,rsrvfldnm + ,claimstatus + ,claimbillcode + + + + + + + + + + + + + + + + insert into mdm_kk_bankflow_gts( + + id , + document_rule , + document_rule_num , + data_status , + add_status , + update_status , + delete_status , + sorts , + create_user_id , + create_time , + create_time , + modify_user_id , + modify_time , + modify_time , + sts , + org_id , + company_id , + data_id , + mdm_up_id , + transeqno1 , + cnteracctname , + cnteracctno , + opnbnkinfo , + tranamt , + inamtlot , + tfroutamt , + ccy , + balance , + outflag , + bussseqno , + bnkprchseqno , + trandate , + trantimep , + yt , + deprecptid , + trantpcdset , + kpdmn , + zy , + remark , + postscript , + rsrvfldnm , + claimstatus , + claimbillcode , + sorts, + sts, + + )values( + + #{id} , + #{documentRule} , + #{documentRuleNum} , + #{dataStatus} , + #{addStatus} , + #{updateStatus} , + #{deleteStatus} , + #{sorts} , + #{create_user_id} , + #{create_time} , + now() , + #{modify_user_id} , + #{modify_time} , + now() , + #{sts} , + #{org_id} , + #{companyId} , + #{dataId} , + #{mdmUpId} , + #{transeqno1} , + #{cnteracctname} , + #{cnteracctno} , + #{opnbnkinfo} , + #{tranamt} , + #{inamtlot} , + #{tfroutamt} , + #{ccy} , + #{balance} , + #{outflag} , + #{bussseqno} , + #{bnkprchseqno} , + #{trandate} , + #{trantimep} , + #{yt} , + #{deprecptid} , + #{trantpcdset} , + #{kpdmn} , + #{zy} , + #{remark} , + #{postscript} , + #{rsrvfldnm} , + #{claimstatus} , + #{claimbillcode} , + (select (max(IFNULL( a.sorts, 0 )) + 1) as sort from mdm_kk_bankflow_gts a WHERE + a.sts = 'Y' ), + + 'Y', + + ) + + + + insert into mdm_kk_bankflow_gts(document_rule, document_rule_num, data_status, add_status, update_status, + delete_status, create_user_id, create_time, modify_user_id, modify_time, sts, org_id, company_id, data_id, + mdm_up_id, transeqno1, cnteracctname, cnteracctno, opnbnkinfo, tranamt, inamtlot, tfroutamt, ccy, balance, + outflag, bussseqno, bnkprchseqno, trandate, trantimep, yt, deprecptid, trantpcdset, kpdmn, zy, remark, + postscript, rsrvfldnm, claimstatus, claimbillcode, sts) + values + + (#{entity.documentRule},#{entity.documentRuleNum},#{entity.dataStatus},#{entity.addStatus},#{entity.updateStatus},#{entity.deleteStatus},#{entity.create_user_id},#{entity.create_time},#{entity.modify_user_id},#{entity.modify_time},#{entity.sts},#{entity.org_id},#{entity.companyId},#{entity.dataId},#{entity.mdmUpId},#{entity.transeqno1},#{entity.cnteracctname},#{entity.cnteracctno},#{entity.opnbnkinfo},#{entity.tranamt},#{entity.inamtlot},#{entity.tfroutamt},#{entity.ccy},#{entity.balance},#{entity.outflag},#{entity.bussseqno},#{entity.bnkprchseqno},#{entity.trandate},#{entity.trantimep},#{entity.yt},#{entity.deprecptid},#{entity.trantpcdset},#{entity.kpdmn},#{entity.zy},#{entity.remark},#{entity.postscript},#{entity.rsrvfldnm},#{entity.claimstatus},#{entity.claimbillcode}, + 'Y') + + + + + insert into mdm_kk_bankflow_gts(document_rule, document_rule_num, data_status, add_status, update_status, + delete_status, create_user_id, create_time, modify_user_id, modify_time, sts, org_id, company_id, data_id, + mdm_up_id, transeqno1, cnteracctname, cnteracctno, opnbnkinfo, tranamt, inamtlot, tfroutamt, ccy, balance, + outflag, bussseqno, bnkprchseqno, trandate, trantimep, yt, deprecptid, trantpcdset, kpdmn, zy, remark, + postscript, rsrvfldnm, claimstatus, claimbillcode) + values + + (#{entity.documentRule},#{entity.documentRuleNum},#{entity.dataStatus},#{entity.addStatus},#{entity.updateStatus},#{entity.deleteStatus},#{entity.create_user_id},#{entity.create_time},#{entity.modify_user_id},#{entity.modify_time},#{entity.sts},#{entity.org_id},#{entity.companyId},#{entity.dataId},#{entity.mdmUpId},#{entity.transeqno1},#{entity.cnteracctname},#{entity.cnteracctno},#{entity.opnbnkinfo},#{entity.tranamt},#{entity.inamtlot},#{entity.tfroutamt},#{entity.ccy},#{entity.balance},#{entity.outflag},#{entity.bussseqno},#{entity.bnkprchseqno},#{entity.trandate},#{entity.trantimep},#{entity.yt},#{entity.deprecptid},#{entity.trantpcdset},#{entity.kpdmn},#{entity.zy},#{entity.remark},#{entity.postscript},#{entity.rsrvfldnm},#{entity.claimstatus},#{entity.claimbillcode}) + + on duplicate key update + document_rule = values(document_rule), + document_rule_num = values(document_rule_num), + data_status = values(data_status), + add_status = values(add_status), + update_status = values(update_status), + delete_status = values(delete_status), + create_user_id = values(create_user_id), + create_time = values(create_time), + modify_user_id = values(modify_user_id), + modify_time = values(modify_time), + sts = values(sts), + org_id = values(org_id), + company_id = values(company_id), + data_id = values(data_id), + mdm_up_id = values(mdm_up_id), + transeqno1 = values(transeqno1), + cnteracctname = values(cnteracctname), + cnteracctno = values(cnteracctno), + opnbnkinfo = values(opnbnkinfo), + tranamt = values(tranamt), + inamtlot = values(inamtlot), + tfroutamt = values(tfroutamt), + ccy = values(ccy), + balance = values(balance), + outflag = values(outflag), + bussseqno = values(bussseqno), + bnkprchseqno = values(bnkprchseqno), + trandate = values(trandate), + trantimep = values(trantimep), + yt = values(yt), + deprecptid = values(deprecptid), + trantpcdset = values(trantpcdset), + kpdmn = values(kpdmn), + zy = values(zy), + remark = values(remark), + postscript = values(postscript), + rsrvfldnm = values(rsrvfldnm), + claimstatus = values(claimstatus), + claimbillcode = values(claimbillcode) + + + + update mdm_kk_bankflow_gts set + + document_rule = #{documentRule}, + document_rule_num = #{documentRuleNum}, + data_status = #{dataStatus}, + add_status = #{addStatus}, + update_status = #{updateStatus}, + delete_status = #{deleteStatus}, + create_user_id = #{create_user_id}, + create_time = #{create_time}, + modify_user_id = #{modify_user_id}, + modify_time = #{modify_time}, + modify_time = now(), + sts = #{sts}, + org_id = #{org_id}, + company_id = #{companyId}, + data_id = #{dataId}, + mdm_up_id = #{mdmUpId}, + transeqno1 = #{transeqno1}, + cnteracctname = #{cnteracctname}, + cnteracctno = #{cnteracctno}, + opnbnkinfo = #{opnbnkinfo}, + tranamt = #{tranamt}, + inamtlot = #{inamtlot}, + tfroutamt = #{tfroutamt}, + ccy = #{ccy}, + balance = #{balance}, + outflag = #{outflag}, + bussseqno = #{bussseqno}, + bnkprchseqno = #{bnkprchseqno}, + trandate = #{trandate}, + trantimep = #{trantimep}, + yt = #{yt}, + deprecptid = #{deprecptid}, + trantpcdset = #{trantpcdset}, + kpdmn = #{kpdmn}, + zy = #{zy}, + remark = #{remark}, + postscript = #{postscript}, + rsrvfldnm = #{rsrvfldnm}, + claimstatus = #{claimstatus}, + claimbillcode = #{claimbillcode}, + + where id = #{id} + + + + update mdm_kk_bankflow_gts + set sts= 'N', + modify_time = #{modify_time}, + modify_user_id = #{modify_user_id} + where id = #{id} + + + + update mdm_kk_bankflow_gts set sts= 'N' ,modify_time =now() + + and id = #{id} + and document_rule = #{documentRule} + and document_rule_num = #{documentRuleNum} + and data_status = #{dataStatus} + and add_status = #{addStatus} + and update_status = #{updateStatus} + and delete_status = #{deleteStatus} + and sorts = #{sorts} + and sts = #{sts} + and company_id = #{companyId} + and data_id = #{dataId} + and mdm_up_id = #{mdmUpId} + and transeqno1 = #{transeqno1} + and cnteracctname = #{cnteracctname} + and cnteracctno = #{cnteracctno} + and opnbnkinfo = #{opnbnkinfo} + and tranamt = #{tranamt} + and inamtlot = #{inamtlot} + and tfroutamt = #{tfroutamt} + and ccy = #{ccy} + and balance = #{balance} + and outflag = #{outflag} + and bussseqno = #{bussseqno} + and bnkprchseqno = #{bnkprchseqno} + and trandate = #{trandate} + and trantimep = #{trantimep} + and yt = #{yt} + and deprecptid = #{deprecptid} + and trantpcdset = #{trantpcdset} + and kpdmn = #{kpdmn} + and zy = #{zy} + and remark = #{remark} + and postscript = #{postscript} + and rsrvfldnm = #{rsrvfldnm} + and claimstatus = #{claimstatus} + and claimbillcode = #{claimbillcode} + and sts='Y' + + + + + delete + from mdm_kk_bankflow_gts + where id = #{id} + + + + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/service/IMdmKkBankflowGtsService.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/service/IMdmKkBankflowGtsService.java new file mode 100644 index 00000000..ca58f30c --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/service/IMdmKkBankflowGtsService.java @@ -0,0 +1,12 @@ +package com.hzya.frame.finance.flow.service; + +import com.hzya.frame.finance.flow.entity.MdmKkBankflowGtsEntity; +import com.hzya.frame.basedao.service.IBaseService; +/** + * 账户明细查询(GTS)(MdmKkBankflowGts)表服务接口 + * + * @author zydd + * @since 2025-08-22 09:36:27 + */ +public interface IMdmKkBankflowGtsService extends IBaseService{ +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/service/impl/MdmKkBankflowGtsServiceImpl.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/service/impl/MdmKkBankflowGtsServiceImpl.java new file mode 100644 index 00000000..a1be5c28 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/flow/service/impl/MdmKkBankflowGtsServiceImpl.java @@ -0,0 +1,26 @@ +package com.hzya.frame.finance.flow.service.impl; + +import com.hzya.frame.finance.flow.entity.MdmKkBankflowGtsEntity; +import com.hzya.frame.finance.flow.dao.IMdmKkBankflowGtsDao; +import com.hzya.frame.finance.flow.service.IMdmKkBankflowGtsService; +import org.springframework.stereotype.Service; +import org.springframework.beans.factory.annotation.Autowired; +import javax.annotation.Resource; +import com.hzya.frame.basedao.service.impl.BaseService; +/** + * 账户明细查询(GTS)(MdmKkBankflowGts)表服务实现类 + * + * @author zydd + * @since 2025-08-22 09:36:27 + */ +@Service +public class MdmKkBankflowGtsServiceImpl extends BaseService implements IMdmKkBankflowGtsService { + + private IMdmKkBankflowGtsDao mdmKkBankflowGtsDao; + + @Autowired + public void setMdmKkBankflowGtsDao(IMdmKkBankflowGtsDao dao) { + this.mdmKkBankflowGtsDao = dao; + this.dao = dao; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Base64Util.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Base64Util.java new file mode 100644 index 00000000..3806f11d --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Base64Util.java @@ -0,0 +1,29 @@ +package com.hzya.frame.finance.utils; + +import sun.misc.BASE64Decoder; +import sun.misc.BASE64Encoder; + +import java.io.IOException; + +/** + * Base64������ + + */ +public class Base64Util { + + /** + * Base64���� + */ + public static String encryptBASE64(byte[] key) { + return (new BASE64Encoder()).encodeBuffer(key); + } + + /** + * Base64���� + * @throws IOException + */ + public static byte[] decryptBASE64(String key) throws IOException { + return (new BASE64Decoder()).decodeBuffer(key); + } + +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/CipherConstant.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/CipherConstant.java new file mode 100644 index 00000000..648bde9e --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/CipherConstant.java @@ -0,0 +1,12 @@ +package com.hzya.frame.finance.utils; + +public class CipherConstant { + // �����㷨����AES�ԳƼ��� + public static final String AES = "AES"; +// public static final String AES_ALGORITHM = "AES"; + public static final String AES_ALGORITHM = "AES/CTR/NoPadding"; + // �����㷨����RSA�ǶԳƼ��� + public static final String RSA = "RSA"; +// public static final String RSA_ALGORITHM = "RSA"; + public static final String RSA_ALGORITHM = "RSA/ECB/OAEPWithSHA-256AndMGF1Padding"; +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/CompressUtil.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/CompressUtil.java new file mode 100644 index 00000000..fd5f5732 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/CompressUtil.java @@ -0,0 +1,158 @@ +package com.hzya.frame.finance.utils; + +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.nio.charset.StandardCharsets; +import java.util.zip.*; + +/** + * ѹ�������� + */ +public class CompressUtil { + + private static int buffSize = 1024; + + /** + * deflaterCompress Ĭ��ѹ�� + * + * @param source ԭ�� + * @return + * @throws IOException + * @throws Exception + */ + public static String deflaterCompress(String source) throws Exception { + String value = null; + + ByteArrayOutputStream bos = new ByteArrayOutputStream(); + Deflater compressor = new Deflater(); + + try { + + byte[] input = source.getBytes(StandardCharsets.UTF_8); + // ����ѹ���Ǽ� + compressor.setLevel(Deflater.DEFAULT_COMPRESSION); + compressor.setInput(input); + compressor.finish(); + final byte[] buf = new byte[buffSize]; + + while (!compressor.finished()) { + int count = compressor.deflate(buf); + bos.write(buf, 0, count); + } + value = Base64Util.encryptBASE64(bos.toByteArray()); + + } finally { + bos.close(); + compressor.end(); + } + + return value; + } + + /** + * deflaterDecompress Ĭ�Ͻ�ѹ + * + * @param source ѹ�����ı� + * @return + * @throws IOException + * @throws @throws Exception + */ + public static String deflaterDecompress(String source) throws Exception { + String value = null; + + ByteArrayOutputStream bos = new ByteArrayOutputStream(); + Inflater decompressor = new Inflater(); + + try { + byte[] input = Base64Util.decryptBASE64(source); + + decompressor.setInput(input); + final byte[] buf = new byte[buffSize]; + + while (!decompressor.finished()) { + int count = decompressor.inflate(buf); + bos.write(buf, 0, count); + } + + value = new String(bos.toByteArray(), StandardCharsets.UTF_8); + } catch (IOException | DataFormatException e) { + throw new Exception("��ѹ�쳣 " + e.getMessage()); + } finally { + bos.close(); + decompressor.end(); + } + return value; + } + + /** + * gzipCompress ����gzipѹ�� + * + * @param source ԭ�� + * @return + * @throws IOException + * @throws Exception + */ + public static String gzipCompress(String source) throws Exception { + String value = null; + + ByteArrayOutputStream out = null; + + try { + out = new ByteArrayOutputStream(); + GZIPOutputStream gzip = new GZIPOutputStream(out); + byte[] input = source.getBytes(StandardCharsets.UTF_8); + gzip.write(input); + gzip.close(); + value = Base64Util.encryptBASE64(out.toByteArray()); + } catch (IOException e) { + throw new Exception("ѹ���쳣 " + e.getMessage()); + } finally { + if (out != null) { + out.close(); + } + } + + return value; + } + + /** + * gzipDecompress gzip��ѹ + * + * @param source ѹ�����ı� + * @return + * @throws Exception + */ + public static String gzipDecompress(String source) throws Exception { + String value = null; + + ByteArrayOutputStream out = null; + ByteArrayInputStream in = null; + + try { + byte[] input = Base64Util.decryptBASE64(source); + out = new ByteArrayOutputStream(); + in = new ByteArrayInputStream(input); + GZIPInputStream ungzip = new GZIPInputStream(in); + + byte[] buffer = new byte[buffSize]; + int n; + while ((n = ungzip.read(buffer)) >= 0) { + out.write(buffer, 0, n); + } + ungzip.close(); + value = new String(out.toByteArray(), StandardCharsets.UTF_8); + } catch (IOException e) { + throw new Exception("ѹ���쳣 " + e.getMessage()); + } finally { + if (in != null) { + in.close(); + } + if (out != null) { + out.close(); + } + + } + return value; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Decryption.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Decryption.java new file mode 100644 index 00000000..f6c2cee9 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Decryption.java @@ -0,0 +1,99 @@ +package com.hzya.frame.finance.utils; + +import javax.crypto.BadPaddingException; +import javax.crypto.Cipher; +import javax.crypto.IllegalBlockSizeException; +import javax.crypto.NoSuchPaddingException; +import javax.crypto.spec.IvParameterSpec; +import javax.crypto.spec.OAEPParameterSpec; +import javax.crypto.spec.PSource; +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.nio.charset.StandardCharsets; +import java.security.InvalidKeyException; +import java.security.Key; +import java.security.NoSuchAlgorithmException; +import java.security.spec.MGF1ParameterSpec; + +/** + * ������ + */ +public class Decryption { + + // RSA���������Ĵ�С + private static final int MAX_DECRYPT_BLOCK = 256; + + /** + * symDecrypt �Գƽ��� + * + * @param strkey �Գ���Կ + * @param src ���� + * @return ԭ�� + * @throws IOException + * @throws Exception + */ + public static String symDecrypt(String strkey, String src) throws Exception { + + String target = null; + try { + Key key = KeysFactory.getSymKey(strkey); + // ���� + Cipher cipher = Cipher.getInstance(CipherConstant.AES_ALGORITHM); + IvParameterSpec iv = new IvParameterSpec(strkey.substring(0, 16).getBytes()); + cipher.init(Cipher.DECRYPT_MODE, key, iv); + byte[] decodeResult = cipher.doFinal(Base64Util.decryptBASE64(src)); + target = new String(decodeResult, StandardCharsets.UTF_8); + + } catch (NoSuchAlgorithmException | NoSuchPaddingException | IllegalBlockSizeException | BadPaddingException | InvalidKeyException e) { + throw new Exception("����ʧ��" + e.getMessage()); + } + + return target; + } + + /** + * priDecrypt ˽Կ���� + * + * @param priKey ˽Կ + * @param src ���� + * @return ԭ�� + * @throws IOException + * @throws Exception + */ + public static String priDecrypt(String priKey, String src) throws Exception { + String target = null; + ByteArrayOutputStream out = null; + try { + Key key = KeysFactory.getPrivateKey(priKey); + // ���� + Cipher cipher = Cipher.getInstance("RSA/ECB/OAEPWithSHA-256AndMGF1Padding"); + cipher.init(Cipher.DECRYPT_MODE, key, new OAEPParameterSpec("SHA-256", "MGF1", new MGF1ParameterSpec("SHA-256"), PSource.PSpecified.DEFAULT)); + byte[] data = Base64Util.decryptBASE64(src); + int inputLen = data.length; + out = new ByteArrayOutputStream(); + int offSet = 0; + byte[] cache; + int i = 0; + // �����ݷֶν��� + while (inputLen - offSet > 0) { + if (inputLen - offSet > MAX_DECRYPT_BLOCK) { + cache = cipher.doFinal(data, offSet, MAX_DECRYPT_BLOCK); + } else { + cache = cipher.doFinal(data, offSet, inputLen - offSet); + } + out.write(cache, 0, cache.length); + i++; + offSet = i * MAX_DECRYPT_BLOCK; + } + target = new String(out.toByteArray()); + + } catch (NoSuchAlgorithmException | NoSuchPaddingException | InvalidKeyException | IllegalBlockSizeException | BadPaddingException e) { + throw new Exception("����ʧ��" + e.getMessage()); + } finally { + if (out != null) { + out.close(); + } + } + return target; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Encryption.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Encryption.java new file mode 100644 index 00000000..c1f192c6 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/Encryption.java @@ -0,0 +1,96 @@ +package com.hzya.frame.finance.utils; + +import javax.crypto.BadPaddingException; +import javax.crypto.Cipher; +import javax.crypto.IllegalBlockSizeException; +import javax.crypto.NoSuchPaddingException; +import javax.crypto.spec.IvParameterSpec; +import javax.crypto.spec.OAEPParameterSpec; +import javax.crypto.spec.PSource; +import java.io.ByteArrayOutputStream; +import java.io.IOException; +import java.io.UnsupportedEncodingException; +import java.nio.charset.StandardCharsets; +import java.security.InvalidKeyException; +import java.security.Key; +import java.security.NoSuchAlgorithmException; +import java.security.spec.MGF1ParameterSpec; + +/** + * ������ + */ +public class Encryption { + + // RSA���������Ĵ�С + private static final int MAX_ENCRYPT_BLOCK = 117; + + /** + * symEncrypt �ԳƼ��� + * + * @param strkey �Գ���Կ + * @param src ԭ�� + * @return ���� + */ + public static String symEncrypt(String strkey, String src) throws Exception { + String target = null; + try { + Key key = KeysFactory.getSymKey(strkey); + //���� + Cipher cipher = Cipher.getInstance(CipherConstant.AES_ALGORITHM); + IvParameterSpec iv = new IvParameterSpec(strkey.substring(0, 16).getBytes()); + cipher.init(Cipher.ENCRYPT_MODE, key, iv); + byte[] encodeResult = cipher.doFinal(src.getBytes(StandardCharsets.UTF_8)); + target = Base64Util.encryptBASE64(encodeResult); + } catch (NoSuchAlgorithmException | NoSuchPaddingException | UnsupportedEncodingException | InvalidKeyException | IllegalBlockSizeException | BadPaddingException e) { + throw new Exception("����ʧ��" + e.getMessage()); + } + return target; + } + + /** + * pubEncrypt ��Կ���� + * + * @param pubKey ��Կ + * @param src ԭ�� + * @return ���� + * @throws IOException + * @throws Exception + */ + public static String pubEncrypt(String pubKey, String src) throws Exception { + String target = null; + ByteArrayOutputStream out = null; + try { + Key key = KeysFactory.getPublicKey(pubKey); + + Cipher cipher = Cipher.getInstance(CipherConstant.RSA_ALGORITHM); + cipher.init(Cipher.ENCRYPT_MODE, key,new OAEPParameterSpec("SHA-256", "MGF1", new MGF1ParameterSpec("SHA-256"), PSource.PSpecified.DEFAULT)); + byte[] data = src.getBytes(); + int inputLen = data.length; + out = new ByteArrayOutputStream(); + int offSet = 0; + byte[] cache; + int i = 0; + // �����ݷֶμ��� + while (inputLen - offSet > 0) { + if (inputLen - offSet > MAX_ENCRYPT_BLOCK) { + cache = cipher.doFinal(data, offSet, MAX_ENCRYPT_BLOCK); + } else { + cache = cipher.doFinal(data, offSet, inputLen - offSet); + } + out.write(cache, 0, cache.length); + i++; + offSet = i * MAX_ENCRYPT_BLOCK; + } + + target = Base64Util.encryptBASE64(out.toByteArray()); + } catch (NoSuchAlgorithmException | NoSuchPaddingException | InvalidKeyException | IllegalBlockSizeException | BadPaddingException e) { + throw new Exception("����ʧ��" + e.getMessage()); + } finally { + if (out != null) { + out.close(); + } + } + return target; + } + +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/KeyPairs.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/KeyPairs.java new file mode 100644 index 00000000..13a68334 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/KeyPairs.java @@ -0,0 +1,25 @@ +package com.hzya.frame.finance.utils; + +import java.security.KeyPair; + +/** + * KeyPairs + * ������ + * + */ +public class KeyPairs { + + private KeyPair keyPair; + + public KeyPairs(KeyPair keyPair){ + this.keyPair = keyPair; + } + + public String getPublicKey(){ + return Base64Util.encryptBASE64(keyPair.getPublic().getEncoded()); + } + + public String getPrivateKey(){ + return Base64Util.encryptBASE64(keyPair.getPrivate().getEncoded()); + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/KeysFactory.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/KeysFactory.java new file mode 100644 index 00000000..d0701181 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/KeysFactory.java @@ -0,0 +1,101 @@ +package com.hzya.frame.finance.utils; + +import javax.crypto.KeyGenerator; +import javax.crypto.SecretKey; +import javax.crypto.spec.SecretKeySpec; +import java.security.Key; +import java.security.KeyFactory; +import java.security.KeyPairGenerator; +import java.security.NoSuchAlgorithmException; +import java.security.spec.PKCS8EncodedKeySpec; +import java.security.spec.X509EncodedKeySpec; + +/** + * Key������ + */ +public class KeysFactory { + + /** + * buildAsymKey ����һ��ǶԳ���Կ + * + * @return KeyPair key��PublicKey��PrivateKey + * @throws NoSuchAlgorithmException + */ + public static KeyPairs buildAsymKey() throws Exception { + + /* ��ʼ����Կ������ */ + KeyPairGenerator keyPairGenerator = KeyPairGenerator.getInstance(CipherConstant.RSA); + keyPairGenerator.initialize(2048, SecureRandomProxy.getRandomInstance()); + + /* ������Կ */ + return new KeyPairs(keyPairGenerator.generateKeyPair()); + } + + /** + * buildAsymKey ����һ���Գ���Կ + * + * @return �Գ���Կ + * @throws NoSuchAlgorithmException + * @throws Exception + */ + public static String buildSymKey() throws Exception { + // ����Key + KeyGenerator keyGenerator = KeyGenerator.getInstance(CipherConstant.AES); + + keyGenerator.init(256, SecureRandomProxy.getRandomInstance()); + // ʹ���������ֳ�ʼ�����������ض�������������Կ���������ܺ��������Ψһ�̶��ġ� + SecretKey secretKey = keyGenerator.generateKey(); + + return Base64Util.encryptBASE64(secretKey.getEncoded()); + + } + + public static Key getPublicKey(String pubKey) throws Exception { + Key key = null; + + try { + byte[] keyBytes = Base64Util.decryptBASE64(pubKey); + KeyFactory keyFactory = KeyFactory.getInstance(CipherConstant.RSA); + + X509EncodedKeySpec x509KeySpec = new X509EncodedKeySpec(keyBytes); + key = keyFactory.generatePublic(x509KeySpec); + + } catch (Exception e) { + throw new Exception("��Ч����Կ " + e.getMessage()); + } + + return key; + } + + public static Key getPrivateKey(String priKey) throws Exception { + Key key = null; + + try { + byte[] keyBytes = Base64Util.decryptBASE64(priKey); + + KeyFactory keyFactory = KeyFactory.getInstance(CipherConstant.RSA); + + PKCS8EncodedKeySpec pkcs8KeySpec = new PKCS8EncodedKeySpec(keyBytes); + key = keyFactory.generatePrivate(pkcs8KeySpec); + + } catch (Exception e) { + throw new Exception("��Ч��Կ " + e.getMessage()); + } + + return key; + } + + public static Key getSymKey(String symKey) throws Exception { + Key key = null; + + try { + byte[] keyBytes = Base64Util.decryptBASE64(symKey); + // Keyת�� + key = new SecretKeySpec(keyBytes, CipherConstant.AES); + } catch (Exception e) { + throw new Exception("��Ч��Կ " + e.getMessage()); + } + + return key; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/ResultMessageUtil.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/ResultMessageUtil.java new file mode 100644 index 00000000..42b0c7fa --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/ResultMessageUtil.java @@ -0,0 +1,45 @@ +package com.hzya.frame.finance.utils; + +public class ResultMessageUtil { + + private boolean success; + + private Object data; + + private String code; + + private String errorMessage; + + public boolean isSuccess() { + return success; + } + + public void setSuccess(boolean success) { + this.success = success; + } + + public Object getData() { + return data; + } + + public void setData(Object data) { + this.data = data; + } + + public String getCode() { + return code; + } + + public void setCode(String code) { + this.code = code; + } + + public String getErrorMessage() { + return errorMessage; + } + + public void setErrorMessage(String errorMessage) { + this.errorMessage = errorMessage; + } + +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/SHA256Util.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/SHA256Util.java new file mode 100644 index 00000000..05ae1803 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/SHA256Util.java @@ -0,0 +1,52 @@ +package com.hzya.frame.finance.utils; + +import java.nio.charset.StandardCharsets; +import java.security.MessageDigest; +import java.security.NoSuchAlgorithmException; +import java.security.SecureRandom; + +public class SHA256Util { + + public static String getSHA256(String str, String key) { + //���� + byte[] salt = new byte[16]; + try { + SecureRandom random = SecureRandom.getInstance("SHA1PRNG"); + random.setSeed(key.getBytes()); + random.nextBytes(salt); + } catch (NoSuchAlgorithmException e) { + e.printStackTrace(); + } + String salt_string = Base64Util.encryptBASE64(salt); +// System.out.println("salt_String::" + salt_string); + return getSHA256(str + salt_string.replaceAll("\r|\n", "")); + } + + private static String getSHA256(String str) { + MessageDigest messageDigest; + String encodestr = ""; + try { + messageDigest = MessageDigest.getInstance("SHA-256"); + messageDigest.update(str.getBytes(StandardCharsets.UTF_8)); + encodestr = byte2Hex(messageDigest.digest()); + } catch (NoSuchAlgorithmException e) { + throw new RuntimeException(e); + } + return encodestr; + } + + private static String byte2Hex(byte[] bytes) { + StringBuffer stringBuffer = new StringBuffer(); + String temp = null; + for (int i = 0; i < bytes.length; i++) { + temp = Integer.toHexString(bytes[i] & 0xFF); + if (temp.length() == 1) { + // 1得到�?��的进行补0操作 + stringBuffer.append("0"); + } + stringBuffer.append(temp); + } + return stringBuffer.toString(); + } + +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/SecureRandomProxy.java b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/SecureRandomProxy.java new file mode 100644 index 00000000..4164e598 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/finance/utils/SecureRandomProxy.java @@ -0,0 +1,23 @@ +package com.hzya.frame.finance.utils; + +import java.security.NoSuchAlgorithmException; +import java.security.SecureRandom; + +/** + * @Describe + */ +public class SecureRandomProxy { + + public static SecureRandom getRandomInstance() { + SecureRandom random = null; + try { + random = SecureRandom.getInstance("SHA1PRNG"); +// random = SecureRandom.getInstance("NativePRNG"); +// random = SecureRandom.getInstance("NativePRNGNonBlocking"); + } catch (NoSuchAlgorithmException e) { + e.printStackTrace(); + } + + return random; + } +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSDataVO.java b/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSDataVO.java new file mode 100644 index 00000000..58dd0b91 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSDataVO.java @@ -0,0 +1,33 @@ +package com.hzya.frame.plugin.coco.vo; + +import lombok.Data; + +/** + * Created by zydd on 2025-08-21 14:59 + * GTS数据VO + */ +@Data +public class GTSDataVO { + private String transeqno1;//交易流水号 + private String cnteracctname;//对方户名 + private String cnteracctno;//对方账户 + private String opnbnkinfo;//对方开户行 + private String tranamt;//交易金额 + private String inamtlot;//转入金额 + private String tfroutamt;//转出金额 + private String ccy;//币种 + private String balance;//余额 + private String outflag;//转入/转出标志 + private String bussseqno;//企业流水 + private String bnkprchseqno;//银行流水 + private String trandate;//交易日期 + private String trantimep;//交易时间 + private String yt;//用途 usage + private String deprecptid;//单据号 + private String trantpcdset;//交易类型 + private String kpdmn;//保留 + private String zy;//摘要 abstract + private String remark;//备注 + private String postscript;//附言 + private String rsrvfldnm;//流水类型 +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSRequestVO.java b/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSRequestVO.java new file mode 100644 index 00000000..6940f3f6 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSRequestVO.java @@ -0,0 +1,18 @@ +package com.hzya.frame.plugin.coco.vo; + +import lombok.Data; + +/** + * Created by zydd on 2025-08-21 15:08 + * GTS请求入参 + */ +@Data +public class GTSRequestVO { + private String clientNo; + private String pyAcctNo; + private String startDate;//格式:yyyyMMdd + private String endDate;//格式:yyyyMMdd + private String tranSeqNo; + private String acptNum;//从1开始 + private String queryNum;//最大100笔 +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSResVO.java b/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSResVO.java new file mode 100644 index 00000000..e4c930f5 --- /dev/null +++ b/base-buildpackage/src/main/java/com/hzya/frame/plugin/coco/vo/GTSResVO.java @@ -0,0 +1,23 @@ +package com.hzya.frame.plugin.coco.vo; + +import lombok.Data; + +/** + * Created by zydd on 2025-08-21 15:05 + * GTS请求返回VO + */ +@Data +public class GTSResVO { + private String statusMsg;//返回信息 + /** + * “0000”-交易成功 + * “0001”-未知错误 + * “0002”-参数校验失败 + */ + private String statusCode;//返回状态码 + private String transNo;//交易流水号 + private String returnCode;//返回代码 + private String returnInfo;//返回信息 + private String qryRsltNum;//本次查询笔数 + private String totalNum;//总笔数 +} diff --git a/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/comf/bd/entity/vo/MdmDBQueryVO.java b/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/comf/bd/entity/vo/MdmDBQueryVO.java index a8c14109..81646ff7 100644 --- a/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/comf/bd/entity/vo/MdmDBQueryVO.java +++ b/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/comf/bd/entity/vo/MdmDBQueryVO.java @@ -37,5 +37,6 @@ public class MdmDBQueryVO extends BaseEntity { private String billstatus; private String claimstatus; private String ids; + private String outFlag; } diff --git a/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/comf/bd/entity/vo/MdmDBQueryVO.xml b/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/comf/bd/entity/vo/MdmDBQueryVO.xml index 86d43025..52d7206b 100644 --- a/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/comf/bd/entity/vo/MdmDBQueryVO.xml +++ b/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/comf/bd/entity/vo/MdmDBQueryVO.xml @@ -263,7 +263,13 @@ and ${prop9} like concat('%', #{propValue9},'%') and ${prop10} like concat('%', #{propValue10},'%') and claimstatus = #{claimstatus} - and id in (${ids}) + and outflag = #{outFlag} + + and id in + + #{id} + + diff --git a/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/push/controller/PushLogController.java b/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/push/controller/PushLogController.java index 03dcdbba..eab0cb88 100644 --- a/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/push/controller/PushLogController.java +++ b/base-buildpackage/src/main/java/com/hzya/frame/voucher/ae/push/controller/PushLogController.java @@ -138,5 +138,4 @@ public class PushLogController extends DefaultController { } - } diff --git a/base-buildpackage/src/main/resources/application-cocodev.yml b/base-buildpackage/src/main/resources/application-cocodev.yml index 55328627..752971c9 100644 --- a/base-buildpackage/src/main/resources/application-cocodev.yml +++ b/base-buildpackage/src/main/resources/application-cocodev.yml @@ -40,6 +40,15 @@ OA: U8C: - usercode: WEB - password: 83f1ad3e7fa3617f1aae62ae7413c810 - system: WEB \ No newline at end of file + usercode: ?? + password: ?? + system: ?? + +#####不变参数--BIP +client_id: XONE +datasource: COCOCS +client_secret: d18726dcc8ad487facdc +pubKey: MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAur9ViNXdgV9qTxoKuLRhXqhKcQ1A4Vl6AqM8me0W5iXSCW49X2jSdnp3kEL5CqiINqPoqwQjFSdBCDrYotvp8nmIW1iifpR+IRteDWmJ6H/bHOarZYCDz3rkYYqe6UOzjWnlx0xq3VPjRyJ51z/bL26c0GiQK6sLS9k960kfv3JwmyT1DFQzXTcRExqSAqDawyvwYfjmbwF8SX50CzIz5eXfVTsQhEZBcd6EIKJL37uo+7mBJ6QLpjLyXio51CdJoLRXmPfRrmY29yyTwLIDV0ujOM0u7SPOK+loXesNnSS9Qjwg9B++GZzZdg0smVd/MS0dVLnr541RzGuaK7GuFwIDAQAB +secret_level: L0 +## 服务器地址 +baseUrl: http://115.238.74.170:8089/ \ No newline at end of file diff --git a/base-buildpackage/src/main/resources/application.yml b/base-buildpackage/src/main/resources/application.yml index 36ab943d..d0b0a944 100644 --- a/base-buildpackage/src/main/resources/application.yml +++ b/base-buildpackage/src/main/resources/application.yml @@ -1,5 +1,5 @@ server: - port: 10086 + port: 10084 servlet: context-path: /kangarooDataCenterV3 localIP: 127.0.0.1 diff --git a/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/controller/ImportExcelController.java b/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/controller/ImportExcelController.java index 0efbc5c6..d4176fbb 100644 --- a/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/controller/ImportExcelController.java +++ b/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/controller/ImportExcelController.java @@ -7,6 +7,7 @@ import com.alibaba.excel.write.metadata.holder.WriteSheetHolder; import com.alibaba.excel.write.style.column.AbstractColumnWidthStyleStrategy; import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSONObject; +import com.hzya.frame.mdm.mdmModule.entity.vo.ExportExcelVO; import com.hzya.frame.mdm.mdmModule.service.IMdmModuleService; import com.hzya.frame.mdm.mdmModule.vo.ExcelTemplateVO; import com.hzya.frame.mdm.mdmModule.vo.ImportExcelVO; @@ -81,7 +82,7 @@ public class ImportExcelController { * 下载数据模版 */ @RequestMapping(value = "generateDataTemplate",method = RequestMethod.POST) - public void generateDataTemplate(HttpServletResponse response,@RequestParam("mdmId") String mdmId,@RequestParam("dbId") String dbId) throws IOException { + public void generateDataTemplate(HttpServletResponse response,@RequestBody ExportExcelVO vo) throws IOException { // 设置响应内容类型 response.setContentType("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"); response.setCharacterEncoding("utf-8"); @@ -90,7 +91,7 @@ public class ImportExcelController { String fileName = URLEncoder.encode("数据模版", "UTF-8").replaceAll("\\+", "%20"); response.setHeader("Content-disposition", "attachment;filename*=utf-8''" + fileName + ".xlsx"); - List dataTemplate = iMdmService.selectFieldsByMdmId(mdmId,dbId); + List dataTemplate = iMdmService.selectFieldsByMdmId(vo.getMdmId(),vo.getDbId()); // 动态表头信息 List> headers = new ArrayList<>(); // 每个字符串作为一个表头列 diff --git a/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/entity/vo/ExportExcelVO.java b/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/entity/vo/ExportExcelVO.java new file mode 100644 index 00000000..c142b9da --- /dev/null +++ b/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/entity/vo/ExportExcelVO.java @@ -0,0 +1,12 @@ +package com.hzya.frame.mdm.mdmModule.entity.vo; + +import lombok.Data; + +/** + * Created by zydd on 2025-08-24 17:09 + */ +@Data +public class ExportExcelVO { + private String mdmId; + private String dbId; +} diff --git a/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/service/impl/MdmModuleServiceImpl.java b/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/service/impl/MdmModuleServiceImpl.java index 52824170..efa53a7b 100644 --- a/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/service/impl/MdmModuleServiceImpl.java +++ b/base-service/src/main/java/com/hzya/frame/mdm/mdmModule/service/impl/MdmModuleServiceImpl.java @@ -1435,10 +1435,11 @@ public class MdmModuleServiceImpl extends BaseService i } // 校验dbId - List all = mdmModuleDbDao.getAll(); - for (MdmModuleDbEntity mdmModuleDbEntity : all) { - if (!entity.getDbId().equals(mdmModuleDbEntity.getId())) - return BaseResult.getFailureMessageEntity("数据库不存在"); + MdmModuleDbEntity mdmModuleDbEntity1 = new MdmModuleDbEntity(); + mdmModuleDbEntity1.setId(entity.getDbId()); + List mdmModuleDbEntityList = mdmModuleDbDao.query(mdmModuleDbEntity1); + if(mdmModuleDbEntityList.size()==0){ + return BaseResult.getFailureMessageEntity("数据库不存在"); } MdmModuleDbFiledsEntity mdmModuleDbFiledsEntity = new MdmModuleDbFiledsEntity();