|
@ -4,11 +4,16 @@ import java.util.List; |
|
|
import com.lzbi.common.utils.DateUtils; |
|
|
import com.lzbi.common.utils.DateUtils; |
|
|
import com.lzbi.draft.domain.DcBusiTargetAdjustDaySubDao; |
|
|
import com.lzbi.draft.domain.DcBusiTargetAdjustDaySubDao; |
|
|
import com.lzbi.draft.mapper.DcBusiTargetAdjustDaySubMapper; |
|
|
import com.lzbi.draft.mapper.DcBusiTargetAdjustDaySubMapper; |
|
|
|
|
|
import com.lzbi.targetFolder.domain.DcBaseAssetTargetDao; |
|
|
|
|
|
import com.lzbi.targetFolder.mapper.DcBaseAssetTargetMapper; |
|
|
|
|
|
import org.apache.commons.lang3.ObjectUtils; |
|
|
import org.springframework.stereotype.Service; |
|
|
import org.springframework.stereotype.Service; |
|
|
import com.baomidou.mybatisplus.extension.service.IService; |
|
|
import com.baomidou.mybatisplus.extension.service.IService; |
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; |
|
|
import org.springframework.transaction.annotation.Transactional; |
|
|
import org.springframework.transaction.annotation.Transactional; |
|
|
|
|
|
|
|
|
|
|
|
import javax.annotation.Resource; |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 统计单元指标调整单子(日)Service业务层处理 |
|
|
* 统计单元指标调整单子(日)Service业务层处理 |
|
|
* |
|
|
* |
|
@ -19,6 +24,9 @@ import org.springframework.transaction.annotation.Transactional; |
|
|
public class DcBusiTargetAdjustDaySubService extends ServiceImpl<DcBusiTargetAdjustDaySubMapper, DcBusiTargetAdjustDaySubDao> implements IService<DcBusiTargetAdjustDaySubDao> |
|
|
public class DcBusiTargetAdjustDaySubService extends ServiceImpl<DcBusiTargetAdjustDaySubMapper, DcBusiTargetAdjustDaySubDao> implements IService<DcBusiTargetAdjustDaySubDao> |
|
|
{ |
|
|
{ |
|
|
|
|
|
|
|
|
|
|
|
@Resource |
|
|
|
|
|
private DcBaseAssetTargetMapper dcBaseAssetTargetMapper; |
|
|
|
|
|
|
|
|
/** |
|
|
/** |
|
|
* 查询统计单元指标调整单子(日) |
|
|
* 查询统计单元指标调整单子(日) |
|
|
* |
|
|
* |
|
@ -51,8 +59,10 @@ public class DcBusiTargetAdjustDaySubService extends ServiceImpl<DcBusiTargetAdj |
|
|
@Transactional(rollbackFor = Exception.class) |
|
|
@Transactional(rollbackFor = Exception.class) |
|
|
public int insertDcBusiTargetAdjustDaySubDao(DcBusiTargetAdjustDaySubDao dcBusiTargetAdjustDaySubDao, String assetId) |
|
|
public int insertDcBusiTargetAdjustDaySubDao(DcBusiTargetAdjustDaySubDao dcBusiTargetAdjustDaySubDao, String assetId) |
|
|
{ |
|
|
{ |
|
|
String targetName = "123"; //TODO 从service获取
|
|
|
DcBaseAssetTargetDao dcBaseAssetTargetDao = dcBaseAssetTargetMapper.selectDcBaseAssetTargetDaoByTargetCodeAndAssetId(dcBusiTargetAdjustDaySubDao.getTargetCode(), assetId); |
|
|
dcBusiTargetAdjustDaySubDao.setTargetName(targetName); |
|
|
if (ObjectUtils.isNotEmpty(dcBaseAssetTargetDao)) { |
|
|
|
|
|
dcBusiTargetAdjustDaySubDao.setTargetName(dcBaseAssetTargetDao.getTargetName()); |
|
|
|
|
|
} |
|
|
dcBusiTargetAdjustDaySubDao.setCreatedTime(DateUtils.getNowDate()); |
|
|
dcBusiTargetAdjustDaySubDao.setCreatedTime(DateUtils.getNowDate()); |
|
|
return baseMapper.insertDcBusiTargetAdjustDaySubDao(dcBusiTargetAdjustDaySubDao); |
|
|
return baseMapper.insertDcBusiTargetAdjustDaySubDao(dcBusiTargetAdjustDaySubDao); |
|
|
} |
|
|
} |
|
|