summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing
diff options
context:
space:
mode:
authorfenn-cs <fenn25.fn@gmail.com>2023-09-20 12:53:54 +0100
committernextcloud-command <nextcloud-command@users.noreply.github.com>2023-09-26 06:06:27 +0000
commita3613350f625ce5bf242cd1ff4b11520b28c55ff (patch)
tree8802d24edff5262509470a06839bd3dd5f9cd6a4 /apps/files_sharing
parent2288e8e57101241724c26d2765875342e14528bc (diff)
downloadnextcloud-server-a3613350f625ce5bf242cd1ff4b11520b28c55ff.tar.gz
nextcloud-server-a3613350f625ce5bf242cd1ff4b11520b28c55ff.zip
Auto set password for new email shares
Suggest auto generated password for new public share (mail share). Resolves : https://github.com/nextcloud/server/issues/40493 Signed-off-by: fenn-cs <fenn25.fn@gmail.com> Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
Diffstat (limited to 'apps/files_sharing')
-rw-r--r--apps/files_sharing/src/views/SharingDetailsTab.vue12
1 files changed, 9 insertions, 3 deletions
diff --git a/apps/files_sharing/src/views/SharingDetailsTab.vue b/apps/files_sharing/src/views/SharingDetailsTab.vue
index 429034c4520..199d413d7f8 100644
--- a/apps/files_sharing/src/views/SharingDetailsTab.vue
+++ b/apps/files_sharing/src/views/SharingDetailsTab.vue
@@ -683,11 +683,17 @@ export default {
this.revertSharingPermission = !isCustomPermissions ? selectedPermission : 'custom'
this.setCustomPermissions = isCustomPermissions
},
- initializeAttributes() {
+ async initializeAttributes() {
+ let hasAdvancedAttributes = false
- if (this.isNewShare) return
+ if (this.isNewShare) {
+ if (this.isPasswordEnforced && this.isPublicShare) {
+ this.share.newPassword = await GeneratePassword()
+ this.advancedSectionAccordionExpanded = true
+ }
+ return
+ }
- let hasAdvancedAttributes = false
if (this.isValidShareAttribute(this.share.note)) {
this.writeNoteToRecipientIsChecked = true
hasAdvancedAttributes = true