gd-sprest-bs 10.2.3 → 10.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -202,7 +202,8 @@ exports.ListForm.renderDisplayForm = function (props) {
202
202
  var mapper = {};
203
203
  var rows = [];
204
204
  // See if we are rendering attachments
205
- if (props.info.attachments) {
205
+ var displayAttachments = typeof (props.displayAttachments) === "boolean" ? props.displayAttachments : true;
206
+ if (props.info.attachments && displayAttachments) {
206
207
  // Render the attachments
207
208
  rows.push({
208
209
  columns: [{
@@ -432,7 +433,8 @@ exports.ListForm.renderEditForm = function (props) {
432
433
  size: 100
433
434
  });
434
435
  // See if we are rendering attachments
435
- if (props.info.attachments) {
436
+ var displayAttachments = typeof (props.displayAttachments) === "boolean" ? props.displayAttachments : true;
437
+ if (props.info.attachments && displayAttachments) {
436
438
  // Set a default field
437
439
  // This will help w/ the onControlRendering/ed events to not have a null value for this parameter
438
440
  props.info.fields["Attachments"] = {};