|
@@ -2,6 +2,9 @@ package com.zzys.qhyscredit.report.rest;
|
|
|
|
|
|
import com.deepoove.poi.XWPFTemplate;
|
|
|
import com.deepoove.poi.data.*;
|
|
|
+import com.deepoove.poi.data.style.PictureStyle;
|
|
|
+import com.deepoove.poi.data.style.Style;
|
|
|
+import com.deepoove.poi.xwpf.XWPFHighlightColor;
|
|
|
import com.zzys.qhyscredit.base.rest.BaseController;
|
|
|
import com.zzys.qhyscredit.param.dao.model.ParamEntry;
|
|
|
import com.zzys.qhyscredit.param.service.ParamService;
|
|
@@ -10,12 +13,13 @@ import com.zzys.qhyscredit.report.dao.model.TaxRateEntity;
|
|
|
import com.zzys.qhyscredit.report.service.ProvinceService;
|
|
|
import com.zzys.qhyscredit.report.service.TaxRateService;
|
|
|
import com.zzys.qhyscredit.report.utils.ReportConstant;
|
|
|
-import com.zzys.qhyscredit.report.utils.ReportUtils;
|
|
|
import com.zzys.qhyscredit.report.utils.WordUtils;
|
|
|
import com.zzys.qhyscredit.report.vo.*;
|
|
|
import com.zzys.qhyscredit.tax.code.service.TaxCodeService;
|
|
|
import com.zzys.qhyscredit.utils.DateUtil;
|
|
|
import com.zzys.qhyscredit.utils.Result;
|
|
|
+import fr.opensagres.poi.xwpf.converter.pdf.PdfConverter;
|
|
|
+import fr.opensagres.poi.xwpf.converter.pdf.PdfOptions;
|
|
|
import io.swagger.annotations.Api;
|
|
|
import org.apache.commons.collections4.ListUtils;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
@@ -23,6 +27,7 @@ import org.apache.poi.hssf.usermodel.HSSFWorkbook;
|
|
|
import org.apache.poi.ss.usermodel.Sheet;
|
|
|
import org.apache.poi.ss.usermodel.Workbook;
|
|
|
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
|
|
|
+import org.apache.poi.xwpf.usermodel.XWPFDocument;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.web.bind.annotation.GetMapping;
|
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
@@ -30,14 +35,16 @@ import org.springframework.web.bind.annotation.RestController;
|
|
|
import org.springframework.web.multipart.MultipartFile;
|
|
|
|
|
|
import javax.validation.constraints.NotNull;
|
|
|
-import javax.xml.soap.Text;
|
|
|
import java.io.File;
|
|
|
+import java.io.FileInputStream;
|
|
|
+import java.io.FileOutputStream;
|
|
|
import java.io.InputStream;
|
|
|
import java.lang.reflect.Constructor;
|
|
|
import java.lang.reflect.Method;
|
|
|
import java.math.BigDecimal;
|
|
|
import java.math.RoundingMode;
|
|
|
import java.text.SimpleDateFormat;
|
|
|
+import java.time.format.TextStyle;
|
|
|
import java.util.*;
|
|
|
|
|
|
/**
|
|
@@ -62,15 +69,7 @@ public class GenerateReport extends BaseController {
|
|
|
@Autowired
|
|
|
private TaxRateService taxRateService;
|
|
|
|
|
|
- private String industryType;//行业大类
|
|
|
|
|
|
- private double minReferenceValue;//最小参考值
|
|
|
-
|
|
|
- private double maxReferenceValue;//最大参考值
|
|
|
-
|
|
|
- private int riskLevel = 0 ;//风险等级
|
|
|
-
|
|
|
- private StringBuilder riskDetail = new StringBuilder();
|
|
|
|
|
|
/**
|
|
|
*
|
|
@@ -96,7 +95,20 @@ public class GenerateReport extends BaseController {
|
|
|
@NotNull MultipartFile taxFile,@NotNull MultipartFile vatFile) throws Exception {
|
|
|
Map<String,Object> dataMap = new HashMap<>();
|
|
|
InputStream inputStream = file.getInputStream();
|
|
|
+ List<RiskVo> riskVos = new ArrayList<>();
|
|
|
String fileName = file.getOriginalFilename();
|
|
|
+ String industryType;//行业大类
|
|
|
+
|
|
|
+ double minReferenceValue;//最小参考值
|
|
|
+
|
|
|
+ double maxReferenceValue;//最大参考值
|
|
|
+
|
|
|
+ int riskLevel = 0 ;//风险等级
|
|
|
+
|
|
|
+ StringBuilder riskDetail = new StringBuilder();
|
|
|
+
|
|
|
+
|
|
|
+ RiskVo riskVo ;
|
|
|
assert fileName != null;
|
|
|
String fileType = fileName.substring(fileName.lastIndexOf("."));
|
|
|
Workbook workbook;
|
|
@@ -126,17 +138,11 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("checkCompanyName2","锦 泓 征 信 有 限 公 司");
|
|
|
dataMap.put("Ltd","JinHong Credit Reporting Co., Ltd");
|
|
|
dataMap.put("webAddress","http://www.jhdatatech.com");
|
|
|
- dataMap.put("email","j h d a t a t e c h@163.com");
|
|
|
+ dataMap.put("email","jhdatatech@163.com");
|
|
|
dataMap.put("companyName", String.valueOf(sheetBusiness.getRow(1).getCell(0)));
|
|
|
dataMap.put("companyname", String.valueOf(sheetBusiness.getRow(1).getCell(0)));
|
|
|
dataMap.put("reportCreateTime", DateUtil.getNowTime());
|
|
|
//概述信息
|
|
|
-
|
|
|
- dataMap.put("risk}","47");
|
|
|
- dataMap.put("hRisk","10");
|
|
|
- dataMap.put("mRisk","20");
|
|
|
- dataMap.put("lRisk","17");
|
|
|
- dataMap.put("round","2019年01月01日-2024年07月31日");
|
|
|
//企业基本信息-基础信息
|
|
|
dataMap.put("industry",String.valueOf(sheetFontLoaded.getRow(3).getCell(1)));//所属行业
|
|
|
industryType = String.valueOf(sheetFontLoaded.getRow(4).getCell(1));
|
|
@@ -145,31 +151,21 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("taxType",String.valueOf(sheetFontLoaded.getRow(1).getCell(1)));//纳税人类型
|
|
|
|
|
|
dataMap.put("establishmentDate",new SimpleDateFormat("yyyy-MM-dd").format(sheetBusiness.getRow(19).getCell(0).getDateCellValue()));//成立日期
|
|
|
- dataMap.put("registerOrgan","登记机关");//登记机关
|
|
|
- dataMap.put("registerState","存续");//登记状态
|
|
|
+ dataMap.put("registerOrgan",String.valueOf(sheetBusiness.getRow(41).getCell(0)));//登记机关
|
|
|
+ dataMap.put("registerState",String.valueOf(sheetBusiness.getRow(43).getCell(0)));//登记状态
|
|
|
dataMap.put("taxGrade",String.valueOf(sheetBusiness.getRow(15).getCell(0)));//纳税等级
|
|
|
dataMap.put("registerCapital",String.valueOf(sheetBusiness.getRow(49).getCell(0)));//注册资本
|
|
|
- dataMap.put("small","是");//是否小微企业
|
|
|
- dataMap.put("publics","否");//是否已上市
|
|
|
+ dataMap.put("small",String.valueOf(sheetBusiness.getRow(45).getCell(0)));//是否小微企业
|
|
|
+// dataMap.put("publics","否");//是否已上市
|
|
|
dataMap.put("legalFictions",String.valueOf(sheetBusiness.getRow(39).getCell(0)));//法人
|
|
|
- dataMap.put("registerAddress","河南省郑州市高新技术产业开发区西四环206号3号楼A455");//注册地址
|
|
|
+ dataMap.put("registerAddress",String.valueOf(sheetBusiness.getRow(51).getCell(0)));//注册地址
|
|
|
dataMap.put("isNew","是");//是否高新技术企业
|
|
|
- dataMap.put("usedName","--");//曾用名
|
|
|
+ dataMap.put("usedName",sheetBusiness.getRow(15).getCell(0) == null?"--":String.valueOf(sheetBusiness.getRow(15).getCell(0)));//曾用名
|
|
|
dataMap.put("tax",String.valueOf(sheetBusiness.getRow(3).getCell(0)));//税号
|
|
|
dataMap.put("businessScope",String.valueOf(sheetBusiness.getRow(37).getCell(0)));//经营范围
|
|
|
- dataMap.put("risk","47");
|
|
|
- //概述表格
|
|
|
- RowRenderData[] rowRenderDatas = new RowRenderData[7];
|
|
|
- rowRenderDatas[0]= Rows.of("风险等级","一级风险","二级风险").textColor("FFFFFF").bgColor("4472C4").center().create();
|
|
|
- rowRenderDatas[1] = Rows.create("高风险","1","11");
|
|
|
- rowRenderDatas[2] = Rows.create("高风险","2","22");
|
|
|
- rowRenderDatas[3] = Rows.create("中风险","3","33");
|
|
|
- rowRenderDatas[4] = Rows.create("中风险","4","44");
|
|
|
- rowRenderDatas[5] = Rows.create("低风险","5","55");
|
|
|
- rowRenderDatas[6] = Rows.create("低风险","6","66");
|
|
|
- dataMap.put("tableRisk",Tables.create(rowRenderDatas));
|
|
|
//投资方情况
|
|
|
dataMap.put("investTable",WordUtils.createInvestmentTable(sheetInvestment));
|
|
|
+ dataMap.put("investCircle",WordUtils.createInvestmentTableCircle(sheetInvestment));
|
|
|
//近三年每年信用等级
|
|
|
dataMap.put("taxGradeTable",WordUtils.createTaxGrade(sheetTaxGrade));
|
|
|
//税务处罚信息
|
|
@@ -261,9 +257,16 @@ public class GenerateReport extends BaseController {
|
|
|
}
|
|
|
|
|
|
dataMap.put("upDownStreamTable",WordUtils.createUpDownStream(upDownList,upDownParam));
|
|
|
- dataMap.put("upDownPic",upDownStreamRiskLevel == 1?new FilePictureRenderData("./images/low-risk.jpg", PictureType.JPEG) :null);
|
|
|
- dataMap.put("upDownDetail",upDownStreamDetail);
|
|
|
- dataMap.put("upDownLevel",upDownStreamRiskLevel ==1?"低风险":"高风险");
|
|
|
+ dataMap.put("upDownPic",getPicPath(upDownStreamRiskLevel));
|
|
|
+ dataMap.put("upDownDetail",createRiskDetail(upDownStreamRiskLevel,upDownStreamDetail));
|
|
|
+ dataMap.put("upDownLevel",getLevelString(upDownStreamRiskLevel));
|
|
|
+ if(upDownStreamRiskLevel > 0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(upDownStreamRiskLevel);
|
|
|
+ riskVo.setFirstTitle("发票分析-购销发票情况");
|
|
|
+ riskVo.setSecondTitle("近12个月上下游发票税额对比分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//近12个月上下游发票税额对比分析 结束
|
|
|
//近12个月互开发票风险--开始
|
|
|
Map<String, MutualInvoiceVo> mapMutually = reportVO.getMapMutually();
|
|
@@ -293,24 +296,16 @@ public class GenerateReport extends BaseController {
|
|
|
mutuallyDetail.append(";与").append(vo.getCustomName()).append("存在互开发票风险:销售金额").append(vo.getSellAmount()).append(",采购金额").append(vo.getBuyAmount());
|
|
|
}
|
|
|
}
|
|
|
- if(riskLevel == 0){
|
|
|
- dataMap.put("mutually-pic",null);
|
|
|
- dataMap.put("mutually-level","");
|
|
|
- dataMap.put("mutually-detail","");
|
|
|
- } else if (riskLevel ==1) {
|
|
|
- dataMap.put("mutually-pic",new FilePictureRenderData("./images/low-risk.jpg", PictureType.JPEG));
|
|
|
- dataMap.put("mutually-level","低风险");
|
|
|
- dataMap.put("mutually-detail",mutuallyDetail.toString());
|
|
|
- }else if(riskLevel == 2){
|
|
|
- dataMap.put("mutually-pic",new FilePictureRenderData("./images/mid-risk.jpg", PictureType.JPEG));
|
|
|
- dataMap.put("mutually-level","中风险");
|
|
|
- dataMap.put("mutually-detail",mutuallyDetail.toString());
|
|
|
- }else {
|
|
|
- dataMap.put("mutually-pic",new FilePictureRenderData("./images/high-risk.jpg", PictureType.JPEG));
|
|
|
- dataMap.put("mutually-level","高风险");
|
|
|
- dataMap.put("mutually-detail",mutuallyDetail.toString());
|
|
|
+ dataMap.put("mutually-pic",getPicPath(riskLevel));
|
|
|
+ dataMap.put("mutually-level",getLevelString(riskLevel));
|
|
|
+ dataMap.put("mutually-detail",createRiskDetail(riskLevel,mutuallyDetail));
|
|
|
+ if(riskLevel > 0 ){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("发票分析");
|
|
|
+ riskVo.setSecondTitle("近 12 个月互开发票风险");
|
|
|
+ riskVos.add(riskVo);
|
|
|
}
|
|
|
-
|
|
|
//近12个月互开发票风险--结束
|
|
|
//购销两头在外风险--开始
|
|
|
Map<String, SellAndBuyOutVo> mapSellAndBuyOut = reportVO.getMapSellAndBuyOut();
|
|
@@ -333,20 +328,27 @@ public class GenerateReport extends BaseController {
|
|
|
// 中风险 M1、M2 处于10%-20%之间
|
|
|
// 高风险 M1、M2 处于20%以上
|
|
|
int buyAndSellOutRisk = 0;
|
|
|
- String buyAndSellOutRiskDetail ="";
|
|
|
+ StringBuilder buyAndSellOutRiskDetail = new StringBuilder();
|
|
|
if(m1>0.2 || m2 >0.2){//高风险
|
|
|
buyAndSellOutRisk = 3;
|
|
|
- buyAndSellOutRiskDetail = "购销两头在外比例过高";
|
|
|
+ buyAndSellOutRiskDetail.append( "购销两头在外比例过高");
|
|
|
}else if(m1<0.1 && m2 < 0.1){ //低风险
|
|
|
buyAndSellOutRisk = 1;
|
|
|
- buyAndSellOutRiskDetail = "购销两头在外比例正常";
|
|
|
+ buyAndSellOutRiskDetail.append("购销两头在外比例正常");
|
|
|
}else {
|
|
|
buyAndSellOutRisk = 2;//中风险
|
|
|
- buyAndSellOutRiskDetail = "购销两头在外比例较高";
|
|
|
+ buyAndSellOutRiskDetail.append("购销两头在外比例较高");
|
|
|
}
|
|
|
dataMap.put("sellAndOutPic",getPicPath(buyAndSellOutRisk));
|
|
|
dataMap.put("sellAndOutRiskLevel",getLevelString(buyAndSellOutRisk));
|
|
|
- dataMap.put("sellAndOutRiskDetail",buyAndSellOutRiskDetail);
|
|
|
+ dataMap.put("sellAndOutRiskDetail",createRiskDetail(buyAndSellOutRisk,buyAndSellOutRiskDetail));
|
|
|
+ if(buyAndSellOutRisk > 0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(buyAndSellOutRisk);
|
|
|
+ riskVo.setFirstTitle("发票分析-购销发票情况");
|
|
|
+ riskVo.setSecondTitle("购销两头在外风险");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//购销两头在外风险--结束
|
|
|
// WordUtils.operateWord(document,businessMap,picMap,textBoxMap);
|
|
|
//销售/采购商品分类--开始
|
|
@@ -397,6 +399,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("redCancellationTable",redFlushAndVoidTableVo.getTableRenderData());
|
|
|
dataMap.put("redCanSumTable",redFlushAndVoidTableVo.getSumRenderData());
|
|
|
dataMap.put("redCalcelHis",redFlushAndVoidTableVo.getChartMultiSeriesRenderData());
|
|
|
+ if(redFlushAndVoidTableVo.getRiskLevel() >0 ){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(redFlushAndVoidTableVo.getRiskLevel());
|
|
|
+ riskVo.setFirstTitle("发票分析");
|
|
|
+ riskVo.setSecondTitle("红冲、作废开票分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//作废、红冲开票分析--结束
|
|
|
//近12个月红冲发票明细--开始
|
|
|
dataMap.put("redFlushDetailTable",WordUtils.createRedFlushDetailTable(reportVO.getRedFlushList()));
|
|
@@ -466,6 +475,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("operatingMarginDetail",riskDetail.toString());
|
|
|
dataMap.put("operatingMargin",WordUtils.createOperatingMarginLineChart(operatingMargins));//折线图
|
|
|
dataMap.put("operatingMarginTable",WordUtils.createOperatingMarginTable(operatingMargins,minReferenceValue,maxReferenceValue));//表格
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-基础指标分析");
|
|
|
+ riskVo.setSecondTitle("营业利润率");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//营业利润率-结束
|
|
|
//期间费用率--开始
|
|
|
riskDetail.setLength(0);
|
|
@@ -488,7 +504,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("periodFeeDetail",riskDetail.toString());
|
|
|
dataMap.put("periodFee",WordUtils.createPeriodFee(periodFeeVos));
|
|
|
dataMap.put("periodFeeTable",WordUtils.createPeriodFeeTable(periodFeeVos,minReferenceValue,maxReferenceValue));
|
|
|
-
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-基础指标分析");
|
|
|
+ riskVo.setSecondTitle("期间费用率");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//期间费用率--结束
|
|
|
//财务费用率--开始
|
|
|
List<FiExVo> fiExVoList = reportVO.getFiExVoList();
|
|
@@ -511,6 +533,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("fiExDetail",riskDetail.toString());
|
|
|
dataMap.put("fiEx",WordUtils.createFiEx(fiExVoList));
|
|
|
dataMap.put("fiExTable",WordUtils.createFiexTable(fiExVoList,minReferenceValue,maxReferenceValue));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-基础指标分析");
|
|
|
+ riskVo.setSecondTitle("财务费用率");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//财务费用率--结束
|
|
|
//管理费用率--开始
|
|
|
List<ManageFeeVo> manageFeeVos = reportVO.getManageFeeVos();
|
|
@@ -533,6 +562,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("manageFeeDetail",riskDetail.toString());
|
|
|
dataMap.put("manageFee",WordUtils.createManageFee(manageFeeVos));
|
|
|
dataMap.put("manageFeeTable",WordUtils.createManageFeeTable(manageFeeVos,minReferenceValue,maxReferenceValue));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-基础指标分析");
|
|
|
+ riskVo.setSecondTitle("管理费用率");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//管理费用率--结束
|
|
|
//销售费用率--开始
|
|
|
List<SellFeeVo> sellFeeVos = reportVO.getSellFeeVos();
|
|
@@ -555,7 +591,12 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("sellFeeDetail",riskDetail.toString());
|
|
|
dataMap.put("sellFee",WordUtils.createSellFee(sellFeeVos));
|
|
|
dataMap.put("sellFeeTable",WordUtils.createSellFeeTable(sellFeeVos,minReferenceValue,maxReferenceValue));
|
|
|
-
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-基础指标分析");
|
|
|
+ riskVo.setSecondTitle("销售费用率");
|
|
|
+ }
|
|
|
//销售费用率--结束
|
|
|
//业务招待费对营业收入占比--开始
|
|
|
List<BuHoVo> buHoVoList = reportVO.getBuHoVoList();
|
|
@@ -578,6 +619,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("buHoDetail",riskDetail.toString());
|
|
|
dataMap.put("buHoChart",WordUtils.createBuHo(buHoVoList));
|
|
|
dataMap.put("buHoTable",WordUtils.createBuHoTable(buHoVoList,minReferenceValue,maxReferenceValue));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-基础指标分析");
|
|
|
+ riskVo.setSecondTitle("业务招待费");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//业务招待费对营业收入占比分析--结束
|
|
|
//广告费和业务宣传费明细占比分析--开始
|
|
|
minReferenceValue = Double.parseDouble(taxRateEntity.getAdFees().split("%-|%")[0]);
|
|
@@ -598,6 +646,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("otherFeeLevel",getLevelString(riskLevel));
|
|
|
dataMap.put("otherFeeDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("otherFeeTable",WordUtils.createOtherFeeTable(otherFeeVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-基础指标分析");
|
|
|
+ riskVo.setSecondTitle("其他费用率");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//其他费用明细占比分析--结束
|
|
|
//固定资产综合折旧率变动异常分析--开始
|
|
|
List<FixedAssetsVo> fixedAssetsVos = reportVO.getFixedAssetsVos();
|
|
@@ -616,6 +671,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("donateLevel",getLevelString(riskLevel));
|
|
|
dataMap.put("donateDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("donateTable",WordUtils.createDonateTable(donateVo));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-基础指标分析");
|
|
|
+ riskVo.setSecondTitle("超额税前扣除公益性捐赠支出的风险");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//超额税前扣除公益性捐赠支出的风险--结束
|
|
|
//未分配利润对实收资本占比分析--开始
|
|
|
List<UndistributedProfitAndPaidCapitalVo> undistributedProfitAndPaidCapitalVos = reportVO.getUndistributedProfitAndPaidCapitalVos();
|
|
@@ -632,6 +694,25 @@ public class GenerateReport extends BaseController {
|
|
|
List<OtherPayablesVo> otherPayablesVos = reportVO.getOtherPayablesVos();
|
|
|
dataMap.put("otherPayables",WordUtils.createOtherPayables(otherPayablesVos));
|
|
|
dataMap.put("otherPayablesTable",WordUtils.createOtherPayablesTable(otherPayablesVos));
|
|
|
+
|
|
|
+ riskLevel =0;
|
|
|
+ riskDetail.setLength(0);
|
|
|
+ for (int i = 1; i < otherPayablesVos.size(); i++) {
|
|
|
+ if(otherPayablesVos.get(i).getProportion() >10){
|
|
|
+ riskLevel = 1;
|
|
|
+ riskDetail.append(otherPayablesVos.get(i).getYear()).append("其他应付款项对营业收入占比").append(otherPayablesVos.get(i).getProportion()).append("%过高;");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ dataMap.put("otherPayablesPic",getPicPath(riskLevel));
|
|
|
+ dataMap.put("otherPayablesLevel",getLevelString(riskLevel));
|
|
|
+ dataMap.put("otherPayablesDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-隐匿收入指标综合分析");
|
|
|
+ riskVo.setSecondTitle("其他应付款变动分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//其他应付款变动分析--结束
|
|
|
//3.2.3 存货余额、预收账款余额变动分析 --开始
|
|
|
riskDetail.setLength(0);
|
|
@@ -652,6 +733,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("stockAndRecDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("stockAndRec",WordUtils.createStockAndRec(stockAndAdvancesReceivedVos));
|
|
|
dataMap.put("stockAndRecTable",WordUtils.createStockAmdRecTable(stockAndAdvancesReceivedVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-隐匿收入指标综合分析");
|
|
|
+ riskVo.setSecondTitle("存货余额、预收账款余额变动分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//3.2.3 存货余额、预收账款余额变动分析--结束
|
|
|
//3.2.4 存货余额变动分析--开始
|
|
|
riskLevel = 0;
|
|
@@ -668,7 +756,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("stockBalanceDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("stockBalance",WordUtils.createStockBalance(stockBalanceVos));
|
|
|
dataMap.put("stockBalanceTable",WordUtils.createStockBalanceTable(stockBalanceVos));
|
|
|
-
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-隐匿收入指标综合分析");
|
|
|
+ riskVo.setSecondTitle("存货余额、预收账款余额变动分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//3.2.4 存货余额变动分析--结束
|
|
|
//预收账款余额变动分析 -- 开始
|
|
|
List<AdvancesReceivedVo> advancesReceivedVos = reportVO.getAdvancesReceivedVos();
|
|
@@ -684,6 +778,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("advancesReceLevel",getLevelString(riskLevel));
|
|
|
dataMap.put("advancesReceDetail",riskDetail.toString());
|
|
|
dataMap.put("advancesReceTable",WordUtils.createAdvancesReceTable(advancesReceivedVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-隐匿收入指标综合分析");
|
|
|
+ riskVo.setSecondTitle("预收账款余额变动分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//预收账款余额变动分析 -- 结束
|
|
|
//应付账款变动分析-开始
|
|
|
List<AccountPayableVo> payables = reportVO.getAccountPayables();
|
|
@@ -701,6 +802,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("accountPayablesTable",WordUtils.createAccountPayables(payables));
|
|
|
dataMap.put("accountPayables",WordUtils.createAccountPayablesLineChart(payables));
|
|
|
dataMap.put("accountPayablesDetail",riskDetail);
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("财务涉税风险评估-隐匿收入指标综合分析");
|
|
|
+ riskVo.setSecondTitle("应付账款变动分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//应付账款变动分析-结束
|
|
|
//应交税费变动分析-开始
|
|
|
List<AccountTaxVo> accountTaxVos = reportVO.getAccountTaxVos();
|
|
@@ -755,6 +863,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("vatMarginDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("vatMargin",WordUtils.createVatMargin(vatMarginRateVos));
|
|
|
dataMap.put("vatMarginTable",WordUtils.createVatMarginTable(vatMarginRateVos,minReferenceValue,maxReferenceValue));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-增值税");
|
|
|
+ riskVo.setSecondTitle("增值税税负率(年度)");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//4.2.2 增值税税负率(年度)--结束
|
|
|
//4.2.4 有免税收入、简易征税销售额且有进项税额但无进项税额转出(季度)
|
|
|
Map<String, FreeTaxSellVo> freeTaxSellVoMap = reportVO.getFreeTaxSellVoMap();
|
|
@@ -795,6 +910,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("unTaxIncomeLevel",getLevelString(riskLevel));
|
|
|
dataMap.put("unTaxIncomeDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("unTaxIncomeTable",WordUtils.createUnTaxIncomeTable(untaxedIncomeVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-企业所得税");
|
|
|
+ riskVo.setSecondTitle("企业所得税不征税收入调减金额分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//4.3.1 企业所得税贡献率
|
|
|
dataMap.put("taxDevote",WordUtils.createTaxDevotes(reportVO.getTaxDevoteVos()));
|
|
|
dataMap.put("taxDevoteTable",WordUtils.createTaxDevotesTable(reportVO.getTaxDevoteVos()));
|
|
@@ -819,6 +941,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("taxAdjustAddDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("taxAdjustAdd",WordUtils.createTaxAdjustAdd(taxAdjustAddVos));
|
|
|
dataMap.put("taxAdjustAddTable",WordUtils.createTaxAdjustAddTable(taxAdjustAddVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-企业所得税");
|
|
|
+ riskVo.setSecondTitle("企业所得税纳税调整增加率");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//4.3.3 企业所得税纳税调整减少率
|
|
|
List<TaxAdjustReduceVo> taxAdjustReduceVos = reportVO.getTaxAdjustReduceVos();
|
|
|
riskLevel = 0;
|
|
@@ -840,6 +969,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("taxAdjustRedDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("taxAdjustRed",WordUtils.createTaxAdjustReduce(taxAdjustReduceVos));
|
|
|
dataMap.put("taxAdjustRedTable",WordUtils.createTaxAdjustReduceTable(taxAdjustReduceVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-企业所得税");
|
|
|
+ riskVo.setSecondTitle("企业所得税纳税调整减少率");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//印花税变动分析
|
|
|
List<StampDutyTaxVo> stampDutyTaxVos = reportVO.getStampDutyTaxVos();
|
|
|
dataMap.put("stampTax",WordUtils.createStampTax(stampDutyTaxVos));
|
|
@@ -868,7 +1004,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("resourceTaxLevel",getLevelString(riskLevel));
|
|
|
dataMap.put("resourceTaxDetail",riskDetail.toString());
|
|
|
dataMap.put("resourceTaxTable",WordUtils.createResourceTax(resourceTaxVos));
|
|
|
-
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-资源税");
|
|
|
+ riskVo.setSecondTitle("资源税变动分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//企业所得税汇缴申报的损失类营业外支出金额
|
|
|
riskLevel = 0;
|
|
|
riskDetail.setLength(0);
|
|
@@ -907,7 +1049,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("nonOperatingExpensesLevel",getLevelString(riskLevel));
|
|
|
dataMap.put("nonOperatingExpensesDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("nonOperatingExpensesTable",WordUtils.createNonOperatingExpensesTable(nonOperatingExpensesVos));
|
|
|
-
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-企业所得税");
|
|
|
+ riskVo.setSecondTitle("企业所得税汇缴申报的损失类营业外支出金额");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//4.3.5 纳税调整后所得变动率分析
|
|
|
List<TaxAdjustmentVo> taxAdjustmentVos = reportVO.getTaxAdjustmentVos();
|
|
|
riskLevel=0;
|
|
@@ -930,15 +1078,6 @@ public class GenerateReport extends BaseController {
|
|
|
.append("过高;");
|
|
|
riskLevel = Math.max(riskLevel,tempRiskLevel);
|
|
|
}
|
|
|
-// if(nonOperatingExpensesVo.getProportion()>3 ){
|
|
|
-// tempRiskLevel = 3;
|
|
|
-// riskDetail.append(nonOperatingExpensesVo.getYear())
|
|
|
-// .append("企业所得税汇缴申报的损失类营业外支出金额占企业年度营业收入比例")
|
|
|
-// .append(nonOperatingExpensesVo.getProportion())
|
|
|
-// .append("过高;");
|
|
|
-// riskLevel = Math.max(riskLevel,tempRiskLevel);
|
|
|
-// }
|
|
|
-
|
|
|
}
|
|
|
|
|
|
dataMap.put("taxAdjustPic",getPicPath(riskLevel));
|
|
@@ -946,6 +1085,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("taxAdjustDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("taxAdjust",WordUtils.createTaxAdjust(taxAdjustmentVos));
|
|
|
dataMap.put("taxAdjustTable",WordUtils.createTaxAdjustTable(taxAdjustmentVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-企业所得税");
|
|
|
+ riskVo.setSecondTitle("纳税调整后所得变动率分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//附加税费税(费)率分析
|
|
|
riskDetail.setLength(0);
|
|
|
riskLevel = 0;
|
|
@@ -967,6 +1113,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("surTaxLevel",getLevelString(riskLevel));
|
|
|
dataMap.put("surTaxDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("surTaxTable",WordUtils.createSurtaxTable(surtaxVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-附加税费");
|
|
|
+ riskVo.setSecondTitle("附加税费税(费)率分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//房产税变动分析
|
|
|
Map<String, HouseTaxVo> houseTaxVoMap = reportVO.getHouseTaxVoMap();
|
|
|
ArrayList<Map.Entry<String, HouseTaxVo>> houseTaxVos = new ArrayList<>(houseTaxVoMap.entrySet());
|
|
@@ -987,6 +1140,13 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("crVoDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("crVo",WordUtils.createCrVo(urbanConstructionVos));
|
|
|
dataMap.put("crVoTable",WordUtils.createCrVoTable(urbanConstructionVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-附加税费");
|
|
|
+ riskVo.setSecondTitle("城建税税率分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//增值税留抵退税的风险
|
|
|
riskDetail.setLength(0);
|
|
|
riskLevel = 0;
|
|
@@ -1012,16 +1172,76 @@ public class GenerateReport extends BaseController {
|
|
|
dataMap.put("taxRefundDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
dataMap.put("taxRefund",WordUtils.createTaxRefund(taxRefunds));
|
|
|
dataMap.put("taxRefundTable",WordUtils.createTaxRefundTable(taxRefunds));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-增值税");
|
|
|
+ riskVo.setSecondTitle("增值税留抵退税的风险");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
//印花税税率推算
|
|
|
List<StampDutyRateVo> stampDutyRateVos = reportVO.getStampDutyRateVos();
|
|
|
dataMap.put("stampDutyTable",WordUtils.createStampDutyTable(stampDutyRateVos));
|
|
|
//4.4.1 分配股息红利未扣缴个人所得税风险预警
|
|
|
List<DividendTaxVo> dividendTaxVos = reportVO.getDividendTaxVos();
|
|
|
dataMap.put("dividendTaxTable",WordUtils.createDividendTaxTable(dividendTaxVos));
|
|
|
- XWPFTemplate.compile("./pdftemplate/最新模板20240820-1.docx").render(dataMap).writeToFile("./pdftemplate/最新报告-20240820.docx");
|
|
|
- File inputWord = new File("./pdftemplate/最新报告-20240820.docx");
|
|
|
- File outputFile = new File("./pdftemplate/最新报告-202408020.pdf");
|
|
|
- WordUtils.word2pdf(inputWord,outputFile);
|
|
|
+ //人工费用变动率分析
|
|
|
+ List<LaborCostVo> laborCostVos = reportVO.getLaborCostVos();
|
|
|
+ riskLevel = 0;
|
|
|
+ riskDetail.setLength(0);
|
|
|
+ for (LaborCostVo item : laborCostVos) {
|
|
|
+ double abs = Math.abs(item.getLaborCostRate());
|
|
|
+ if(abs < 5){
|
|
|
+ riskLevel = 1;
|
|
|
+ riskDetail.append(item.getYear()).append("人工费用变动率").append(item.getLaborCostRate()).append("属于低风险;");
|
|
|
+ } else if (abs>=5 && abs <= 15) {
|
|
|
+ riskLevel = 2;
|
|
|
+ riskDetail.append(item.getYear()).append("人工费用变动率").append(item.getLaborCostRate()).append("属于中风险;");
|
|
|
+ } else {
|
|
|
+ riskLevel = 3;
|
|
|
+ riskDetail.append(item.getYear()).append("人工费用变动率").append(item.getLaborCostRate()).append("属于高风险;");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ dataMap.put("laborCostPic",getPicPath(riskLevel));
|
|
|
+ dataMap.put("laborCostLevel",getLevelString(riskLevel));
|
|
|
+ dataMap.put("laborCostDetail",createRiskDetail(riskLevel,riskDetail));
|
|
|
+ dataMap.put("laborCost",WordUtils.createLaborCost(laborCostVos));
|
|
|
+ dataMap.put("laborCostTable",WordUtils.createLaborCostTable(laborCostVos));
|
|
|
+ if(riskLevel>0){
|
|
|
+ riskVo = new RiskVo();
|
|
|
+ riskVo.setRiskLevel(riskLevel);
|
|
|
+ riskVo.setFirstTitle("税务风险评估-企业所得税");
|
|
|
+ riskVo.setSecondTitle("人工费用变动率分析");
|
|
|
+ riskVos.add(riskVo);
|
|
|
+ }
|
|
|
+
|
|
|
+ //风险等级表格
|
|
|
+ //概述表格
|
|
|
+ dataMap.put("tableRisk",WordUtils.createRiskTable(riskVos));
|
|
|
+ dataMap.put("risk",riskVos.size());
|
|
|
+ int hRisk =0,mRisk =0,lRisk=0;
|
|
|
+ for (RiskVo item : riskVos) {
|
|
|
+ if(item.getRiskLevel() ==1){
|
|
|
+ lRisk +=1;
|
|
|
+ } else if (item.getRiskLevel()==2) {
|
|
|
+ mRisk +=1;
|
|
|
+ }else {
|
|
|
+ hRisk +=1;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ dataMap.put("hRisk",hRisk);
|
|
|
+ dataMap.put("mRisk",mRisk);
|
|
|
+ dataMap.put("lRisk",lRisk);
|
|
|
+ Calendar instance1 = Calendar.getInstance();
|
|
|
+ String dateEnd = new SimpleDateFormat("yyyy年MM月dd日").format(instance1.getTime());
|
|
|
+ instance1.set(instance1.get(Calendar.YEAR)-2, Calendar.JANUARY,1);
|
|
|
+ String dataBegin = new SimpleDateFormat("yyyy年MM月dd日").format(instance1.getTime());
|
|
|
+ dataMap.put("round",dataBegin+"-"+dateEnd);
|
|
|
+ String companyName = String.valueOf(sheetBusiness.getRow(1).getCell(0));
|
|
|
+ XWPFTemplate.compile("./pdftemplate/最新模板20240820-1.docx").render(dataMap).writeToFile(String.format("./pdftemplate/%s.docx",companyName));
|
|
|
+ File outputFile = new File(String.format("./pdftemplate/%s.pdf",companyName));
|
|
|
+ WordUtils.word2pdfAspose(String.format("./pdftemplate/%s.docx",companyName),outputFile);
|
|
|
return success();
|
|
|
}
|
|
|
|
|
@@ -1033,19 +1253,18 @@ public class GenerateReport extends BaseController {
|
|
|
String color = "";
|
|
|
switch (riskLevel){
|
|
|
case 1:
|
|
|
- color = "3333FF";
|
|
|
+ color = "0768dd";
|
|
|
break;
|
|
|
case 2:
|
|
|
- color = "FF9933";
|
|
|
+ color = "e0a500";
|
|
|
break;
|
|
|
case 3:
|
|
|
- color = "FF3333";
|
|
|
+ color = "f20606";
|
|
|
}
|
|
|
return color;
|
|
|
}
|
|
|
|
|
|
private TextRenderData getLevelString(int riskLevel) {
|
|
|
-
|
|
|
String text ="";
|
|
|
switch (riskLevel){
|
|
|
case 1:
|
|
@@ -1061,15 +1280,22 @@ public class GenerateReport extends BaseController {
|
|
|
return Texts.of(text).color(getColor(riskLevel)).create();
|
|
|
}
|
|
|
|
|
|
+
|
|
|
FilePictureRenderData getPicPath(int riskLevel){
|
|
|
+ PictureStyle pictureStyle = new PictureStyle();
|
|
|
+ pictureStyle.setWidth(100);
|
|
|
+ pictureStyle.setHeight(100);
|
|
|
+ FilePictureRenderData filePictureRenderData ;
|
|
|
if(riskLevel == 0){
|
|
|
return null;
|
|
|
} else if (riskLevel == 1) {
|
|
|
- return new FilePictureRenderData("./images/low-risk.jpg", PictureType.JPEG);
|
|
|
+ filePictureRenderData = new FilePictureRenderData("./images/low-risk.png", PictureType.PNG);
|
|
|
} else if (riskLevel ==2) {
|
|
|
- return new FilePictureRenderData("./images/mid-risk.jpg", PictureType.JPEG);
|
|
|
+ filePictureRenderData = new FilePictureRenderData("./images/mid-risk.png", PictureType.PNG);
|
|
|
}else {
|
|
|
- return new FilePictureRenderData("./images/high-risk.jpg", PictureType.JPEG);
|
|
|
+ filePictureRenderData = new FilePictureRenderData("./images/high-risk.png", PictureType.PNG);
|
|
|
}
|
|
|
+ filePictureRenderData.setPictureStyle(pictureStyle);
|
|
|
+ return filePictureRenderData;
|
|
|
}
|
|
|
}
|