22
22
{{ t('forms', 'Allow multiple responses per person') }}
23
23
</NcCheckboxRadioSwitch>
24
24
<NcCheckboxRadioSwitch
25
- v-tooltip="disableAllowEditExplanation"
26
- :checked="allowEdit"
25
+ :model-value="form.allowEdit"
27
26
type="switch"
28
- :disabled="disableAllowEdit"
29
- @update:checked="onAllowEditChange">
30
- {{ t('forms', 'Allow editing responses per person') }}
27
+ @update:model-value="onAllowEditChange">
28
+ {{ t('forms', 'Allow editing own responses') }}
31
29
</NcCheckboxRadioSwitch>
32
30
<NcCheckboxRadioSwitch
33
31
:checked="formExpires"
@@ -197,22 +195,13 @@ export default {
197
195
* Submit Multiple is disabled, if it cannot be controlled.
198
196
*/
199
197
disableSubmitMultiple() {
200
- return this.hasPublicLink || this.form.allowEdit || this.form. isAnonymous
198
+ return this.hasPublicLink || this.form.isAnonymous
201
199
},
202
200
disableSubmitMultipleExplanation() {
203
201
if (this.disableSubmitMultiple) {
204
202
return t(
205
203
'forms',
206
- 'This can not be controlled, if the form has a public link, stores responses anonymously, or the response can be edited.',
207
- )
208
- }
209
- return ''
210
- },
211
- disableAllowEditExplanation() {
212
- if (this.disableAllowEdit) {
213
- return t(
214
- 'forms',
215
- 'This can not be controlled, if the form has a public link, stores responses anonymously, or multiple responses are allowed.',
204
+ 'This can not be controlled, if the form has a public link or stores responses anonymously.',
216
205
)
217
206
}
218
207
return ''
@@ -225,22 +214,11 @@ export default {
225
214
)
226
215
},
227
216
228
- // If disabled, submitMultiple will be casted to false if allowEdit is true, else casted to true
217
+ // If disabled, submitMultiple will be casted to true
229
218
submitMultiple() {
230
- if (this.disableSubmitMultiple && this.allowEdit) {
231
- return false
232
- }
233
219
return this.disableSubmitMultiple || this.form.submitMultiple
234
220
},
235
221
236
- // If disabled, allowEdit will be casted to false
237
- allowEdit() {
238
- if (this.disableAllowEdit) {
239
- return false
240
- }
241
- return this.form.allowEdit
242
- },
243
-
244
222
formExpires() {
245
223
return this.form.expires !== 0
246
224
},
0 commit comments