Compare commits

..

5 Commits

28 changed files with 1501 additions and 75 deletions

View File

@ -1,15 +1,17 @@
package com.hzya.frame.voucher.ae.comf.bd.controller; package com.hzya.frame.voucher.ae.comf.bd.controller;
import cn.hutool.core.lang.Assert; import cn.hutool.core.lang.Assert;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.hzya.frame.voucher.ae.comf.bd.dao.IAeConfBdAccsubjDao; import com.hzya.frame.voucher.ae.comf.bd.dao.IAeConfBdAccsubjDao;
import com.hzya.frame.voucher.ae.comf.bd.dao.IAeConfBdBdinfoDao; import com.hzya.frame.voucher.ae.comf.bd.dao.IAeConfBdBdinfoDao;
import com.hzya.frame.voucher.ae.comf.bd.dao.IAeConfBdOrgBookVODao; import com.hzya.frame.voucher.ae.comf.bd.dao.IAeConfBdOrgBookVODao;
import com.hzya.frame.voucher.ae.comf.bd.entity.AccsubjTreeNode; import com.hzya.frame.voucher.ae.comf.bd.dao.IU8CQueryVODAO;
import com.hzya.frame.voucher.ae.comf.bd.entity.AeConfBdAccsubjEntity; import com.hzya.frame.voucher.ae.comf.bd.entity.*;
import com.hzya.frame.voucher.ae.comf.bd.entity.AeConfBdBdinfoEntity;
import com.hzya.frame.voucher.ae.comf.bd.entity.OrgBookVO;
import com.hzya.frame.voucher.ae.comf.bd.utils.AccsubjTreeBuilder; import com.hzya.frame.voucher.ae.comf.bd.utils.AccsubjTreeBuilder;
import com.hzya.frame.voucher.constant.ProfilesActiveConstant;
import com.hzya.frame.web.action.DefaultController; import com.hzya.frame.web.action.DefaultController;
import com.hzya.frame.web.entity.BaseEntity;
import com.hzya.frame.web.entity.JsonResultEntity; import com.hzya.frame.web.entity.JsonResultEntity;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestBody;
@ -17,7 +19,9 @@ import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map;
/** /**
* Created by zydd on 2025-06-04 15:04 * Created by zydd on 2025-06-04 15:04
@ -32,6 +36,8 @@ public class BdController extends DefaultController {
private IAeConfBdBdinfoDao aeConfBdBdinfoDao; private IAeConfBdBdinfoDao aeConfBdBdinfoDao;
@Autowired @Autowired
private IAeConfBdAccsubjDao aeConfBdAccsubjDao; private IAeConfBdAccsubjDao aeConfBdAccsubjDao;
@Autowired
private IU8CQueryVODAO u8CQueryVODAO;
/** /**
* 查询所有公司账簿信息 * 查询所有公司账簿信息
@ -77,4 +83,49 @@ public class BdController extends DefaultController {
} }
} }
/**
* 查询基础数据数据表
*/
@RequestMapping(value = "/queryDataByMap", method = RequestMethod.POST)
public JsonResultEntity queryDataByMap(@RequestBody HashMap<String, String> map) {
try {
if (map.get("tablename") == null || "".equals(map.get("tablename"))) {
return getSuccessMessageEntity("请求成功", null);
}
//查询u8c数据库
U8CQueryVO u8CQueryVO = new U8CQueryVO();
u8CQueryVO.setDataSourceCode(ProfilesActiveConstant.LETS_PROD_DATE_SOURCE);
u8CQueryVO.setTablename(map.get("tablename"));
List<Map<String, Object>> objectList = u8CQueryVODAO.queryU8CBD(u8CQueryVO);
return getSuccessMessageEntity("请求成功", objectList);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败", e.getMessage());
}
}
/**
* 查询基础数据数据表
*/
@RequestMapping(value = "/queryDataPagedByMap", method = RequestMethod.POST)
public JsonResultEntity queryDataPagedByMap(@RequestBody U8CQueryVO entity) {
try {
if (entity.getTablename() == null || "".equals(entity.getTablename())) {
return getSuccessMessageEntity("请求成功", null);
}
PageHelper.startPage(entity.getPageNum(), entity.getPageSize());
//查询u8c数据库
U8CQueryVO u8CQueryVO = new U8CQueryVO();
u8CQueryVO.setDataSourceCode(ProfilesActiveConstant.LETS_PROD_DATE_SOURCE);
u8CQueryVO.setTablename(entity.getTablename());
List<Map<String, Object>> objectList = u8CQueryVODAO.queryU8CBD(u8CQueryVO);
PageInfo pageInfo = new PageInfo(objectList);
return getSuccessMessageEntity("请求成功", pageInfo);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败", e.getMessage());
}
}
} }

View File

@ -0,0 +1,15 @@
package com.hzya.frame.voucher.ae.comf.bd.dao;
import com.hzya.frame.basedao.dao.IBaseDao;
import com.hzya.frame.voucher.ae.comf.bd.entity.OrgBookVO;
import com.hzya.frame.voucher.ae.comf.bd.entity.U8CQueryVO;
import java.util.List;
import java.util.Map;
/**
* Created by zydd on 2025-06-06 10:03
*/
public interface IU8CQueryVODAO extends IBaseDao<U8CQueryVO, String> {
List<Map<String, Object>> queryU8CBD(U8CQueryVO u8CQueryVO);
}

View File

@ -0,0 +1,27 @@
package com.hzya.frame.voucher.ae.comf.bd.dao.impl;
import com.baomidou.dynamic.datasource.annotation.DS;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
import com.hzya.frame.voucher.ae.comf.bd.dao.IAeConfBdOrgBookVODao;
import com.hzya.frame.voucher.ae.comf.bd.dao.IU8CQueryVODAO;
import com.hzya.frame.voucher.ae.comf.bd.entity.OrgBookVO;
import com.hzya.frame.voucher.ae.comf.bd.entity.U8CQueryVO;
import com.hzya.frame.voucher.constant.ProfilesActiveConstant;
import org.springframework.stereotype.Repository;
import java.util.List;
import java.util.Map;
/**
* Created by zydd on 2025-06-06 10:05
*/
@Repository
public class U8CQueryVODAOImpl extends MybatisGenericDao<U8CQueryVO, String> implements IU8CQueryVODAO {
@Override
@DS(ProfilesActiveConstant.LETS_PROD_DATE_SOURCE)
public List<Map<String, Object>> queryU8CBD(U8CQueryVO u8CQueryVO) {
List<Map<String, Object>> maps = (List<Map<String, Object>>) selectList("com.hzya.frame.voucher.ae.comf.bd.dao.impl.U8CQueryVODAOImpl.queryU8CBD", u8CQueryVO);
return maps;
}
}

View File

@ -15,69 +15,69 @@ import lombok.Data;
@Data @Data
public class AeConfBdBdinfoEntity extends BaseEntity { public class AeConfBdBdinfoEntity extends BaseEntity {
@JsonIgnore
private String accessclass; private String accessclass;
@JsonIgnore
private String basedoctablename; private String basedoctablename;
@JsonIgnore
private String basedoctablepkname; private String basedoctablepkname;
@JsonIgnore
private String bdcode; private String bdcode;
@JsonIgnore
private String bdname; private String bdname;
@JsonIgnore
private Long bdtype; private Long bdtype;
@JsonIgnore
private String budgetconst; private String budgetconst;
@JsonIgnore
private String classcheme; private String classcheme;
@JsonIgnore
private String codefieldname; private String codefieldname;
@JsonIgnore
private String coderulegetter; private String coderulegetter;
@JsonIgnore
private String corpfieldname; private String corpfieldname;
@JsonIgnore
private Long dr; private Long dr;
@JsonIgnore
private String fatherfieldname; private String fatherfieldname;
@JsonIgnore
private String funccode; private String funccode;
@JsonIgnore
private String isdef; private String isdef;
@JsonIgnore
private String isincludegroupdata; private String isincludegroupdata;
@JsonIgnore
private String isparaLevscheme; private String isparaLevscheme;
@JsonIgnore
private String isselfref; private String isselfref;
@JsonIgnore
private String namefieldname; private String namefieldname;
@JsonIgnore
private String orgbookfieldname; private String orgbookfieldname;
@JsonIgnore
private String orgtypecode; private String orgtypecode;
@JsonIgnore
private String pkBdinfo; private String pkBdinfo;
@JsonIgnore
private String pkCorp; private String pkCorp;
@JsonIgnore
private String pkDefdef; private String pkDefdef;
@JsonIgnore
private String refnodename; private String refnodename;
@JsonIgnore
private String refsystem; private String refsystem;
@JsonIgnore
private String reserved1; private String reserved1;
@JsonIgnore
private String reserved2; private String reserved2;
@JsonIgnore
private String selfrefclass; private String selfrefclass;
@JsonIgnore
private String tablename; private String tablename;
@JsonIgnore
private String tablepkname; private String tablepkname;
@JsonIgnore
private Date ts; private Date ts;

View File

@ -0,0 +1,33 @@
package com.hzya.frame.voucher.ae.comf.bd.entity;
import com.hzya.frame.web.entity.BaseEntity;
import lombok.Data;
/**
* Created by zydd on 2025-06-06 09:59
*/
@Data
public class U8CQueryVO extends BaseEntity {
private String tablename;
private String prop1;
private String prop2;
private String prop3;
private String prop4;
private String prop5;
private String prop6;
private String prop7;
private String prop8;
private String prop9;
private String prop10;
private String propValue1;
private String propValue2;
private String propValue3;
private String propValue4;
private String propValue5;
private String propValue6;
private String propValue7;
private String propValue8;
private String propValue9;
private String propValue10;
}

View File

@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.voucher.ae.comf.bd.dao.impl.U8CQueryVODAOImpl">
<resultMap id="get-U8CQueryVO-result" type="com.hzya.frame.voucher.ae.comf.bd.entity.U8CQueryVO">
<result property="tablename" column="tablename" />
</resultMap>
<select id="queryU8CBD" parameterType="com.hzya.frame.voucher.ae.comf.bd.entity.U8CQueryVO" resultType="map">
select
*
from
${tablename}
<trim prefix="where" prefixOverrides="and">
<if test="prop1 !=null and prop1 !=''">and #{prop1}=#{propValue1}</if>
<if test="prop2 !=null and prop2 !=''">and #{prop2}=#{propValue2}</if>
<if test="prop3 !=null and prop3 !=''">and #{prop3}=#{propValue3}</if>
<if test="prop4 !=null and prop4 !=''">and #{prop4}=#{propValue4}</if>
<if test="prop5 !=null and prop5 !=''">and #{prop5}=#{propValue5}</if>
<if test="prop6 !=null and prop6 !=''">and #{prop6}=#{propValue6}</if>
<if test="prop7 !=null and prop7 !=''">and #{prop7}=#{propValue7}</if>
<if test="prop8 !=null and prop8 !=''">and #{prop8}=#{propValue8}</if>
<if test="prop9 !=null and prop9 !=''">and #{prop9}=#{propValue9}</if>
<if test="prop10 !=null and prop10 !=''">and #{prop10}=#{propValue10}</if>
</trim>
</select>
</mapper>

View File

@ -27,15 +27,15 @@ public class AeConfInfluenceFactorEntity extends BaseEntity {
*/ */
private String factorName; private String factorName;
/** /**
* 映射档案id * 映射档案id bd_bdinfo的pkBdinfo
*/ */
private String mappingFileId; private String mappingFileId;
/** /**
* 映射档案code * 映射档案code bd_bdinfo的tablename
*/ */
private String mappingFileCode; private String mappingFileCode;
/** /**
* 映射档案名称 * 映射档案名称 bd_bdinfo的bdname
*/ */
private String mappingFileName; private String mappingFileName;
/** /**

View File

@ -70,6 +70,8 @@ public class AeConfInfluenceFactorServiceImpl extends BaseService<AeConfInfluenc
public AeConfInfluenceFactorEntity save(AeConfInfluenceFactorEntity entity) throws Exception { public AeConfInfluenceFactorEntity save(AeConfInfluenceFactorEntity entity) throws Exception {
Assert.notNull(entity.getAeConfModuleId(), "保存影响因素设置时业务模块id不能为空"); Assert.notNull(entity.getAeConfModuleId(), "保存影响因素设置时业务模块id不能为空");
Assert.notNull(entity.getFactorName(), "保存影响因素设置时,影响因素名称不能为空"); Assert.notNull(entity.getFactorName(), "保存影响因素设置时,影响因素名称不能为空");
//关联档案
updateModuleName(entity); updateModuleName(entity);
return super.save(entity); return super.save(entity);

View File

@ -115,7 +115,7 @@ public class AeConfBusinessModuleMdmServiceImpl extends BaseService<AeConfBusine
//校验是否存在重复 //校验是否存在重复
for (AeConfBusinessModuleMdmEntity aeConfBusinessModuleMdmEntity : list) { for (AeConfBusinessModuleMdmEntity aeConfBusinessModuleMdmEntity : list) {
AeConfBusinessModuleMdmEntity ae1 = new AeConfBusinessModuleMdmEntity(); AeConfBusinessModuleMdmEntity ae1 = new AeConfBusinessModuleMdmEntity();
ae1.setAeConfModuleId(aeConfBusinessModuleMdmEntity.getAeConfModuleId()); // ae1.setAeConfModuleId(aeConfBusinessModuleMdmEntity.getAeConfModuleId());
ae1.setMdmId(aeConfBusinessModuleMdmEntity.getMdmId()); ae1.setMdmId(aeConfBusinessModuleMdmEntity.getMdmId());
List<AeConfBusinessModuleMdmEntity> query1 = aeConfBusinessModuleMdmDao.query(ae1); List<AeConfBusinessModuleMdmEntity> query1 = aeConfBusinessModuleMdmDao.query(ae1);
if (query1.size() > 0) { if (query1.size() > 0) {

View File

@ -0,0 +1,80 @@
package com.hzya.frame.voucher.ae.comf.subject.controller;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastEntity;
import com.hzya.frame.voucher.ae.comf.subject.service.IAeConfSubjectClassificationService;
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.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.List;
/**
* Created by zydd on 2025-05-30 15:13
* 分类定义
*/
@RestController
@RequestMapping("/ae/conf/subjectClassification")
public class ClassificationController extends DefaultController {
@Autowired
private IAeConfSubjectClassificationService aeConfSubjectClassificationService;
@RequestMapping(value = "/queryAll", method = RequestMethod.POST)
public JsonResultEntity queryAll(@RequestBody AeConfSubjectClassificationEntity entity){
try {
List<AeConfSubjectClassificationEntity> all = aeConfSubjectClassificationService.queryAll(entity);
return getSuccessMessageEntity("请求成功",all);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
@RequestMapping(value = "/queryById", method = RequestMethod.POST)
public JsonResultEntity queryById(@RequestBody AeConfSubjectClassificationEntity entity){
try {
AeConfSubjectClassificationEntity aeConfSubjectClassificationEntity = aeConfSubjectClassificationService.queryById(entity);
return getSuccessMessageEntity("请求成功",aeConfSubjectClassificationEntity);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
@RequestMapping(value = "/save", method = RequestMethod.POST)
public JsonResultEntity save(@RequestBody AeConfSubjectClassificationEntity entity) {
try {
AeConfSubjectClassificationEntity save = aeConfSubjectClassificationService.saveEntity(entity);
return getSuccessMessageEntity("请求成功", save);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败", e.getMessage());
}
}
@RequestMapping(value = "/update", method = RequestMethod.POST)
public JsonResultEntity update(@RequestBody AeConfSubjectClassificationEntity entity) {
try {
AeConfSubjectClassificationEntity update = aeConfSubjectClassificationService.updateEntity(entity);
return getSuccessMessageEntity("请求成功", update);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败", e.getMessage());
}
}
@RequestMapping(value = "/delete", method = RequestMethod.POST)
public JsonResultEntity delete(@RequestBody AeConfSubjectClassificationEntity entity) {
try {
aeConfSubjectClassificationService.deleteEntity(entity);
return getSuccessMessageEntity("请求成功", null);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败", e.getMessage());
}
}
}

View File

@ -0,0 +1,70 @@
package com.hzya.frame.voucher.ae.comf.subject.controller;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastBEntity;
import com.hzya.frame.voucher.ae.comf.subject.service.IAeConfSubjectContrastBService;
import com.hzya.frame.voucher.ae.comf.subject.service.IAeConfSubjectContrastService;
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.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.List;
/**
* Created by zydd on 2025-05-30 15:13
*/
@RestController
@RequestMapping("/ae/conf/subjectContrastB")
public class ContrastBController extends DefaultController {
@Autowired
private IAeConfSubjectContrastService contrastService;
@Autowired
private IAeConfSubjectContrastBService contrastBService;
@RequestMapping(value = "/queryAllByContrastId", method = RequestMethod.POST)
public JsonResultEntity queryAllByContrastId(@RequestBody AeConfSubjectContrastBEntity entity){
try {
List<AeConfSubjectContrastBEntity> all = contrastBService.queryAllByContrastId(entity);
return getSuccessMessageEntity("请求成功",all);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
@RequestMapping(value = "/saveList", method = RequestMethod.POST)
public JsonResultEntity saveList(@RequestBody List<AeConfSubjectContrastBEntity> list){
try {
List<AeConfSubjectContrastBEntity> all = contrastBService.saveListEntity(list);
return getSuccessMessageEntity("请求成功",all);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
@RequestMapping(value = "/updateList", method = RequestMethod.POST)
public JsonResultEntity updateList(@RequestBody List<AeConfSubjectContrastBEntity> list){
try {
List<AeConfSubjectContrastBEntity> all = contrastBService.updateList(list);
return getSuccessMessageEntity("请求成功",all);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
@RequestMapping(value = "/delete", method = RequestMethod.POST)
public JsonResultEntity delete(@RequestBody AeConfSubjectContrastBEntity entity){
try {
contrastBService.deleteList(entity);
return getSuccessMessageEntity("请求成功",null);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
}

View File

@ -53,4 +53,38 @@ public class ContrastController extends DefaultController {
return getFailureMessageEntity("请求失败",e.getMessage()); return getFailureMessageEntity("请求失败",e.getMessage());
} }
} }
@RequestMapping(value = "/update", method = RequestMethod.POST)
public JsonResultEntity update(@RequestBody AeConfSubjectContrastEntity entity){
try {
AeConfSubjectContrastEntity save = aeConfSubjectContrastService.updateEntity(entity);
return getSuccessMessageEntity("请求成功",save);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
@RequestMapping(value = "/delete", method = RequestMethod.POST)
public JsonResultEntity delete(@RequestBody AeConfSubjectContrastEntity entity){
try {
AeConfSubjectContrastEntity save = aeConfSubjectContrastService.deleteEntity(entity);
return getSuccessMessageEntity("请求成功",save);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
//1根据入参影响因素ids分别查询影响因素设置的对应基础档案类型
//2再按顺序拼接写类型的ids再去科目对照表中查询这个ids对应的对照表
//3返回对照表对象
@RequestMapping(value = "/queryByInfluenceIds", method = RequestMethod.POST)
public JsonResultEntity queryByInfluenceIds(@RequestBody AeConfSubjectContrastEntity entity){
try {
List<AeConfSubjectContrastEntity> list = aeConfSubjectContrastService.queryByInfluenceIds(entity);
return getSuccessMessageEntity("请求成功",list);
} catch (Exception e) {
e.printStackTrace();
return getFailureMessageEntity("请求失败",e.getMessage());
}
}
} }

View File

@ -0,0 +1,15 @@
package com.hzya.frame.voucher.ae.comf.subject.dao;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity;
import com.hzya.frame.basedao.dao.IBaseDao;
/**
* 会计事项(accounting_event)-配置-科目分类定义(ae_conf_subject_classification: table)表数据库访问层
*
* @author zydd
* @since 2025-06-06 17:00:57
*/
public interface IAeConfSubjectClassificationDao extends IBaseDao<AeConfSubjectClassificationEntity, String> {
}

View File

@ -0,0 +1,17 @@
package com.hzya.frame.voucher.ae.comf.subject.dao.impl;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity;
import com.hzya.frame.voucher.ae.comf.subject.dao.IAeConfSubjectClassificationDao;
import org.springframework.stereotype.Repository;
import com.hzya.frame.basedao.dao.MybatisGenericDao;
/**
* 会计事项(accounting_event)-配置-科目分类定义(AeConfSubjectClassification)表数据库访问层
*
* @author zydd
* @since 2025-06-06 17:00:57
*/
@Repository
public class AeConfSubjectClassificationDaoImpl extends MybatisGenericDao<AeConfSubjectClassificationEntity, String> implements IAeConfSubjectClassificationDao{
}

View File

@ -0,0 +1,106 @@
package com.hzya.frame.voucher.ae.comf.subject.entity;
import java.util.Date;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.hzya.frame.web.entity.BaseEntity;
import lombok.Data;
/**
* 会计事项(accounting_event)-配置-科目分类定义(AeConfSubjectClassification)实体类
*
* @author zydd
* @since 2025-06-06 17:00:57
*/
@Data
public class AeConfSubjectClassificationEntity extends BaseEntity {
/**
* 科目分类编码
*/
private String code;
/**
* 科目分类名称
*/
private String name;
/**
* 模块id
*/
private String aeConfModuleId;
/**
* 公司pk
*/
private String pkCorp;
/**
* 账簿主键
*/
private String pkglorgbook;
/**
* 账簿编码
*/
private String glorgbookcode;
/**
* 账簿名称
*/
private String glorgbookname;
/**
* 影响因素定义ids
*/
private String factorids;
/**
* 影响因素定义names
*/
private String factornames;
/**
* 对照表id
*/
private String contrastId;
private String contrastCode;
private String contrastName;
/**
* 目标档案值会计科目)-默认值没有对照表时使用
*/
private String desdocvalueDefaultId;
private String desdocvalueDefaultName;
/**
* 备注
*/
private String remark;
@JsonIgnore
private String def1;
@JsonIgnore
private String def2;
@JsonIgnore
private String def3;
@JsonIgnore
private String def4;
@JsonIgnore
private String def5;
@JsonIgnore
private String def6;
@JsonIgnore
private String def7;
@JsonIgnore
private String def8;
@JsonIgnore
private String def9;
@JsonIgnore
private String def10;
/**
* 创建人
*/
private String createUser;
/**
* 修改人
*/
private String modifyUser;
/**
* 科目对照子表
*/
private List<AeConfSubjectContrastBEntity> contrastBEntityList;
}

View File

@ -0,0 +1,459 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.hzya.frame.voucher.ae.comf.subject.dao.impl.AeConfSubjectClassificationDaoImpl">
<resultMap id="get-AeConfSubjectClassificationEntity-result"
type="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity">
<result property="id" column="id" jdbcType="INTEGER"/>
<result property="code" column="code" jdbcType="VARCHAR"/>
<result property="name" column="name" jdbcType="VARCHAR"/>
<result property="aeConfModuleId" column="aeConfModuleId" jdbcType="VARCHAR"/>
<result property="pkCorp" column="pk_corp" jdbcType="VARCHAR"/>
<result property="pkglorgbook" column="pkglorgbook" jdbcType="VARCHAR"/>
<result property="glorgbookcode" column="glorgbookcode" jdbcType="VARCHAR"/>
<result property="glorgbookname" column="glorgbookname" jdbcType="VARCHAR"/>
<result property="factorids" column="factorIds" jdbcType="VARCHAR"/>
<result property="factornames" column="factorNames" jdbcType="VARCHAR"/>
<result property="contrastId" column="contrast_id" jdbcType="VARCHAR"/>
<result property="contrastCode" column="contrast_code" jdbcType="VARCHAR"/>
<result property="contrastName" column="contrast_name" jdbcType="VARCHAR"/>
<result property="desdocvalueDefaultId" column="desdocvalue_default_id" jdbcType="VARCHAR"/>
<result property="desdocvalueDefaultName" column="desdocvalue_default_name" jdbcType="VARCHAR"/>
<result property="remark" column="remark" jdbcType="VARCHAR"/>
<result property="def1" column="def1" jdbcType="VARCHAR"/>
<result property="def2" column="def2" jdbcType="VARCHAR"/>
<result property="def3" column="def3" jdbcType="VARCHAR"/>
<result property="def4" column="def4" jdbcType="VARCHAR"/>
<result property="def5" column="def5" jdbcType="VARCHAR"/>
<result property="def6" column="def6" jdbcType="VARCHAR"/>
<result property="def7" column="def7" jdbcType="VARCHAR"/>
<result property="def8" column="def8" jdbcType="VARCHAR"/>
<result property="def9" column="def9" jdbcType="VARCHAR"/>
<result property="def10" column="def10" jdbcType="VARCHAR"/>
<result property="create_time" column="create_time" jdbcType="TIMESTAMP"/>
<result property="createUser" column="create_user" jdbcType="VARCHAR"/>
<result property="modify_time" column="modify_time" jdbcType="TIMESTAMP"/>
<result property="modifyUser" column="modify_user" jdbcType="VARCHAR"/>
<result property="sts" column="sts" jdbcType="VARCHAR"/>
</resultMap>
<!-- 查询的字段-->
<sql id="AeConfSubjectClassificationEntity_Base_Column_List">
id
,code
,name
,aeConfModuleId
,pk_corp
,pkglorgbook
,glorgbookcode
,glorgbookname
,factorIds
,factorNames
,contrast_id
,contrast_code
,contrast_name
,desdocvalue_default_id
,desdocvalue_default_name
,remark
,def1
,def2
,def3
,def4
,def5
,def6
,def7
,def8
,def9
,def10
,create_time
,create_user
,modify_time
,modify_user
,sts
</sql>
<!-- 查询 采用==查询 -->
<select id="entity_list_base" resultMap="get-AeConfSubjectClassificationEntity-result"
parameterType="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity">
select
<include refid="AeConfSubjectClassificationEntity_Base_Column_List"/>
from ae_conf_subject_classification
<trim prefix="where" prefixOverrides="and">
<if test="id != null">and id = #{id}</if>
<if test="code != null and code != ''">and code = #{code}</if>
<if test="name != null and name != ''">and name = #{name}</if>
<if test="aeConfModuleId != null and aeConfModuleId != ''">and aeConfModuleId = #{aeConfModuleId}</if>
<if test="pkCorp != null and pkCorp != ''">and pk_corp = #{pkCorp}</if>
<if test="pkglorgbook != null and pkglorgbook != ''">and pkglorgbook = #{pkglorgbook}</if>
<if test="glorgbookcode != null and glorgbookcode != ''">and glorgbookcode = #{glorgbookcode}</if>
<if test="glorgbookname != null and glorgbookname != ''">and glorgbookname = #{glorgbookname}</if>
<if test="factorids != null and factorids != ''">and factorIds = #{factorids}</if>
<if test="factornames != null and factornames != ''">and factorNames = #{factornames}</if>
<if test="contrastId != null and contrastId != ''">and contrast_id = #{contrastId}</if>
<if test="contrastCode != null and contrastCode != ''">and contrast_code = #{contrastCode}</if>
<if test="contrastName != null and contrastName != ''">and contrast_name = #{contrastName}</if>
<if test="desdocvalueDefaultId != null and desdocvalueDefaultId != ''">and desdocvalue_default_id = #{desdocvalueDefaultId} </if>
<if test="desdocvalueDefaultName != null and desdocvalueDefaultName != ''">and desdocvalue_default_name = #{desdocvalueDefaultName} </if>
<if test="remark != null and remark != ''">and remark = #{remark}</if>
<if test="def1 != null and def1 != ''">and def1 = #{def1}</if>
<if test="def2 != null and def2 != ''">and def2 = #{def2}</if>
<if test="def3 != null and def3 != ''">and def3 = #{def3}</if>
<if test="def4 != null and def4 != ''">and def4 = #{def4}</if>
<if test="def5 != null and def5 != ''">and def5 = #{def5}</if>
<if test="def6 != null and def6 != ''">and def6 = #{def6}</if>
<if test="def7 != null and def7 != ''">and def7 = #{def7}</if>
<if test="def8 != null and def8 != ''">and def8 = #{def8}</if>
<if test="def9 != null and def9 != ''">and def9 = #{def9}</if>
<if test="def10 != null and def10 != ''">and def10 = #{def10}</if>
<if test="create_time != null">and create_time = #{create_time}</if>
<if test="createUser != null and createUser != ''">and create_user = #{createUser}</if>
<if test="modify_time != null">and modify_time = #{modify_time}</if>
<if test="modifyUser != null and modifyUser != ''">and modify_user = #{modifyUser}</if>
<if test="sts != null and sts != ''">and sts = #{sts}</if>
and sts='Y'
</trim>
</select>
<!-- 查询符合条件的数量 -->
<select id="entity_count" resultType="Integer"
parameterType="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity">
select count(1) from ae_conf_subject_classification
<trim prefix="where" prefixOverrides="and">
<if test="id != null">and id = #{id}</if>
<if test="code != null and code != ''">and code = #{code}</if>
<if test="name != null and name != ''">and name = #{name}</if>
<if test="aeConfModuleId != null and aeConfModuleId != ''">and aeConfModuleId = #{aeConfModuleId}</if>
<if test="pkCorp != null and pkCorp != ''">and pk_corp = #{pkCorp}</if>
<if test="pkglorgbook != null and pkglorgbook != ''">and pkglorgbook = #{pkglorgbook}</if>
<if test="glorgbookcode != null and glorgbookcode != ''">and glorgbookcode = #{glorgbookcode}</if>
<if test="glorgbookname != null and glorgbookname != ''">and glorgbookname = #{glorgbookname}</if>
<if test="factorids != null and factorids != ''">and factorIds = #{factorids}</if>
<if test="factornames != null and factornames != ''">and factorNames = #{factornames}</if>
<if test="contrastId != null and contrastId != ''">and contrast_id = #{contrastId}</if>
<if test="contrastCode != null and contrastCode != ''">and contrast_code = #{contrastCode}</if>
<if test="contrastName != null and contrastName != ''">and contrast_name = #{contrastName}</if>
<if test="desdocvalueDefaultId != null and desdocvalueDefaultId != ''">and desdocvalue_default_id = #{desdocvalueDefaultId} </if>
<if test="desdocvalueDefaultName != null and desdocvalueDefaultName != ''">and desdocvalue_default_name = #{desdocvalueDefaultName} </if>
<if test="remark != null and remark != ''">and remark = #{remark}</if>
<if test="def1 != null and def1 != ''">and def1 = #{def1}</if>
<if test="def2 != null and def2 != ''">and def2 = #{def2}</if>
<if test="def3 != null and def3 != ''">and def3 = #{def3}</if>
<if test="def4 != null and def4 != ''">and def4 = #{def4}</if>
<if test="def5 != null and def5 != ''">and def5 = #{def5}</if>
<if test="def6 != null and def6 != ''">and def6 = #{def6}</if>
<if test="def7 != null and def7 != ''">and def7 = #{def7}</if>
<if test="def8 != null and def8 != ''">and def8 = #{def8}</if>
<if test="def9 != null and def9 != ''">and def9 = #{def9}</if>
<if test="def10 != null and def10 != ''">and def10 = #{def10}</if>
<if test="create_time != null">and create_time = #{create_time}</if>
<if test="createUser != null and createUser != ''">and create_user = #{createUser}</if>
<if test="modify_time != null">and modify_time = #{modify_time}</if>
<if test="modifyUser != null and modifyUser != ''">and modify_user = #{modifyUser}</if>
<if test="sts != null and sts != ''">and sts = #{sts}</if>
and sts='Y'
</trim>
</select>
<!-- 分页查询列表 采用like格式 -->
<select id="entity_list_like" resultMap="get-AeConfSubjectClassificationEntity-result"
parameterType="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity">
select
<include refid="AeConfSubjectClassificationEntity_Base_Column_List"/>
from ae_conf_subject_classification
<trim prefix="where" prefixOverrides="and">
<if test="id != null">and id like concat('%',#{id},'%')</if>
<if test="code != null and code != ''">and code like concat('%',#{code},'%')</if>
<if test="name != null and name != ''">and name like concat('%',#{name},'%')</if>
<if test="aeConfModuleId != null and aeConfModuleId != ''">and aeConfModuleId like concat('%',#{aeConfModuleId},'%')</if>
<if test="pkCorp != null and pkCorp != ''">and pk_corp like concat('%',#{pkCorp},'%')</if>
<if test="pkglorgbook != null and pkglorgbook != ''">and pkglorgbook like concat('%',#{pkglorgbook},'%')
</if>
<if test="glorgbookcode != null and glorgbookcode != ''">and glorgbookcode like
concat('%',#{glorgbookcode},'%')
</if>
<if test="glorgbookname != null and glorgbookname != ''">and glorgbookname like
concat('%',#{glorgbookname},'%')
</if>
<if test="factorids != null and factorids != ''">and factorIds like concat('%',#{factorids},'%')</if>
<if test="factornames != null and factornames != ''">and factorNames like concat('%',#{factornames},'%')
</if>
<if test="contrastId != null and contrastId != ''">and contrast_id like concat('%',#{contrastId},'%')</if>
<if test="contrastCode != null and contrastCode != ''">and contrast_code like concat('%',#{contrastCode},'%')</if>
<if test="contrastName != null and contrastName != ''">and contrast_name like concat('%',#{contrastName},'%')</if>
<if test="desdocvalueDefaultId != null and desdocvalueDefaultId != ''">and desdocvalue_default_id like concat('%',#{desdocvalueDefaultId},'%') </if>
<if test="desdocvalueDefaultName != null and desdocvalueDefaultName != ''">and desdocvalue_default_name like concat('%',#{desdocvalueDefaultName},'%') </if>
<if test="remark != null and remark != ''">and remark like concat('%',#{remark},'%')</if>
<if test="def1 != null and def1 != ''">and def1 like concat('%',#{def1},'%')</if>
<if test="def2 != null and def2 != ''">and def2 like concat('%',#{def2},'%')</if>
<if test="def3 != null and def3 != ''">and def3 like concat('%',#{def3},'%')</if>
<if test="def4 != null and def4 != ''">and def4 like concat('%',#{def4},'%')</if>
<if test="def5 != null and def5 != ''">and def5 like concat('%',#{def5},'%')</if>
<if test="def6 != null and def6 != ''">and def6 like concat('%',#{def6},'%')</if>
<if test="def7 != null and def7 != ''">and def7 like concat('%',#{def7},'%')</if>
<if test="def8 != null and def8 != ''">and def8 like concat('%',#{def8},'%')</if>
<if test="def9 != null and def9 != ''">and def9 like concat('%',#{def9},'%')</if>
<if test="def10 != null and def10 != ''">and def10 like concat('%',#{def10},'%')</if>
<if test="create_time != null">and create_time like concat('%',#{create_time},'%')</if>
<if test="createUser != null and createUser != ''">and create_user like concat('%',#{createUser},'%')</if>
<if test="modify_time != null">and modify_time like concat('%',#{modify_time},'%')</if>
<if test="modifyUser != null and modifyUser != ''">and modify_user like concat('%',#{modifyUser},'%')</if>
<if test="sts != null and sts != ''">and sts like concat('%',#{sts},'%')</if>
and sts='Y'
</trim>
</select>
<!-- 查询列表 字段采用or格式 -->
<select id="AeConfSubjectClassificationentity_list_or" resultMap="get-AeConfSubjectClassificationEntity-result"
parameterType="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity">
select
<include refid="AeConfSubjectClassificationEntity_Base_Column_List"/>
from ae_conf_subject_classification
<trim prefix="where" prefixOverrides="and">
<if test="id != null">or id = #{id}</if>
<if test="code != null and code != ''">or code = #{code}</if>
<if test="name != null and name != ''">or name = #{name}</if>
<if test="aeConfModuleId != null and aeConfModuleId != ''">or aeConfModuleId = #{aeConfModuleId}</if>
<if test="pkCorp != null and pkCorp != ''">or pk_corp = #{pkCorp}</if>
<if test="pkglorgbook != null and pkglorgbook != ''">or pkglorgbook = #{pkglorgbook}</if>
<if test="glorgbookcode != null and glorgbookcode != ''">or glorgbookcode = #{glorgbookcode}</if>
<if test="glorgbookname != null and glorgbookname != ''">or glorgbookname = #{glorgbookname}</if>
<if test="factorids != null and factorids != ''">or factorIds = #{factorids}</if>
<if test="factornames != null and factornames != ''">or factorNames = #{factornames}</if>
<if test="contrastId != null and contrastId != ''">or contrast_id = #{contrastId}</if>
<if test="desdocvalueDefaultId != null and desdocvalueDefaultId != ''">or desdocvalue_default_id = #{desdocvalueDefaultId} </if>
<if test="desdocvalueDefaultName != null and desdocvalueDefaultName != ''">or desdocvalue_default_name = #{desdocvalueDefaultName} </if>
<if test="remark != null and remark != ''">or remark = #{remark}</if>
<if test="def1 != null and def1 != ''">or def1 = #{def1}</if>
<if test="def2 != null and def2 != ''">or def2 = #{def2}</if>
<if test="def3 != null and def3 != ''">or def3 = #{def3}</if>
<if test="def4 != null and def4 != ''">or def4 = #{def4}</if>
<if test="def5 != null and def5 != ''">or def5 = #{def5}</if>
<if test="def6 != null and def6 != ''">or def6 = #{def6}</if>
<if test="def7 != null and def7 != ''">or def7 = #{def7}</if>
<if test="def8 != null and def8 != ''">or def8 = #{def8}</if>
<if test="def9 != null and def9 != ''">or def9 = #{def9}</if>
<if test="def10 != null and def10 != ''">or def10 = #{def10}</if>
<if test="create_time != null">or create_time = #{create_time}</if>
<if test="createUser != null and createUser != ''">or create_user = #{createUser}</if>
<if test="modify_time != null">or modify_time = #{modify_time}</if>
<if test="modifyUser != null and modifyUser != ''">or modify_user = #{modifyUser}</if>
<if test="sts != null and sts != ''">or sts = #{sts}</if>
and sts='Y'
</trim>
</select>
<!--新增所有列-->
<insert id="entity_insert"
parameterType="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity"
keyProperty="id" useGeneratedKeys="true">
insert into ae_conf_subject_classification(
<trim suffix="" suffixOverrides=",">
<if test="code != null and code != ''">code ,</if>
<if test="name != null and name != ''">name ,</if>
<if test="aeConfModuleId != null and aeConfModuleId != ''">aeConfModuleId ,</if>
<if test="pkCorp != null and pkCorp != ''">pk_corp ,</if>
<if test="pkglorgbook != null and pkglorgbook != ''">pkglorgbook ,</if>
<if test="glorgbookcode != null and glorgbookcode != ''">glorgbookcode ,</if>
<if test="glorgbookname != null and glorgbookname != ''">glorgbookname ,</if>
<if test="factorids != null and factorids != ''">factorIds ,</if>
<if test="factornames != null and factornames != ''">factorNames ,</if>
<if test="contrastId != null and contrastId != ''">contrast_id ,</if>
<if test="contrastCode != null and contrastCode != ''">contrast_code ,</if>
<if test="contrastName != null and contrastName != ''">contrast_name ,</if>
<if test="desdocvalueDefaultId != null and desdocvalueDefaultId != ''">desdocvalue_default_id ,</if>
<if test="desdocvalueDefaultName != null and desdocvalueDefaultName != ''">desdocvalue_default_name ,</if>
<if test="remark != null and remark != ''">remark ,</if>
<if test="def1 != null and def1 != ''">def1 ,</if>
<if test="def2 != null and def2 != ''">def2 ,</if>
<if test="def3 != null and def3 != ''">def3 ,</if>
<if test="def4 != null and def4 != ''">def4 ,</if>
<if test="def5 != null and def5 != ''">def5 ,</if>
<if test="def6 != null and def6 != ''">def6 ,</if>
<if test="def7 != null and def7 != ''">def7 ,</if>
<if test="def8 != null and def8 != ''">def8 ,</if>
<if test="def9 != null and def9 != ''">def9 ,</if>
<if test="def10 != null and def10 != ''">def10 ,</if>
<if test="create_time != null">create_time ,</if>
<if test="create_time == null">create_time ,</if>
<if test="createUser != null and createUser != ''">create_user ,</if>
<if test="modify_time != null">modify_time ,</if>
<if test="modify_time == null">modify_time ,</if>
<if test="modifyUser != null and modifyUser != ''">modify_user ,</if>
<if test="sts != null and sts != ''">sts ,</if>
<if test="sts == null ">sts,</if>
</trim>
)values(
<trim suffix="" suffixOverrides=",">
<if test="code != null and code != ''">#{code} ,</if>
<if test="name != null and name != ''">#{name} ,</if>
<if test="aeConfModuleId != null and aeConfModuleId != ''">#{aeConfModuleId} ,</if>
<if test="pkCorp != null and pkCorp != ''">#{pkCorp} ,</if>
<if test="pkglorgbook != null and pkglorgbook != ''">#{pkglorgbook} ,</if>
<if test="glorgbookcode != null and glorgbookcode != ''">#{glorgbookcode} ,</if>
<if test="glorgbookname != null and glorgbookname != ''">#{glorgbookname} ,</if>
<if test="factorids != null and factorids != ''">#{factorids} ,</if>
<if test="factornames != null and factornames != ''">#{factornames} ,</if>
<if test="contrastId != null and contrastId != ''">#{contrastId} ,</if>
<if test="contrastCode != null and contrastCode != ''">#{contrastCode} ,</if>
<if test="contrastName != null and contrastName != ''">#{contrastName} ,</if>
<if test="desdocvalueDefaultId != null and desdocvalueDefaultId != ''">#{desdocvalueDefaultId} ,</if>
<if test="desdocvalueDefaultName != null and desdocvalueDefaultName != ''">#{desdocvalueDefaultName} ,</if>
<if test="remark != null and remark != ''">#{remark} ,</if>
<if test="def1 != null and def1 != ''">#{def1} ,</if>
<if test="def2 != null and def2 != ''">#{def2} ,</if>
<if test="def3 != null and def3 != ''">#{def3} ,</if>
<if test="def4 != null and def4 != ''">#{def4} ,</if>
<if test="def5 != null and def5 != ''">#{def5} ,</if>
<if test="def6 != null and def6 != ''">#{def6} ,</if>
<if test="def7 != null and def7 != ''">#{def7} ,</if>
<if test="def8 != null and def8 != ''">#{def8} ,</if>
<if test="def9 != null and def9 != ''">#{def9} ,</if>
<if test="def10 != null and def10 != ''">#{def10} ,</if>
<if test="create_time != null">#{create_time} ,</if>
<if test="create_time == null">now() ,</if>
<if test="createUser != null and createUser != ''">#{createUser} ,</if>
<if test="modify_time != null">#{modify_time} ,</if>
<if test="modify_time == null">now() ,</if>
<if test="modifyUser != null and modifyUser != ''">#{modifyUser} ,</if>
<if test="sts != null and sts != ''">#{sts} ,</if>
<if test="sts == null ">'Y',</if>
</trim>
)
</insert>
<!-- 批量新增 -->
<insert id="entityInsertBatch" keyProperty="id" useGeneratedKeys="true">
insert into ae_conf_subject_classification(code, name, pk_corp, pkglorgbook, glorgbookcode, glorgbookname,
factorIds, factorNames, contrast_id, desdocvalue_default_id, remark, def1, def2, def3, def4, def5, def6, def7,
def8, def9, def10, create_time, create_user, modify_time, modify_user, sts, sts)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.code},#{entity.name},#{entity.pkCorp},#{entity.pkglorgbook},#{entity.glorgbookcode},#{entity.glorgbookname},#{entity.factorids},#{entity.factornames},#{entity.contrastId},#{entity.desdocvalueDefaultId},#{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')
</foreach>
</insert>
<!-- 批量新增或者修改-->
<insert id="entityInsertOrUpdateBatch" keyProperty="id" useGeneratedKeys="true">
insert into ae_conf_subject_classification(code, name, pk_corp, pkglorgbook, glorgbookcode, glorgbookname,
factorIds, factorNames, contrast_id, desdocvalue_default_id, remark, def1, def2, def3, def4, def5, def6, def7,
def8, def9, def10, create_time, create_user, modify_time, modify_user, sts)
values
<foreach collection="entities" item="entity" separator=",">
(#{entity.code},#{entity.name},#{entity.pkCorp},#{entity.pkglorgbook},#{entity.glorgbookcode},#{entity.glorgbookname},#{entity.factorids},#{entity.factornames},#{entity.contrastId},#{entity.desdocvalueDefaultId},#{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})
</foreach>
on duplicate key update
code = values(code),
name = values(name),
pk_corp = values(pk_corp),
pkglorgbook = values(pkglorgbook),
glorgbookcode = values(glorgbookcode),
glorgbookname = values(glorgbookname),
factorIds = values(factorIds),
factorNames = values(factorNames),
contrast_id = values(contrast_id),
desdocvalue_default_id = values(desdocvalue_default_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)
</insert>
<!--通过主键修改方法-->
<update id="entity_update"
parameterType="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity">
update ae_conf_subject_classification set
<trim suffix="" suffixOverrides=",">
<if test="code != null and code != ''">code = #{code},</if>
<if test="name != null and name != ''">name = #{name},</if>
<if test="aeConfModuleId != null and aeConfModuleId != ''">aeConfModuleId = #{aeConfModuleId},</if>
<if test="pkCorp != null and pkCorp != ''">pk_corp = #{pkCorp},</if>
<if test="pkglorgbook != null and pkglorgbook != ''">pkglorgbook = #{pkglorgbook},</if>
<if test="glorgbookcode != null and glorgbookcode != ''">glorgbookcode = #{glorgbookcode},</if>
<if test="glorgbookname != null and glorgbookname != ''">glorgbookname = #{glorgbookname},</if>
<if test="factorids != null and factorids != ''">factorIds = #{factorids},</if>
<if test="factornames != null and factornames != ''">factorNames = #{factornames},</if>
<if test="contrastId != null and contrastId != ''">contrast_id = #{contrastId},</if>
<if test="contrastCode != null and contrastCode != ''">contrast_code = #{contrastCode},</if>
<if test="contrastName != null and contrastName != ''">contrast_name = #{contrastName},</if>
<if test="desdocvalueDefaultId != null and desdocvalueDefaultId != ''">desdocvalue_default_id = #{desdocvalueDefaultId}, </if>
<if test="desdocvalueDefaultName != null and desdocvalueDefaultName != ''">desdocvalue_default_name = #{desdocvalueDefaultName}, </if>
<if test="remark != null and remark != ''">remark = #{remark},</if>
<if test="def1 != null and def1 != ''">def1 = #{def1},</if>
<if test="def2 != null and def2 != ''">def2 = #{def2},</if>
<if test="def3 != null and def3 != ''">def3 = #{def3},</if>
<if test="def4 != null and def4 != ''">def4 = #{def4},</if>
<if test="def5 != null and def5 != ''">def5 = #{def5},</if>
<if test="def6 != null and def6 != ''">def6 = #{def6},</if>
<if test="def7 != null and def7 != ''">def7 = #{def7},</if>
<if test="def8 != null and def8 != ''">def8 = #{def8},</if>
<if test="def9 != null and def9 != ''">def9 = #{def9},</if>
<if test="def10 != null and def10 != ''">def10 = #{def10},</if>
<if test="create_time != null">create_time = #{create_time},</if>
<if test="createUser != null and createUser != ''">create_user = #{createUser},</if>
<if test="modify_time != null">modify_time = #{modify_time},</if>
<if test="modify_time == null">modify_time = now(),</if>
<if test="modifyUser != null and modifyUser != ''">modify_user = #{modifyUser},</if>
<if test="sts != null and sts != ''">sts = #{sts},</if>
</trim>
where id = #{id}
</update>
<!-- 逻辑删除 -->
<update id="entity_logicDelete"
parameterType="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity">
update ae_conf_subject_classification
set sts= 'N',
modify_time = now()
where id = #{id}
</update>
<!-- 多条件逻辑删除 -->
<update id="entity_logicDelete_Multi_Condition"
parameterType="com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity">
update ae_conf_subject_classification set sts= 'N' ,modify_time = #{modify_time},modify_user_id =
#{modify_user_id}
<trim prefix="where" prefixOverrides="and">
<if test="id != null">and id = #{id}</if>
<if test="code != null and code != ''">and code = #{code}</if>
<if test="name != null and name != ''">and name = #{name}</if>
<if test="pkCorp != null and pkCorp != ''">and pk_corp = #{pkCorp}</if>
<if test="pkglorgbook != null and pkglorgbook != ''">and pkglorgbook = #{pkglorgbook}</if>
<if test="glorgbookcode != null and glorgbookcode != ''">and glorgbookcode = #{glorgbookcode}</if>
<if test="glorgbookname != null and glorgbookname != ''">and glorgbookname = #{glorgbookname}</if>
<if test="factorids != null and factorids != ''">and factorIds = #{factorids}</if>
<if test="factornames != null and factornames != ''">and factorNames = #{factornames}</if>
<if test="contrastId != null and contrastId != ''">and contrast_id = #{contrastId}</if>
<if test="desdocvalueDefaultId != null and desdocvalueDefaultId != ''">and desdocvalue_default_id = #{desdocvalueDefaultId} </if>
<if test="desdocvalueDefaultName != null and desdocvalueDefaultName != ''">and desdocvalue_default_name = #{desdocvalueDefaultName} </if>
<if test="remark != null and remark != ''">and remark = #{remark}</if>
<if test="def1 != null and def1 != ''">and def1 = #{def1}</if>
<if test="def2 != null and def2 != ''">and def2 = #{def2}</if>
<if test="def3 != null and def3 != ''">and def3 = #{def3}</if>
<if test="def4 != null and def4 != ''">and def4 = #{def4}</if>
<if test="def5 != null and def5 != ''">and def5 = #{def5}</if>
<if test="def6 != null and def6 != ''">and def6 = #{def6}</if>
<if test="def7 != null and def7 != ''">and def7 = #{def7}</if>
<if test="def8 != null and def8 != ''">and def8 = #{def8}</if>
<if test="def9 != null and def9 != ''">and def9 = #{def9}</if>
<if test="def10 != null and def10 != ''">and def10 = #{def10}</if>
<if test="createUser != null and createUser != ''">and create_user = #{createUser}</if>
<if test="modifyUser != null and modifyUser != ''">and modify_user = #{modifyUser}</if>
<if test="sts != null and sts != ''">and sts = #{sts}</if>
and sts='Y'
</trim>
</update>
<!--通过主键删除-->
<delete id="entity_delete">
delete
from ae_conf_subject_classification
where id = #{id}
</delete>
</mapper>

View File

@ -2,6 +2,7 @@ package com.hzya.frame.voucher.ae.comf.subject.entity;
import java.util.Date; import java.util.Date;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.hzya.frame.web.entity.BaseEntity; import com.hzya.frame.web.entity.BaseEntity;
import lombok.Data; import lombok.Data;
@ -17,136 +18,227 @@ public class AeConfSubjectContrastBEntity extends BaseEntity {
/** /**
* 对照表id * 对照表id
*/ */
@JsonIgnore
private Long contrastId; private Long contrastId;
/** /**
* 公司pk * 公司pk
*/ */
@JsonIgnore
private String pkCorp; private String pkCorp;
private String glorgname;
/**
* 目标档案id
*/
@JsonIgnore
private String pkAccsubj;
/** /**
* 目标档案值会计科目) * 目标档案值会计科目)
*/ */
@JsonIgnore
private String desdocvalue; private String desdocvalue;
/** /**
* 来源档案表1 * 来源档案表1
*/ */
@JsonIgnore
private String factortable1; private String factortable1;
/** /**
* 来源档案表2 * 来源档案表2
*/ */
@JsonIgnore
private String factortable2; private String factortable2;
/** /**
* 来源档案表3 * 来源档案表3
*/ */
@JsonIgnore
private String factortable3; private String factortable3;
/** /**
* 来源档案表4 * 来源档案表4
*/ */
@JsonIgnore
private String factortable4; private String factortable4;
/** /**
* 来源档案表5 * 来源档案表5
*/ */
@JsonIgnore
private String factortable5; private String factortable5;
/** /**
* 来源档案表6 * 来源档案表6
*/ */
@JsonIgnore
private String factortable6; private String factortable6;
/** /**
* 来源档案表7 * 来源档案表7
*/ */
@JsonIgnore
private String factortable7; private String factortable7;
/** /**
* 来源档案表8 * 来源档案表8
*/ */
@JsonIgnore
private String factortable8; private String factortable8;
/** /**
* 来源档案表9 * 来源档案表9
*/ */
@JsonIgnore
private String factortable9; private String factortable9;
/** /**
* 来源档案主键1 * 来源档案主键1
*/ */
@JsonIgnore
private String factorpk1; private String factorpk1;
/** /**
* 来源档案主键2 * 来源档案主键2
*/ */
@JsonIgnore
private String factorpk2; private String factorpk2;
/** /**
* 来源档案主键3 * 来源档案主键3
*/ */
@JsonIgnore
private String factorpk3; private String factorpk3;
/** /**
* 来源档案主键4 * 来源档案主键4
*/ */
@JsonIgnore
private String factorpk4; private String factorpk4;
/** /**
* 来源档案主键5 * 来源档案主键5
*/ */
@JsonIgnore
private String factorpk5; private String factorpk5;
/** /**
* 来源档案主键6 * 来源档案主键6
*/ */
@JsonIgnore
private String factorpk6; private String factorpk6;
/** /**
* 来源档案主键7 * 来源档案主键7
*/ */
@JsonIgnore
private String factorpk7; private String factorpk7;
/** /**
* 来源档案主键8 * 来源档案主键8
*/ */
@JsonIgnore
private String factorpk8; private String factorpk8;
/** /**
* 来源档案主键9 * 来源档案主键9
*/ */
@JsonIgnore
private String factorpk9; private String factorpk9;
/** /**
* 来源档案值1 * 来源档案值1
*/ */
@JsonIgnore
private String factorid1; private String factorid1;
/** /**
* 来源档案值2 * 来源档案值2
*/ */
@JsonIgnore
private String factorid2; private String factorid2;
/** /**
* 来源档案值3 * 来源档案值3
*/ */
@JsonIgnore
private String factorid3; private String factorid3;
/** /**
* 来源档案值4 * 来源档案值4
*/ */
@JsonIgnore
private String factorid4; private String factorid4;
/** /**
* 来源档案值5 * 来源档案值5
*/ */
@JsonIgnore
private String factorid5; private String factorid5;
/** /**
* 来源档案值6 * 来源档案值6
*/ */
@JsonIgnore
private String factorid6; private String factorid6;
/** /**
* 来源档案值7 * 来源档案值7
*/ */
@JsonIgnore
private String factorid7; private String factorid7;
/** /**
* 来源档案值8 * 来源档案值8
*/ */
@JsonIgnore
private String factorid8; private String factorid8;
/** /**
* 来源档案值9 * 来源档案值9
*/ */
@JsonIgnore
private String factorid9; private String factorid9;
/**
* 来源档案名称1
*/
@JsonIgnore
private String factorname1;
/**
* 来源档案名称2
*/
@JsonIgnore
private String factorname2;
/**
* 来源档案名称3
*/
@JsonIgnore
private String factorname3;
/**
* 来源档案名称4
*/
@JsonIgnore
private String factorname4;
/**
* 来源档案名称5
*/
@JsonIgnore
private String factorname5;
/**
* 来源档案名称6
*/
@JsonIgnore
private String factorname6;
/**
* 来源档案名称7
*/
@JsonIgnore
private String factorname7;
/**
* 来源档案名称8
*/
@JsonIgnore
private String factorname8;
/**
* 来源档案名称9
*/
@JsonIgnore
private String factorname9;
/** /**
* 备注 * 备注
*/ */
private String remark; private String remark;
@JsonIgnore
private String def1; private String def1;
@JsonIgnore
private String def2; private String def2;
@JsonIgnore
private String def3; private String def3;
@JsonIgnore
private String def4; private String def4;
@JsonIgnore
private String def5; private String def5;
@JsonIgnore
private String def6; private String def6;
@JsonIgnore
private String def7; private String def7;
@JsonIgnore
private String def8; private String def8;
@JsonIgnore
private String def9; private String def9;
@JsonIgnore
private String def10; private String def10;
/** /**
* 创建人 * 创建人

View File

@ -7,7 +7,9 @@
<result property="id" column="id" jdbcType="INTEGER"/> <result property="id" column="id" jdbcType="INTEGER"/>
<result property="contrastId" column="contrast_id" jdbcType="INTEGER"/> <result property="contrastId" column="contrast_id" jdbcType="INTEGER"/>
<result property="pkCorp" column="pk_corp" jdbcType="VARCHAR"/> <result property="pkCorp" column="pk_corp" jdbcType="VARCHAR"/>
<result property="glorgname" column="glorgname" jdbcType="VARCHAR"/>
<result property="desdocvalue" column="desdocvalue" jdbcType="VARCHAR"/> <result property="desdocvalue" column="desdocvalue" jdbcType="VARCHAR"/>
<result property="pkAccsubj" column="pkAccsubj" jdbcType="VARCHAR"/>
<result property="factortable1" column="factortable1" jdbcType="VARCHAR"/> <result property="factortable1" column="factortable1" jdbcType="VARCHAR"/>
<result property="factortable2" column="factortable2" jdbcType="VARCHAR"/> <result property="factortable2" column="factortable2" jdbcType="VARCHAR"/>
<result property="factortable3" column="factortable3" jdbcType="VARCHAR"/> <result property="factortable3" column="factortable3" jdbcType="VARCHAR"/>
@ -35,6 +37,15 @@
<result property="factorid7" column="factorid7" jdbcType="VARCHAR"/> <result property="factorid7" column="factorid7" jdbcType="VARCHAR"/>
<result property="factorid8" column="factorid8" jdbcType="VARCHAR"/> <result property="factorid8" column="factorid8" jdbcType="VARCHAR"/>
<result property="factorid9" column="factorid9" jdbcType="VARCHAR"/> <result property="factorid9" column="factorid9" jdbcType="VARCHAR"/>
<result property="factorname1" column="factorname1" jdbcType="VARCHAR"/>
<result property="factorname2" column="factorname2" jdbcType="VARCHAR"/>
<result property="factorname3" column="factorname3" jdbcType="VARCHAR"/>
<result property="factorname4" column="factorname4" jdbcType="VARCHAR"/>
<result property="factorname5" column="factorname5" jdbcType="VARCHAR"/>
<result property="factorname6" column="factorname6" jdbcType="VARCHAR"/>
<result property="factorname7" column="factorname7" jdbcType="VARCHAR"/>
<result property="factorname8" column="factorname8" jdbcType="VARCHAR"/>
<result property="factorname9" column="factorname9" jdbcType="VARCHAR"/>
<result property="remark" column="remark" jdbcType="VARCHAR"/> <result property="remark" column="remark" jdbcType="VARCHAR"/>
<result property="def1" column="def1" jdbcType="VARCHAR"/> <result property="def1" column="def1" jdbcType="VARCHAR"/>
<result property="def2" column="def2" jdbcType="VARCHAR"/> <result property="def2" column="def2" jdbcType="VARCHAR"/>
@ -57,6 +68,8 @@
id id
,contrast_id ,contrast_id
,pk_corp ,pk_corp
,glorgname
,pkAccsubj
,desdocvalue ,desdocvalue
,factortable1 ,factortable1
,factortable2 ,factortable2
@ -85,6 +98,15 @@
,factorid7 ,factorid7
,factorid8 ,factorid8
,factorid9 ,factorid9
,factorname1
,factorname2
,factorname3
,factorname4
,factorname5
,factorname6
,factorname7
,factorname8
,factorname9
,remark ,remark
,def1 ,def1
,def2 ,def2
@ -357,10 +379,11 @@
useGeneratedKeys="true"> useGeneratedKeys="true">
insert into ae_conf_subject_contrast_b( insert into ae_conf_subject_contrast_b(
<trim suffix="" suffixOverrides=","> <trim suffix="" suffixOverrides=",">
<if test="id != null">id ,</if>
<if test="contrastId != null">contrast_id ,</if> <if test="contrastId != null">contrast_id ,</if>
<if test="pkCorp != null and pkCorp != ''">pk_corp ,</if> <if test="pkCorp != null and pkCorp != ''">pk_corp ,</if>
<if test="glorgname != null and glorgname != ''">glorgname ,</if>
<if test="desdocvalue != null and desdocvalue != ''">desdocvalue ,</if> <if test="desdocvalue != null and desdocvalue != ''">desdocvalue ,</if>
<if test="pkAccsubj != null and pkAccsubj != ''">pkAccsubj ,</if>
<if test="factortable1 != null and factortable1 != ''">factortable1 ,</if> <if test="factortable1 != null and factortable1 != ''">factortable1 ,</if>
<if test="factortable2 != null and factortable2 != ''">factortable2 ,</if> <if test="factortable2 != null and factortable2 != ''">factortable2 ,</if>
<if test="factortable3 != null and factortable3 != ''">factortable3 ,</if> <if test="factortable3 != null and factortable3 != ''">factortable3 ,</if>
@ -388,6 +411,15 @@
<if test="factorid7 != null and factorid7 != ''">factorid7 ,</if> <if test="factorid7 != null and factorid7 != ''">factorid7 ,</if>
<if test="factorid8 != null and factorid8 != ''">factorid8 ,</if> <if test="factorid8 != null and factorid8 != ''">factorid8 ,</if>
<if test="factorid9 != null and factorid9 != ''">factorid9 ,</if> <if test="factorid9 != null and factorid9 != ''">factorid9 ,</if>
<if test="factorname1 != null and factorname1 != ''">factorname1 ,</if>
<if test="factorname2 != null and factorname2 != ''">factorname2 ,</if>
<if test="factorname3 != null and factorname3 != ''">factorname3 ,</if>
<if test="factorname4 != null and factorname4 != ''">factorname4 ,</if>
<if test="factorname5 != null and factorname5 != ''">factorname5 ,</if>
<if test="factorname6 != null and factorname6 != ''">factorname6 ,</if>
<if test="factorname7 != null and factorname7 != ''">factorname7 ,</if>
<if test="factorname8 != null and factorname8 != ''">factorname8 ,</if>
<if test="factorname9 != null and factorname9 != ''">factorname9 ,</if>
<if test="remark != null and remark != ''">remark ,</if> <if test="remark != null and remark != ''">remark ,</if>
<if test="def1 != null and def1 != ''">def1 ,</if> <if test="def1 != null and def1 != ''">def1 ,</if>
<if test="def2 != null and def2 != ''">def2 ,</if> <if test="def2 != null and def2 != ''">def2 ,</if>
@ -410,10 +442,11 @@
</trim> </trim>
)values( )values(
<trim suffix="" suffixOverrides=","> <trim suffix="" suffixOverrides=",">
<if test="id != null">#{id} ,</if>
<if test="contrastId != null">#{contrastId} ,</if> <if test="contrastId != null">#{contrastId} ,</if>
<if test="pkCorp != null and pkCorp != ''">#{pkCorp} ,</if> <if test="pkCorp != null and pkCorp != ''">#{pkCorp} ,</if>
<if test="glorgname != null and glorgname != ''">#{glorgname} ,</if>
<if test="desdocvalue != null and desdocvalue != ''">#{desdocvalue} ,</if> <if test="desdocvalue != null and desdocvalue != ''">#{desdocvalue} ,</if>
<if test="pkAccsubj != null and pkAccsubj != ''">#{pkAccsubj} ,</if>
<if test="factortable1 != null and factortable1 != ''">#{factortable1} ,</if> <if test="factortable1 != null and factortable1 != ''">#{factortable1} ,</if>
<if test="factortable2 != null and factortable2 != ''">#{factortable2} ,</if> <if test="factortable2 != null and factortable2 != ''">#{factortable2} ,</if>
<if test="factortable3 != null and factortable3 != ''">#{factortable3} ,</if> <if test="factortable3 != null and factortable3 != ''">#{factortable3} ,</if>
@ -441,6 +474,15 @@
<if test="factorid7 != null and factorid7 != ''">#{factorid7} ,</if> <if test="factorid7 != null and factorid7 != ''">#{factorid7} ,</if>
<if test="factorid8 != null and factorid8 != ''">#{factorid8} ,</if> <if test="factorid8 != null and factorid8 != ''">#{factorid8} ,</if>
<if test="factorid9 != null and factorid9 != ''">#{factorid9} ,</if> <if test="factorid9 != null and factorid9 != ''">#{factorid9} ,</if>
<if test="factorname1 != null and factorname1 != ''">#{factorname1} ,</if>
<if test="factorname2 != null and factorname2 != ''">#{factorname2} ,</if>
<if test="factorname3 != null and factorname3 != ''">#{factorname3} ,</if>
<if test="factorname4 != null and factorname4 != ''">#{factorname4} ,</if>
<if test="factorname5 != null and factorname5 != ''">#{factorname5} ,</if>
<if test="factorname6 != null and factorname6 != ''">#{factorname6} ,</if>
<if test="factorname7 != null and factorname7 != ''">#{factorname7} ,</if>
<if test="factorname8 != null and factorname8 != ''">#{factorname8} ,</if>
<if test="factorname9 != null and factorname9 != ''">#{factorname9} ,</if>
<if test="remark != null and remark != ''">#{remark} ,</if> <if test="remark != null and remark != ''">#{remark} ,</if>
<if test="def1 != null and def1 != ''">#{def1} ,</if> <if test="def1 != null and def1 != ''">#{def1} ,</if>
<if test="def2 != null and def2 != ''">#{def2} ,</if> <if test="def2 != null and def2 != ''">#{def2} ,</if>
@ -453,10 +495,10 @@
<if test="def9 != null and def9 != ''">#{def9} ,</if> <if test="def9 != null and def9 != ''">#{def9} ,</if>
<if test="def10 != null and def10 != ''">#{def10} ,</if> <if test="def10 != null and def10 != ''">#{def10} ,</if>
<if test="create_time != null">#{create_time} ,</if> <if test="create_time != null">#{create_time} ,</if>
<if test="create_time != null">now() ,</if> <if test="create_time == null">now() ,</if>
<if test="createUser != null and createUser != ''">#{createUser} ,</if> <if test="createUser != null and createUser != ''">#{createUser} ,</if>
<if test="modify_time != null">#{modify_time} ,</if> <if test="modify_time != null">#{modify_time} ,</if>
<if test="modify_time != null">now() ,</if> <if test="modify_time == null">now() ,</if>
<if test="modifyUser != null and modifyUser != ''">#{modifyUser} ,</if> <if test="modifyUser != null and modifyUser != ''">#{modifyUser} ,</if>
<if test="sts != null and sts != ''">#{sts} ,</if> <if test="sts != null and sts != ''">#{sts} ,</if>
<if test="sts == null ">'Y',</if> <if test="sts == null ">'Y',</if>

View File

@ -93,10 +93,10 @@ public class AeConfSubjectContrastEntity extends BaseEntity {
private List<AeConfSubjectContrastBEntity> contrastBEntityList; private List<AeConfSubjectContrastBEntity> contrastBEntityList;
/** */
/** 多选来源档案时接收参数使用,在逐一保存自白哦 */
private List<MappingFileVO> mappingFileVOS; private List<MappingFileVO> mappingFileVOS;
private String aeConfModuleId;
} }

View File

@ -16,6 +16,8 @@
<result property="pkCorp" column="pk_corp" jdbcType="VARCHAR"/> <result property="pkCorp" column="pk_corp" jdbcType="VARCHAR"/>
<result property="corpType" column="corp_type" jdbcType="VARCHAR"/> <result property="corpType" column="corp_type" jdbcType="VARCHAR"/>
<result property="desdocId" column="desdocid" jdbcType="VARCHAR"/> <result property="desdocId" column="desdocid" jdbcType="VARCHAR"/>
<result property="desdocCode" column="desdoccode" jdbcType="VARCHAR"/>
<result property="desdocName" column="desdocname" jdbcType="VARCHAR"/>
<result property="pkSetcorp1" column="pk_setcorp1" jdbcType="VARCHAR"/> <result property="pkSetcorp1" column="pk_setcorp1" jdbcType="VARCHAR"/>
<result property="remark" column="remark" jdbcType="VARCHAR"/> <result property="remark" column="remark" jdbcType="VARCHAR"/>
<result property="def1" column="def1" jdbcType="VARCHAR"/> <result property="def1" column="def1" jdbcType="VARCHAR"/>
@ -50,6 +52,8 @@
,pk_corp ,pk_corp
,corp_type ,corp_type
,desdocid ,desdocid
,desdoccode
,desdocname
,pk_setcorp1 ,pk_setcorp1
,remark ,remark
,def1 ,def1
@ -90,7 +94,7 @@
<if test="sourceNames != null and sourceNames != ''">and sourceNames = #{sourceNames}</if> <if test="sourceNames != null and sourceNames != ''">and sourceNames = #{sourceNames}</if>
<if test="pkCorp != null and pkCorp != ''">and pk_corp = #{pkCorp}</if> <if test="pkCorp != null and pkCorp != ''">and pk_corp = #{pkCorp}</if>
<if test="corpType != null and corpType != ''">and corp_type = #{corpType}</if> <if test="corpType != null and corpType != ''">and corp_type = #{corpType}</if>
<if test="desdocid != null and desdocid != ''">and desdocid = #{desdocid}</if> <if test="desdocId != null and desdocId != ''">and desdocid = #{desdocId}</if>
<if test="pkSetcorp1 != null and pkSetcorp1 != ''">and pk_setcorp1 = #{pkSetcorp1}</if> <if test="pkSetcorp1 != null and pkSetcorp1 != ''">and pk_setcorp1 = #{pkSetcorp1}</if>
<if test="remark != null and remark != ''">and remark = #{remark}</if> <if test="remark != null and remark != ''">and remark = #{remark}</if>
<if test="def1 != null and def1 != ''">and def1 = #{def1}</if> <if test="def1 != null and def1 != ''">and def1 = #{def1}</if>
@ -130,7 +134,7 @@
<if test="sourceNames != null and sourceNames != ''">and sourceNames = #{sourceNames}</if> <if test="sourceNames != null and sourceNames != ''">and sourceNames = #{sourceNames}</if>
<if test="pkCorp != null and pkCorp != ''">and pk_corp = #{pkCorp}</if> <if test="pkCorp != null and pkCorp != ''">and pk_corp = #{pkCorp}</if>
<if test="corpType != null and corpType != ''">and corp_type = #{corpType}</if> <if test="corpType != null and corpType != ''">and corp_type = #{corpType}</if>
<if test="desdocid != null and desdocid != ''">and desdocid = #{desdocid}</if> <if test="desdocId != null and desdocId != ''">and desdocid = #{desdocId}</if>
<if test="pkSetcorp1 != null and pkSetcorp1 != ''">and pk_setcorp1 = #{pkSetcorp1}</if> <if test="pkSetcorp1 != null and pkSetcorp1 != ''">and pk_setcorp1 = #{pkSetcorp1}</if>
<if test="remark != null and remark != ''">and remark = #{remark}</if> <if test="remark != null and remark != ''">and remark = #{remark}</if>
<if test="def1 != null and def1 != ''">and def1 = #{def1}</if> <if test="def1 != null and def1 != ''">and def1 = #{def1}</if>
@ -173,7 +177,7 @@
</if> </if>
<if test="pkCorp != null and pkCorp != ''">and pk_corp like concat('%',#{pkCorp},'%')</if> <if test="pkCorp != null and pkCorp != ''">and pk_corp like concat('%',#{pkCorp},'%')</if>
<if test="corpType != null and corpType != ''">and corp_type like concat('%',#{corpType},'%')</if> <if test="corpType != null and corpType != ''">and corp_type like concat('%',#{corpType},'%')</if>
<if test="desdocid != null and desdocid != ''">and desdocid like concat('%',#{desdocid},'%')</if> <if test="desdocId != null and desdocId != ''">and desdocid like concat('%',#{desdocId},'%')</if>
<if test="pkSetcorp1 != null and pkSetcorp1 != ''">and pk_setcorp1 like concat('%',#{pkSetcorp1},'%')</if> <if test="pkSetcorp1 != null and pkSetcorp1 != ''">and pk_setcorp1 like concat('%',#{pkSetcorp1},'%')</if>
<if test="remark != null and remark != ''">and remark like concat('%',#{remark},'%')</if> <if test="remark != null and remark != ''">and remark like concat('%',#{remark},'%')</if>
<if test="def1 != null and def1 != ''">and def1 like concat('%',#{def1},'%')</if> <if test="def1 != null and def1 != ''">and def1 like concat('%',#{def1},'%')</if>
@ -210,7 +214,7 @@
<if test="accountBookName != null and accountBookName != ''">or account_book_name = #{accountBookName}</if> <if test="accountBookName != null and accountBookName != ''">or account_book_name = #{accountBookName}</if>
<if test="pkCorp != null and pkCorp != ''">or pk_corp = #{pkCorp}</if> <if test="pkCorp != null and pkCorp != ''">or pk_corp = #{pkCorp}</if>
<if test="corpType != null and corpType != ''">or corp_type = #{corpType}</if> <if test="corpType != null and corpType != ''">or corp_type = #{corpType}</if>
<if test="desdocid != null and desdocid != ''">or desdocid = #{desdocid}</if> <if test="desdocId != null and desdocId != ''">or desdocid = #{desdocId}</if>
<if test="pkSetcorp1 != null and pkSetcorp1 != ''">or pk_setcorp1 = #{pkSetcorp1}</if> <if test="pkSetcorp1 != null and pkSetcorp1 != ''">or pk_setcorp1 = #{pkSetcorp1}</if>
<if test="remark != null and remark != ''">or remark = #{remark}</if> <if test="remark != null and remark != ''">or remark = #{remark}</if>
<if test="def1 != null and def1 != ''">or def1 = #{def1}</if> <if test="def1 != null and def1 != ''">or def1 = #{def1}</if>
@ -249,7 +253,9 @@
<if test="sourceNames != null and sourceNames != ''">sourceNames ,</if> <if test="sourceNames != null and sourceNames != ''">sourceNames ,</if>
<if test="pkCorp != null and pkCorp != ''">pk_corp ,</if> <if test="pkCorp != null and pkCorp != ''">pk_corp ,</if>
<if test="corpType != null and corpType != ''">corp_type ,</if> <if test="corpType != null and corpType != ''">corp_type ,</if>
<if test="desdocid != null and desdocid != ''">desdocid ,</if> <if test="desdocId != null and desdocId != ''">desdocid ,</if>
<if test="desdocCode != null and desdocCode != ''">desdoccode ,</if>
<if test="desdocName != null and desdocName != ''">desdocname ,</if>
<if test="pkSetcorp1 != null and pkSetcorp1 != ''">pk_setcorp1 ,</if> <if test="pkSetcorp1 != null and pkSetcorp1 != ''">pk_setcorp1 ,</if>
<if test="remark != null and remark != ''">remark ,</if> <if test="remark != null and remark != ''">remark ,</if>
<if test="def1 != null and def1 != ''">def1 ,</if> <if test="def1 != null and def1 != ''">def1 ,</if>
@ -285,7 +291,9 @@
<if test="sourceNames != null and sourceNames != ''">#{sourceNames} ,</if> <if test="sourceNames != null and sourceNames != ''">#{sourceNames} ,</if>
<if test="pkCorp != null and pkCorp != ''">#{pkCorp} ,</if> <if test="pkCorp != null and pkCorp != ''">#{pkCorp} ,</if>
<if test="corpType != null and corpType != ''">#{corpType} ,</if> <if test="corpType != null and corpType != ''">#{corpType} ,</if>
<if test="desdocid != null and desdocid != ''">#{desdocid} ,</if> <if test="desdocId != null and desdocId != ''">#{desdocId} ,</if>
<if test="desdocCode != null and desdocCode != ''">#{desdocCode} ,</if>
<if test="desdocName != null and desdocName != ''">#{desdocName} ,</if>
<if test="pkSetcorp1 != null and pkSetcorp1 != ''">#{pkSetcorp1} ,</if> <if test="pkSetcorp1 != null and pkSetcorp1 != ''">#{pkSetcorp1} ,</if>
<if test="remark != null and remark != ''">#{remark} ,</if> <if test="remark != null and remark != ''">#{remark} ,</if>
<if test="def1 != null and def1 != ''">#{def1} ,</if> <if test="def1 != null and def1 != ''">#{def1} ,</if>

View File

@ -0,0 +1,24 @@
package com.hzya.frame.voucher.ae.comf.subject.service;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity;
import com.hzya.frame.basedao.service.IBaseService;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastEntity;
import java.util.List;
/**
* 会计事项(accounting_event)-配置-科目分类定义(AeConfSubjectClassification)表服务接口
*
* @author zydd
* @since 2025-06-06 17:00:57
*/
public interface IAeConfSubjectClassificationService extends IBaseService<AeConfSubjectClassificationEntity, String>{
List<AeConfSubjectClassificationEntity> queryAll(AeConfSubjectClassificationEntity entity);
AeConfSubjectClassificationEntity queryById(AeConfSubjectClassificationEntity entity);
AeConfSubjectClassificationEntity saveEntity(AeConfSubjectClassificationEntity entity);
AeConfSubjectClassificationEntity updateEntity(AeConfSubjectClassificationEntity entity);
void deleteEntity(AeConfSubjectClassificationEntity entity);
}

View File

@ -2,6 +2,9 @@ package com.hzya.frame.voucher.ae.comf.subject.service;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastBEntity; import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastBEntity;
import com.hzya.frame.basedao.service.IBaseService; import com.hzya.frame.basedao.service.IBaseService;
import java.util.List;
/** /**
* 会计事项(accounting_event)-配置-科目对照_子表(AeConfSubjectContrastB)表服务接口 * 会计事项(accounting_event)-配置-科目对照_子表(AeConfSubjectContrastB)表服务接口
* *
@ -9,4 +12,11 @@ import com.hzya.frame.basedao.service.IBaseService;
* @since 2025-06-05 15:13:29 * @since 2025-06-05 15:13:29
*/ */
public interface IAeConfSubjectContrastBService extends IBaseService<AeConfSubjectContrastBEntity, String>{ public interface IAeConfSubjectContrastBService extends IBaseService<AeConfSubjectContrastBEntity, String>{
List<AeConfSubjectContrastBEntity> queryAllByContrastId(AeConfSubjectContrastBEntity entity);
List<AeConfSubjectContrastBEntity> saveListEntity(List<AeConfSubjectContrastBEntity> list);
List<AeConfSubjectContrastBEntity> updateList(List<AeConfSubjectContrastBEntity> list);
void deleteList(AeConfSubjectContrastBEntity entity);
} }

View File

@ -16,5 +16,9 @@ public interface IAeConfSubjectContrastService extends IBaseService<AeConfSubjec
AeConfSubjectContrastEntity queryById(AeConfSubjectContrastEntity entity); AeConfSubjectContrastEntity queryById(AeConfSubjectContrastEntity entity);
AeConfSubjectContrastEntity saveEntity(AeConfSubjectContrastEntity entity); AeConfSubjectContrastEntity saveEntity(AeConfSubjectContrastEntity entity) throws NoSuchFieldException, IllegalAccessException;
AeConfSubjectContrastEntity updateEntity(AeConfSubjectContrastEntity entity) throws Exception;
AeConfSubjectContrastEntity deleteEntity(AeConfSubjectContrastEntity entity) throws Exception;
List<AeConfSubjectContrastEntity> queryByInfluenceIds(AeConfSubjectContrastEntity entity);
} }

View File

@ -0,0 +1,121 @@
package com.hzya.frame.voucher.ae.comf.subject.service.impl;
import cn.hutool.core.lang.Assert;
import com.hzya.frame.voucher.ae.comf.subject.dao.IAeConfSubjectContrastBDao;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectClassificationEntity;
import com.hzya.frame.voucher.ae.comf.subject.dao.IAeConfSubjectClassificationDao;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastBEntity;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastEntity;
import com.hzya.frame.voucher.ae.comf.subject.service.IAeConfSubjectClassificationService;
import com.hzya.frame.voucher.ae.comf.subject.service.IAeConfSubjectContrastBService;
import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService;
import java.util.List;
/**
* 会计事项(accounting_event)-配置-科目分类定义(AeConfSubjectClassification)表服务实现类
*
* @author zydd
* @since 2025-06-06 17:00:57
*/
@Service
public class AeConfSubjectClassificationServiceImpl extends BaseService<AeConfSubjectClassificationEntity, String> implements IAeConfSubjectClassificationService {
private IAeConfSubjectClassificationDao aeConfSubjectClassificationDao;
@Autowired
public void setAeConfSubjectClassificationDao(IAeConfSubjectClassificationDao dao) {
this.aeConfSubjectClassificationDao = dao;
this.dao = dao;
}
@Autowired
private IAeConfSubjectContrastBService contrastBService;
@Override
public List<AeConfSubjectClassificationEntity> queryAll(AeConfSubjectClassificationEntity entity) {
Assert.notNull(entity.getPkCorp(), "查询科目分类定义时,公司主键不允许为空。");
Assert.notNull(entity.getPkglorgbook(), "查询科目分类定义时,账簿主键不允许为空。");
Assert.notNull(entity.getAeConfModuleId(), "查询科目分类定义时业务模块id不允许为空。");
List<AeConfSubjectClassificationEntity> query = aeConfSubjectClassificationDao.query(entity);
for (AeConfSubjectClassificationEntity aeConfSubjectClassificationEntity : query) {
//查询科目对照子表
queryaeConfSubjectContrastBList(aeConfSubjectClassificationEntity);
}
return query;
}
@Override
public AeConfSubjectClassificationEntity queryById(AeConfSubjectClassificationEntity entity) {
Assert.notNull(entity.getId(), "查询科目分类定义时id不允许为空。");
Assert.notNull(entity.getPkCorp(), "查询科目分类定义时,公司主键不允许为空。");
Assert.notNull(entity.getPkglorgbook(), "查询科目分类定义时,账簿主键不允许为空。");
Assert.notNull(entity.getAeConfModuleId(), "查询科目分类定义时业务模块id不允许为空。");
List<AeConfSubjectClassificationEntity> query = aeConfSubjectClassificationDao.query(entity);
if (query.size() == 0 || query.size() > 1) {
return null;
}
AeConfSubjectClassificationEntity aeConfSubjectClassificationEntity = query.get(0);
//查询科目对照子表
queryaeConfSubjectContrastBList(aeConfSubjectClassificationEntity);
return aeConfSubjectClassificationEntity;
}
/**
* 科目分类定义
*/
@Override
public AeConfSubjectClassificationEntity saveEntity(AeConfSubjectClassificationEntity entity) {
Assert.notNull(entity.getPkCorp(), "科目分类定义新增时,公司主键不允许为空。");
Assert.notNull(entity.getPkglorgbook(), "科目分类定义新增时核算账簿id不允许为空。");
Assert.notNull(entity.getAeConfModuleId(), "科目分类定义新增时业务模块id不允许为空。");
Assert.notNull(entity.getGlorgbookcode(), "科目分类定义新增时,核算账簿编码不允许为空。");
Assert.notNull(entity.getGlorgbookname(), "科目分类定义新增时,核算账簿名称不允许为空。");
Assert.notNull(entity.getCode(), "科目分类定义新增时,编码不允许为空。");
Assert.notNull(entity.getName(), "科目分类定义新增时,名称不允许为空。");
AeConfSubjectClassificationEntity save = aeConfSubjectClassificationDao.save(entity);
//查询科目对照子表
queryaeConfSubjectContrastBList(save);
return save;
}
@Override
public AeConfSubjectClassificationEntity updateEntity(AeConfSubjectClassificationEntity entity) {
Assert.notNull(entity.getId(), "科目分类定义更新时id不允许为空。");
Assert.notNull(entity.getPkCorp(), "科目分类定义更新时,公司主键不允许为空。");
Assert.notNull(entity.getAeConfModuleId(), "科目分类定义更新时业务模块id不允许为空。");
Assert.notNull(entity.getPkglorgbook(), "科目分类定义更新时核算账簿id不允许为空。");
Assert.notNull(entity.getGlorgbookcode(), "科目分类定义更新时,核算账簿编码不允许为空。");
Assert.notNull(entity.getGlorgbookname(), "科目分类定义更新时,核算账簿名称不允许为空。");
Assert.notNull(entity.getCode(), "科目分类定义更新时,编码不允许为空。");
Assert.notNull(entity.getName(), "科目分类定义更新时,名称不允许为空。");
AeConfSubjectClassificationEntity update = aeConfSubjectClassificationDao.update(entity);
//查询科目对照子表
queryaeConfSubjectContrastBList(update);
return update;
}
@Override
public void deleteEntity(AeConfSubjectClassificationEntity entity) {
Assert.notNull(entity.getId(), "科目分类定义删除时id不允许为空。");
aeConfSubjectClassificationDao.logicRemove(entity);
}
public void queryaeConfSubjectContrastBList(AeConfSubjectClassificationEntity entity) {
if (entity.getContrastId() != null || !"".equals(entity.getContrastId())) {
//查询科目对照子表
AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity = new AeConfSubjectContrastBEntity();
aeConfSubjectContrastBEntity.setContrastId(Long.valueOf(entity.getContrastId()));
List<AeConfSubjectContrastBEntity> bEntities = contrastBService.queryAllByContrastId(aeConfSubjectContrastBEntity);
entity.setContrastBEntityList(bEntities);
}
}
}

View File

@ -1,12 +1,21 @@
package com.hzya.frame.voucher.ae.comf.subject.service.impl; package com.hzya.frame.voucher.ae.comf.subject.service.impl;
import cn.hutool.core.lang.Assert;
import com.hzya.frame.voucher.ae.comf.subject.dao.IAeConfSubjectContrastDao;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastBEntity; import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastBEntity;
import com.hzya.frame.voucher.ae.comf.subject.dao.IAeConfSubjectContrastBDao; import com.hzya.frame.voucher.ae.comf.subject.dao.IAeConfSubjectContrastBDao;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastEntity;
import com.hzya.frame.voucher.ae.comf.subject.service.IAeConfSubjectContrastBService; import com.hzya.frame.voucher.ae.comf.subject.service.IAeConfSubjectContrastBService;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import javax.annotation.Resource; import javax.annotation.Resource;
import com.hzya.frame.basedao.service.impl.BaseService; import com.hzya.frame.basedao.service.impl.BaseService;
import java.util.ArrayList;
import java.util.List;
/** /**
* 会计事项(accounting_event)-配置-科目对照_子表(AeConfSubjectContrastB)表服务实现类 * 会计事项(accounting_event)-配置-科目对照_子表(AeConfSubjectContrastB)表服务实现类
* *
@ -23,4 +32,77 @@ public class AeConfSubjectContrastBServiceImpl extends BaseService<AeConfSubject
this.aeConfSubjectContrastBDao = dao; this.aeConfSubjectContrastBDao = dao;
this.dao = dao; this.dao = dao;
} }
@Autowired
private IAeConfSubjectContrastDao aeConfSubjectContrastDao;
/**
* 根据contrastId查询所有子表
*/
@Override
public List<AeConfSubjectContrastBEntity> queryAllByContrastId(AeConfSubjectContrastBEntity entity) {
Assert.notNull(entity.getContrastId(), "根据科目对照子表查询所属所有子表时contrastId不能为空");
AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity = new AeConfSubjectContrastBEntity();
aeConfSubjectContrastBEntity.setContrastId(entity.getContrastId());
List<AeConfSubjectContrastBEntity> query = aeConfSubjectContrastBDao.query(aeConfSubjectContrastBEntity);
return query;
}
/**
* 依次保存批量新增
*/
@Override
public List<AeConfSubjectContrastBEntity> saveListEntity(List<AeConfSubjectContrastBEntity> list) {
if (list == null || list.size() == 0) {
Assert.state(false, "批量新增科目对照子表时,子表不能为空。");
}
for (AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity : list) {
Assert.notNull(aeConfSubjectContrastBEntity.getContrastId(), "新增科目对照子表时contrastId不能为空");
Assert.notNull(aeConfSubjectContrastBEntity.getPkCorp(), "新增科目对照子表时,公司主键不能为空");
}
//检查主表是否存在
AeConfSubjectContrastEntity aeConfSubjectContrastEntity = new AeConfSubjectContrastEntity();
aeConfSubjectContrastEntity.setId(String.valueOf(list.get(0).getContrastId()));
List<AeConfSubjectContrastEntity> query = aeConfSubjectContrastDao.query(aeConfSubjectContrastEntity);
if (query == null || query.size() == 0) {
Assert.state(false, "新增科目对照子表时,主表不存在。");
}
List<AeConfSubjectContrastBEntity> all = new ArrayList<>();
for (AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity : list) {
AeConfSubjectContrastBEntity save = aeConfSubjectContrastBDao.save(aeConfSubjectContrastBEntity);
all.add(save);
}
return all;
}
@Override
public List<AeConfSubjectContrastBEntity> updateList(List<AeConfSubjectContrastBEntity> list) {
if (list == null || list.size() == 0) {
Assert.state(false, "批量修改科目对照子表时,子表不能为空。");
}
for (AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity : list) {
Assert.notNull(aeConfSubjectContrastBEntity.getId(), "修改科目对照子表时子表id不能为空");
Assert.notNull(aeConfSubjectContrastBEntity.getContrastId(), "修改科目对照子表时,主表不能为空");
Assert.notNull(aeConfSubjectContrastBEntity.getPkCorp(), "修改科目对照子表时,子表公司主键不能为空");
}
//检查主表是否存在
AeConfSubjectContrastEntity aeConfSubjectContrastEntity = new AeConfSubjectContrastEntity();
aeConfSubjectContrastEntity.setId(String.valueOf(list.get(0).getContrastId()));
List<AeConfSubjectContrastEntity> query = aeConfSubjectContrastDao.query(aeConfSubjectContrastEntity);
if (query == null || query.size() == 0) {
Assert.state(false, "修改科目对照子表时,主表不存在。");
}
for (AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity : list) {
aeConfSubjectContrastBDao.update(aeConfSubjectContrastBEntity);
}
return list;
}
@Override
public void deleteList(AeConfSubjectContrastBEntity entity) {
Assert.notNull(entity.getId(), "删除科目对照子表时子表id不能为空");
aeConfSubjectContrastBDao.logicRemove(entity);
}
} }

View File

@ -1,6 +1,8 @@
package com.hzya.frame.voucher.ae.comf.subject.service.impl; package com.hzya.frame.voucher.ae.comf.subject.service.impl;
import cn.hutool.core.lang.Assert; import cn.hutool.core.lang.Assert;
import com.hzya.frame.voucher.ae.comf.factor.entity.AeConfInfluenceFactorEntity;
import com.hzya.frame.voucher.ae.comf.factor.service.IAeConfInfluenceFactorService;
import com.hzya.frame.voucher.ae.comf.subject.dao.IAeConfSubjectContrastBDao; import com.hzya.frame.voucher.ae.comf.subject.dao.IAeConfSubjectContrastBDao;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastBEntity; import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastBEntity;
import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastEntity; import com.hzya.frame.voucher.ae.comf.subject.entity.AeConfSubjectContrastEntity;
@ -11,6 +13,8 @@ import org.springframework.beans.factory.annotation.Autowired;
import com.hzya.frame.basedao.service.impl.BaseService; import com.hzya.frame.basedao.service.impl.BaseService;
import java.lang.reflect.Field;
import java.util.ArrayList;
import java.util.List; import java.util.List;
/** /**
@ -32,6 +36,8 @@ public class AeConfSubjectContrastServiceImpl extends BaseService<AeConfSubjectC
@Autowired @Autowired
private IAeConfSubjectContrastBDao aeConfSubjectContrastBDao; private IAeConfSubjectContrastBDao aeConfSubjectContrastBDao;
@Autowired
private IAeConfInfluenceFactorService iAeConfInfluenceFactorService;
@Override @Override
public List<AeConfSubjectContrastEntity> queryAll(AeConfSubjectContrastEntity entity) { public List<AeConfSubjectContrastEntity> queryAll(AeConfSubjectContrastEntity entity) {
@ -72,7 +78,8 @@ public class AeConfSubjectContrastServiceImpl extends BaseService<AeConfSubjectC
* 新增科目对照表现保存主表再将来源档案分割为子表进行存储 * 新增科目对照表现保存主表再将来源档案分割为子表进行存储
*/ */
@Override @Override
public AeConfSubjectContrastEntity saveEntity(AeConfSubjectContrastEntity entity) { public AeConfSubjectContrastEntity saveEntity(AeConfSubjectContrastEntity entity) throws NoSuchFieldException, IllegalAccessException {
//校验主表
Assert.notNull(entity.getPkCorp(), "科目对照表新增时公司id不能为空"); Assert.notNull(entity.getPkCorp(), "科目对照表新增时公司id不能为空");
Assert.notNull(entity.getCode(), "科目对照表新增时code不能为空"); Assert.notNull(entity.getCode(), "科目对照表新增时code不能为空");
Assert.notNull(entity.getName(), "科目对照表新增时name不能为空"); Assert.notNull(entity.getName(), "科目对照表新增时name不能为空");
@ -84,25 +91,112 @@ public class AeConfSubjectContrastServiceImpl extends BaseService<AeConfSubjectC
List<AeConfSubjectContrastBEntity> contrastBList = entity.getContrastBEntityList(); List<AeConfSubjectContrastBEntity> contrastBList = entity.getContrastBEntityList();
Assert.notNull(contrastBList, "科目对照表新增时,来源档案不能为空!"); // Assert.notNull(contrastBList, "科目对照表新增时,来源档案不能为空!");
if (contrastBList == null || contrastBList.size() == 0) { // if (contrastBList == null || contrastBList.size() == 0) {
Assert.state(false, "科目对照表新增时来源档案VOS不能为空"); // Assert.state(false, "科目对照表新增时来源档案VOS不能为空");
} // }
if (contrastBList.size() > 9) { // if (contrastBList.size() > 9) {
Assert.state(false, "科目对照表新增时来源档案VOS最多为9个"); // Assert.state(false, "科目对照表新增时来源档案VOS最多为9个");
} // }
// //校验子表
// for (int i = 1; i <= split.length; i++) {
// String fieldName = "factortable" + i;
// Field field = AeConfSubjectContrastBEntity.class.getDeclaredField(fieldName);
// field.setAccessible(true);
// String value = (String) field.get(entity);
//
// if (value == null || value.trim().isEmpty()) {
// Assert.state(false, "");
// }
// }
//保存主表 //保存主表
AeConfSubjectContrastEntity saveH = aeConfSubjectContrastDao.save(entity); AeConfSubjectContrastEntity saveH = aeConfSubjectContrastDao.save(entity);
String Hid = saveH.getId(); String Hid = saveH.getId();
String HpkCorp = saveH.getPkCorp(); String HpkCorp = saveH.getPkCorp();
if (contrastBList == null || contrastBList.size() == 0) {
return saveH;
}
//保存子表 //保存子表
for (AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity : contrastBList) { for (AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity : contrastBList) {
aeConfSubjectContrastBEntity.setContrastId(Long.valueOf(Hid)); aeConfSubjectContrastBEntity.setContrastId(Long.valueOf(Hid));
aeConfSubjectContrastBEntity.setPkCorp(HpkCorp); aeConfSubjectContrastBEntity.setPkCorp(HpkCorp);
AeConfSubjectContrastBEntity saveB = aeConfSubjectContrastBDao.save(aeConfSubjectContrastBEntity); aeConfSubjectContrastBDao.save(aeConfSubjectContrastBEntity);
} }
return saveH; return saveH;
} }
/**
* 将原有的主子表全部删除再重新新增
*/
@Override
public AeConfSubjectContrastEntity updateEntity(AeConfSubjectContrastEntity entity) throws Exception {
Assert.notNull(entity.getId(), "科目对照表修改时科目对照表id不能为空");
AeConfSubjectContrastEntity aeConfSubjectContrastEntity = new AeConfSubjectContrastEntity();
aeConfSubjectContrastEntity.setId(entity.getId());
List<AeConfSubjectContrastEntity> query = aeConfSubjectContrastDao.query(aeConfSubjectContrastEntity);
if (query == null || query.size() == 0) {
Assert.state(false, "科目对照表修改时科目对照表id{},未查询到科目对照!", entity.getId());
}
deleteEntity(entity);
saveEntity(entity);
return null;
}
/**
* 将原有的主子表全部删除
*/
@Override
public AeConfSubjectContrastEntity deleteEntity(AeConfSubjectContrastEntity entity) throws Exception {
Assert.notNull(entity.getId(), "科目对照表删除时科目对照表id不能为空");
aeConfSubjectContrastDao.logicRemove(entity);
//查询子表
AeConfSubjectContrastBEntity ContrastBEntity = new AeConfSubjectContrastBEntity();
ContrastBEntity.setContrastId(Long.valueOf(entity.getId()));
List<AeConfSubjectContrastBEntity> query = aeConfSubjectContrastBDao.query(ContrastBEntity);
for (AeConfSubjectContrastBEntity aeConfSubjectContrastBEntity : query) {
aeConfSubjectContrastBDao.logicRemove(aeConfSubjectContrastBEntity);
}
return null;
}
/**
* 1根据入参影响因素ids分别查询影响因素设置的对应基础档案类型
* 2再按顺序拼接写类型的ids再去科目对照表中查询这个ids对应的对照表
* 3返回对照表对象
*/
@Override
public List<AeConfSubjectContrastEntity> queryByInfluenceIds(AeConfSubjectContrastEntity entity) {
Assert.notNull(entity.getSourceIds(), "根据影响因素ids查询时对照表时来源档案ids不能为空");
String sourceIds = entity.getSourceIds();
String moduleId = entity.getAeConfModuleId();
String[] sourceIdSplit = sourceIds.split(",");
List<String> sourceIdList = new ArrayList<>();
for (String sourceId : sourceIdSplit) {
AeConfInfluenceFactorEntity aeConfInfluenceFactorEntity = new AeConfInfluenceFactorEntity();
aeConfInfluenceFactorEntity.setAeConfModuleId(Long.valueOf(moduleId));
aeConfInfluenceFactorEntity.setId(sourceId);
List<AeConfInfluenceFactorEntity> query = iAeConfInfluenceFactorService.query(aeConfInfluenceFactorEntity);
if (query.size() == 0 || query.size() > 1) {
Assert.state(false, "根据模块id{}影响因素id{},未查询到或查到多个影响因素配置,请检查");
}
sourceIdList.add(query.get(0).getMappingFileId());
}
//将sourceIdList,拼接起来
String result = String.join(",", sourceIdList);
System.out.println(result);
AeConfSubjectContrastEntity aeConfSubjectContrastEntity = new AeConfSubjectContrastEntity();
aeConfSubjectContrastEntity.setSourceIds(result);
List<AeConfSubjectContrastEntity> query = aeConfSubjectContrastDao.query(aeConfSubjectContrastEntity);
if (query.size() == 0) {
return null;
}
return query;
}
} }

View File

@ -0,0 +1,10 @@
package com.hzya.frame.voucher.constant;
/**
* Created by zydd on 2025-06-06 09:38
*/
public class ProfilesActiveConstant {
public static final String LETS_PROD_DATE_SOURCE = "lets-prod";
public static final String LETS_PROFILES_ACTIVE = "prod";
}

View File

@ -80,7 +80,7 @@ public class AESUtil {
} }
public static void main(String[] args) { public static void main(String[] args) {
String data = "201103"; String data = "U8C241231";
String encrypt1 = encrypt(data); String encrypt1 = encrypt(data);
System.out.println(encrypt1); System.out.println(encrypt1);
} }