1821349743@qq.com
2023-04-03 3df221b0a98cde4562471727a6ad41ffafbe39a8
picc of version
已修改2个文件
27 ■■■■ 文件已修改
src/main/java/com/product/server/report/service/DataListReportService.java 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/product/server/report/service/ReportConfigService.java 23 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/product/server/report/service/DataListReportService.java
@@ -132,8 +132,10 @@
            if (preX != x || preY != y) {
                fieldConfigObj = new JSONObject();
                areaList.add(fieldConfigObj);
            } else {
            } else if (areaList.size() > 0) {
                fieldConfigObj = areaList.get(areaList.size() - 1);
            } else {
                continue;
            }
            fieldConfigObj.put(attrFse.getString(CmnConst.ATTR_NAME), attrFse.getString(CmnConst.ATTR_VALUE));
            fieldConfigObj.put(CmnConst.ATTR_X, x);
src/main/java/com/product/server/report/service/ReportConfigService.java
@@ -8,6 +8,7 @@
import com.product.admin.service.UpdateLoginUserInfoService;
import com.product.common.lang.StringUtils;
import com.product.core.cache.DataPoolCacheImpl;
import com.product.core.config.CoreConst;
import com.product.core.dao.BaseDao;
import com.product.core.entity.DataTableEntity;
import com.product.core.entity.FieldSetEntity;
@@ -24,9 +25,7 @@
import org.springframework.stereotype.Component;
import javax.xml.crypto.Data;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.*;
@Component
public class ReportConfigService extends AbstractBaseService implements IReportConfigService {
@@ -136,8 +135,9 @@
        if (StringUtils.isEmpty(fse.getString(CmnConst.PAGE_SIZE))) {
            fse.setValue(CmnConst.PAGE_SIZE, null);
        }
        System.out.println(System.currentTimeMillis());
        String uuid = baseDao.add(fse);
        System.out.println(System.currentTimeMillis());
        if ("1".equals(fse.getString(CmnConst.RELATE_FLAG))) {
            // 重新设置缓存
@@ -207,10 +207,11 @@
                String tempUUID;
                for (int i = 0; i < reportAttrDte.getRows(); i++) {
                    tempFse = reportAttrDte.getFieldSetEntity(i);
                    tempFse.setValue("report_type_attr_show_name", tempFse.getString(CmnConst.REPORT_TYPE_ATTR));
                    tempFse.setValue(CmnConst.REPORT_TYPE_ATTR, reportTypeAttrMap.get(tempFse.getString(CmnConst.REPORT_TYPE_ATTR)));
                    tempFse.setValue(CmnConst.CELL_POSITION_X, tempFse.getString(CmnConst.ATTR_X));
                    tempFse.setValue(CmnConst.CELL_POSITION_Y, tempFse.getString(CmnConst.ATTR_Y));
                    String x = tempFse.getString(CmnConst.ATTR_X);
                    tempObj = new JSONObject();
                    tempObj.put(CmnConst.ATTR_REPORT_AREA, tempFse.getString(CmnConst.ATTR_REPORT_AREA));
                    tempObj.put(CmnConst.CELL_POSITION_X, tempFse.getString(CmnConst.CELL_POSITION_X));
@@ -221,6 +222,18 @@
                    if (!StringUtils.isEmpty(tempUUID)) {
                        tempFse.setValue(CmnConst.UUID, tempUUID);
                    }
                    if (StringUtils.isEmpty(tempFse.getString(CmnConst.REPORT_TYPE_ATTR_VALUE))) {
                        //属性值是否为空
                        if (StringUtils.isEmpty(tempFse.getUUID())) {
                            //没有保存过的属性
                            reportAttrDte.removeFieldSetEntity(i);
                            i--;
                        } else {
                            //标记为删除
                            tempFse.setValue(CoreConst.SYSTEM_DATA_OPERATE_TYPE, "del");
                        }
                        continue;
                    }
                }
            }
        }