package cn.iocoder.yudao.module.finance.service.asset;
|
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
import cn.iocoder.yudao.module.finance.controller.admin.asset.vo.FinFixedAssetDepreciateRespVO;
|
import cn.iocoder.yudao.module.finance.controller.admin.asset.vo.FinFixedAssetPageReqVO;
|
import cn.iocoder.yudao.module.finance.controller.admin.asset.vo.FinFixedAssetSaveReqVO;
|
import cn.iocoder.yudao.module.finance.dal.dataobject.asset.FinFixedAssetDO;
|
import jakarta.validation.Valid;
|
|
import java.util.Collection;
|
import java.util.List;
|
|
/**
|
* 固定资产 Service 接口
|
*
|
* @author 超级管理员
|
*/
|
public interface FinFixedAssetService {
|
|
/**
|
* 创建固定资产
|
*
|
* @param createReqVO 创建信息
|
* @return 资产编号
|
*/
|
Long createFixedAsset(@Valid FinFixedAssetSaveReqVO createReqVO);
|
|
/**
|
* 更新固定资产
|
*
|
* 修改原值、使用年限、残值率时会按新参数重算累计折旧与净值
|
*
|
* @param updateReqVO 更新信息
|
*/
|
void updateFixedAsset(@Valid FinFixedAssetSaveReqVO updateReqVO);
|
|
/**
|
* 删除固定资产
|
*
|
* @param id 资产编号
|
*/
|
void deleteFixedAsset(Long id);
|
|
/**
|
* 批量删除固定资产
|
*
|
* @param ids 资产编号数组
|
*/
|
void deleteFixedAssetList(List<Long> ids);
|
|
/**
|
* 计提折旧
|
*
|
* 每个资产计提一个月的折旧:月折旧额 = 原值 × (1 - 残值率 / 100) / (使用年限 × 12)。
|
* 累计折旧以应计提总额封顶,最后一期按剩余可折旧额计提,净值不会被提成负数
|
*
|
* @param ids 资产编号数组;为空时对所有未报废的固定资产计提
|
* @return 计提结果
|
*/
|
FinFixedAssetDepreciateRespVO depreciateFixedAssetList(List<Long> ids);
|
|
/**
|
* 获得固定资产
|
*
|
* @param id 资产编号
|
* @return 固定资产
|
*/
|
FinFixedAssetDO getFixedAsset(Long id);
|
|
/**
|
* 获得固定资产分页
|
*
|
* @param pageReqVO 分页查询
|
* @return 固定资产分页
|
*/
|
PageResult<FinFixedAssetDO> getFixedAssetPage(FinFixedAssetPageReqVO pageReqVO);
|
|
/**
|
* 获得指定编号的固定资产列表
|
*
|
* @param ids 资产编号数组
|
* @return 固定资产列表
|
*/
|
List<FinFixedAssetDO> getFixedAssetList(Collection<Long> ids);
|
|
/**
|
* 获得全部固定资产列表
|
*
|
* @return 固定资产列表
|
*/
|
List<FinFixedAssetDO> getFixedAssetList();
|
|
}
|