1 <eg-confirm-dialog #confirmDelVol
2 i18n-dialogTitle i18n-dialogBody
3 dialogTitle="Delete Call Number?"
4 dialogBody="Delete {{deleteVolCount}} Call Number(s) and All Associated Item(s)?">
7 <eg-confirm-dialog #confirmDelCopy
8 i18n-dialogTitle i18n-dialogBody
9 dialogTitle="Delete Item?"
10 dialogBody="Delete {{deleteCopyCount}} Item(s)?">
13 <div *ngIf="!volcopy.defaults.visible.batch_actions"
14 class="bg-faint mb-2 p-1 border border-dark rounded">
15 <button class="btn btn-sm btn-outline-dark label-with-material-icon"
16 (click)="toggleBatchVisibility()">
17 <span i18n>Batch Actions</span>
18 <span class="material-icons">unfold_more</span>
22 <div *ngIf="volcopy.defaults.visible.batch_actions"
23 class="row d-flex bg-faint mb-2 pb-1 pt-1 border border-dark rounded">
24 <div class="p-1" [ngStyle]="{flex: flexAt(1)}">
25 <div><label class="font-weight-bold" i18n> </label></div>
26 <button class="btn btn-sm btn-outline-dark label-with-material-icon"
27 (click)="toggleBatchVisibility()">
28 <span i18n>Batch Actions</span>
29 <span class="material-icons">unfold_less</span>
32 <div class="p-1" [ngStyle]="{flex: flexAt(3)}">
33 <ng-container *ngIf="displayColumn('classification')">
34 <div><label class="font-weight-bold" i18n>Classification</label></div>
36 <eg-combobox [smallFormControl]="true" [(ngModel)]="batchVolClass">
37 <eg-combobox-entry *ngFor="let cls of volcopy.commonData.acn_class"
38 [entryId]="cls.id()" [entryLabel]="cls.name()">
44 <div class="p-1" [ngStyle]="{flex: flexAt(4)}">
45 <ng-container *ngIf="displayColumn('prefix')">
46 <div><label class="font-weight-bold" i18n>Prefix</label></div>
48 <eg-combobox [smallFormControl]="true" [(ngModel)]="batchVolPrefix">
49 <eg-combobox-entry *ngFor="let pfx of volcopy.commonData.acn_prefix"
50 [entryId]="pfx.id()" [entryLabel]="pfx.label()">
56 <div class="p-1" [ngStyle]="{flex: flexAt(5)}">
58 <label class="font-weight-bold" i18n>
63 <eg-combobox [smallFormControl]="true"
64 [allowFreeText]="true" [(ngModel)]="batchVolLabel">
65 <eg-combobox-entry *ngFor="let label of recordVolLabels"
66 [entryId]="label" [entryLabel]="label">
71 <div class="p-1" [ngStyle]="{flex: flexAt(6)}">
72 <ng-container *ngIf="displayColumn('suffix')">
73 <div><label class="font-weight-bold" i18n>Suffix</label></div>
75 <eg-combobox [smallFormControl]="true" [(ngModel)]="batchVolSuffix">
76 <eg-combobox-entry *ngFor="let sfx of volcopy.commonData.acn_suffix"
77 [entryId]="sfx.id()" [entryLabel]="sfx.label()">
83 <div class="p-1" [ngStyle]="{flex: flexAt(7)}">
84 <div><label class="font-weight-bold" i18n>Batch</label></div>
86 <button class="btn btn-sm btn-outline-dark label-with-material-icon"
87 (click)="batchVolApply()">
88 <span i18n>Apply</span>
89 <span class="material-icons">arrow_downward</span>
93 <!-- needed for consistent column widths -->
94 <div class="p-1" [ngStyle]="{flex: flexAt(8)}"></div>
95 <div class="p-1" [ngStyle]="{flex: flexAt(9)}"></div>
96 <div class="p-1" [ngStyle]="{flex: flexAt(10)}"></div>
97 <div class="p-1" [ngStyle]="{flex: flexAt(11)}"></div>
100 <div class="row d-flex mt-2 mb-2">
101 <div class="p-1" [ngStyle]="{flex: flexAt(1)}">
102 <span class="font-weight-bold" i18n>Owning Library
103 <ng-container *ngIf="expand !== 1">
104 <button title="Expand Column" i18n-title
105 class="material-icon-button" (click)="expand = 1">
109 <ng-container *ngIf="expand === 1">
110 <button title="Shrink Column" i18n-title
111 class="material-icon-button" (click)="expand = null">
117 <div class="p-1" [ngStyle]="{flex: flexAt(3)}">
118 <ng-container *ngIf="displayColumn('classification')">
119 <span class="font-weight-bold" i18n>Classification
120 <ng-container *ngIf="expand !== 3">
121 <button title="Expand Column" i18n-title
122 class="material-icon-button" (click)="expand = 3">
126 <ng-container *ngIf="expand === 3">
127 <button title="Shrink Column" i18n-title
128 class="material-icon-button" (click)="expand = null">
135 <div class="p-1" [ngStyle]="{flex: flexAt(4)}">
136 <ng-container *ngIf="displayColumn('prefix')">
137 <span class="font-weight-bold" i18n>Prefix
138 <ng-container *ngIf="expand !== 4">
139 <button title="Expand Column" i18n-title
140 class="material-icon-button" (click)="expand = 4">
144 <ng-container *ngIf="expand === 4">
145 <button title="Shrink Column" i18n-title
146 class="material-icon-button" (click)="expand = null">
153 <div class="p-1" [ngStyle]="{flex: flexAt(5)}">
154 <span class="font-weight-bold" i18n>Call Number Label
155 <ng-container *ngIf="expand !== 5">
156 <button title="Expand Column" i18n-title
157 class="material-icon-button" (click)="expand = 5">
161 <ng-container *ngIf="expand === 5">
162 <button title="Shrink Column" i18n-title
163 class="material-icon-button" (click)="expand = null">
169 <div class="p-1" [ngStyle]="{flex: flexAt(6)}">
170 <ng-container *ngIf="displayColumn('suffix')">
171 <span class="font-weight-bold" i18n>Suffix
172 <ng-container *ngIf="expand !== 6">
173 <button title="Expand Column" i18n-title
174 class="material-icon-button" (click)="expand = 6">
178 <ng-container *ngIf="expand === 6">
179 <button title="Shrink Column" i18n-title
180 class="material-icon-button" (click)="expand = null">
187 <div class="p-1" [ngStyle]="{flex: flexAt(7)}">
188 <label class="font-weight-bold" i18n></label>
191 When hiding the copy_number column, absorb its colum width to
192 take advantage of the space and to ensure the main columns still
193 line up with the batch updater row sitting above
195 <div class="p-1" [ngStyle]="{flex: flexAt(8)}">
196 <span class="font-weight-bold" i18n>Barcode
197 <ng-container *ngIf="expand !== 8">
198 <button title="Expand Column" i18n-title
199 class="material-icon-button" (click)="expand = 8">
203 <ng-container *ngIf="expand === 8">
204 <button title="Shrink Column" i18n-title
205 class="material-icon-button" (click)="expand = null">
211 <div class="p-1" [ngStyle]="{flex: flexAt(9)}">
212 <ng-container *ngIf="displayColumn('copy_number_vc')">
213 <label class="font-weight-bold" i18n>Item #</label>
216 <div class="p-1" [ngStyle]="{flex: flexAt(10)}">
217 <ng-container *ngIf="displayColumn('copy_part')">
218 <span class="font-weight-bold" i18n>Part
219 <ng-container *ngIf="expand !== 10">
220 <button title="Expand Column" i18n-title
221 class="material-icon-button" (click)="expand = 10">
225 <ng-container *ngIf="expand === 10">
226 <button title="Shrink Column" i18n-title
227 class="material-icon-button" (click)="expand = null">
234 <div class="p-1" [ngStyle]="{flex: flexAt(11)}"></div>
237 <ng-container *ngFor="let orgNode of context.orgNodes(); let orgIdx = index">
238 <ng-container *ngFor="let volNode of orgNode.children; let volIdx = index">
239 <ng-container *ngFor="let copyNode of volNode.children; let copyIdx = index">
240 <div class="row d-flex mt-1" [ngClass]="{'vol-row': copyIdx == 0}">
241 <div class="p-1" [ngStyle]="{flex: flexAt(1)}">
243 <div class="flex-1 pl-1">
244 <ng-container *ngIf="copyIdx == 0 && volIdx == 0">
245 <span>{{orgNode.target.shortname()}}</span>
249 <ng-container *ngIf="copyIdx == 0 && volIdx == 0 && (
250 context.sessionType == 'record' || context.sessionType == 'mixed')">
251 <ng-template #addOrgTmpl>
252 <eg-org-select [limitPerms]="['CREATE_VOLUME']"
253 placeholder="Select Location..." i18n-placeholder
254 [hideOrgs]="volcopy.hideVolOrgs"
255 (onChange)="addVol($event); addOrgPopover.close()">
259 <button class="btn btn-sm material-icon-button p-1"
260 placement="bottom" [ngbPopover]="addOrgTmpl"
261 autoClose="outside" #addOrgPopover="ngbPopover"
262 i18n-popoverTitle="Add Call Number For Location"
263 i18n-title title="Add Call Number For Location"
264 (click)="addVolOrg=null">
265 <span class="material-icons">add_circle_outline</span>
271 <div class="p-1" [ngStyle]="{flex: flexAt(3)}">
272 <ng-container *ngIf="displayColumn('classification')">
273 <ng-container *ngIf="copyIdx == 0">
275 [selectedId]="volNode.target.label_class()"
276 [smallFormControl]="true"
278 (onChange)="applyVolValue(volNode.target, 'label_class', $event ? $event.id : null)">
279 <eg-combobox-entry *ngFor="let cls of volcopy.commonData.acn_class"
280 [entryId]="cls.id()" [entryLabel]="cls.name()">
286 <div class="p-1" [ngStyle]="{flex: flexAt(4)}">
287 <ng-container *ngIf="displayColumn('prefix')">
288 <ng-container *ngIf="copyIdx == 0">
290 [selectedId]="volNode.target.prefix()"
292 [smallFormControl]="true"
293 (onChange)="applyVolValue(volNode.target, 'prefix', $event ? $event.id : null)">
295 [entryId]="-1" entryLabel="<None>" i18n-entryLabel>
297 <eg-combobox-entry *ngFor="let pfx of volcopy.commonData.acn_prefix"
298 [entryId]="pfx.id()" [entryLabel]="pfx.label()">
304 <div class="p-1" [ngStyle]="{flex: flexAt(5)}">
305 <ng-container *ngIf="copyIdx == 0">
306 <input class="form-control form-control-sm" type="text"
309 [ngClass]="{invalid: !volNode.target.label()}"
310 [ngModel]="volNode.target.label()"
311 (change)="applyVolValue(volNode.target, 'label', $event.target.value)">
314 <div class="p-1" [ngStyle]="{flex: flexAt(6)}">
315 <ng-container *ngIf="displayColumn('suffix')">
316 <ng-container *ngIf="copyIdx == 0">
318 [selectedId]="volNode.target.suffix()"
320 [smallFormControl]="true"
321 (onChange)="applyVolValue(volNode.target, 'suffix', $event ? $event.id : null)">
323 [entryId]="-1" entryLabel="<None>" i18n-entryLabel>
325 <eg-combobox-entry *ngFor="let sfx of volcopy.commonData.acn_suffix"
326 [entryId]="sfx.id()" [entryLabel]="sfx.label()">
332 <div class="p-1" [ngStyle]="{flex: flexAt(7)}">
333 <ng-container *ngIf="copyIdx == 0">
335 *ngIf="context.sessionType == 'record' || context.sessionType == 'mixed'">
336 <button class="btn btn-sm material-icon-button p-1"
337 (click)="createVols(orgNode, 1)"
338 i18n-title title="Add Call Number">
339 <span class="material-icons">add_circle_outline</span>
342 <ng-template #addVolCountTmpl>
343 <div i18n>Add How Many Call Numbers</div>
344 <div class="form-inline mt-1">
345 <input type="number" class="form-control form-control-sm"
347 (keyup.enter)="createVolsFromPopover(orgNode, addVolsPopover)"
348 [(ngModel)]="addVolCount" [required]="true" min="1"/>
349 <button class="btn btn-sm btn-success ml-1"
350 (click)="createVolsFromPopover(orgNode, addVolsPopover)"
355 <button class="btn btn-sm material-icon-button p-1"
356 [disabled]="context.sessionType == 'copy' || context.sessionType == 'vol'"
357 (shown)="focusElement('add-vol-popover')"
358 placement="bottom" [ngbPopover]="addVolCountTmpl"
359 autoClose="outside" #addVolsPopover="ngbPopover"
360 i18n-popoverTitle="Add Call Numbers"
361 i18n-title title="Add Call Numbers">
362 <span class="material-icons">playlist_add</span>
365 <button class="btn btn-sm material-icon-button p-1"
366 (click)="deleteVol(volNode)"
367 i18n-title title="Remove Call Number">
368 <span class="material-icons">remove_circle_outline</span>
374 <div class="p-1" [ngStyle]="{flex: flexAt(8)}">
377 Barcode value is not required for new copies, since those
378 without a barcode will be ignored.
380 <input type="text" class="form-control form-control-sm"
381 title="{{copyStatLabel(copyNode.target)}}"
382 id="barcode-input-{{copyNode.target.id()}}"
383 spellcheck="false" [required]="true"
384 placeholder="New Barcode..." i18n-placeholder
385 [disabled]="volcopy.copyStatIsMagic(copyNode.target.status())"
387 'text-danger': copyNode.target._dupe_barcode,
388 'invalid': !copyNode.target.barcode() && !copyNode.target.isnew()
390 (change)="barcodeChanged(copyNode.target, $event.target.value)"
391 (ngModelChange)="copyNode.target.barcode($event)"
392 (keyup.enter)="selectNextBarcode(copyNode.target.id())"
393 (keyup.shift.enter)="selectNextBarcode(copyNode.target.id(), true)"
394 (focus)="$event.target.select()"
395 [ngModel]="copyNode.target.barcode()"
396 (ngModelChange)="applyCopyValue(copyNode.target, 'barcode', $event)"/>
398 <div *ngIf="copyNode.target._dupe_barcode"
399 class="alert alert-danger font-italic p-1" i18n>
403 <div class="p-1" [ngStyle]="{flex: flexAt(9)}">
404 <ng-container *ngIf="displayColumn('copy_number_vc')">
405 <input type="number" min="1" class="form-control form-control-sm"
406 [ngModel]="copyNode.target.copy_number()"
407 (ngModelChange)="applyCopyValue(copyNode.target, 'copy_number', $event)"/>
410 <div class="p-1" [ngStyle]="{flex: flexAt(10)}">
411 <ng-container *ngIf="displayColumn('copy_part')">
413 [selectedId]="copyNode.target.parts()[0] ? copyNode.target.parts()[0].id() : null"
414 [smallFormControl]="true" [allowFreeText]="true"
415 (onChange)="copyPartChanged(copyNode, $event)">
417 *ngFor="let part of volcopy.bibParts[volNode.target.record()]"
418 [entryId]="part.id()" [entryLabel]="part.label()">
423 <div class="p-1" [ngStyle]="{flex: flexAt(11)}">
424 <ng-container *ngIf="context.sessionType != 'copy'">
426 <button class="btn btn-sm material-icon-button p-1"
427 (click)="createCopies(volNode, 1)" i18n-title title="Add Item">
428 <span class="material-icons">add_circle_outline</span>
431 <ng-template #addCopyCountTmpl>
432 <div i18n>Add How Many Items</div>
433 <div class="form-inline mt-1">
434 <input type="number" class="form-control form-control-sm"
435 id="add-copy-popover"
436 (keyup.enter)="createCopiesFromPopover(volNode, addCopiesPopover)"
437 [(ngModel)]="addCopyCount" [required]="true" min="1"/>
438 <button class="btn btn-sm btn-success ml-1"
439 (click)="createCopiesFromPopover(volNode, addCopiesPopover)"
444 <button class="btn btn-sm material-icon-button p-1"
445 placement="left" [ngbPopover]="addCopyCountTmpl"
446 autoClose="outside" #addCopiesPopover="ngbPopover"
447 i18n-popoverTitle="Add Items" i18n-title title="Add Items"
448 (shown)="focusElement('add-copy-popover')">
449 <span class="material-icons">playlist_add</span>
452 <button class="btn btn-sm material-icon-button p-1"
453 (click)="deleteCopy(copyNode)" i18n-title title="Remove Item">
454 <span class="material-icons">remove_circle_outline</span>