Skip to content

Commit

Permalink
[Bug]: Changing Data-Hub display of fields to Names instead of Titles (
Browse files Browse the repository at this point in the history
…#575)

* Fix: Display field name if title is empty instead of "Root"

* Update src/Resources/public/js/fieldConfigDialog.js

Co-authored-by: Sebastian Blank <[email protected]>

Co-authored-by: Sebastian Blank <[email protected]>
  • Loading branch information
robertSt7 and blankse authored Aug 2, 2022
1 parent 8ff7be0 commit e3f1b3b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Resources/public/js/fieldConfigDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ pimcore.plugin.datahub.fieldConfigDialog = Class.create({
child = child[0];
} else {
var attributes = nodeConf.attributes;
var text = ts(attributes.label);
let text = attributes.label ? t(attributes.label) : `(${attributes.attribute})`;

if (attributes.dataType !== "system" && this.showFieldname && attributes.key) {
text = text + " (" + attributes.key.replace("~", ".") + ")";
Expand Down

0 comments on commit e3f1b3b

Please sign in to comment.