Skip to content

Commit

Permalink
Merge pull request #38 from apostrophecms/pro-4965-relationship-max-1
Browse files Browse the repository at this point in the history
only one form in form widget relationship
  • Loading branch information
haroun committed Oct 12, 2023
2 parents cb72eff + db3dadd commit 57a007f
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ We use the default express connect-multiparty size limits. The rule is checked b
This can now be disabled.
* Add divider widget (`<hr>` tag) to form widgets.

### Fixes

* To avoid confusion, we can now select only one form when editing the form widget relationship to form field ('Form to display'). Note that selecting more than one form never had any useful effect.

## 1.1.1 (2023-02-17)

### Fixes
Expand Down
3 changes: 2 additions & 1 deletion modules/@apostrophecms/form-widget/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@ module.exports = {
label: 'aposForm:widgetFormSelect',
type: 'relationship',
withType: '@apostrophecms/form',
required: true
required: true,
max: 1
}
}
},
Expand Down
1 change: 1 addition & 0 deletions modules/@apostrophecms/form-widget/ui/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ export default () => {
try {
input.recaptcha = await recaptcha.getToken(el);
} catch (error) {
// eslint-disable-next-line
console.error('reCAPTCHA execution error:', error);
apos.util.addClass(recaptchaError, 'apos-form-visible');
return null;
Expand Down

0 comments on commit 57a007f

Please sign in to comment.