Browse Source

费用详情修改

gao.qiang 3 months ago
parent
commit
40c404b77d

+ 1 - 1
application-webadmin/src/main/java/com/ankaibei/workFlow/webadmin/ankaibei/mapper/CostInfoMapper.java

@@ -52,7 +52,7 @@ public interface CostInfoMapper extends JpaRepository<CostInfoEntity, Integer>,
             "FROM\n" +
             "\tcost_info costinfoen0_\n" +
             "WHERE\n" +
-            "\tcostinfoen0_.cost_id =?1 \n" +
+            "\tcostinfoen0_.apply_cost_id =?1 \n" +
             "\tAND costinfoen0_.cost_type =?2"
             , nativeQuery = true)
     CostInfoEntity findByApplyCostIdAndCostType(Integer costId, String costType);

+ 2 - 1
application-webadmin/src/main/java/com/ankaibei/workFlow/webadmin/ankaibei/service/impl/CostInfoServiceImpl.java

@@ -123,7 +123,8 @@ public class CostInfoServiceImpl implements CostInfoService {
 
     @Override
     public ResMsg findCostInfoDetails(CostInfoEntity costInfoEntity) {
-        CostInfoEntity costInfo = costInfoMapper.findByApplyCostIdAndCostType(costInfoEntity.getCostId(), costInfoEntity.getCostType());
+        CostInfoEntity byId = costInfoMapper.findById(costInfoEntity.getCostId()).orElse(null);
+        CostInfoEntity costInfo = costInfoMapper.findByApplyCostIdAndCostType(byId.getApplyCostId(), costInfoEntity.getCostType());
         if (ObjectUtils.isEmpty(costInfo)) {
             return new ResMsg(CodeEnum.NO_DATA);
         }

+ 2 - 0
application-webadmin/src/main/java/com/ankaibei/workFlow/webadmin/ankaibei/vo/CostInfoVo.java

@@ -62,4 +62,6 @@ public class CostInfoVo extends BaseVo {
      */
     private String processDefinitionId;
 
+    private Integer applyCostId;
+
 }