Commit a8c72ec3 by huluobin

更新费用类型

parent ade55cbc
...@@ -64,7 +64,7 @@ public class SpecDepartmentCheckConfigController { ...@@ -64,7 +64,7 @@ public class SpecDepartmentCheckConfigController {
} }
@ApiOperation("导出excel") @ApiOperation("导出excel")
@PostMapping("/importExcel") @PostMapping("/exportExcel")
public CostResult<Void> exportExcel(HttpServletResponse response, public CostResult<Void> exportExcel(HttpServletResponse response,
@RequestBody SpecDepartmentCheckExportExcelReq req) throws IOException { @RequestBody SpecDepartmentCheckExportExcelReq req) throws IOException {
specDepartmentCheckConfigService.exportExcel(response, req); specDepartmentCheckConfigService.exportExcel(response, req);
......
package com.blt.other.module.cost.dto.request; package com.blt.other.module.cost.dto.request;
import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.ApiOperation;
import lombok.Data; import lombok.Data;
/** /**
...@@ -14,7 +15,9 @@ import lombok.Data; ...@@ -14,7 +15,9 @@ import lombok.Data;
@Data @Data
public class CheckCostListReq { public class CheckCostListReq {
@ApiModelProperty("oa用户id")
Integer userid; Integer userid;
Integer pageNum; Integer pageNum;
Integer pageSize; Integer pageSize;
@ApiModelProperty("1-财务+最终审核 2-部门审核 3-人事审核") @ApiModelProperty("1-财务+最终审核 2-部门审核 3-人事审核")
......
...@@ -74,12 +74,10 @@ public class CostApiServiceImpl implements CostApiService { ...@@ -74,12 +74,10 @@ public class CostApiServiceImpl implements CostApiService {
costDomain.setCostReason(logisticsCostDto.getCostReason()); costDomain.setCostReason(logisticsCostDto.getCostReason());
costDomain.setTypeNo("CTN1809180519188"); costDomain.setTypeNo("CTN1809180519188");
costDomain.setTypeName("销售费用/物流费"); costDomain.setTypeName("销售费用/物流费");
costDomain.setKindNo("CTK1809181719182"); // costDomain.setKindNo("CTK1809181719182");
costDomain.setKindName("物流费"); // costDomain.setKindName("物流费");
costDomain.setSubjectCode("660104"); // costDomain.setSubjectCode("660104");
costDomain.setCompanyNo("COM1806191800013"); costDomain.setCompanyNo("COM1806191800013");
costDomain.setCompanyValue(2); //dy
costDomain.setCompanyName("香港百伦科技有限公司"); //dy
costDomain.setAmount(logisticsCostDto.getAmount()); costDomain.setAmount(logisticsCostDto.getAmount());
costDomain.setDic(logisticsCostDto.getCurrency()); costDomain.setDic(logisticsCostDto.getCurrency());
costDomain.setSourceFrom(logisticsCostDto.getSourceFrom()); costDomain.setSourceFrom(logisticsCostDto.getSourceFrom());
...@@ -297,7 +295,7 @@ public class CostApiServiceImpl implements CostApiService { ...@@ -297,7 +295,7 @@ public class CostApiServiceImpl implements CostApiService {
costDomain.setTypeNo(costTypeKindDomain.getTypeNo()); costDomain.setTypeNo(costTypeKindDomain.getTypeNo());
costDomain.setTypeName(costTypeKindDomain.getTypeName()); costDomain.setTypeName(costTypeKindDomain.getTypeName());
costDomain.setSubjectCode(costTypeKindDomain.getSubjectCode()); // costDomain.setSubjectCode(costTypeKindDomain.getSubjectCode());
costDomain.setCompanyNo(costTypeKindDomain.getCompanyNo()); costDomain.setCompanyNo(costTypeKindDomain.getCompanyNo());
costDomain.setCompanyName(wageCostDto.getCompanyName()); //dy costDomain.setCompanyName(wageCostDto.getCompanyName()); //dy
costDomain.setCompanyValue(wageCostDto.getCompanyValue()); costDomain.setCompanyValue(wageCostDto.getCompanyValue());
...@@ -308,8 +306,8 @@ public class CostApiServiceImpl implements CostApiService { ...@@ -308,8 +306,8 @@ public class CostApiServiceImpl implements CostApiService {
costDomain.setBankName(wageCostDto.getBankName()); costDomain.setBankName(wageCostDto.getBankName());
costDomain.setKindNo(costTypeKindDomain.getKindNo()); // costDomain.setKindNo(costTypeKindDomain.getKindNo());
costDomain.setKindName(costTypeKindDomain.getKindName()); // costDomain.setKindName(costTypeKindDomain.getKindName());
costDomain.setAmount(wageCostDto.getAmount()); costDomain.setAmount(wageCostDto.getAmount());
costDomain.setDic(wageCostDto.getCurrency()); costDomain.setDic(wageCostDto.getCurrency());
......
...@@ -32,7 +32,10 @@ import com.blt.other.module.cost.vo.ApplyCallbackUrlDataDataVo; ...@@ -32,7 +32,10 @@ import com.blt.other.module.cost.vo.ApplyCallbackUrlDataDataVo;
import com.blt.other.module.cost.vo.ApplyCallbackUrlVo; import com.blt.other.module.cost.vo.ApplyCallbackUrlVo;
import com.blt.other.module.cost.vo.CashierCallbackUrlDataDataVo; import com.blt.other.module.cost.vo.CashierCallbackUrlDataDataVo;
import com.blt.other.module.cost.vo.CashierCallbackUrlVo; import com.blt.other.module.cost.vo.CashierCallbackUrlVo;
import com.blt.other.module.database.model.*; import com.blt.other.module.database.model.CostApplycallbackDomain;
import com.blt.other.module.database.model.CostCashiercallbackDomain;
import com.blt.other.module.database.model.CostCompanyDomain;
import com.blt.other.module.database.model.UserDomain;
import com.github.pagehelper.PageHelper; import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo; import com.github.pagehelper.PageInfo;
import com.google.common.collect.Lists; import com.google.common.collect.Lists;
...@@ -181,14 +184,15 @@ public abstract class AbstractCostService implements CostService { ...@@ -181,14 +184,15 @@ public abstract class AbstractCostService implements CostService {
if (null != costDomain.getCompanyNo()) { if (null != costDomain.getCompanyNo()) {
costDomain.setCompanyName(costCompanyDao.selectByNo(costDomain.getCompanyNo()).getCompanyName()); costDomain.setCompanyName(costCompanyDao.selectByNo(costDomain.getCompanyNo()).getCompanyName());
} }
if (null != costDomain.getKindNo() && !"".equals(costDomain.getKindNo())) { //todo
CostTypeKindDomain costTypeKindDomain = costTypeKindDao.selectByKindNo(costDomain.getKindNo()); // if (null != costDomain.getKindNo() && !"".equals(costDomain.getKindNo())) {
if (null != costTypeKindDomain) { // CostTypeKindDomain costTypeKindDomain = costTypeKindDao.selectByKindNo(costDomain.getKindNo());
costDomain.setKindName(costTypeKindDomain.getKindName()); // if (null != costTypeKindDomain) {
costDomain.setTypeName(costTypeKindDomain.getTypeName()); // costDomain.setKindName(costTypeKindDomain.getKindName());
costDomain.setTypeNo(costTypeKindDomain.getTypeNo()); // costDomain.setTypeName(costTypeKindDomain.getTypeName());
} // costDomain.setTypeNo(costTypeKindDomain.getTypeNo());
} // }
// }
if (ListUtil.isNotEmpty(costDomain.getAttach())) { if (ListUtil.isNotEmpty(costDomain.getAttach())) {
...@@ -219,8 +223,8 @@ public abstract class AbstractCostService implements CostService { ...@@ -219,8 +223,8 @@ public abstract class AbstractCostService implements CostService {
costDomain.setCostNo(costNo); costDomain.setCostNo(costNo);
costDomain.setAmount(amount); costDomain.setAmount(amount);
costDomain.setKindNo(costDetailDomains.get(0).getKindNo()); // costDomain.setKindNo(costDetailDomains.get(0).getKindNo());
costDomain.setKindName(costDetailDomains.get(0).getKindName()); // costDomain.setKindName(costDetailDomains.get(0).getKindName());
costDomain.setLastModifyDate(LocalDateTime.now()); costDomain.setLastModifyDate(LocalDateTime.now());
costDao.update(costDomain, new LambdaQueryWrapper<CostDomain>() costDao.update(costDomain, new LambdaQueryWrapper<CostDomain>()
.eq(CostDomain::getCostNo, costDomain.getCostNo())); .eq(CostDomain::getCostNo, costDomain.getCostNo()));
......
...@@ -9,7 +9,6 @@ import com.blt.other.module.cost.service.CostPlanService; ...@@ -9,7 +9,6 @@ import com.blt.other.module.cost.service.CostPlanService;
import com.blt.other.module.cost.utils.CostUtils; import com.blt.other.module.cost.utils.CostUtils;
import com.blt.other.module.database.model.CostPlanDomain; import com.blt.other.module.database.model.CostPlanDomain;
import com.blt.other.module.database.model.CostPlanTempDomain; import com.blt.other.module.database.model.CostPlanTempDomain;
import com.blt.other.module.database.model.CostTypeDomain;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
...@@ -110,8 +109,8 @@ public class CostPlanNewPayServiceImpl extends AbstractCostPlanService implement ...@@ -110,8 +109,8 @@ public class CostPlanNewPayServiceImpl extends AbstractCostPlanService implement
// CostTypeDomain costTypeDomain = costTypeDao.selectByTypeNo(typeNo); // CostTypeDomain costTypeDomain = costTypeDao.selectByTypeNo(typeNo);
// costDomain.setSubjectCode(costTypeDomain.getSubjectCode()); // costDomain.setSubjectCode(costTypeDomain.getSubjectCode());
costDomain.setKindNo(costDetailDomains.get(0).getKindNo()); // costDomain.setKindNo(costDetailDomains.get(0).getKindNo());
costDomain.setKindName(costDetailDomains.get(0).getKindName()); // costDomain.setKindName(costDetailDomains.get(0).getKindName());
if (null == costDomain.getAmount()) { if (null == costDomain.getAmount()) {
costDomain.setAmount(new BigDecimal(0)); costDomain.setAmount(new BigDecimal(0));
} }
......
...@@ -54,6 +54,7 @@ public class CostPlanDomain implements Serializable { ...@@ -54,6 +54,7 @@ public class CostPlanDomain implements Serializable {
private Integer createUserid; private Integer createUserid;
@ApiModelProperty("创建人编号") @ApiModelProperty("创建人编号")
private String createUsercode; private String createUsercode;
@ApiModelProperty("创建人名称") @ApiModelProperty("创建人名称")
private String createUsername; private String createUsername;
......
...@@ -464,7 +464,7 @@ ...@@ -464,7 +464,7 @@
<select id="departmentCheckCostList" resultType="com.blt.other.module.cost.model.CostDomain"> <select id="departmentCheckCostList" resultType="com.blt.other.module.cost.model.CostDomain">
select t1.* select t1.*
from cost t1 from cost t1
left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.oaUserId} left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.userid}
where t1.cost_status = 6 where t1.cost_status = 6
and t3.id is not null and t3.id is not null
</select> </select>
...@@ -473,13 +473,13 @@ ...@@ -473,13 +473,13 @@
<select id="departmentCheckAllCostList" resultType="com.blt.other.module.cost.model.CostDomain"> <select id="departmentCheckAllCostList" resultType="com.blt.other.module.cost.model.CostDomain">
select t1.* select t1.*
from cost t1 from cost t1
left join cost_log t2 on t1.cost_no = t2.cost_no and t2.type in (2, 3) and t2.update_userid = #{req.oaUserId} left join cost_log t2 on t1.cost_no = t2.cost_no and t2.type in (2, 3) and t2.update_userid = #{req.userid}
where t1.cost_status not in (0, 3, 5) where t1.cost_status not in (0, 3, 5)
and t2.id is not null and t2.id is not null
union union
select t1.* select t1.*
from cost t1 from cost t1
left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.oaUserId} left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.userid}
where t1.cost_status = 6 where t1.cost_status = 6
and t3.id is not null and t3.id is not null
</select> </select>
...@@ -488,8 +488,8 @@ ...@@ -488,8 +488,8 @@
<select id="departmentManualCheckLllCostList" resultType="com.blt.other.module.cost.model.CostDomain"> <select id="departmentManualCheckLllCostList" resultType="com.blt.other.module.cost.model.CostDomain">
select t1.* select t1.*
from cost t1 from cost t1
left join cost_log t2 on t1.cost_no = t2.cost_no and t2.type = 3 and t2.update_userid = #{req.oaUserId} left join cost_log t2 on t1.cost_no = t2.cost_no and t2.type = 3 and t2.update_userid = #{req.userid}
left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.oaUserId} left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.userid}
where t1.cost_status not in (0, 3, 5) where t1.cost_status not in (0, 3, 5)
and t2.id is not null and t2.id is not null
</select> </select>
...@@ -498,8 +498,8 @@ ...@@ -498,8 +498,8 @@
<select id="departmentAutoCheckLllCostList" resultType="com.blt.other.module.cost.model.CostDomain"> <select id="departmentAutoCheckLllCostList" resultType="com.blt.other.module.cost.model.CostDomain">
select t1.* select t1.*
from cost t1 from cost t1
left join cost_log t2 on t1.cost_no = t2.cost_no and t2.type = 2 and t2.update_userid = #{req.oaUserId} left join cost_log t2 on t1.cost_no = t2.cost_no and t2.type = 2 and t2.update_userid = #{userid.oaUserId}
left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.oaUserId} left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.userid}
where t1.cost_status not in (0, 3, 5) where t1.cost_status not in (0, 3, 5)
and t2.id is not null and t2.id is not null
</select> </select>
...@@ -508,7 +508,7 @@ ...@@ -508,7 +508,7 @@
<select id="financialOrFinalCheckCostList" resultType="com.blt.other.module.cost.model.CostDomain"> <select id="financialOrFinalCheckCostList" resultType="com.blt.other.module.cost.model.CostDomain">
select t1.* select t1.*
from cost t1 from cost t1
left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.oaUserId} left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.userid}
where t1.cost_status = 6 where t1.cost_status = 6
and t3.id is not null and t3.id is not null
</select> </select>
...@@ -517,7 +517,7 @@ ...@@ -517,7 +517,7 @@
<select id="hrCheckCostList" resultType="com.blt.other.module.cost.model.CostDomain"> <select id="hrCheckCostList" resultType="com.blt.other.module.cost.model.CostDomain">
select t1.* select t1.*
from cost t1 from cost t1
left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.oaUserId} left join cost_current_reviewer t3 on t1.cost_no = t3.cost_no and t3.oa_user_id = #{req.userid}
where t1.cost_status = 9 where t1.cost_status = 9
and t3.id is not null and t3.id is not null
</select> </select>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment