|
|
|
@ -101,8 +101,13 @@ public class TbCompanyInformationReportingController extends BaseController {
|
|
|
|
|
if(tbCompanyInformationReporting.getDetails()==null||tbCompanyInformationReporting.getDetails().size()<1){
|
|
|
|
|
return error("上报详情信息三项不能都为空");
|
|
|
|
|
}
|
|
|
|
|
boolean sing=false;
|
|
|
|
|
List<TbCompanyInformationReportingDetails> details = tbCompanyInformationReporting.getDetails();
|
|
|
|
|
for (TbCompanyInformationReportingDetails detail : details) {
|
|
|
|
|
if(StringUtils.isBlank(detail.getDataType())){
|
|
|
|
|
sing=true;
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
if(tbCompanyInformationReportingDetailsService.group1FieldsEmptyByCompanyThreePreventionData(detail)){
|
|
|
|
|
tbCompanyInformationReporting.setCompanyThreePreventionData("0");
|
|
|
|
|
}else {
|
|
|
|
@ -120,8 +125,14 @@ public class TbCompanyInformationReportingController extends BaseController {
|
|
|
|
|
}
|
|
|
|
|
detail.setCreateTime(DateUtils.getNowDate());
|
|
|
|
|
}
|
|
|
|
|
if(sing){
|
|
|
|
|
return error("上报详情类型为空");
|
|
|
|
|
}
|
|
|
|
|
tbCompanyInformationReporting.setReportState("1");
|
|
|
|
|
int i = tbCompanyInformationReportingService.insertTbCompanyInformationReporting(tbCompanyInformationReporting);
|
|
|
|
|
for (TbCompanyInformationReportingDetails detail : details){
|
|
|
|
|
detail.setCompanyInformationReportingId(tbCompanyInformationReporting.getId());
|
|
|
|
|
}
|
|
|
|
|
boolean saveBatch = tbCompanyInformationReportingDetailsService.saveBatch(details);
|
|
|
|
|
if(!saveBatch){
|
|
|
|
|
i=0;
|
|
|
|
@ -219,9 +230,12 @@ public class TbCompanyInformationReportingController extends BaseController {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* 修改企业信息上报
|
|
|
|
|
*上报提交
|
|
|
|
|
*/
|
|
|
|
|
@PutMapping("/changeState")
|
|
|
|
|
@ApiOperation("上报提交")
|
|
|
|
|
@ApiOperationSupport(author = "张二富", order = 20)
|
|
|
|
|
@ApiImplicitParam(name = "id", value = "企业信息上报id 列表返回的id", required = true)
|
|
|
|
|
public AjaxResult changeState(@RequestBody TbCompanyInformationReporting tbCompanyInformationReporting){
|
|
|
|
|
UpdateWrapper<TbCompanyInformationReporting> updateWrapper = new UpdateWrapper<>();
|
|
|
|
|
updateWrapper.eq(StringUtils.camelToUnderline(TbCompanyInformationReporting.Fields.id),tbCompanyInformationReporting.getId());
|
|
|
|
|