|
|
|
@ -2,16 +2,28 @@ package com.ruoyi.tc.service.impl;
|
|
|
|
|
|
|
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
|
|
|
import com.ruoyi.tc.entity.*;
|
|
|
|
|
import com.ruoyi.tc.entity.AssetTask;
|
|
|
|
|
import com.ruoyi.tc.entity.request.AssestTaskXqRequest;
|
|
|
|
|
import com.ruoyi.tc.entity.request.AssetCurrentShRequest;
|
|
|
|
|
import com.ruoyi.tc.entity.request.AssetTaskPageRequest;
|
|
|
|
|
import com.ruoyi.tc.entity.response.*;
|
|
|
|
|
import com.ruoyi.tc.entity.response.AssestTaskXqresponse;
|
|
|
|
|
import com.ruoyi.tc.entity.response.AssetBasicNetworkCpResponse;
|
|
|
|
|
import com.ruoyi.tc.entity.response.AssetBusinessFormCpResponse;
|
|
|
|
|
import com.ruoyi.tc.entity.response.AssetCurrentResponse;
|
|
|
|
|
import com.ruoyi.tc.entity.response.AssetSupplyChainCpResponse;
|
|
|
|
|
import com.ruoyi.tc.entity.response.AssetTaskResponse;
|
|
|
|
|
import com.ruoyi.tc.entity.response.UnitOtherConcatCpResponse;
|
|
|
|
|
import com.ruoyi.tc.mapper.AssetTaskMapper;
|
|
|
|
|
import com.ruoyi.tc.service.*;
|
|
|
|
|
import com.ruoyi.tc.service.AssetBasicNetworkCpService;
|
|
|
|
|
import com.ruoyi.tc.service.AssetBusinessFormCpService;
|
|
|
|
|
import com.ruoyi.tc.service.AssetCurrentCpService;
|
|
|
|
|
import com.ruoyi.tc.service.AssetSupplyChainCpService;
|
|
|
|
|
import com.ruoyi.tc.service.AssetTaskService;
|
|
|
|
|
import com.ruoyi.tc.service.UnitOtherConcatCpService;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
|
|
import java.util.ArrayList;
|
|
|
|
|
import java.util.List;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
@ -43,8 +55,6 @@ public class AssetTaskServiceImpl extends ServiceImpl<AssetTaskMapper, AssetTask
|
|
|
|
|
private UnitOtherConcatCpService unitOtherConcatCpService;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 通过ID查询单条数据
|
|
|
|
|
*
|
|
|
|
@ -86,6 +96,7 @@ public class AssetTaskServiceImpl extends ServiceImpl<AssetTaskMapper, AssetTask
|
|
|
|
|
assetCurrentResponse.setTaskId(id);
|
|
|
|
|
}
|
|
|
|
|
assetCurrentCpService.saveBatch(list);
|
|
|
|
|
List<AssetBusinessFormCpResponse> assetBusinessFormCpResponseList = new ArrayList<>();
|
|
|
|
|
for (AssetCurrentResponse assetCurrentResponse : list) {
|
|
|
|
|
//新增新监管业务形态
|
|
|
|
|
//根据资产id查询新监管业务形态主表id
|
|
|
|
@ -95,8 +106,9 @@ public class AssetTaskServiceImpl extends ServiceImpl<AssetTaskMapper, AssetTask
|
|
|
|
|
assetCurrentResponse.getXjgywxt().setId(assetBusinessFormCpResponse.getId());
|
|
|
|
|
assetCurrentResponse.getXjgywxt().setAssetId(assetCurrentResponse.getId());
|
|
|
|
|
assetCurrentResponse.getXjgywxt().setTaskId(id);
|
|
|
|
|
assetBusinessFormCpService.save(assetCurrentResponse.getXjgywxt());
|
|
|
|
|
assetBusinessFormCpResponseList.add(assetCurrentResponse.getXjgywxt());
|
|
|
|
|
}
|
|
|
|
|
assetBusinessFormCpService.saveBatch(assetBusinessFormCpResponseList);
|
|
|
|
|
}
|
|
|
|
|
//根据资产id查询供应链主表id-
|
|
|
|
|
List<AssetSupplyChainCpResponse> supplyChainList = assetSupplyChainCpService.findByassetId(assetCurrentResponse.getId());
|
|
|
|
@ -106,8 +118,8 @@ public class AssetTaskServiceImpl extends ServiceImpl<AssetTaskMapper, AssetTask
|
|
|
|
|
items.setId(items.getId());
|
|
|
|
|
items.setTaskId(id);
|
|
|
|
|
//新增供应链
|
|
|
|
|
assetSupplyChainCpService.save(items);
|
|
|
|
|
}
|
|
|
|
|
assetSupplyChainCpService.saveBatch(supplyChainList);
|
|
|
|
|
}
|
|
|
|
|
List<AssetBasicNetworkCpResponse> BasicNetworkCpList = assetBasicNetworkCpService.findByassetId(assetCurrentResponse.getId());
|
|
|
|
|
if (BasicNetworkCpList != null) {
|
|
|
|
@ -117,9 +129,8 @@ public class AssetTaskServiceImpl extends ServiceImpl<AssetTaskMapper, AssetTask
|
|
|
|
|
items.setId(items.getId());
|
|
|
|
|
items.setTaskId(id);
|
|
|
|
|
//新增基础网络
|
|
|
|
|
assetBasicNetworkCpService.save(items);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
assetBasicNetworkCpService.saveBatch(BasicNetworkCpList);
|
|
|
|
|
}
|
|
|
|
|
List<UnitOtherConcatCpResponse> unitOtherConcatList = unitOtherConcatCpService.findByassetId(assetCurrentResponse.getId());
|
|
|
|
|
if (unitOtherConcatList != null) {
|
|
|
|
@ -129,9 +140,8 @@ public class AssetTaskServiceImpl extends ServiceImpl<AssetTaskMapper, AssetTask
|
|
|
|
|
items.setConcatId(items.getConcatId());
|
|
|
|
|
items.setTaskId(id);
|
|
|
|
|
//新增其他联系人
|
|
|
|
|
unitOtherConcatCpService.save(items);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
unitOtherConcatCpService.saveBatch(unitOtherConcatList);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|