ariesy 修改冲突bean

release
yefei 2 years ago
parent ddc74d3f52
commit 9a2aa362e2
  1. 2
      dxhy-base/src/main/java/com/dxhy/base/dao/SysDeptAuthDao.java
  2. 12
      dxhy-base/src/main/java/com/dxhy/base/service/invoicecheck/BaseInvoiceManualCheckServiceImpl.java
  3. 2
      dxhy-base/src/main/resources/mapper/SysDeptAuthDao.xml

@ -13,7 +13,7 @@ import java.util.List;
* @author jiaohongyang * @author jiaohongyang
*/ */
@Mapper @Mapper
public interface SysDeptDao extends BaseMapper<SysDeptEntity> { public interface SysDeptAuthDao extends BaseMapper<SysDeptEntity> {
/** /**
* 根据集团编码查询税号 * 根据集团编码查询税号
* *

@ -9,7 +9,7 @@ import java.util.stream.Collectors;
import javax.annotation.Resource; import javax.annotation.Resource;
import com.dxhy.base.dao.SysDeptDao; import com.dxhy.base.dao.SysDeptAuthDao;
import com.dxhy.base.entity.SysDeptEntity; import com.dxhy.base.entity.SysDeptEntity;
import com.dxhy.common.constant.DictConstant; import com.dxhy.common.constant.DictConstant;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
@ -56,7 +56,7 @@ public class BaseInvoiceManualCheckServiceImpl extends MpBaseServiceImpl<BaseTDx
@Resource @Resource
private BaseTDxRecordInvoiceDao baseTDxRecordInvoiceDao; private BaseTDxRecordInvoiceDao baseTDxRecordInvoiceDao;
@Resource @Resource
private SysDeptDao sysDeptDao; private SysDeptAuthDao sysDeptAuthDao;
@Resource @Resource
private DictdetaServcice dictdetaServcice; private DictdetaServcice dictdetaServcice;
@Resource @Resource
@ -579,17 +579,19 @@ public class BaseInvoiceManualCheckServiceImpl extends MpBaseServiceImpl<BaseTDx
@Override @Override
public List<String> getGfshList(List<String> gfshList, List<String> companyCodes) { public List<String> getGfshList(List<String> gfshList, List<String> companyCodes) {
DynamicContextHolder.push(DbConstant.BASICS_READ); DynamicContextHolder.push(DbConstant.BASICS_READ);
List<SysDeptEntity> taxnoList = sysDeptDao.queryTaxnoList(); List<SysDeptEntity> taxnoList = sysDeptAuthDao.queryTaxnoList();
List<SysDeptEntity> parentIdList = sysDeptDao.queryParentIdList(); List<SysDeptEntity> parentIdList = sysDeptAuthDao.queryParentIdList();
Map<String, String> taxnoMap = taxnoList.stream().collect(Collectors.toMap(SysDeptEntity::getDeptId, SysDeptEntity::getTaxno)); Map<String, String> taxnoMap = taxnoList.stream().collect(Collectors.toMap(SysDeptEntity::getDeptId, SysDeptEntity::getTaxno));
Map<String, String> parentIdMap = parentIdList.stream().collect(Collectors.toMap(SysDeptEntity::getDeptId, SysDeptEntity::getParentId)); Map<String, String> parentIdMap = parentIdList.stream().collect(Collectors.toMap(SysDeptEntity::getDeptId, SysDeptEntity::getParentId));
log.info("taxnoMap={},parentIdMap={}",taxnoMap,parentIdMap);
String gfsh = ""; String gfsh = "";
for(String companyCode : companyCodes){ for(String companyCode : companyCodes){
QueryWrapper<SysDeptEntity> wrapper = new QueryWrapper<>(); QueryWrapper<SysDeptEntity> wrapper = new QueryWrapper<>();
wrapper.eq("org_code",companyCode); wrapper.eq("org_code",companyCode);
SysDeptEntity sysDeptEntity = sysDeptDao.selectOne(wrapper); SysDeptEntity sysDeptEntity = sysDeptAuthDao.selectOne(wrapper);
String dId = sysDeptEntity.getDeptId(); String dId = sysDeptEntity.getDeptId();
gfsh = getGfsh(dId,taxnoMap,parentIdMap); gfsh = getGfsh(dId,taxnoMap,parentIdMap);

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?> <?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"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.dxhy.base.dao.SysDeptDao"> <mapper namespace="com.dxhy.base.dao.SysDeptAuthDao">
<select id="queryList" resultType="com.dxhy.base.entity.SysDeptEntity"> <select id="queryList" resultType="com.dxhy.base.entity.SysDeptEntity">
select t1.*,(select t2.name from sys_dept t2 where t2.dept_id=t1.parent_id)parentName from sys_dept t1 select t1.*,(select t2.name from sys_dept t2 where t2.dept_id=t1.parent_id)parentName from sys_dept t1
Loading…
Cancel
Save