parent
9a3856f748
commit
13bfbbac3c
@ -0,0 +1,128 @@
|
|||||||
|
package org.dromara.oa.erp.controller;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import jakarta.servlet.http.HttpServletResponse;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||||
|
import org.dromara.common.log.annotation.Log;
|
||||||
|
import org.dromara.common.web.core.BaseController;
|
||||||
|
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||||
|
import org.dromara.common.core.domain.R;
|
||||||
|
import org.dromara.common.core.validate.AddGroup;
|
||||||
|
import org.dromara.common.core.validate.EditGroup;
|
||||||
|
import org.dromara.common.log.enums.BusinessType;
|
||||||
|
import org.dromara.common.excel.utils.ExcelUtil;
|
||||||
|
import org.dromara.oa.erp.domain.vo.ErpFinAccountInstallmentDetailVo;
|
||||||
|
import org.dromara.oa.erp.domain.bo.ErpFinAccountInstallmentDetailBo;
|
||||||
|
import org.dromara.oa.erp.service.IErpFinAccountInstallmentDetailService;
|
||||||
|
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分款明细信息
|
||||||
|
* 前端访问路由地址为:/oa/erp/finAccountInstallmentDetail
|
||||||
|
*
|
||||||
|
* @author xins
|
||||||
|
* @date 2026-03-09
|
||||||
|
*/
|
||||||
|
@Validated
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/erp/finAccountInstallmentDetail")
|
||||||
|
public class ErpFinAccountInstallmentDetailController extends BaseController {
|
||||||
|
|
||||||
|
private final IErpFinAccountInstallmentDetailService erpFinAccountInstallmentDetailService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询分款明细信息列表
|
||||||
|
*/
|
||||||
|
@SaCheckPermission("oa/erp:finAccountInstallmentDetail:list")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo<ErpFinAccountInstallmentDetailVo> list(ErpFinAccountInstallmentDetailBo bo, PageQuery pageQuery) {
|
||||||
|
return erpFinAccountInstallmentDetailService.queryPageList(bo, pageQuery);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出分款明细信息列表
|
||||||
|
*/
|
||||||
|
@SaCheckPermission("oa/erp:finAccountInstallmentDetail:export")
|
||||||
|
@Log(title = "分款明细信息", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
public void export(ErpFinAccountInstallmentDetailBo bo, HttpServletResponse response) {
|
||||||
|
List<ErpFinAccountInstallmentDetailVo> list = erpFinAccountInstallmentDetailService.queryList(bo);
|
||||||
|
ExcelUtil.exportExcel(list, "分款明细信息", ErpFinAccountInstallmentDetailVo.class, response);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取分款明细信息详细信息
|
||||||
|
*
|
||||||
|
* @param installmentDetailId 主键
|
||||||
|
*/
|
||||||
|
@SaCheckPermission("oa/erp:finAccountInstallmentDetail:query")
|
||||||
|
@GetMapping("/{installmentDetailId}")
|
||||||
|
public R<ErpFinAccountInstallmentDetailVo> getInfo(@NotNull(message = "主键不能为空")
|
||||||
|
@PathVariable("installmentDetailId") Long installmentDetailId) {
|
||||||
|
return R.ok(erpFinAccountInstallmentDetailService.queryById(installmentDetailId));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增分款明细信息
|
||||||
|
*/
|
||||||
|
@SaCheckPermission("oa/erp:finAccountInstallmentDetail:add")
|
||||||
|
@Log(title = "分款明细信息", businessType = BusinessType.INSERT)
|
||||||
|
@RepeatSubmit()
|
||||||
|
@PostMapping()
|
||||||
|
public R<Void> add(@Validated(AddGroup.class) @RequestBody ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
return toAjax(erpFinAccountInstallmentDetailService.insertByBo(bo));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改分款明细信息
|
||||||
|
*/
|
||||||
|
@SaCheckPermission("oa/erp:finAccountInstallmentDetail:edit")
|
||||||
|
@Log(title = "分款明细信息", businessType = BusinessType.UPDATE)
|
||||||
|
@RepeatSubmit()
|
||||||
|
@PutMapping()
|
||||||
|
public R<Void> edit(@Validated(EditGroup.class) @RequestBody ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
return toAjax(erpFinAccountInstallmentDetailService.updateByBo(bo));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除分款明细信息
|
||||||
|
*
|
||||||
|
* @param installmentDetailIds 主键串
|
||||||
|
*/
|
||||||
|
@SaCheckPermission("oa/erp:finAccountInstallmentDetail:remove")
|
||||||
|
@Log(title = "分款明细信息", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{installmentDetailIds}")
|
||||||
|
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||||
|
@PathVariable("installmentDetailIds") Long[] installmentDetailIds) {
|
||||||
|
return toAjax(erpFinAccountInstallmentDetailService.deleteWithValidByIds(List.of(installmentDetailIds), true));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 下拉框查询分款明细信息列表
|
||||||
|
*/
|
||||||
|
@GetMapping("/getErpFinAccountInstallmentDetailList")
|
||||||
|
public R<List<ErpFinAccountInstallmentDetailVo>> getErpFinAccountInstallmentDetailList(ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
List<ErpFinAccountInstallmentDetailVo> list = erpFinAccountInstallmentDetailService.queryJoinList(bo);
|
||||||
|
return R.ok(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除分款明细信息
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
@SaCheckPermission("oa/erp:finAccountInstallmentDetail:remove")
|
||||||
|
@Log(title = "分款明细信息", businessType = BusinessType.DELETE)
|
||||||
|
@PostMapping("/deleteInstallmentDetailByBo")
|
||||||
|
public R<Void> deleteInstallmentDetailByBo(@RequestBody ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
return toAjax(erpFinAccountInstallmentDetailService.deleteAccountInstallmentDetail(bo));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,84 @@
|
|||||||
|
package org.dromara.oa.erp.service;
|
||||||
|
|
||||||
|
import org.dromara.oa.erp.domain.ErpFinAccountInstallmentDetail;
|
||||||
|
import org.dromara.oa.erp.domain.vo.ErpFinAccountInstallmentDetailVo;
|
||||||
|
import org.dromara.oa.erp.domain.bo.ErpFinAccountInstallmentDetailBo;
|
||||||
|
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||||
|
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||||
|
|
||||||
|
import java.util.Collection;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分款明细信息Service接口
|
||||||
|
*
|
||||||
|
* @author xins
|
||||||
|
* @date 2026-03-09
|
||||||
|
*/
|
||||||
|
public interface IErpFinAccountInstallmentDetailService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询分款明细信息
|
||||||
|
*
|
||||||
|
* @param installmentDetailId 主键
|
||||||
|
* @return 分款明细信息
|
||||||
|
*/
|
||||||
|
ErpFinAccountInstallmentDetailVo queryById(Long installmentDetailId);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询分款明细信息列表
|
||||||
|
*
|
||||||
|
* @param bo 查询条件
|
||||||
|
* @param pageQuery 分页参数
|
||||||
|
* @return 分款明细信息分页列表
|
||||||
|
*/
|
||||||
|
TableDataInfo<ErpFinAccountInstallmentDetailVo> queryPageList(ErpFinAccountInstallmentDetailBo bo, PageQuery pageQuery);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询符合条件的分款明细信息列表
|
||||||
|
*
|
||||||
|
* @param bo 查询条件
|
||||||
|
* @return 分款明细信息列表
|
||||||
|
*/
|
||||||
|
List<ErpFinAccountInstallmentDetailVo> queryList(ErpFinAccountInstallmentDetailBo bo);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询符合条件的分款明细信息列表,Join contract和paymentstage
|
||||||
|
*
|
||||||
|
* @param bo 查询条件
|
||||||
|
* @return 分款明细信息列表
|
||||||
|
*/
|
||||||
|
public List<ErpFinAccountInstallmentDetailVo> queryJoinList(ErpFinAccountInstallmentDetailBo bo);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增分款明细信息
|
||||||
|
*
|
||||||
|
* @param bo 分款明细信息
|
||||||
|
* @return 是否新增成功
|
||||||
|
*/
|
||||||
|
Boolean insertByBo(ErpFinAccountInstallmentDetailBo bo);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改分款明细信息
|
||||||
|
*
|
||||||
|
* @param bo 分款明细信息
|
||||||
|
* @return 是否修改成功
|
||||||
|
*/
|
||||||
|
Boolean updateByBo(ErpFinAccountInstallmentDetailBo bo);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 校验并批量删除分款明细信息信息
|
||||||
|
*
|
||||||
|
* @param ids 待删除的主键集合
|
||||||
|
* @param isValid 是否进行有效性校验
|
||||||
|
* @return 是否删除成功
|
||||||
|
*/
|
||||||
|
Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除分款信息
|
||||||
|
* @param bo
|
||||||
|
* @return 是否删除成功
|
||||||
|
*/
|
||||||
|
public Boolean deleteAccountInstallmentDetail(ErpFinAccountInstallmentDetailBo bo);
|
||||||
|
}
|
||||||
@ -0,0 +1,202 @@
|
|||||||
|
package org.dromara.oa.erp.service.impl;
|
||||||
|
|
||||||
|
import org.dromara.common.core.utils.MapstructUtils;
|
||||||
|
import org.dromara.common.core.utils.StringUtils;
|
||||||
|
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||||
|
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.github.yulichang.toolkit.JoinWrappers;
|
||||||
|
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import org.dromara.oa.base.domain.BasePaymentStage;
|
||||||
|
import org.dromara.oa.erp.domain.ErpContractInfo;
|
||||||
|
import org.dromara.oa.erp.domain.ErpFinAccountInstallment;
|
||||||
|
import org.dromara.oa.erp.mapper.ErpFinAccountInstallmentMapper;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.dromara.oa.erp.domain.bo.ErpFinAccountInstallmentDetailBo;
|
||||||
|
import org.dromara.oa.erp.domain.vo.ErpFinAccountInstallmentDetailVo;
|
||||||
|
import org.dromara.oa.erp.domain.ErpFinAccountInstallmentDetail;
|
||||||
|
import org.dromara.oa.erp.mapper.ErpFinAccountInstallmentDetailMapper;
|
||||||
|
import org.dromara.oa.erp.service.IErpFinAccountInstallmentDetailService;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.Collection;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分款明细信息Service业务层处理
|
||||||
|
*
|
||||||
|
* @author xins
|
||||||
|
* @date 2026-03-09
|
||||||
|
*/
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
@Service
|
||||||
|
public class ErpFinAccountInstallmentDetailServiceImpl implements IErpFinAccountInstallmentDetailService {
|
||||||
|
|
||||||
|
private final ErpFinAccountInstallmentDetailMapper baseMapper;
|
||||||
|
|
||||||
|
private final ErpFinAccountInstallmentMapper finAccountInstallmentMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询分款明细信息
|
||||||
|
*
|
||||||
|
* @param installmentDetailId 主键
|
||||||
|
* @return 分款明细信息
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public ErpFinAccountInstallmentDetailVo queryById(Long installmentDetailId) {
|
||||||
|
return baseMapper.selectVoById(installmentDetailId);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页查询分款明细信息列表
|
||||||
|
*
|
||||||
|
* @param bo 查询条件
|
||||||
|
* @param pageQuery 分页参数
|
||||||
|
* @return 分款明细信息分页列表
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public TableDataInfo<ErpFinAccountInstallmentDetailVo> queryPageList(ErpFinAccountInstallmentDetailBo bo, PageQuery pageQuery) {
|
||||||
|
MPJLambdaWrapper<ErpFinAccountInstallmentDetail> lqw = buildQueryWrapper(bo);
|
||||||
|
Page<ErpFinAccountInstallmentDetailVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
||||||
|
return TableDataInfo.build(result);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询符合条件的分款明细信息列表
|
||||||
|
*
|
||||||
|
* @param bo 查询条件
|
||||||
|
* @return 分款明细信息列表
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<ErpFinAccountInstallmentDetailVo> queryList(ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
MPJLambdaWrapper<ErpFinAccountInstallmentDetail> lqw = buildQueryWrapper(bo);
|
||||||
|
return baseMapper.selectVoList(lqw);
|
||||||
|
}
|
||||||
|
|
||||||
|
private MPJLambdaWrapper<ErpFinAccountInstallmentDetail> buildQueryWrapper(ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
Map<String, Object> params = bo.getParams();
|
||||||
|
MPJLambdaWrapper<ErpFinAccountInstallmentDetail> lqw = JoinWrappers.lambda(ErpFinAccountInstallmentDetail.class)
|
||||||
|
.selectAll(ErpFinAccountInstallmentDetail.class)
|
||||||
|
.eq(bo.getAccountInstallmentId() != null, ErpFinAccountInstallmentDetail::getAccountInstallmentId, bo.getAccountInstallmentId())
|
||||||
|
.eq(bo.getProjectId() != null, ErpFinAccountInstallmentDetail::getProjectId, bo.getProjectId())
|
||||||
|
.eq(StringUtils.isNotBlank(bo.getProjectCode()), ErpFinAccountInstallmentDetail::getProjectCode, bo.getProjectCode())
|
||||||
|
.like(StringUtils.isNotBlank(bo.getProjectName()), ErpFinAccountInstallmentDetail::getProjectName, bo.getProjectName())
|
||||||
|
.eq(bo.getContractId() != null, ErpFinAccountInstallmentDetail::getContractId, bo.getContractId())
|
||||||
|
.eq(bo.getPaymentStageId() != null, ErpFinAccountInstallmentDetail::getPaymentStageId, bo.getPaymentStageId())
|
||||||
|
.eq(bo.getDetailAmount() != null, ErpFinAccountInstallmentDetail::getDetailAmount, bo.getDetailAmount());
|
||||||
|
return lqw;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询符合条件的分款明细信息列表,Join contract和paymentstage
|
||||||
|
*
|
||||||
|
* @param bo 查询条件
|
||||||
|
* @return 分款明细信息列表
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<ErpFinAccountInstallmentDetailVo> queryJoinList(ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
MPJLambdaWrapper<ErpFinAccountInstallmentDetail> lqw = buildJoinQueryWrapper(bo);
|
||||||
|
return baseMapper.selectVoList(lqw);
|
||||||
|
}
|
||||||
|
|
||||||
|
private MPJLambdaWrapper<ErpFinAccountInstallmentDetail> buildJoinQueryWrapper(ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
Map<String, Object> params = bo.getParams();
|
||||||
|
MPJLambdaWrapper<ErpFinAccountInstallmentDetail> lqw = JoinWrappers.lambda(ErpFinAccountInstallmentDetail.class)
|
||||||
|
.selectAll(ErpFinAccountInstallmentDetail.class)
|
||||||
|
.select(ErpContractInfo::getContractCode)
|
||||||
|
.select(ErpContractInfo::getContractName)
|
||||||
|
.select(BasePaymentStage::getStageName)
|
||||||
|
.leftJoin(ErpContractInfo.class, ErpContractInfo::getContractId, ErpFinAccountInstallmentDetail::getContractId)
|
||||||
|
.leftJoin(BasePaymentStage.class, BasePaymentStage::getPaymentStageId, ErpFinAccountInstallmentDetail::getPaymentStageId)
|
||||||
|
.eq(bo.getAccountInstallmentId() != null, ErpFinAccountInstallmentDetail::getAccountInstallmentId, bo.getAccountInstallmentId())
|
||||||
|
.eq(bo.getProjectId() != null, ErpFinAccountInstallmentDetail::getProjectId, bo.getProjectId())
|
||||||
|
.eq(StringUtils.isNotBlank(bo.getProjectCode()), ErpFinAccountInstallmentDetail::getProjectCode, bo.getProjectCode())
|
||||||
|
.like(StringUtils.isNotBlank(bo.getProjectName()), ErpFinAccountInstallmentDetail::getProjectName, bo.getProjectName())
|
||||||
|
.eq(bo.getContractId() != null, ErpFinAccountInstallmentDetail::getContractId, bo.getContractId())
|
||||||
|
.eq(bo.getPaymentStageId() != null, ErpFinAccountInstallmentDetail::getPaymentStageId, bo.getPaymentStageId())
|
||||||
|
.eq(bo.getDetailAmount() != null, ErpFinAccountInstallmentDetail::getDetailAmount, bo.getDetailAmount());
|
||||||
|
return lqw;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增分款明细信息
|
||||||
|
*
|
||||||
|
* @param bo 分款明细信息
|
||||||
|
* @return 是否新增成功
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public Boolean insertByBo(ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
ErpFinAccountInstallmentDetail add = MapstructUtils.convert(bo, ErpFinAccountInstallmentDetail.class);
|
||||||
|
validEntityBeforeSave(add);
|
||||||
|
boolean flag = baseMapper.insert(add) > 0;
|
||||||
|
if (flag) {
|
||||||
|
bo.setInstallmentDetailId(add.getInstallmentDetailId());
|
||||||
|
}
|
||||||
|
ErpFinAccountInstallment erpFinAccountInstallment = finAccountInstallmentMapper.selectById(bo.getAccountInstallmentId());
|
||||||
|
erpFinAccountInstallment.setInstallmentStatus(bo.getInstallmentStatus());
|
||||||
|
finAccountInstallmentMapper.updateById(erpFinAccountInstallment);
|
||||||
|
|
||||||
|
return flag;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改分款明细信息
|
||||||
|
*
|
||||||
|
* @param bo 分款明细信息
|
||||||
|
* @return 是否修改成功
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public Boolean updateByBo(ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
ErpFinAccountInstallmentDetail update = MapstructUtils.convert(bo, ErpFinAccountInstallmentDetail.class);
|
||||||
|
validEntityBeforeSave(update);
|
||||||
|
ErpFinAccountInstallment erpFinAccountInstallment = finAccountInstallmentMapper.selectById(bo.getAccountInstallmentId());
|
||||||
|
erpFinAccountInstallment.setInstallmentStatus(bo.getInstallmentStatus());
|
||||||
|
finAccountInstallmentMapper.updateById(erpFinAccountInstallment);
|
||||||
|
return baseMapper.updateById(update) > 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 保存前的数据校验
|
||||||
|
*/
|
||||||
|
private void validEntityBeforeSave(ErpFinAccountInstallmentDetail entity) {
|
||||||
|
//TODO 做一些数据校验,如唯一约束
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 校验并批量删除分款明细信息信息
|
||||||
|
*
|
||||||
|
* @param ids 待删除的主键集合
|
||||||
|
* @param isValid 是否进行有效性校验
|
||||||
|
* @return 是否删除成功
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) {
|
||||||
|
if (isValid) {
|
||||||
|
//TODO 做一些业务上的校验,判断是否需要校验
|
||||||
|
}
|
||||||
|
return baseMapper.deleteByIds(ids) > 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除分款信息
|
||||||
|
* @param bo
|
||||||
|
* @return 是否删除成功
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public Boolean deleteAccountInstallmentDetail(ErpFinAccountInstallmentDetailBo bo) {
|
||||||
|
|
||||||
|
ErpFinAccountInstallment erpFinAccountInstallment = new ErpFinAccountInstallment();
|
||||||
|
erpFinAccountInstallment.setAccountInstallmentId(bo.getAccountInstallmentId());
|
||||||
|
erpFinAccountInstallment.setInstallmentStatus(bo.getInstallmentStatus());
|
||||||
|
finAccountInstallmentMapper.updateById(erpFinAccountInstallment);
|
||||||
|
|
||||||
|
return baseMapper.deleteById(bo.getInstallmentDetailId()) > 0;
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,14 @@
|
|||||||
|
<?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="org.dromara.oa.erp.mapper.ErpFinAccountInstallmentDetailMapper">
|
||||||
|
<resultMap type="org.dromara.oa.erp.domain.vo.ErpFinAccountInstallmentDetailVo" id="ErpFinAccountInstallmentDetailResult">
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<select id="selectCustomErpFinAccountInstallmentDetailVoList" resultMap="ErpFinAccountInstallmentDetailResult">
|
||||||
|
select installment_detail_id, account_installment_id, project_id, project_code, project_name, contract_id, payment_stage_id, detail_amount, remark, create_dept, create_by, create_time, update_by, update_time from erp_fin_account_installment_detail t
|
||||||
|
${ew.getCustomSqlSegment}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
Loading…
Reference in New Issue