LP1892077 Staff catalog Holdings grid more columns
authorBill Erickson <berickxx@gmail.com>
Thu, 20 Aug 2020 15:07:13 +0000 (11:07 -0400)
committerJane Sandberg <sandbej@linnbenton.edu>
Sat, 22 Aug 2020 20:50:29 +0000 (13:50 -0700)
Adds columns for Parts and Circulate As MARC Type.

Additionally, adds columns for Notes, Tags, and Alerts which display the
count of each linked to a given item.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
Open-ILS/src/eg2/src/app/staff/catalog/record/holdings.component.html
Open-ILS/src/eg2/src/app/staff/catalog/record/holdings.component.ts

index 86f35cb..8ba41a8 100644 (file)
     <eg-grid-column i18n-label label="Call Number Suffix" 
       path="callNum.suffix.label" name="call_number.suffix.label" [hidden]="true">
     </eg-grid-column>
+    <eg-grid-column i18n-label label="Parts" path="copy._monograph_parts"
+      name="monograph_parts" [hidden]="true">
+    </eg-grid-column>
+    <eg-grid-column i18n-label label="Notes" path="copy.notes.length"
+      name="note_count" [hidden]="true">
+    </eg-grid-column>
+    <eg-grid-column i18n-label label="Tags" path="copy.tags.length"
+      name="tag_count" [hidden]="true">
+    </eg-grid-column>
+    <eg-grid-column i18n-label label="Alerts" path="copy.copy_alerts.length"
+      name="alert_count" [hidden]="true">
+    </eg-grid-column>
+    <eg-grid-column i18n-label label="Circulate As MARC Type"
+      path="copy.circ_as_type" [hidden]="true">
+    </eg-grid-column>
     <eg-grid-column i18n-label label="Active/Create Date" 
       path="copy.active_date" datatype="timestamp">
     </eg-grid-column>
index ed31980..3bde851 100644 (file)
@@ -506,8 +506,8 @@ export class HoldingsMaintenanceComponent implements OnInit {
                 }, {
                     flesh: 3,
                     flesh_fields: {
-                        acp: ['status', 'location', 'circ_lib', 'parts',
-                            'age_protect', 'copy_alerts', 'latest_inventory'],
+                        acp: ['status', 'location', 'circ_lib', 'parts', 'notes',
+                            'tags', 'age_protect', 'copy_alerts', 'latest_inventory'],
                         acn: ['prefix', 'suffix', 'copies'],
                         acli: ['inventory_workstation']
                     }
@@ -604,6 +604,11 @@ export class HoldingsMaintenanceComponent implements OnInit {
 
         copyNode.target = copy;
         const stat = Number(copy.status().id());
+        copy._monograph_parts = '';
+        if (copy.parts().length > 0) {
+            copy._monograph_parts =
+                copy.parts().map(p => p.label()).join(',');
+        }
 
         if (stat === 1 /* checked out */ || stat === 16 /* long overdue */) {
             // Avoid looking up circs on items that are not checked out.