1 <eg-staff-banner bannerText="Org Unit Type Configuration" i18n-bannerText>
4 <ng-template #editStrTmpl i18n>Org Unit Type Update Succeeded</ng-template>
5 <eg-string #editString [template]="editStrTmpl"></eg-string>
7 <ng-template #createStrTmpl i18n>Org Unit Type Successfully Created</ng-template>
8 <eg-string #createString [template]="createStrTmpl"></eg-string>
10 <ng-template #errorStrTmpl i18n>Org Unit Type Update Failed</ng-template>
11 <eg-string #errorString [template]="errorStrTmpl"></eg-string>
13 <eg-confirm-dialog #delConfirm
14 i18n-dialogTitle i18n-dialogBody
15 dialogTitle="Confirm Delete"
16 dialogBody="Delete Org Unit Type {{selected ? selected.label : ''}}?">
19 <eg-fm-record-editor #editDialog idlClass="aout" readonlyFields="depth,parent"
20 [fieldOptions]="{name:{isRequired:true},opac_label:{isRequired:true}}"
22 </eg-fm-record-editor>
24 <div class="row org-unit-types-row">
25 <div class="col-lg-4 org-unit-types-col-aside">
26 <h3 i18n>Org Unit Types</h3>
27 <eg-tree [tree]="tree" (nodeClicked)="nodeClicked($event)"></eg-tree>
29 <div class="col-lg-8 org-unit-types-col-main">
30 <h3 i18n class="mb-3">Selected Org Unit Type</h3>
31 <ng-container *ngIf="!selected">
32 <div class="alert alert-info fst-italic" i18n>
33 Select an org unit type from the tree on the left.
36 <div *ngIf="selected" class="common-form striped-even">
38 <div class="col-lg-3">
39 <label class="form-label" i18n>Actions for Selected: </label>
41 <div class="col-lg-9">
42 <button type="button" class="btn btn-info me-2" (click)="edit()" i18n>Edit</button>
43 <button type="button" class="btn btn-info me-2" (click)="addChild()" i18n>Add Child</button>
44 <button type="button" class="btn btn-destroy me-2" (click)="remove()"
45 [disabled]="selected.callerData.aout.children().length > 0 || selected.callerData.orgCount > 0" i18n>Delete</button>
49 <!-- TODO: use FmRecordEditPaneComponent once it exists -->
50 <div class="col-lg-4">
51 <label class="form-label" i18n>Name: </label>
53 <div class="col-lg-8 fw-bold">
54 {{selected.callerData.aout.name()}}
58 <div class="col-lg-4">
59 <label class="form-label" i18n>Label: </label>
61 <div class="col-lg-8 fw-bold">
62 {{selected.callerData.aout.opac_label()}}
66 <div class="col-lg-4">
67 <label class="form-label" i18n>Can Have Users: </label>
69 <div class="col-lg-8 fw-bold">
70 <!-- TODO: use <eg-bool/> once merged-->
71 {{selected.callerData.aout.can_have_users() === 't'}}
75 <div class="col-lg-4">
76 <label class="form-label" i18n>Can Have Holdings: </label>
78 <div class="col-lg-8 fw-bold">
79 <!-- TODO: use <eg-bool/> once merged-->
80 {{selected.callerData.aout.can_have_vols() === 't'}}
84 <div class="col-lg-4">
85 <label class="form-label" i18n>Depth: </label>
87 <div class="col-lg-8 fw-bold">
88 {{selected.callerData.aout.depth()}}
92 <div class="col-lg-4">
93 <label class="form-label" i18n>Number of Org Units Of This Type: </label>
95 <div class="col-lg-8 fw-bold">
96 {{selected.callerData.orgCount}}