Merge pull request #1673 from dataease/pr@dev@dev@fix_empty_tag

fix: 我分享的仪表板展示空tags
This commit is contained in:
fit2cloud-chenyw 2022-01-20 14:01:04 +08:00 committed by GitHub
commit 87af7c9bc0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -315,7 +315,9 @@ public class ShareService {
}
public List<PanelShareOutDTO> queryTargets(String panelId) {
return extPanelShareMapper.queryTargets(panelId);
List<PanelShareOutDTO> targets = extPanelShareMapper.queryTargets(panelId);
if (CollectionUtils.isEmpty(targets)) return new ArrayList<>();
return targets.stream().filter(item -> StringUtils.isNotEmpty(item.getTargetName())).collect(Collectors.toList());
}
public void removeShares(PanelShareRemoveRequest removeRequest) {