From: Bill Erickson Date: Fri, 8 Jul 2022 21:46:40 +0000 (-0400) Subject: LP1956627 Copy editor shows full org path of copy locations X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=abfc05b396a13c289eb886091d9452412efd07ce;p=evergreen%2Ftadl.git LP1956627 Copy editor shows full org path of copy locations Copy location selector in the copy editor now includes locations from all org units above, at, and below the workstation org unit. Previously, copy locations at "lower" org units were not included. Signed-off-by: Bill Erickson Signed-off-by: Carol Witt --- diff --git a/Open-ILS/src/eg2/src/app/staff/cat/volcopy/copy-attrs.component.html b/Open-ILS/src/eg2/src/app/staff/cat/volcopy/copy-attrs.component.html index 2479ca6b1a..f312fe8e37 100644 --- a/Open-ILS/src/eg2/src/app/staff/cat/volcopy/copy-attrs.component.html +++ b/Open-ILS/src/eg2/src/app/staff/cat/volcopy/copy-attrs.component.html @@ -151,7 +151,7 @@
diff --git a/Open-ILS/src/eg2/src/app/staff/cat/volcopy/copy-attrs.component.ts b/Open-ILS/src/eg2/src/app/staff/cat/volcopy/copy-attrs.component.ts index 805f88835c..d4f41d4ca3 100644 --- a/Open-ILS/src/eg2/src/app/staff/cat/volcopy/copy-attrs.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/cat/volcopy/copy-attrs.component.ts @@ -719,9 +719,16 @@ export class CopyAttrsComponent implements OnInit, AfterViewInit { this.batchAttrs.filter(attr => attr.editing).forEach(attr => attr.save()); } - affectedOrgIds(): number[] { + copyLocationOrgs(): number[] { if (!this.context) { return []; } - return this.context.orgNodes().map(n => n.target.id()); + + // Make sure every org unit represented by the edit batch + // is represented. + const ids = this.context.orgNodes().map(n => n.target.id()); + + // Make sure all locations within the "full path" of our + // workstation org unit are included. + return ids.concat(this.org.fullPath(this.auth.user().ws_ou())); } }