Skip to content

Commit

Permalink
[Improvement]: Make depedencies hideable based on config (#79)
Browse files Browse the repository at this point in the history
  • Loading branch information
kingjia90 authored Jun 18, 2024
1 parent 2c3934b commit 393fa4f
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions public/js/document/printpage.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,9 @@ pimcore.document.printpage = Class.create(pimcore.document.printabstract, {
this.versions = new pimcore.document.versions(this);
}

this.dependencies = new pimcore.element.dependencies(this, "document");
if (typeof pimcore.settings.dependency === 'undefined' || pimcore.settings.dependency) {
this.dependencies = new pimcore.element.dependencies(this, "document");
}
this.preview = new pimcore.document.pages.preview(this);
this.pdfpreview = new pimcore.document.printpages.pdfpreview(this);
this.workflows = new pimcore.element.workflows(this, "document");
Expand All @@ -65,7 +67,9 @@ pimcore.document.printpage = Class.create(pimcore.document.printabstract, {
items.push(this.versions.getLayout());
}

items.push(this.dependencies.getLayout());
if (typeof this.dependencies !== "undefined") {
items.push(this.dependencies.getLayout());
}

if (user.isAllowed("notes_events")) {
items.push(this.notes.getLayout());
Expand Down

0 comments on commit 393fa4f

Please sign in to comment.