提交人:陈绍鑫

日期:2025/11/18 17:30
内容:报表
This commit is contained in:
陈绍鑫 2025-11-19 17:52:34 +08:00
parent b2b90154f2
commit e44c69df32
1 changed files with 8 additions and 1 deletions

View File

@ -11,6 +11,8 @@ import kd.bos.db.DB;
import kd.bos.db.DBRoute;
import kd.bos.entity.report.AbstractReportListDataPlugin;
import kd.bos.entity.report.ReportQueryParam;
import kd.bos.logging.Log;
import kd.bos.logging.LogFactory;
import kd.bos.orm.ORM;
import kd.bos.orm.query.QCP;
import kd.bos.orm.query.QFilter;
@ -28,6 +30,8 @@ import java.util.*;
**/
public class PlanReportPlugin extends AbstractReportListDataPlugin {
private static final Log logger = LogFactory.getLog(PlanReportPlugin.class);
//明细字段对应的字段名
public static final Map<String, String> zdm = new HashMap() {{
put("金融机构", "fbankcateid");
@ -88,12 +92,15 @@ public class PlanReportPlugin extends AbstractReportListDataPlugin {
//获取计划编制里的融资计划
QFilter qFilter = new QFilter("name", QCP.equals, "融资计划");
qFilter=qFilter.and(new QFilter("reportperiod",QCP.equals,shkd_qj.getLong("id")));
DynamicObject[] load = BusinessDataServiceHelper.load("fpm_report", "id", qFilter.toArray());
logger.info("找到:"+load.length+"个融资计划");
DynamicObject fpm_report = BusinessDataServiceHelper.loadSingle("fpm_report", qFilter.toArray());
if (fpm_report==null){
logger.info("融资计划未找到");
return DB.queryDataSet(this.getClass().getSimpleName(), DBRoute.of("fi"),"select NULL AS res ");//财务云;
}
long id = fpm_report.getLong("id");
logger.info("id"+id);
StringBuilder dangyuesqlBuilder=getsql(id,zdm,dangyue,shkd_km);
DataSet dangyueres = DB.queryDataSet(this.getClass().getSimpleName(), DBRoute.of("fi"), dangyuesqlBuilder.toString());//财务云
dangyueres= dangyueres.select(DANGYUE_SELECT);