纪新园 3 месяцев назад
Родитель
Сommit
14495d8cc5

+ 6 - 0
blade-service-api/blade-user-api/src/main/java/org/springblade/system/user/feign/IUserClient.java

@@ -79,6 +79,8 @@ public interface IUserClient {
 
 	String GET_USER_LIST_BY_ROLE = API_PREFIX + "/getUserListByRole";
 
+	String GET_USER_BY_DEPT =  "/getUserByDept";
+
 	@GetMapping(LIST_USER_BY_ROLE_ID)
 	R<List<User>> listUserByRoleId(@RequestParam("roleId") String roleId, @RequestParam(value = "tenantId", required = false) String tenantId, @RequestParam(value = "salesCompanyId", required = false) String salesCompanyId);
 
@@ -314,4 +316,8 @@ public interface IUserClient {
 
 	@GetMapping(GET_USER_LIST_BY_ROLE)
 	List<User> selectListByRole(@RequestParam(value = "tenantId", required = false) String tenantId);
+
+	@GetMapping(GET_USER_BY_DEPT)
+    List<User> getUserByDept(@RequestParam(value = "deptPid", required = false)Long deptPid,
+							 @RequestParam(value = "tenantId", required = false) String tenantId);
 }

+ 7 - 2
blade-service/blade-los/src/main/java/org/springblade/los/business/aea/service/impl/AeaBillsServiceImpl.java

@@ -23,8 +23,6 @@ import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
 import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import lombok.AllArgsConstructor;
-import org.springblade.core.mp.support.Condition;
-import org.springblade.core.mp.support.Query;
 import org.springblade.core.secure.utils.AuthUtil;
 import org.springblade.core.tool.api.R;
 import org.springblade.core.tool.utils.BeanUtil;
@@ -47,6 +45,7 @@ import org.springblade.los.business.amends.entity.Amends;
 import org.springblade.los.business.amends.mapper.AmendsMapper;
 import org.springblade.los.business.files.entity.FilesCenter;
 import org.springblade.los.business.files.service.IFilesCenterService;
+import org.springblade.los.business.sea.service.IDataProcessingService;
 import org.springblade.los.check.dto.LosAuditProecessDTO;
 import org.springblade.los.check.entity.LosAuditPathsActs;
 import org.springblade.los.check.entity.LosAuditPathsLevels;
@@ -117,6 +116,8 @@ public class AeaBillsServiceImpl extends ServiceImpl<AeaBillsMapper, AeaBills> i
 
 	private final AmendsMapper amendsMapper;
 
+	private final IDataProcessingService dataProcessingUtil;
+
 	@Override
 	public IPage<AeaBillsVO> selectAeaBillsPage(IPage<AeaBillsVO> page, AeaBillsVO aeaBills) {
 		return page.setRecords(baseMapper.selectAeaBillsPage(page, aeaBills));
@@ -821,6 +822,10 @@ public class AeaBillsServiceImpl extends ServiceImpl<AeaBillsMapper, AeaBills> i
 		Long pathId = losAuditPathsActs.getPathId();
 		auditPathsLevels = auditPathsLevelsService.list(new LambdaQueryWrapper<LosAuditPathsLevels>()
 			.eq(LosAuditPathsLevels::getTenantId, AuthUtil.getTenantId()).eq(LosAuditPathsLevels::getPathId, pathId));
+		String business = sysClient.getParamServiceNew("business");
+		if ("1".equals(business) && !auditPathsLevels.isEmpty()) {
+			auditPathsLevels = dataProcessingUtil.toExamine(auditPathsLevels, declare.getAccDept());
+		}
 		auditProecessDTO.setTimes(1);
 		auditProecessDTO.setProcessType(processType);
 		List<FeeCenter> feeCenterList = feeCenterService.list(new LambdaQueryWrapper<FeeCenter>()

+ 20 - 27
blade-service/blade-los/src/main/java/org/springblade/los/business/amends/service/impl/AmendsServiceImpl.java

@@ -40,6 +40,7 @@ import org.springblade.los.business.amends.service.IAmendsService;
 import org.springblade.los.business.amends.vo.AmendsVO;
 import org.springblade.los.business.sea.entity.Bills;
 import org.springblade.los.business.sea.mapper.BillsMapper;
+import org.springblade.los.business.sea.service.IDataProcessingService;
 import org.springblade.los.check.dto.LosAuditProecessDTO;
 import org.springblade.los.check.entity.LosAuditPathsActs;
 import org.springblade.los.check.entity.LosAuditPathsLevels;
@@ -106,6 +107,8 @@ public class AmendsServiceImpl extends ServiceImpl<AmendsMapper, Amends> impleme
 
 	private final FinPeriodMapper finPeriodMapper;
 
+	private final IDataProcessingService dataProcessingUtil;
+
 	@Override
 	public IPage<AmendsVO> selectAmendsPage(IPage<AmendsVO> page, AmendsVO amends) {
 		return page.setRecords(baseMapper.selectAmendsPage(page, amends));
@@ -114,17 +117,7 @@ public class AmendsServiceImpl extends ServiceImpl<AmendsMapper, Amends> impleme
 	@Override
 	@Transactional(rollbackFor = Exception.class)
 	public R submit(Amends amends) {
-		String deptId = "";
-		String deptName = "";
 		String branchId = deptUtils.getDeptPid() + "";
-		//获取部门ids对应中文名
-		if (ObjectUtils.isNotNull(deptUtils.getDeptPid()+"")) {
-			deptId = deptUtils.getDeptPid()+"";
-			R<List<String>> res = sysClient.getDeptNames(deptUtils.getDeptPid()+"");
-			if (res.isSuccess() && ObjectUtils.isNotNull(res.getData())) {
-				deptName = String.join(",", res.getData());
-			}
-		}
 		amends.setBillDate(new Date());
 		if (ObjectUtils.isNotNull(amends.getBillDate())) {
 			LocalDate date = amends.getBillDate().toInstant().atZone(ZoneId.systemDefault()).toLocalDate();
@@ -165,11 +158,7 @@ public class AmendsServiceImpl extends ServiceImpl<AmendsMapper, Amends> impleme
 			//amends.setCreateTime(new Date());
 			amends.setCreateUser(AuthUtil.getUserId());
 			amends.setCreateUserName(AuthUtil.getUserName());
-			if (ObjectUtils.isNotNull(deptUtils.getDeptPid()+"")) {
-				amends.setBranchId(branchId);
-				amends.setCreateDept(deptId);
-				amends.setCreateDeptName(deptName);
-			}
+			amends.setBranchId(branchId);
 		} else {
 			amends.setUpdateUser(AuthUtil.getUserId());
 			amends.setUpdateTime(new Date());
@@ -179,7 +168,7 @@ public class AmendsServiceImpl extends ServiceImpl<AmendsMapper, Amends> impleme
 		if (ObjectUtils.isNotNull(amends.getFeeCenterList())) {
 			for (FeeCenter item : amends.getFeeCenterList()) {
 				item.setBillNo(amends.getBillNo());
-				if ("SEA".equals(amends.getBusinessType())){
+				if ("SEA".equals(amends.getBusinessType())) {
 					item.setBillDate(amends.getEtd());
 				} else if ("SIA".equals(amends.getBusinessType())) {
 					item.setBillDate(amends.getEta());
@@ -250,35 +239,35 @@ public class AmendsServiceImpl extends ServiceImpl<AmendsMapper, Amends> impleme
 			actId = 1112;
 			processType = "空运进口AMEND";
 			checkType = "aia-approve";
-		}else if ("EXPA".equals(declare.getBusinessType())) {
+		} else if ("EXPA".equals(declare.getBusinessType())) {
 			actId = 1129;
 			processType = "快递业务amend审核";
 			checkType = "EXPA";
-		}else if ("TRUCKA".equals(declare.getBusinessType())) {
+		} else if ("TRUCKA".equals(declare.getBusinessType())) {
 			actId = 1135;
 			processType = "海运派车amend审核";
 			checkType = "TRUCKA";
-		}else if ("MFAA".equals(declare.getBusinessType())) {
+		} else if ("MFAA".equals(declare.getBusinessType())) {
 			actId = 1133;
 			processType = "空运舱单amend审核";
 			checkType = "MFAA";
-		}else if ("MFSA".equals(declare.getBusinessType())) {
+		} else if ("MFSA".equals(declare.getBusinessType())) {
 			actId = 1131;
 			processType = "海运舱单amend审核";
 			checkType = "MFSA";
-		}else if ("BGSEA".equals(declare.getBusinessType())) {
+		} else if ("BGSEA".equals(declare.getBusinessType())) {
 			actId = 1136;
 			processType = "海运出口报关amend审核";
 			checkType = "BGSEA";
-		}else if ("BGSIA".equals(declare.getBusinessType())) {
+		} else if ("BGSIA".equals(declare.getBusinessType())) {
 			actId = 1137;
 			processType = "海运进口报关amend审核";
 			checkType = "BGSIA";
-		}else if ("BGAEA".equals(declare.getBusinessType())) {
+		} else if ("BGAEA".equals(declare.getBusinessType())) {
 			actId = 1138;
 			processType = "空运出口报关amend审核";
 			checkType = "BGAEA";
-		}else if ("BGAIA".equals(declare.getBusinessType())) {
+		} else if ("BGAIA".equals(declare.getBusinessType())) {
 			actId = 1139;
 			processType = "空运进口报关amend审核";
 			checkType = "BGAIA";
@@ -295,18 +284,22 @@ public class AmendsServiceImpl extends ServiceImpl<AmendsMapper, Amends> impleme
 			.eq(LosAuditPathsActs::getIsEnable, 1)
 			.eq(LosAuditPathsActs::getFidStatus, "status")
 			.eq(LosAuditPathsActs::getTenantId, AuthUtil.getTenantId())
-			.eq(LosAuditPathsActs::getSalesCompanyId, deptUtils.getDeptPid()+"")
+			.eq(LosAuditPathsActs::getSalesCompanyId, deptUtils.getDeptPid() + "")
 			.eq(LosAuditPathsActs::getActId, actId);
 		pathsActs = auditPathsActsService.getOne(auditPathsActsLambdaQueryWrapper);
 		//获取审批信息
 		LosAuditPathsActs losAuditPathsActs = auditPathsActsService.getOne(new LambdaQueryWrapper<LosAuditPathsActs>()
 			.eq(LosAuditPathsActs::getActId, actId)
 			.eq(LosAuditPathsActs::getFidStatus, "status")
-			.eq(LosAuditPathsActs::getSalesCompanyId, deptUtils.getDeptPid()+"")
+			.eq(LosAuditPathsActs::getSalesCompanyId, deptUtils.getDeptPid() + "")
 			.eq(LosAuditPathsActs::getTenantId, AuthUtil.getTenantId()));
 		Long pathId = losAuditPathsActs.getPathId();
 		auditPathsLevels = auditPathsLevelsService.list(new LambdaQueryWrapper<LosAuditPathsLevels>()
 			.eq(LosAuditPathsLevels::getTenantId, AuthUtil.getTenantId()).eq(LosAuditPathsLevels::getPathId, pathId));
+		String business = sysClient.getParamServiceNew("business");
+		if ("1".equals(business) && !auditPathsLevels.isEmpty()) {
+			auditPathsLevels = dataProcessingUtil.toExamine(auditPathsLevels, declare.getCreateDept());
+		}
 		auditProecessDTO.setTimes(1);
 		auditProecessDTO.setProcessType(processType);
 		// 没开启审批流直接走 通过流程
@@ -384,7 +377,7 @@ public class AmendsServiceImpl extends ServiceImpl<AmendsMapper, Amends> impleme
 
 			auditProecessDTO.setGrossProfit(amountCnyD.subtract(amountCnyC));
 			auditProecessDTO.setGrossProfitUsd(amountUsdD.subtract(amountUsdC));
-			auditProecessDTO.setGrossProfitLoc(auditProecessDTO.getGrossProfit().add(bCurrencyService.converterCny("USD", auditProecessDTO.getGrossProfitUsd(), "","1")));
+			auditProecessDTO.setGrossProfitLoc(auditProecessDTO.getGrossProfit().add(bCurrencyService.converterCny("USD", auditProecessDTO.getGrossProfitUsd(), "", "1")));
 			auditProecessDTO.setSalesCompanyName(declare.getCreateDeptName());
 			auditProecessDTO.setSrcId(declare.getSrcId());
 			auditProecessDTO.setSrcCnName(declare.getSrcCnName());

+ 12 - 21
blade-service/blade-los/src/main/java/org/springblade/los/business/customsDeclaration/service/impl/CustomsDeclarationServiceImpl.java

@@ -22,7 +22,6 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.core.toolkit.CollectionUtils;
 import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import io.seata.spring.annotation.GlobalTransactional;
 import lombok.AllArgsConstructor;
 import org.springblade.core.secure.utils.AuthUtil;
 import org.springblade.core.tool.api.R;
@@ -34,7 +33,6 @@ import org.springblade.los.basic.business.service.IBusinessTypeService;
 import org.springblade.los.basic.cur.service.IBCurrencyService;
 import org.springblade.los.billno.entity.BusinessBillNo;
 import org.springblade.los.billno.service.IBusinessBillNoService;
-import org.springblade.los.business.aea.entity.AeaBills;
 import org.springblade.los.business.customsDeclaration.entity.CustomsDeclaration;
 import org.springblade.los.business.customsDeclaration.entity.CustomsDeclarationGoods;
 import org.springblade.los.business.customsDeclaration.mapper.CustomsDeclarationMapper;
@@ -43,6 +41,7 @@ import org.springblade.los.business.customsDeclaration.service.ICustomsDeclarati
 import org.springblade.los.business.customsDeclaration.vo.CustomsDeclarationVO;
 import org.springblade.los.business.files.entity.FilesCenter;
 import org.springblade.los.business.files.service.IFilesCenterService;
+import org.springblade.los.business.sea.service.IDataProcessingService;
 import org.springblade.los.check.dto.LosAuditProecessDTO;
 import org.springblade.los.check.entity.LosAuditPathsActs;
 import org.springblade.los.check.entity.LosAuditPathsLevels;
@@ -104,6 +103,8 @@ public class CustomsDeclarationServiceImpl extends ServiceImpl<CustomsDeclaratio
 
 	private final FinPeriodMapper finPeriodMapper;
 
+	private final IDataProcessingService dataProcessingUtil;
+
 	@Override
 	public IPage<CustomsDeclarationVO> selectCustomsDeclarationPage(IPage<CustomsDeclarationVO> page, CustomsDeclarationVO customsDeclaration) {
 		return page.setRecords(baseMapper.selectCustomsDeclarationPage(page, customsDeclaration));
@@ -141,20 +142,10 @@ public class CustomsDeclarationServiceImpl extends ServiceImpl<CustomsDeclaratio
 
 	@Override
 	@Transactional(rollbackFor = Exception.class)
-	public R submit(CustomsDeclaration customsDeclarations) throws Exception{
-		Object object = StringTools.handle(customsDeclarations,"CustomsDeclaration");
+	public R submit(CustomsDeclaration customsDeclarations) throws Exception {
+		Object object = StringTools.handle(customsDeclarations, "CustomsDeclaration");
 		CustomsDeclaration customsDeclaration = JSONObject.parseObject(JSONObject.toJSONString(object), CustomsDeclaration.class);
-		String deptId = "";
-		String deptName = "";
 		String branchId = deptUtils.getDeptPid() + "";
-		//获取部门ids对应中文名
-		if (ObjectUtils.isNotNull(AuthUtil.getDeptId())) {
-			deptId = AuthUtil.getDeptId();
-			R<List<String>> res = sysClient.getDeptNames(AuthUtil.getDeptId());
-			if (res.isSuccess() && ObjectUtils.isNotNull(res.getData())) {
-				deptName = String.join(",", res.getData());
-			}
-		}
 		if (ObjectUtils.isNotNull(customsDeclaration.getMblno())) {
 			customsDeclaration.setMblno(customsDeclaration.getMblno().replaceAll(" ", ""));
 		}
@@ -212,11 +203,7 @@ public class CustomsDeclarationServiceImpl extends ServiceImpl<CustomsDeclaratio
 			customsDeclaration.setCreateTime(new Date());
 			customsDeclaration.setCreateUser(AuthUtil.getUserId());
 			customsDeclaration.setCreateUserName(AuthUtil.getUserName());
-			if (ObjectUtils.isNotNull(AuthUtil.getDeptId())) {
-				customsDeclaration.setBranchId(branchId);
-				customsDeclaration.setCreateDept(deptId);
-				customsDeclaration.setCreateDeptName(deptName);
-			}
+			customsDeclaration.setBranchId(branchId);
 		} else {
 			List<Long> ids = count.stream().map(CustomsDeclaration::getId).distinct().collect(Collectors.toList());
 			if (ObjectUtils.isNotNull(customsDeclaration.getMblno())) {
@@ -314,7 +301,7 @@ public class CustomsDeclarationServiceImpl extends ServiceImpl<CustomsDeclaratio
 			customsDeclaration.setAccountStatus(1);
 		} else if (0 == statusD && 1 == statusC) {
 			customsDeclaration.setAccountStatus(2);
-		}else if (1 == statusD && 1 == statusC) {
+		} else if (1 == statusD && 1 == statusC) {
 			customsDeclaration.setAccountStatus(3);
 		}
 		//利润 = 收 - 付
@@ -387,6 +374,10 @@ public class CustomsDeclarationServiceImpl extends ServiceImpl<CustomsDeclaratio
 		Long pathId = losAuditPathsActs.getPathId();
 		auditPathsLevels = auditPathsLevelsService.list(new LambdaQueryWrapper<LosAuditPathsLevels>()
 			.eq(LosAuditPathsLevels::getTenantId, AuthUtil.getTenantId()).eq(LosAuditPathsLevels::getPathId, pathId));
+		String business = sysClient.getParamServiceNew("business");
+		if ("1".equals(business) && !auditPathsLevels.isEmpty()) {
+			auditPathsLevels = dataProcessingUtil.toExamine(auditPathsLevels, declare.getAccDept());
+		}
 		auditProecessDTO.setTimes(1);
 		auditProecessDTO.setProcessType(processType);
 		List<FeeCenter> feeCenterList = feeCenterService.list(new LambdaQueryWrapper<FeeCenter>()
@@ -461,7 +452,7 @@ public class CustomsDeclarationServiceImpl extends ServiceImpl<CustomsDeclaratio
 
 			auditProecessDTO.setGrossProfit(amountCnyD.subtract(amountCnyC));
 			auditProecessDTO.setGrossProfitUsd(amountUsdD.subtract(amountUsdC));
-			auditProecessDTO.setGrossProfitLoc(auditProecessDTO.getGrossProfit().add(bCurrencyService.converterCny("USD", auditProecessDTO.getGrossProfitUsd(), "","1")));
+			auditProecessDTO.setGrossProfitLoc(auditProecessDTO.getGrossProfit().add(bCurrencyService.converterCny("USD", auditProecessDTO.getGrossProfitUsd(), "", "1")));
 
 			auditProecessDTO.setSalesCompanyName(declare.getCreateDeptName());
 			R financeProcess = auditProecessService.createFinanceProcess(auditProecessDTO);

+ 14 - 0
blade-service/blade-los/src/main/java/org/springblade/los/business/sea/service/IDataProcessingService.java

@@ -0,0 +1,14 @@
+package org.springblade.los.business.sea.service;
+
+import org.springblade.los.check.entity.LosAuditPathsLevels;
+
+import java.util.List;
+
+/**
+ * @author :jixinyuan
+ * @date : 2025/8/4
+ */
+public interface IDataProcessingService {
+
+	 List<LosAuditPathsLevels> toExamine(List<LosAuditPathsLevels> auditPathsLevels, String deptId);
+}

+ 24 - 33
blade-service/blade-los/src/main/java/org/springblade/los/business/sea/service/impl/BillsServiceImpl.java

@@ -76,6 +76,7 @@ import org.springblade.los.trade.mapper.DispatchVehiclesMapper;
 import org.springblade.los.trade.mapper.InOutStorageMapper;
 import org.springblade.system.entity.Dept;
 import org.springblade.system.feign.ISysClient;
+import org.springblade.system.user.feign.IUserClient;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 import org.springframework.transaction.interceptor.TransactionAspectSupport;
@@ -158,6 +159,8 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 
 	private final ZrUtil zrUtil;
 
+	private final IDataProcessingService dataProcessingUtil;
+
 
 	@Override
 	public IPage<BillsVO> selectBillsPage(IPage<BillsVO> page, BillsVO bills) {
@@ -193,28 +196,28 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 
 		List<Bills> count = null;
 		// 只判断海运出口
-		if("SE".equals(bills.getBusinessType()) && ObjectUtils.isNotNull(bills.getMblno())){
+		if ("SE".equals(bills.getBusinessType()) && ObjectUtils.isNotNull(bills.getMblno())) {
 			// 改为同一团队内,Booking+MblNo 不重复
 			LambdaQueryWrapper<Bills> lambdaQueryWrapper = new LambdaQueryWrapper<>();
 			lambdaQueryWrapper.select(Bills::getId);
 			// CreateDept 是一级部门,总公司,分公司等
 			lambdaQueryWrapper.eq(Bills::getCreateDept, branchId)
-				 .eq(Bills::getTenantId, AuthUtil.getTenantId())
-				 .eq(Bills::getIsDeleted, 0)
-				 .eq(Bills::getTeamId, bills.getTeamId())
-				 .eq(Bills::getMblno, bills.getMblno());
-			if(ObjectUtils.isNotNull(bills.getBookingNo())) {
+				.eq(Bills::getTenantId, AuthUtil.getTenantId())
+				.eq(Bills::getIsDeleted, 0)
+				.eq(Bills::getTeamId, bills.getTeamId())
+				.eq(Bills::getMblno, bills.getMblno());
+			if (ObjectUtils.isNotNull(bills.getBookingNo())) {
 				lambdaQueryWrapper.eq(Bills::getBookingNo, bills.getBookingNo());
 			}
-			if(ObjectUtils.isNotNull(bills.getId())) {
+			if (ObjectUtils.isNotNull(bills.getId())) {
 				lambdaQueryWrapper.ne(Bills::getId, bills.getId());
 			}
 
 			List<String> billTypes = new ArrayList<>();
-			if("DDMM".contains(bills.getBillType())){
+			if ("DDMM".contains(bills.getBillType())) {
 				billTypes.add("DD");
 				billTypes.add("MM");
-			}else{
+			} else {
 				billTypes.add("MH");
 				billTypes.add("HH");
 			}
@@ -223,7 +226,7 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 			count = baseMapper.selectList(lambdaQueryWrapper);
 		}
 
-		if(ObjectUtils.isNotNull(count) && count.size()>0){
+		if (ObjectUtils.isNotNull(count) && count.size() > 0) {
 			throw new RuntimeException("提单号不允许重复输入:" + bills.getMblno());
 		}
 
@@ -1440,6 +1443,10 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 		Long pathId = losAuditPathsActs.getPathId();
 		auditPathsLevels = auditPathsLevelsService.list(new LambdaQueryWrapper<LosAuditPathsLevels>()
 			.eq(LosAuditPathsLevels::getTenantId, AuthUtil.getTenantId()).eq(LosAuditPathsLevels::getPathId, pathId));
+		String business = sysClient.getParamServiceNew("business");
+		if ("1".equals(business) && !auditPathsLevels.isEmpty()) {
+			auditPathsLevels = dataProcessingUtil.toExamine(auditPathsLevels, declare.getAccDept());
+		}
 		auditProecessDTO.setTimes(1);
 		auditProecessDTO.setProcessType(processType);
 		List<FeeCenter> feeCenterList = feeCenterService.list(new LambdaQueryWrapper<FeeCenter>()
@@ -1532,23 +1539,7 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 			auditProecessDTO.setPageStatus(bills.getPageStatus());
 			auditProecessDTO.setPageLabel(bills.getPageLabel());
 			auditProecessDTO.setOrderRemark(declare.getRemarks());
-			List<LosAuditPathsLevels> pathsLevelsList = bills.getAuditPathsLevels();
-			if (ObjectUtils.isNotNull(pathsLevelsList) && !pathsLevelsList.isEmpty()) {
-				List<Long> idList = pathsLevelsList.stream().map(LosAuditPathsLevels::getId).collect(Collectors.toList());
-				List<LosAuditPathsLevels> levelsList = new ArrayList<>();
-				for (LosAuditPathsLevels item : auditPathsLevels) {
-					if (2 == item.getUserMold()) {
-						if (idList.contains(item.getId())) {
-							levelsList.add(item);
-						}
-					} else {
-						levelsList.add(item);
-					}
-				}
-				auditProecessDTO.setPathsLevelsList(levelsList);
-			} else {
-				auditProecessDTO.setPathsLevelsList(auditPathsLevels);
-			}
+			auditProecessDTO.setPathsLevelsList(auditPathsLevels);
 			auditProecessDTO.setActId(1);
 			auditProecessDTO.setSrcBillId(declare.getId());
 			auditProecessDTO.setBillId(declare.getId());
@@ -3593,7 +3584,7 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 
 		List<Bills> count = null;
 		// 只判断海运出口
-		if("SE".equals(bills.getBusinessType()) && ObjectUtils.isNotNull(bills.getMblno())){
+		if ("SE".equals(bills.getBusinessType()) && ObjectUtils.isNotNull(bills.getMblno())) {
 			// 改为同一团队内,Booking+MblNo 不重复
 			LambdaQueryWrapper<Bills> lambdaQueryWrapper = new LambdaQueryWrapper<>();
 			lambdaQueryWrapper.select(Bills::getId);
@@ -3603,18 +3594,18 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 				.eq(Bills::getIsDeleted, 0)
 				.eq(Bills::getTeamId, bills.getTeamId())
 				.eq(Bills::getMblno, bills.getMblno());
-			if(ObjectUtils.isNotNull(bills.getBookingNo())) {
+			if (ObjectUtils.isNotNull(bills.getBookingNo())) {
 				lambdaQueryWrapper.eq(Bills::getBookingNo, bills.getBookingNo());
 			}
-			if(ObjectUtils.isNotNull(bills.getId())) {
+			if (ObjectUtils.isNotNull(bills.getId())) {
 				lambdaQueryWrapper.ne(Bills::getId, bills.getId());
 			}
 
 			List<String> billTypes = new ArrayList<>();
-			if("DDMM".contains(bills.getBillType())){
+			if ("DDMM".contains(bills.getBillType())) {
 				billTypes.add("DD");
 				billTypes.add("MM");
-			}else{
+			} else {
 				billTypes.add("MH");
 				billTypes.add("HH");
 			}
@@ -3623,7 +3614,7 @@ public class BillsServiceImpl extends ServiceImpl<BillsMapper, Bills> implements
 			count = baseMapper.selectList(lambdaQueryWrapper);
 		}
 
-		if(ObjectUtils.isNotNull(count) && count.size()>0){
+		if (ObjectUtils.isNotNull(count) && count.size() > 0) {
 			throw new RuntimeException("提单号不允许重复输入:" + bills.getMblno());
 		}
 

+ 78 - 0
blade-service/blade-los/src/main/java/org/springblade/los/business/sea/service/impl/DataProcessingImplService.java

@@ -0,0 +1,78 @@
+package org.springblade.los.business.sea.service.impl;
+
+import com.baomidou.mybatisplus.core.toolkit.ObjectUtils;
+import lombok.AllArgsConstructor;
+import org.springblade.core.secure.utils.AuthUtil;
+import org.springblade.core.tool.utils.Func;
+import org.springblade.los.Util.IDeptUtils;
+import org.springblade.los.business.sea.service.IDataProcessingService;
+import org.springblade.los.check.entity.LosAuditPathsLevels;
+import org.springblade.system.user.entity.User;
+import org.springblade.system.user.feign.IUserClient;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+import java.util.stream.Collectors;
+
+/**
+ * @author :jixinyuan
+ * @date : 2025/8/4
+ */
+@Service
+@AllArgsConstructor
+public class DataProcessingImplService implements IDataProcessingService {
+
+
+	private final IUserClient userClient;
+
+	private final IDeptUtils deptUtils;
+
+
+	@Override
+	public List<LosAuditPathsLevels> toExamine(List<LosAuditPathsLevels> auditPathsLevels, String deptId) {
+		List<User> userList = userClient.getUserByDept(deptUtils.getDeptPid(), AuthUtil.getTenantId());
+		for (LosAuditPathsLevels item : auditPathsLevels) {
+			StringBuilder userIds = new StringBuilder();
+			//角色
+			if (1 == item.getUserMold()) {
+				List<Long> moldList = Func.toLongList(item.getAuditMoldId());
+				if (!userList.isEmpty() && !moldList.isEmpty()) {
+					for (Long mold : moldList) {
+						List<Long> userIdList = userList.stream().filter(e -> e.getRoleId().contains(mold + "")
+								&& e.getDeptId().equals(deptId) )
+							.map(User::getId).collect(Collectors.toList());
+						for (Long userId : userIdList) {
+							userIds.append(userId).append(",");
+						}
+					}
+				}
+				if (ObjectUtils.isNotNull(userIds.toString()) && ",".equals(userIds.substring(userIds.length() - 1))) {
+					item.setAuditUserId(userIds.substring(0, userIds.length() - 1));
+				} else {
+					throw new RuntimeException("未查到对应审核人");
+				}
+			} else if (2 == item.getUserMold()) {
+				//部门
+				List<Long> deptList = Func.toLongList(item.getAuditMoldId());
+				if (!userList.isEmpty() && !deptList.isEmpty()) {
+					for (Long dept : deptList) {
+						List<Long> deptIdList = userList.stream().filter(e -> e.getDeptId().equals(dept + ""))
+							.map(User::getId).collect(Collectors.toList());
+						for (Long userId : deptIdList) {
+							userIds.append(userId).append(",");
+						}
+					}
+				}
+				if (ObjectUtils.isNotNull(userIds.toString()) && ",".equals(userIds.substring(userIds.length() - 1))) {
+					item.setAuditUserId(userIds.substring(0, userIds.length() - 1));
+				} else {
+					throw new RuntimeException("未查到对应审核人");
+				}
+			} else if (3 == item.getUserMold()) {
+				item.setAuditUserId(item.getAuditUserId());
+			}
+
+		}
+		return auditPathsLevels;
+	}
+}

+ 12 - 28
blade-service/blade-los/src/main/java/org/springblade/los/finance/stl/service/impl/FinStlBillsServiceImpl.java

@@ -43,6 +43,7 @@ import org.springblade.los.business.customsDeclaration.entity.CustomsDeclaration
 import org.springblade.los.business.customsDeclaration.mapper.CustomsDeclarationMapper;
 import org.springblade.los.business.sea.entity.Bills;
 import org.springblade.los.business.sea.mapper.BillsMapper;
+import org.springblade.los.business.sea.service.IDataProcessingService;
 import org.springblade.los.check.dto.LosAuditProecessDTO;
 import org.springblade.los.check.entity.LosAuditPathsActs;
 import org.springblade.los.check.entity.LosAuditPathsLevels;
@@ -73,7 +74,6 @@ import org.springblade.los.finance.vouchers.entity.FinVouchers;
 import org.springblade.los.finance.vouchers.entity.FinVouchersItems;
 import org.springblade.los.finance.vouchers.mapper.FinVouchersMapper;
 import org.springblade.los.finance.vouchers.service.IFinVouchersItemsService;
-import org.springblade.los.trade.mapper.AgentMapper;
 import org.springblade.system.entity.Dept;
 import org.springblade.system.feign.ISysClient;
 import org.springblade.system.user.entity.User;
@@ -150,7 +150,7 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 
 	private final CustomsDeclarationMapper customsDeclarationMapper;
 
-	private final AgentMapper agentMapper;
+	private final IDataProcessingService dataProcessingUtil;
 
 	@Override
 	public IPage<FinStlBillsVO> selectFinStlBillsPage(IPage<FinStlBillsVO> page, FinStlBillsVO finStlBills) {
@@ -179,17 +179,7 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 	@Override
 	@Transactional(rollbackFor = Exception.class)
 	public R submit(FinStlBills finStlBills) {
-		String deptId = "";
-		String deptName = "";
 		String branchId = deptUtils.getDeptPid() + "";
-		//获取部门ids对应中文名
-		if (ObjectUtils.isNotNull(AuthUtil.getDeptId())) {
-			deptId = AuthUtil.getDeptId();
-			R<List<String>> res = sysClient.getDeptNames(AuthUtil.getDeptId());
-			if (res.isSuccess() && ObjectUtils.isNotNull(res.getData())) {
-				deptName = String.join(",", res.getData());
-			}
-		}
 		if (ObjectUtils.isNotNull(finStlBills.getBillDate()) && "STL".equals(finStlBills.getBusinessType())) {
 			LocalDate date = finStlBills.getBillDate().toInstant().atZone(ZoneId.systemDefault()).toLocalDate();
 			int year = date.getYear();
@@ -231,11 +221,7 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 			finStlBills.setCreateTime(new Date());
 			finStlBills.setCreateUser(AuthUtil.getUserId());
 			finStlBills.setCreateUserName(AuthUtil.getUserName());
-			if (ObjectUtils.isNotNull(AuthUtil.getDeptId())) {
-				finStlBills.setCreateDept(deptId);
-				finStlBills.setBranchId(branchId);
-				finStlBills.setCreateDeptName(deptName);
-			}
+			finStlBills.setBranchId(branchId);
 		} else {
 			finStlBills.setUpdateUser(AuthUtil.getUserId());
 			finStlBills.setUpdateTime(new Date());
@@ -273,11 +259,7 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 					item.setCreateTime(new Date());
 					item.setCreateUser(AuthUtil.getUserId());
 					item.setCreateUserName(AuthUtil.getUserName());
-					if (ObjectUtils.isNotNull(AuthUtil.getDeptId())) {
-						item.setCreateDept(deptId);
-						item.setBranchId(branchId);
-						item.setCreateDeptName(deptName);
-					}
+					item.setBranchId(branchId);
 				} else {
 					item.setUpdateUser(AuthUtil.getUserId());
 					item.setUpdateTime(new Date());
@@ -439,9 +421,9 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 								feeCenter.setReconciliationAmount(feeCenter.getReconciliationAmount().add(currentStlAmount));
 								currentStlAmount = new BigDecimal("0.00");
 							} else {
-								if (new BigDecimal("0.00").compareTo(currentStlAmount) > 0){
+								if (new BigDecimal("0.00").compareTo(currentStlAmount) > 0) {
 									currentStlAmount = currentStlAmount.add((feeCenter.getAmount().abs().subtract(feeCenter.getReconciliationAmount().abs())).abs());
-								}else{
+								} else {
 									currentStlAmount = currentStlAmount.subtract((feeCenter.getAmount().subtract(feeCenter.getReconciliationAmount())));
 								}
 								feeCenter.setReconciliationAmount(feeCenter.getAmount());
@@ -1096,8 +1078,7 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 						finAccBills.getAmountDrUsd().abs().compareTo(finAccBills.getStlAmountDrUsd().abs()) == 0) {
 						status = true;
 					}
-				}
-				else if ("C".equals(item.getDc())) {
+				} else if ("C".equals(item.getDc())) {
 					if (finAccBills.getStlAmountCr().abs().compareTo(finAccBills.getAmountCr().abs()) > 0 ||
 						finAccBills.getStlAmountCrUsd().abs().compareTo(finAccBills.getAmountCrUsd().abs()) > 0
 					) {
@@ -1413,8 +1394,7 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 						}
 					}
 
-				}
-				else if ("C".equals(item.getDc())) {
+				} else if ("C".equals(item.getDc())) {
 					if ("CNY".equals(item.getCurCode())) {
 						finAccBills.setStlAmountCr(finAccBills.getStlAmountCr().subtract(item.getCurrentStlAmount().subtract(item.getCurrentStlDiscount())));
 						finAccBills.setStlAmountCrLoc(finAccBills.getStlAmountCrLoc().subtract(item.getCurrentStlAmount().subtract(item.getCurrentStlDiscount())));
@@ -1790,6 +1770,10 @@ public class FinStlBillsServiceImpl extends ServiceImpl<FinStlBillsMapper, FinSt
 		Long pathId = losAuditPathsActs.getPathId();
 		auditPathsLevels = auditPathsLevelsService.list(new LambdaQueryWrapper<LosAuditPathsLevels>()
 			.eq(LosAuditPathsLevels::getTenantId, AuthUtil.getTenantId()).eq(LosAuditPathsLevels::getPathId, pathId));
+		String business = sysClient.getParamServiceNew("business");
+		if ("1".equals(business) && !auditPathsLevels.isEmpty()) {
+			auditPathsLevels = dataProcessingUtil.toExamine(auditPathsLevels, AuthUtil.getDeptId());
+		}
 		auditProecessDTO.setTimes(1);
 		auditProecessDTO.setProcessType("付费申请");
 

+ 8 - 0
blade-service/blade-user/src/main/java/org/springblade/system/user/feign/UserClient.java

@@ -327,6 +327,14 @@ public class UserClient implements IUserClient {
 		}
 	}
 
+	@Override
+	public List<User> getUserByDept(Long deptPid, String tenantId) {
+        return service.list(new LambdaQueryWrapper<User>()
+			.eq(User::getTenantId, tenantId)
+			.eq(User::getDeptPid, deptPid)
+			.eq(User::getIsDeleted, 0));
+	}
+
 	/**
 	 * 获取用户
 	 * @param user