ljlong_2630
12 months ago
8 changed files with 193 additions and 109 deletions
@ -0,0 +1,100 @@ |
|||
package com.lzbi.asset.service; |
|||
|
|||
import com.baomidou.mybatisplus.extension.service.IService; |
|||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|||
import com.lzbi.asset.domain.DcBaseAssetInfo; |
|||
import com.lzbi.asset.mapper.DcBaseAssetInfoMapper; |
|||
import com.lzbi.common.utils.DateUtils; |
|||
import org.springframework.stereotype.Service; |
|||
|
|||
import java.util.List; |
|||
|
|||
/** |
|||
* 资产信息Service业务层处理 |
|||
* |
|||
* @author Lu.JL |
|||
* @date 2023-12-10 |
|||
*/ |
|||
@Service |
|||
public class DcBaseAssetInfoService extends ServiceImpl<DcBaseAssetInfoMapper, DcBaseAssetInfo> implements IService<DcBaseAssetInfo> |
|||
{ |
|||
|
|||
/** |
|||
* 查询资产信息 |
|||
* |
|||
* @param id 资产信息主键 |
|||
* @return 资产信息 |
|||
*/ |
|||
public DcBaseAssetInfo selectDcBaseAssetInfoById(Long id) |
|||
{ |
|||
return baseMapper.selectDcBaseAssetInfoById(id); |
|||
} |
|||
|
|||
/** |
|||
* 查询资产信息列表 |
|||
* |
|||
* @param dcBaseAssetInfo 资产信息 |
|||
* @return 资产信息 |
|||
*/ |
|||
public List<DcBaseAssetInfo> selectDcBaseAssetInfoList(DcBaseAssetInfo dcBaseAssetInfo) |
|||
{ |
|||
return baseMapper.selectDcBaseAssetInfoList(dcBaseAssetInfo); |
|||
} |
|||
|
|||
/** |
|||
* 新增资产信息 |
|||
* |
|||
* @param dcBaseAssetInfo 资产信息 |
|||
* @return 结果 |
|||
*/ |
|||
|
|||
public int insertDcBaseAssetInfo(DcBaseAssetInfo dcBaseAssetInfo) |
|||
{ |
|||
dcBaseAssetInfo.setCreatedTime(DateUtils.getNowDate()); |
|||
return baseMapper.insertDcBaseAssetInfo(dcBaseAssetInfo); |
|||
} |
|||
|
|||
/** |
|||
* 修改资产信息 |
|||
* |
|||
* @param dcBaseAssetInfo 资产信息 |
|||
* @return 结果 |
|||
*/ |
|||
|
|||
public int updateDcBaseAssetInfo(DcBaseAssetInfo dcBaseAssetInfo) |
|||
{ |
|||
dcBaseAssetInfo.setUpdatedTime(DateUtils.getNowDate()); |
|||
return baseMapper.updateDcBaseAssetInfo(dcBaseAssetInfo); |
|||
} |
|||
|
|||
/** |
|||
* 批量删除资产信息 |
|||
* |
|||
* @param ids 需要删除的资产信息主键 |
|||
* @return 结果 |
|||
*/ |
|||
|
|||
public int deleteDcBaseAssetInfoByIds(Long[] ids) |
|||
{ |
|||
return baseMapper.deleteDcBaseAssetInfoByIds(ids); |
|||
} |
|||
|
|||
/** |
|||
* 删除资产信息信息 |
|||
* |
|||
* @param id 资产信息主键 |
|||
* @return 结果 |
|||
*/ |
|||
|
|||
public int deleteDcBaseAssetInfoById(Long id) |
|||
{ |
|||
return baseMapper.deleteDcBaseAssetInfoById(id); |
|||
} |
|||
|
|||
|
|||
public DcBaseAssetInfo selectDcBaseAssetInfoByCode(String assetCode) { |
|||
return baseMapper.selectDcBaseAssetInfoByCode(assetCode); |
|||
} |
|||
|
|||
|
|||
} |
Loading…
Reference in new issue