From: Michael Shamoon <4887959+shamoon@users.noreply.github.com> Date: Sat, 10 Dec 2022 01:51:01 +0000 (-0800) Subject: Support bulk edit owner X-Git-Tag: v1.14.0-beta.rc1~109^2~41 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6dc5c1de3293f0e591685b9b0381f424c325c161;p=thirdparty%2Fpaperless-ngx.git Support bulk edit owner --- diff --git a/src-ui/src/app/components/common/permissions-dialog/permissions-dialog.component.html b/src-ui/src/app/components/common/permissions-dialog/permissions-dialog.component.html index 1f23cecd91..e452c8144f 100644 --- a/src-ui/src/app/components/common/permissions-dialog/permissions-dialog.component.html +++ b/src-ui/src/app/components/common/permissions-dialog/permissions-dialog.component.html @@ -5,24 +5,10 @@ diff --git a/src-ui/src/app/components/common/permissions-dialog/permissions-dialog.component.ts b/src-ui/src/app/components/common/permissions-dialog/permissions-dialog.component.ts index 0d7b07c000..c786be5df8 100644 --- a/src-ui/src/app/components/common/permissions-dialog/permissions-dialog.component.ts +++ b/src-ui/src/app/components/common/permissions-dialog/permissions-dialog.component.ts @@ -27,20 +27,17 @@ export class PermissionsDialogComponent implements OnInit { title = $localize`Set Permissions` form = new FormGroup({ - set_permissions: new FormGroup({ - view: new FormGroup({ - users: new FormControl([]), - groups: new FormControl([]), - }), - change: new FormGroup({ - users: new FormControl([]), - groups: new FormControl([]), - }), - }), + permissions_form: new FormControl(), }) get permissions() { - return this.form.value['set_permissions'] + console.log(this.form.get('permissions_form')) + + return { + owner: this.form.get('permissions_form')?.value['owner'], + set_permissions: + this.form.get('permissions_form')?.value['set_permissions'], + } } @Input() diff --git a/src-ui/src/app/components/document-detail/document-detail.component.html b/src-ui/src/app/components/document-detail/document-detail.component.html index 0384e976ca..336d722c31 100644 --- a/src-ui/src/app/components/document-detail/document-detail.component.html +++ b/src-ui/src/app/components/document-detail/document-detail.component.html @@ -181,7 +181,9 @@
  • Permissions - +
    + +
  • diff --git a/src-ui/src/app/components/document-detail/document-detail.component.ts b/src-ui/src/app/components/document-detail/document-detail.component.ts index 6be68e5d10..76bb2099f5 100644 --- a/src-ui/src/app/components/document-detail/document-detail.component.ts +++ b/src-ui/src/app/components/document-detail/document-detail.component.ts @@ -209,7 +209,7 @@ export class DocumentDetailComponent this.openDocumentService.getOpenDocument(this.documentId) ) } else { - this.openDocumentService.openDocument(doc, false) + this.openDocumentService.openDocument(doc) this.updateComponent(doc) } diff --git a/src-ui/src/app/components/document-list/bulk-editor/bulk-editor.component.html b/src-ui/src/app/components/document-list/bulk-editor/bulk-editor.component.html index cca53552c0..9c7c87d580 100644 --- a/src-ui/src/app/components/document-list/bulk-editor/bulk-editor.component.html +++ b/src-ui/src/app/components/document-list/bulk-editor/bulk-editor.component.html @@ -69,7 +69,7 @@
    -
    +