Skip to content

Commit

Permalink
✨ [#1451] -- add showInPDF and showInSummary to form builder
Browse files Browse the repository at this point in the history
  • Loading branch information
sergei-maertens committed May 9, 2022
1 parent 3b023db commit 055274d
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 1 deletion.
16 changes: 16 additions & 0 deletions src/openforms/js/components/form/edit/options.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,27 @@ const DESCRIPTION = {
label: 'Description'
};

const SHOW_IN_SUMMARY = {
type: 'checkbox',
key: 'showInSummary',
label: 'Show in summary',
tooltip: 'Whether to show this value in the submission summary',
};

const SHOW_IN_EMAIL = {
type: 'checkbox',
key: 'showInEmail',
label: 'Show in email',
tooltip: 'Whether to show this value in the confirmation email'
};

const SHOW_IN_PDF = {
type: 'checkbox',
key: 'showInPDF',
label: 'Show in PDF',
tooltip: 'Whether to show this value in the confirmation PDF'
};

const MULTIPLE = {
type: 'checkbox',
key: 'multiple',
Expand Down Expand Up @@ -85,7 +99,9 @@ export {
LABEL,
KEY,
DESCRIPTION,
SHOW_IN_SUMMARY,
SHOW_IN_EMAIL,
SHOW_IN_PDF,
MULTIPLE,
HIDDEN,
CLEAR_ON_HIDE,
Expand Down
16 changes: 15 additions & 1 deletion src/openforms/js/components/form/edit/tabs.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ import {
LABEL,
KEY,
DESCRIPTION,
SHOW_IN_SUMMARY,
SHOW_IN_EMAIL,
SHOW_IN_PDF,
MULTIPLE,
HIDDEN,
CLEAR_ON_HIDE,
Expand All @@ -19,14 +21,26 @@ import {
* Define the tabs available when editing components in the form builder.
*/


const PRESENTATION = {
type: 'panel',
title: 'Presentation',
key: 'presentationConfig',
components: [
SHOW_IN_SUMMARY,
SHOW_IN_EMAIL,
SHOW_IN_PDF,
]
};

const BASIC = {
key: 'basic',
label: 'Basic',
components: [
LABEL,
KEY,
DESCRIPTION,
SHOW_IN_EMAIL,
PRESENTATION,
MULTIPLE,
HIDDEN,
CLEAR_ON_HIDE,
Expand Down

0 comments on commit 055274d

Please sign in to comment.