2 <!-- display a single heading as MARC -->
3 <ng-template #fieldAsMarc let-field="field">
4 <span>{{field.tag}} {{field.ind1}} {{field.ind2}}</span>
5 <span *ngFor="let sf of field.subfields">
6 <span class="text-danger" i18n>‡</span>{{sf[0]}} {{sf[1]}}
10 <!-- MARC edit-ception! -->
11 <eg-marc-editor-dialog #marcEditDialog recordType="authority">
12 </eg-marc-editor-dialog>
14 <!-- display a single heading as MARC or as the human friendlier string -->
15 <ng-template #headingField
16 let-field="field" let-from="from" let-also="also" let-authId="authId">
17 <button class="btn btn-sm p-1 me-1"
18 [ngClass]="{'btn-outline-primary': !(from || also), 'btn-outline-info': (from || also)}"
19 (click)="applyHeading(field, authId)" i18n>Apply</button>
20 <ng-container *ngIf="showAs === 'heading'">
21 <span *ngIf="from" i18n>See From: {{field.heading}}</span>
22 <span *ngIf="also" i18n>See Also: {{field.heading}}</span>
23 <span *ngIf="!from && !also" i18n>{{field.heading}}</span>
25 <ng-container *ngIf="showAs === 'marc'">
27 *ngTemplateOutlet="fieldAsMarc;context:{field:field}">
32 <ng-template #dialogContent>
33 <div class="modal-header bg-info">
34 <h4 class="modal-title" i18n>Manage Authority Links</h4>
35 <button type="button" class="btn-close btn-close-white"
36 i18n-aria-label aria-label="Close" (click)="close()"></button>
38 <div class="modal-body">
39 <div class="row border-bottom border-secondary p-2 d-flex">
40 <div class="flex-1 fw-bold p-1 ps-2 pt-2 ms-2">
41 <div>{{bibField.tag}} {{bibField.ind1}} {{bibField.ind2}}</div>
43 <div *ngFor="let sf of bibField.subfields">
44 <div class="form-check form-check-inline">
45 <input class="form-check-input" id="search-subfield-{{sf[0]}}"
46 type="checkbox" [disabled]="!isControlledBibSf(sf[0])"
47 [(ngModel)]="selectedSubfields[sf[0]]"
48 (change)="getPage(pager.offset)"/>
50 <span class="text-danger" i18n>‡</span>
52 <label class="form-label form-check-label" for="search-subfield-{{sf[0]}}" i18n>
58 <div class="ms-2 p-1">
59 <div class="mb-1" i18n>Create new authority from this field</div>
61 <button class="btn btn-outline-info"
62 (click)="createNewAuthority()">Immediately</button>
63 <button class="btn btn-outline-info ms-2"
64 (click)="createNewAuthority(true)">Create and Edit</button>
68 <div class="row border-bottom border-secondary p-2 d-flex">
70 <button class="btn btn-outline-dark" [disabled]="pager.offset === 0"
71 (click)="getPage(0)" i18n>Start</button>
72 <button class="btn btn-outline-dark ms-2"
73 (click)="getPage(-1)" i18n>Previous</button>
74 <button class="btn btn-outline-dark ms-2"
75 (click)="getPage(1)" i18n>Next</button>
77 <div class="pt-2 mb-2">
78 <div class="form-check form-check-inline">
79 <input class="form-check-input" type="radio" value="heading"
80 [(ngModel)]="showAs" name='show-as-heading' id="show-as-heading">
81 <label class="form-label form-check-label" for="show-as-heading" i18n>Show As Heading</label>
83 <div class="form-check form-check-inline">
84 <input class="form-check-input" type="radio" value="marc"
85 [(ngModel)]="showAs" name='show-as-heading' id="show-as-marc">
86 <label class="form-label form-check-label" for="show-as-marc" i18n>Show As MARC</label>
90 <ul *ngFor="let entry of browseData">
91 <li class="d-flex mt-1">
94 *ngTemplateOutlet="headingField;context:{field:entry.main_heading, authId: entry.authority_id}">
97 <div class="fst-italic">
99 i18n-title title="Authority Record ID {{entry.authority_id}}"
100 routerLink="/staff/cat/authority/edit/{{entry.authority_id}}">
101 #{{entry.authority_id}}
105 <ul *ngFor="let from of entry.see_froms">
108 *ngTemplateOutlet="headingField;context:{field:from, from:true}">
112 <ul *ngFor="let also of entry.see_alsos">
115 *ngTemplateOutlet="headingField;context:{field:also, also:true}">