|
|
|
@ -16,16 +16,20 @@ import com.sztzjy.linkCommerce.mapper.JzhyfxStuAnswerMapper;
|
|
|
|
import com.sztzjy.linkCommerce.mapper.StuGradeMapper;
|
|
|
|
import com.sztzjy.linkCommerce.mapper.StuGradeMapper;
|
|
|
|
import com.sztzjy.linkCommerce.service.IndustryDemandAnalysisService;
|
|
|
|
import com.sztzjy.linkCommerce.service.IndustryDemandAnalysisService;
|
|
|
|
import com.sztzjy.linkCommerce.service.ScoreService;
|
|
|
|
import com.sztzjy.linkCommerce.service.ScoreService;
|
|
|
|
|
|
|
|
import com.sztzjy.linkCommerce.util.CompareListsUtil;
|
|
|
|
import com.sztzjy.linkCommerce.util.ResultEntity;
|
|
|
|
import com.sztzjy.linkCommerce.util.ResultEntity;
|
|
|
|
|
|
|
|
import com.sztzjy.linkCommerce.util.file.IFileUtil;
|
|
|
|
import io.swagger.annotations.Api;
|
|
|
|
import io.swagger.annotations.Api;
|
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
|
import io.swagger.annotations.ApiParam;
|
|
|
|
import io.swagger.annotations.ApiParam;
|
|
|
|
|
|
|
|
import org.checkerframework.checker.units.qual.A;
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
import org.springframework.http.HttpStatus;
|
|
|
|
import org.springframework.http.HttpStatus;
|
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
import org.springframework.transaction.annotation.Transactional;
|
|
|
|
import org.springframework.util.CollectionUtils;
|
|
|
|
import org.springframework.util.CollectionUtils;
|
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import javax.servlet.http.HttpServletResponse;
|
|
|
|
import java.math.BigDecimal;
|
|
|
|
import java.math.BigDecimal;
|
|
|
|
import java.util.*;
|
|
|
|
import java.util.*;
|
|
|
|
|
|
|
|
|
|
|
|
@ -44,6 +48,15 @@ public class IndustryDemandAnalysisController {
|
|
|
|
@Autowired
|
|
|
|
@Autowired
|
|
|
|
private ScoreService scoreService;
|
|
|
|
private ScoreService scoreService;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private CompareListsUtil compareListsUtil;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private JzhyfxStuAnswerMapper jzhyfxStuAnswerMapper;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private IFileUtil fileUtil;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//数据查询
|
|
|
|
//数据查询
|
|
|
|
@ApiOperation("行业需求分析提交")
|
|
|
|
@ApiOperation("行业需求分析提交")
|
|
|
|
@ -118,6 +131,8 @@ public class IndustryDemandAnalysisController {
|
|
|
|
|
|
|
|
|
|
|
|
hyxqfxStuAnswerMapper.insertSelective(hyxqfxStuAnswer);
|
|
|
|
hyxqfxStuAnswerMapper.insertSelective(hyxqfxStuAnswer);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
int i = compareListsUtil.calculateLengthPenaltyEnhanced(analysisDTO.getContext());
|
|
|
|
|
|
|
|
count = count + i;
|
|
|
|
|
|
|
|
|
|
|
|
subtract = BigDecimal.valueOf(100).subtract(Convert.toBigDecimal(count));
|
|
|
|
subtract = BigDecimal.valueOf(100).subtract(Convert.toBigDecimal(count));
|
|
|
|
|
|
|
|
|
|
|
|
@ -180,8 +195,7 @@ public class IndustryDemandAnalysisController {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Autowired
|
|
|
|
|
|
|
|
private JzhyfxStuAnswerMapper jzhyfxStuAnswerMapper;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ApiOperation("竞争环境分析提交")
|
|
|
|
@ApiOperation("竞争环境分析提交")
|
|
|
|
@ -199,6 +213,8 @@ public class IndustryDemandAnalysisController {
|
|
|
|
count ++ ;
|
|
|
|
count ++ ;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
int i = compareListsUtil.calculateLengthPenaltyEnhanced(competitiveEnvDTO.getContext());
|
|
|
|
|
|
|
|
count = count + i;
|
|
|
|
|
|
|
|
|
|
|
|
//查询数据库 是否已经答过题
|
|
|
|
//查询数据库 是否已经答过题
|
|
|
|
JzhyfxStuAnswerExample example = new JzhyfxStuAnswerExample();
|
|
|
|
JzhyfxStuAnswerExample example = new JzhyfxStuAnswerExample();
|
|
|
|
@ -247,6 +263,35 @@ public class IndustryDemandAnalysisController {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ApiOperation("EXCEL下载数据")
|
|
|
|
|
|
|
|
@GetMapping("/downloadExcel")
|
|
|
|
|
|
|
|
@AnonymousAccess
|
|
|
|
|
|
|
|
public void downloadExcel(HttpServletResponse response,
|
|
|
|
|
|
|
|
@ApiParam("对应小模块如:行业需求分析") String module,
|
|
|
|
|
|
|
|
@RequestParam(required = false) @ApiParam("对应数据如:年度数据、月度数据,没有就不传参")String fileName) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (Constant.MODULE_HYXQFX.equals(module))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
if (Constant.INFO_NDSJ.equals(fileName))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
fileUtil.download(response,"行业需求分析年度数据.xls");
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (Constant.INFO_YDSJ.equals(fileName))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
fileUtil.download(response,"行业需求分析月度数据.xls");
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (Constant.MODULE_JZHJFX.equals(module))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
fileUtil.download(response,"竞争环境分析.xls");
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//fileUtil.download(response,"RFM分析方法data.xls");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|