diff --git a/backend/src/main/java/io/dataease/service/chart/ChartViewService.java b/backend/src/main/java/io/dataease/service/chart/ChartViewService.java index 395598d620..37838d15c6 100644 --- a/backend/src/main/java/io/dataease/service/chart/ChartViewService.java +++ b/backend/src/main/java/io/dataease/service/chart/ChartViewService.java @@ -208,6 +208,13 @@ public class ChartViewService { }.getType()); List drill = new Gson().fromJson(view.getDrillFields(), new TypeToken>() { }.getType()); + // 获取对应数据集行权限 + DatasetTableField datasetTableFieldObj = DatasetTableField.builder().tableId(view.getTableId()).checked(Boolean.TRUE).build(); + List fields = dataSetTableFieldsService.list(datasetTableFieldObj); + DatasetTable datasetTable = dataSetTableService.get(view.getTableId()); + List permissionFields = dataSetTableService.getCustomFilters(fields, datasetTable); + fieldCustomFilter.addAll(permissionFields); + for (ChartFieldCustomFilterDTO ele : fieldCustomFilter) { ele.setField(dataSetTableFieldsService.get(ele.getId())); }