ngx-techlify-core 18.66.0 → 18.67.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/entity-files/entity-file.service.mjs +1 -4
- package/esm2022/lib/entity-files/entity-files-view-all.component.mjs +25 -97
- package/esm2022/lib/entity-files/entity-files-view-all.module.mjs +12 -4
- package/esm2022/lib/techlify-icon/techlify-icon.component.mjs +3 -2
- package/fesm2022/ngx-techlify-core.mjs +27 -98
- package/fesm2022/ngx-techlify-core.mjs.map +1 -1
- package/lib/entity-files/entity-file.service.d.ts +1 -2
- package/lib/entity-files/entity-files-view-all.component.d.ts +4 -22
- package/lib/entity-files/entity-files-view-all.module.d.ts +3 -1
- package/package.json +1 -1
|
@@ -13,6 +13,8 @@ import { SearchableSelectorModule } from '../searchable-selector/searchable-sele
|
|
|
13
13
|
import { ReadMoreModule } from '../read-more/read-more.module';
|
|
14
14
|
import { MatProgressBarModule } from "@angular/material/progress-bar";
|
|
15
15
|
import { WrapPipe } from "../pipes/wrap.pipe";
|
|
16
|
+
import { TechlifyIconModule } from '../techlify-icon/techlify-icon.module';
|
|
17
|
+
import { TechlifyDeleteButtonComponent } from '../delete-button/techlify-delete-button.component';
|
|
16
18
|
import * as i0 from "@angular/core";
|
|
17
19
|
export class EntityFilesViewAllModule {
|
|
18
20
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: EntityFilesViewAllModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
@@ -28,7 +30,9 @@ export class EntityFilesViewAllModule {
|
|
|
28
30
|
SearchableSelectorModule,
|
|
29
31
|
ReadMoreModule,
|
|
30
32
|
MatProgressBarModule,
|
|
31
|
-
WrapPipe
|
|
33
|
+
WrapPipe,
|
|
34
|
+
TechlifyIconModule,
|
|
35
|
+
TechlifyDeleteButtonComponent], exports: [EntityFilesViewAllComponent] }); }
|
|
32
36
|
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: EntityFilesViewAllModule, imports: [CommonModule,
|
|
33
37
|
FormsModule,
|
|
34
38
|
ReactiveFormsModule,
|
|
@@ -39,7 +43,9 @@ export class EntityFilesViewAllModule {
|
|
|
39
43
|
TechlifyTaggerTagFormFieldModule,
|
|
40
44
|
SearchableSelectorModule,
|
|
41
45
|
ReadMoreModule,
|
|
42
|
-
MatProgressBarModule
|
|
46
|
+
MatProgressBarModule,
|
|
47
|
+
TechlifyIconModule,
|
|
48
|
+
TechlifyDeleteButtonComponent] }); }
|
|
43
49
|
}
|
|
44
50
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: EntityFilesViewAllModule, decorators: [{
|
|
45
51
|
type: NgModule,
|
|
@@ -58,11 +64,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
58
64
|
SearchableSelectorModule,
|
|
59
65
|
ReadMoreModule,
|
|
60
66
|
MatProgressBarModule,
|
|
61
|
-
WrapPipe
|
|
67
|
+
WrapPipe,
|
|
68
|
+
TechlifyIconModule,
|
|
69
|
+
TechlifyDeleteButtonComponent
|
|
62
70
|
],
|
|
63
71
|
exports: [
|
|
64
72
|
EntityFilesViewAllComponent
|
|
65
73
|
]
|
|
66
74
|
}]
|
|
67
75
|
}] });
|
|
68
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
76
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZW50aXR5LWZpbGVzLXZpZXctYWxsLm1vZHVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25neC10ZWNobGlmeS1jb3JlL3NyYy9saWIvZW50aXR5LWZpbGVzL2VudGl0eS1maWxlcy12aWV3LWFsbC5tb2R1bGUudHMiX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AgICBBY3Rpb25Qb3B1cE1vZHVsZSxcbiAgICAgICAgTWF0ZXJpYWxNb2R1bGUsXG4gICAgICAgIFRlY2hsaWZ5VGFnZ2VyVGFnRm9ybUZpZWxkTW9kdWxlLFxuICAgICAgICBTZWFyY2hhYmxlU2VsZWN0b3JNb2R1bGUsXG4gICAgICAgIFJlYWRNb3JlTW9kdWxlLFxuICAgICAgICBNYXRQcm9ncmVzc0Jhck1vZHVsZSxcbiAgICAgICAgV3JhcFBpcGUsXG4gICAgICAgIFRlY2hsaWZ5SWNvbk1vZHVsZSxcbiAgICAgICAgVGVjaGxpZnlEZWxldGVCdXR0b25Db21wb25lbnRcbiAgICBdLFxuICAgIGV4cG9ydHM6IFtcbiAgICAgICAgRW50aXR5RmlsZXNWaWV3QWxsQ29tcG9uZW50XG4gICAgXVxufSlcbmV4cG9ydCBjbGFzcyBFbnRpdHlGaWxlc1ZpZXdBbGxNb2R1bGUgeyB9XG4iXX0=
|
|
@@ -33,7 +33,8 @@ export class TechlifyIconComponent {
|
|
|
33
33
|
phone: 'fas fa-phone',
|
|
34
34
|
location: 'fas fa-map-marker-alt',
|
|
35
35
|
unlink: 'fas fa-unlink',
|
|
36
|
-
disable_user: 'fas fa-user-slash'
|
|
36
|
+
disable_user: 'fas fa-user-slash',
|
|
37
|
+
swap: 'fas fa-retweet'
|
|
37
38
|
};
|
|
38
39
|
// Map size input to CSS classes
|
|
39
40
|
this.sizeMap = {
|
|
@@ -64,4 +65,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
64
65
|
}], size: [{
|
|
65
66
|
type: Input
|
|
66
67
|
}] } });
|
|
67
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
68
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGVjaGxpZnktaWNvbi5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8u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S1yZXR3ZWV0J1xuICB9O1xuXG4gIC8vIE1hcCBzaXplIGlucHV0IHRvIENTUyBjbGFzc2VzXG4gIHByaXZhdGUgc2l6ZU1hcDogUmVjb3JkPHN0cmluZywgc3RyaW5nPiA9IHtcbiAgICB4czogJ2ZhLXhzJyxcbiAgICBzbTogJ2ZhLXNtJyxcbiAgICBtZDogJ2ZhLW1kJyxcbiAgICBsZzogJ2ZhLWxnJyxcbiAgICB4bDogJ2ZhLTJ4J1xuICB9O1xufSIsIjwhLS0gIEN1c3RvbSBpY29uIC0tPlxuPG5nLWNvbnRhaW5lciAqbmdJZj1cImlzQ3VzdG9tSWNvbihuYW1lKTsgZWxzZSBmYUljb25cIj5cbiAgICA8YXBwLWN1c3RvbS1pY29uIFtuYW1lXT1cIm5hbWVcIj48L2FwcC1jdXN0b20taWNvbj5cbjwvbmctY29udGFpbmVyPlxuXG48IS0tIEZvbnQgQXdlc29tZSAtLT5cbjxuZy10ZW1wbGF0ZSAjZmFJY29uPlxuICAgIDxpIFtuZ0NsYXNzXT1cImljb25DbGFzc1wiPjwvaT5cbjwvbmctdGVtcGxhdGU+Il19
|
|
@@ -1706,9 +1706,6 @@ class EntityFileService extends TechlifyService {
|
|
|
1706
1706
|
super(http, 'entity-files');
|
|
1707
1707
|
this.http = http;
|
|
1708
1708
|
}
|
|
1709
|
-
deleteEntityFile(model) {
|
|
1710
|
-
return this.http.delete(`api/entity-files/${model.id}`).toPromise();
|
|
1711
|
-
}
|
|
1712
1709
|
uploadEntityFile(file, params) {
|
|
1713
1710
|
const formData = new FormData();
|
|
1714
1711
|
formData.append("fileData", file, file.name);
|
|
@@ -3637,7 +3634,8 @@ class TechlifyIconComponent {
|
|
|
3637
3634
|
phone: 'fas fa-phone',
|
|
3638
3635
|
location: 'fas fa-map-marker-alt',
|
|
3639
3636
|
unlink: 'fas fa-unlink',
|
|
3640
|
-
disable_user: 'fas fa-user-slash'
|
|
3637
|
+
disable_user: 'fas fa-user-slash',
|
|
3638
|
+
swap: 'fas fa-retweet'
|
|
3641
3639
|
};
|
|
3642
3640
|
// Map size input to CSS classes
|
|
3643
3641
|
this.sizeMap = {
|
|
@@ -5123,8 +5121,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
5123
5121
|
}]
|
|
5124
5122
|
}] });
|
|
5125
5123
|
|
|
5126
|
-
let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
5124
|
+
let EntityFilesViewAllComponent = class EntityFilesViewAllComponent extends TechlifyListComponent {
|
|
5127
5125
|
constructor(entityFileService, location, alertService, dialog, fb, errorHandler, currentUserService) {
|
|
5126
|
+
super();
|
|
5128
5127
|
this.entityFileService = entityFileService;
|
|
5129
5128
|
this.location = location;
|
|
5130
5129
|
this.alertService = alertService;
|
|
@@ -5138,8 +5137,6 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5138
5137
|
this.viewMode = 'list';
|
|
5139
5138
|
this.fileDropperHeight = '500px';
|
|
5140
5139
|
this.isShowDragDropSection = true;
|
|
5141
|
-
this.documentIds = [];
|
|
5142
|
-
this.isAllSelected = false;
|
|
5143
5140
|
/**
|
|
5144
5141
|
* Should we allow tagging entity-files?
|
|
5145
5142
|
*/
|
|
@@ -5148,7 +5145,6 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5148
5145
|
this.techlifyTagConfig = new TechlifyTaggerTagFormConfigModel();
|
|
5149
5146
|
this.title = "File";
|
|
5150
5147
|
this.filters = {};
|
|
5151
|
-
this.entityFiles = [];
|
|
5152
5148
|
this.displayedColumns = [
|
|
5153
5149
|
'index',
|
|
5154
5150
|
'title',
|
|
@@ -5156,17 +5152,12 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5156
5152
|
'file_size',
|
|
5157
5153
|
'uploaded_on',
|
|
5158
5154
|
];
|
|
5159
|
-
this.isWorking = false;
|
|
5160
|
-
this.page = 1;
|
|
5161
|
-
this.perPage = 25;
|
|
5162
|
-
this.lastPage = 0;
|
|
5163
|
-
this.fileList = [];
|
|
5164
5155
|
this.isShowCreateAction = true;
|
|
5165
5156
|
this.isShowUpdateAction = true;
|
|
5166
5157
|
this.isShowDeleteAction = true;
|
|
5167
5158
|
this.isShowReadAction = true;
|
|
5168
5159
|
this.user = this.currentUserService.getUser();
|
|
5169
|
-
this.
|
|
5160
|
+
this.filterForm = this.fb.group({
|
|
5170
5161
|
title: [""],
|
|
5171
5162
|
tag_ids: [""]
|
|
5172
5163
|
});
|
|
@@ -5216,7 +5207,7 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5216
5207
|
entity_id: this.entityId,
|
|
5217
5208
|
title: ""
|
|
5218
5209
|
};
|
|
5219
|
-
this.
|
|
5210
|
+
this.loadData();
|
|
5220
5211
|
if (!this.viewOnly) {
|
|
5221
5212
|
this.displayedColumns.push('actions');
|
|
5222
5213
|
}
|
|
@@ -5225,15 +5216,15 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5225
5216
|
}
|
|
5226
5217
|
}
|
|
5227
5218
|
listenRoutes() {
|
|
5228
|
-
this.
|
|
5219
|
+
this.filterForm.valueChanges.pipe(debounceTime(500), untilDestroyed(this))
|
|
5229
5220
|
.subscribe(changes => {
|
|
5230
5221
|
this.reload();
|
|
5231
5222
|
});
|
|
5232
5223
|
}
|
|
5233
|
-
|
|
5224
|
+
loadData() {
|
|
5234
5225
|
this.filters.page = this.page;
|
|
5235
5226
|
this.filters.perPage = this.perPage;
|
|
5236
|
-
const formGroup = this.
|
|
5227
|
+
const formGroup = this.filterForm.value;
|
|
5237
5228
|
formGroup.tag_ids = formGroup.tag_ids.toString();
|
|
5238
5229
|
this.filters = {
|
|
5239
5230
|
...this.filters,
|
|
@@ -5244,8 +5235,8 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5244
5235
|
this.entityFileService.index(this.filters).subscribe({
|
|
5245
5236
|
next: (result) => {
|
|
5246
5237
|
this.lastPage = result.last_page || this.page;
|
|
5247
|
-
this.
|
|
5248
|
-
this.
|
|
5238
|
+
this.models = this.models.concat(result.data);
|
|
5239
|
+
this.lastPage = result?.last_page;
|
|
5249
5240
|
this.isWorking = false;
|
|
5250
5241
|
},
|
|
5251
5242
|
error: () => this.isWorking = false
|
|
@@ -5292,43 +5283,6 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5292
5283
|
}
|
|
5293
5284
|
});
|
|
5294
5285
|
}
|
|
5295
|
-
deleteEntityFile(file) {
|
|
5296
|
-
const dialogRef = this.dialog.open(ActionPopupComponent, {
|
|
5297
|
-
width: "400px",
|
|
5298
|
-
data: {
|
|
5299
|
-
title: "Delete File",
|
|
5300
|
-
message: `Are you sure to proceed delete the file ${file.title}?`
|
|
5301
|
-
},
|
|
5302
|
-
autoFocus: false
|
|
5303
|
-
});
|
|
5304
|
-
dialogRef.afterClosed().subscribe(async (result) => {
|
|
5305
|
-
if (result) {
|
|
5306
|
-
//Action confirmed
|
|
5307
|
-
const result = await this.entityFileService.deleteEntityFile(file);
|
|
5308
|
-
this.alertService.addAlert("File successfully deleted", "success");
|
|
5309
|
-
this.reload();
|
|
5310
|
-
}
|
|
5311
|
-
});
|
|
5312
|
-
}
|
|
5313
|
-
onScroll() {
|
|
5314
|
-
if (this.page < this.lastPage && !this.isWorking) {
|
|
5315
|
-
this.page += 1;
|
|
5316
|
-
this.fetchEntityFilesDetails();
|
|
5317
|
-
}
|
|
5318
|
-
}
|
|
5319
|
-
reload() {
|
|
5320
|
-
this.entityFiles = [];
|
|
5321
|
-
this.documentIds = [];
|
|
5322
|
-
this.page = 1;
|
|
5323
|
-
if (!this.isWorking) {
|
|
5324
|
-
this.fetchEntityFilesDetails();
|
|
5325
|
-
}
|
|
5326
|
-
}
|
|
5327
|
-
ngOnDestroy() { }
|
|
5328
|
-
resetFieldValue(event, field) {
|
|
5329
|
-
event.stopPropagation();
|
|
5330
|
-
this.filterFormGroup.get(field).setValue("");
|
|
5331
|
-
}
|
|
5332
5286
|
sizeOf(bytes) {
|
|
5333
5287
|
if (!bytes) {
|
|
5334
5288
|
return "0.00 B";
|
|
@@ -5337,55 +5291,24 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5337
5291
|
return (bytes / Math.pow(1024, e)).toFixed(2) + ' ' + ' KMGTP'.charAt(e) + 'B';
|
|
5338
5292
|
}
|
|
5339
5293
|
async fileChanged(event) {
|
|
5340
|
-
this.
|
|
5341
|
-
if (this.
|
|
5342
|
-
await this.
|
|
5294
|
+
this.models = event;
|
|
5295
|
+
if (this.models.length > 0) {
|
|
5296
|
+
await this.models.forEach(async (file) => {
|
|
5343
5297
|
const result = await this.entityFileService.uploadEntityFile(file, {
|
|
5344
5298
|
entity_type: this.entityType,
|
|
5345
5299
|
entity_id: this.entityId,
|
|
5346
5300
|
});
|
|
5347
5301
|
this.reload();
|
|
5348
5302
|
});
|
|
5349
|
-
this.
|
|
5303
|
+
this.models = [];
|
|
5350
5304
|
this.alertService.addAlert('Files uploaded successfully!', 'success');
|
|
5351
5305
|
}
|
|
5352
5306
|
}
|
|
5353
|
-
selectAll() {
|
|
5354
|
-
this.documentIds = [];
|
|
5355
|
-
this.entityFiles.map((employee) => {
|
|
5356
|
-
employee.is_selected = this.isAllSelected;
|
|
5357
|
-
if (this.isAllSelected) {
|
|
5358
|
-
this.documentIds.push(employee.id);
|
|
5359
|
-
}
|
|
5360
|
-
});
|
|
5361
|
-
this.entityFiles = [...this.entityFiles];
|
|
5362
|
-
}
|
|
5363
|
-
employeeListModified(event, employee) {
|
|
5364
|
-
this.isAllSelected = false;
|
|
5365
|
-
if (event.checked) {
|
|
5366
|
-
this.documentIds.push(employee.id);
|
|
5367
|
-
}
|
|
5368
|
-
else {
|
|
5369
|
-
this.documentIds = this.documentIds.filter((employeeData) => employeeData != employee.id);
|
|
5370
|
-
}
|
|
5371
|
-
}
|
|
5372
|
-
unCheckAll() {
|
|
5373
|
-
this.isAllSelected = false;
|
|
5374
|
-
this.documentIds = [];
|
|
5375
|
-
this.entityFiles.map((employee) => {
|
|
5376
|
-
employee.is_selected = false;
|
|
5377
|
-
});
|
|
5378
|
-
this.entityFiles = [...this.entityFiles];
|
|
5379
|
-
}
|
|
5380
|
-
resetFieldValueOfRow(field, event) {
|
|
5381
|
-
event.stopPropagation();
|
|
5382
|
-
this.updateRowForm.get(field).setValue("");
|
|
5383
|
-
}
|
|
5384
5307
|
async bulkUpdate(fieldName) {
|
|
5385
5308
|
var data = this.updateRowForm.value;
|
|
5386
5309
|
this.isWorking = true;
|
|
5387
5310
|
data.field_name = fieldName;
|
|
5388
|
-
data.document_ids = this.
|
|
5311
|
+
data.document_ids = this.selectedModelIds;
|
|
5389
5312
|
try {
|
|
5390
5313
|
await this.entityFileService.bulkUpdate(data).then(res => {
|
|
5391
5314
|
this.alertService.addAlert("Successfully updated", "success");
|
|
@@ -5399,14 +5322,14 @@ let EntityFilesViewAllComponent = class EntityFilesViewAllComponent {
|
|
|
5399
5322
|
}
|
|
5400
5323
|
}
|
|
5401
5324
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: EntityFilesViewAllComponent, deps: [{ token: EntityFileService }, { token: i3.Location }, { token: AlertService }, { token: i1.MatDialog }, { token: i1$5.UntypedFormBuilder }, { token: ErrorHandlerService }, { token: CurrentUserService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5402
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.14", type: EntityFilesViewAllComponent, selector: "app-entity-files-view-all", inputs: { entityId: "entityId", entityType: "entityType", viewOnly: "viewOnly", removeSearch: "removeSearch", hideTitleAndDetails: "hideTitleAndDetails", displayMode: "displayMode", allowMultipleFiles: "allowMultipleFiles", allowBulkUpdate: "allowBulkUpdate", viewMode: "viewMode", fileDropperHeight: "fileDropperHeight", isShowDragDropSection: "isShowDragDropSection", useTechlifyTags: "useTechlifyTags", techlifyTagCategories: "techlifyTagCategories", techlifyTagConfig: "techlifyTagConfig", title: "title", permission: "permission" }, ngImport: i0, template: "<div *ngIf=\"viewMode === 'list'\">\n <div *ngIf=\"this.documentIds.length\" class=\"d-none d-md-flex flex-column\">\n <mat-card class=\"update_card\" *ngIf=\"this.documentIds.length\">\n <mat-card-header>\n <mat-card-title>\n <div mat-dialog-title class=\"mt-2 ml-2 text-center\">\n <div>Update Selected Rows</div>\n </div>\n </mat-card-title>\n </mat-card-header>\n <mat-card-content class=\"d-flex flex-column\">\n <form [formGroup]=\"updateRowForm\">\n <div class=\"d-flex flex-column\">\n\n <mat-form-field class=\"w-100 px-1\">\n <input matInput formControlName=\"title\" placeholder=\"Title\" autocomplete=\"off\" />\n <button *ngIf=\"updateRowForm.get('title').value || updateRowForm.get('title').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"resetFieldValueOfRow('title', $event)\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('title').value || updateRowForm.get('title').value===0)\n && updateRowForm.get('title').valid\" (click)=\"bulkUpdate('title')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n\n <mat-form-field class=\"w-100 px-1\">\n <textarea matInput formControlName=\"details\" placeholder=\"Details\" autocomplete=\"off\"></textarea>\n <button *ngIf=\"updateRowForm.get('details').value || updateRowForm.get('details').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"resetFieldValueOfRow('details', $event)\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('details').value || updateRowForm.get('details').value===0)\n && updateRowForm.get('details').valid\" (click)=\"bulkUpdate('details')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n\n <ng-container *ngIf=\"useTechlifyTags\">\n <mat-form-field>\n <mat-label>Tag</mat-label>\n <app-techlify-tagger-tag-form-field modelType=\"entity-file\" formControlName=\"tag_ids\"\n placeholder=\"Enter new tag\">\n </app-techlify-tagger-tag-form-field>\n <button *ngIf=\"updateRowForm.get('tag_ids').value || updateRowForm.get('tag_ids').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"resetFieldValueOfRow('tag_ids', $event)\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('tag_ids').value || updateRowForm.get('tag_ids').value===0)\n && updateRowForm.get('tag_ids').valid\" (click)=\"bulkUpdate('tag_ids')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n </ng-container>\n </div>\n </form>\n </mat-card-content>\n </mat-card>\n\n </div>\n\n <div>\n <div class=\"mat-typography\" *ngIf=\"!displayMode\">\n <div class=\"d-flex flex-row gap-3\">\n <mat-card class=\"flex-grow-1\">\n <mat-card-content>\n <div class=\"d-flex align-items-center\">\n <mat-icon>\n description\n </mat-icon>\n <h3 class=\"font-weight-bold mb-0\">\n {{title}}s\n </h3>\n <mat-icon class=\"cursor-pointer\" *ngIf=\"!viewOnly && isShowCreateAction\" (click)=\"addEntityFile()\">\n add\n </mat-icon>\n <span class=\"flex-grow-1\"></span>\n <form [formGroup]=\"filterFormGroup\" class=\"d-flex gap-2\">\n <mat-form-field *ngIf=\"!removeSearch\" appearance=\"outline\">\n <mat-label>Search</mat-label>\n <input type=\"text\" matInput formControlName=\"title\" placeholder=\"Search\" name=\"title\"\n autocomplete=\"off\" />\n <button *ngIf=\"filters.title\" matSuffix mat-icon-button (click)=\"resetFieldValue($event, 'title')\">\n <mat-icon>close</mat-icon>\n </button>\n </mat-form-field>\n\n <ng-container *ngIf=\"useTechlifyTags\">\n <mat-form-field>\n <mat-label>Tag</mat-label>\n <app-techlify-tagger-tag-form-field [categories]=\"techlifyTagCategories\" formControlName=\"tag_ids\"\n placeholder=\"Select Tags\" [config]=\"techlifyTagConfig\"></app-techlify-tagger-tag-form-field>\n </mat-form-field>\n </ng-container>\n\n </form>\n </div>\n </mat-card-content>\n <mat-card-content class=\"entity-file-card p-0\">\n <table mat-table [dataSource]=\"entityFiles\" class=\"w-100\" matSort multiTemplateDataRows infiniteScroll\n [infiniteScrollDistance]=\"1.5\" [infiniteScrollThrottle]=\"50\" (scrolled)=\"onScroll()\">\n\n <!-- Select Column -->\n <ng-container matColumnDef=\"select\">\n <th mat-header-cell *matHeaderCellDef style=\"width:30px\">\n <mat-checkbox name=\"employee\" [(ngModel)]=\"isAllSelected\" (change)=\"selectAll()\">\n </mat-checkbox>\n </th>\n <td mat-cell *matCellDef=\"let element\" style=\"width:30px\">\n <mat-checkbox name=\"employee[{{element?.id}}]\" (click)=\"$event.stopPropagation()\"\n [(ngModel)]=\"element.is_selected\" (change)=\"employeeListModified($event, element)\"\n [disabled]=\"!entityFiles.length\">\n </mat-checkbox>\n </td>\n </ng-container>\n\n <!-- Index Column -->\n <ng-container matColumnDef=\"index\">\n <th mat-header-cell *matHeaderCellDef> # </th>\n <td mat-cell *matCellDef=\"let element; let i = dataIndex\"> {{ i+1 }} </td>\n </ng-container>\n\n <!-- Title Column -->\n <ng-container matColumnDef=\"title\">\n <th mat-header-cell *matHeaderCellDef> Title </th>\n <td mat-cell *matCellDef=\"let element\">\n {{element.title}}\n <ng-container *ngIf=\"useTechlifyTags\">\n <br>\n <small class=\"badge badge-secondary mr-1\" *ngFor=\"let tag of element?.tags\">{{tag?.title}}</small>\n </ng-container>\n\n </td>\n </ng-container>\n\n <!-- Details Column -->\n <ng-container matColumnDef=\"details\">\n <th mat-header-cell *matHeaderCellDef> Details </th>\n <td mat-cell *matCellDef=\"let element\">\n <app-read-more [text]=\"element.details\" [maxLength]=\"50\"></app-read-more>\n </td>\n </ng-container>\n\n <!-- File size Column -->\n <ng-container matColumnDef=\"file_size\">\n <th mat-header-cell *matHeaderCellDef> File Size </th>\n <td mat-cell *matCellDef=\"let element\"> {{ sizeOf(element.file_size)}} </td>\n </ng-container>\n\n <!-- Uploaded On Column -->\n <ng-container matColumnDef=\"uploaded_on\">\n <th mat-header-cell *matHeaderCellDef> Uploaded On </th>\n <td mat-cell *matCellDef=\"let element\">\n <div>\n {{element.created_at | date: 'mediumDate'}}\n </div>\n <div class=\"text-muted\">\n By {{element.creator?.name}}\n </div>\n </td>\n </ng-container>\n\n <!-- Actions Column -->\n <ng-container matColumnDef=\"actions\">\n <th mat-header-cell *matHeaderCellDef> Actions </th>\n <td mat-cell *matCellDef=\"let element\" class=\"text-muted\">\n <div class=\"d-flex\">\n <a href=\"{{element.url}}\" target=\"_blank\" class=\"text-decoration-none text-muted clickable\">\n <mat-icon>download</mat-icon>\n </a>\n <mat-icon class=\"clickable\" *ngIf=\"isShowUpdateAction\"\n (click)=\"editEntityFile(element)\">edit</mat-icon>\n <mat-icon class=\"clickable\" *ngIf=\"isShowDeleteAction\"\n (click)=\"deleteEntityFile(element)\">delete</mat-icon>\n </div>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"displayedColumns\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: displayedColumns;\"></tr>\n </table>\n\n <mat-progress-bar mode=\"indeterminate\" *ngIf=\"isWorking\"></mat-progress-bar>\n </mat-card-content>\n </mat-card>\n <ng-container *ngIf=\"isShowDragDropSection\">\n <section style=\"flex: 0 1 30%;\" *ngIf=\"!this.documentIds.length && !viewOnly && isShowCreateAction\">\n <app-file-dropper [config]=\"fileConfig\" (fileChanged)=\"fileChanged($event)\" [fileArray]=\"fileList\">\n </app-file-dropper>\n </section>\n </ng-container>\n </div>\n </div>\n </div>\n\n <div class=\"d-flex flex-wrap gap-3 mat-typography p-4\" *ngIf=\"displayMode\">\n <div *ngFor=\"let efile of entityFiles\">\n <app-document-viewer [file]=\"efile.file\" [fileUrl]=\"efile.url\" [config]=\"this.viewerConfig\" [disableEdit]=\"true\">\n </app-document-viewer>\n <a href=\"{{efile.url}}\" target=\"_blank\">\n <button mat-button type=\"button\">View</button>\n </a>\n </div>\n </div>\n</div>\n\n<mat-card *ngIf=\"viewMode === 'timeline'\">\n <mat-card-content>\n <div class=\"d-flex justify-content-start align-items-center gap-2\">\n <mat-icon>\n description\n </mat-icon>\n <h3 class=\"font-weight-bold primary-color mb-0\">\n {{title}}s\n </h3>\n <span class=\"badge bg-primary\" *ngIf=\"total > 0\">{{ total }}</span>\n <mat-icon color=\"primary\" class=\"cursor-pointer\" *ngIf=\"!viewOnly && isShowCreateAction\"\n (click)=\"addEntityFile()\">\n add\n </mat-icon>\n </div>\n </mat-card-content>\n <mat-card-content *ngIf=\"!this.documentIds.length && !viewOnly && isShowCreateAction\" class=\"mt-3\">\n <app-file-dropper [config]=\"fileConfig\" (fileChanged)=\"fileChanged($event)\" [fileArray]=\"fileList\">\n </app-file-dropper>\n </mat-card-content>\n\n <mat-card-content class=\"mt-3\">\n <div *ngFor=\"let entityFile of entityFiles\" class=\"d-flex flex-column gap-0\">\n <div class=\"d-flex flex-column gap-0\">\n <div class=\"d-flex justify-content-between align-items-center gap-1\">\n <p class=\"mb-0 fw-bold text-wrap\">{{ entityFile?.title | wrap:20 }}</p>\n <span class=\"badge bg-dark\" *ngFor=\"let tag of entityFile?.tags\">\n {{ tag?.title }}\n </span>\n <small class=\"text-dark\">{{ sizeOf(entityFile.file_size) }}</small>\n </div>\n </div>\n <app-read-more [text]=\"entityFile?.details\" [maxLength]=\"50\"></app-read-more>\n <div class=\"d-flex justify-content-between gap-2\">\n <small class=\"text-secondary\" style=\"max-width: 70%\">\n <i>Uploaded By {{ entityFile?.creator?.name }} {{ entityFile?.created_at | date: 'mediumDate'}}</i>\n </small>\n <div class=\"d-flex justify-content-end align-items-center gap-1\">\n <a href=\"{{entityFile?.url}}\" target=\"_blank\" class=\"text-decoration-none text-secondary mt-2\">\n <mat-icon>download</mat-icon>\n </a>\n <mat-icon *ngIf=\"isShowUpdateAction\" (click)=\"editEntityFile(entityFile)\"\n class=\"cursor-pointer text-secondary\">\n edit\n </mat-icon>\n <mat-icon *ngIf=\"isShowDeleteAction\" (click)=\"deleteEntityFile(entityFile)\"\n class=\"cursor-pointer text-secondary\">\n delete\n </mat-icon>\n </div>\n </div>\n <hr style=\"margin: 0.5rem 0\">\n </div>\n <mat-progress-bar mode=\"indeterminate\" *ngIf=\"isWorking\"></mat-progress-bar>\n </mat-card-content>\n</mat-card>\n", styles: ["th.mat-header-cell,td.mat-cell,td.mat-footer-cell{padding:2px}.entity-file-card{overflow-x:auto}.clickable:hover{cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1$5.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$5.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: FileDropperComponent, selector: "app-file-dropper", inputs: ["fileArray", "config", "styles"], outputs: ["fileChanged"] }, { kind: "component", type: DocumentViewerComponent, selector: "app-document-viewer", inputs: ["config", "file", "fileUrl", "disableEdit"], outputs: ["remove"] }, { kind: "directive", type: i6$2.InfiniteScrollDirective, selector: "[infiniteScroll], [infinite-scroll], [data-infinite-scroll]", inputs: ["infiniteScrollDistance", "infiniteScrollUpDistance", "infiniteScrollThrottle", "infiniteScrollDisabled", "infiniteScrollContainer", "scrollWindow", "immediateCheck", "horizontal", "alwaysCallback", "fromRoot"], outputs: ["scrolled", "scrolledUp"] }, { kind: "component", type: i6.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: i6.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: i8$1.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "directive", type: i1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "component", type: i8$4.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i8$4.MatLabel, selector: "mat-label" }, { kind: "directive", type: i8$4.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "component", type: i8.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i9.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "directive", type: i11.MatSort, selector: "[matSort]", inputs: ["matSortActive", "matSortStart", "matSortDirection", "matSortDisableClear", "matSortDisabled"], outputs: ["matSortChange"], exportAs: ["matSort"] }, { kind: "component", type: i12.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i12.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i12.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i12.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i12.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i12.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i12.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i12.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i12.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i12.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "component", type: i4.MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "directive", type: i4.MatCardContent, selector: "mat-card-content" }, { kind: "component", type: i4.MatCardHeader, selector: "mat-card-header" }, { kind: "directive", type: i4.MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }, { kind: "component", type: i11$1.MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "component", type: TechlifyTaggerTagFormFieldComponent, selector: "app-techlify-tagger-tag-form-field", inputs: ["config", "modelType", "modelId", "allTags", "categories", "defaultCreateCategory", "required", "disabled", "value", "placeholder"] }, { kind: "component", type: ReadMoreComponent, selector: "app-read-more", inputs: ["text", "maxLength"] }, { kind: "pipe", type: i3.DatePipe, name: "date" }, { kind: "pipe", type: WrapPipe, name: "wrap" }] }); }
|
|
5325
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.14", type: EntityFilesViewAllComponent, selector: "app-entity-files-view-all", inputs: { entityId: "entityId", entityType: "entityType", viewOnly: "viewOnly", removeSearch: "removeSearch", hideTitleAndDetails: "hideTitleAndDetails", displayMode: "displayMode", allowMultipleFiles: "allowMultipleFiles", allowBulkUpdate: "allowBulkUpdate", viewMode: "viewMode", fileDropperHeight: "fileDropperHeight", isShowDragDropSection: "isShowDragDropSection", useTechlifyTags: "useTechlifyTags", techlifyTagCategories: "techlifyTagCategories", techlifyTagConfig: "techlifyTagConfig", title: "title", permission: "permission" }, usesInheritance: true, ngImport: i0, template: "<div *ngIf=\"viewMode === 'list'\">\n <div *ngIf=\"this.selectedModelIds.length\" class=\"d-none d-md-flex flex-column\">\n <mat-card class=\"update_card\" *ngIf=\"this.selectedModelIds.length\">\n <mat-card-header>\n <mat-card-title>\n <div mat-dialog-title class=\"mt-2 ml-2 text-center\">\n <div>Update Selected Rows</div>\n </div>\n </mat-card-title>\n </mat-card-header>\n <mat-card-content class=\"d-flex flex-column\">\n <form [formGroup]=\"updateRowForm\">\n <div class=\"d-flex flex-column\">\n\n <mat-form-field class=\"w-100 px-1\">\n <input matInput formControlName=\"title\" placeholder=\"Title\" autocomplete=\"off\" />\n <button *ngIf=\"updateRowForm.get('title').value || updateRowForm.get('title').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"updateRowForm.get('title').setValue('')\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('title').value || updateRowForm.get('title').value===0)\n && updateRowForm.get('title').valid\" (click)=\"bulkUpdate('title')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n\n <mat-form-field class=\"w-100 px-1\">\n <textarea matInput formControlName=\"details\" placeholder=\"Details\" autocomplete=\"off\"></textarea>\n <button *ngIf=\"updateRowForm.get('details').value || updateRowForm.get('details').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"updateRowForm.get('details').setValue('')\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('details').value || updateRowForm.get('details').value===0)\n && updateRowForm.get('details').valid\" (click)=\"bulkUpdate('details')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n\n <ng-container *ngIf=\"useTechlifyTags\">\n <mat-form-field>\n <mat-label>Tag</mat-label>\n <app-techlify-tagger-tag-form-field modelType=\"entity-file\" formControlName=\"tag_ids\"\n placeholder=\"Enter new tag\">\n </app-techlify-tagger-tag-form-field>\n <button *ngIf=\"updateRowForm.get('tag_ids').value || updateRowForm.get('tag_ids').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"updateRowForm.get('tag_ids').setValue('')\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('tag_ids').value || updateRowForm.get('tag_ids').value===0)\n && updateRowForm.get('tag_ids').valid\" (click)=\"bulkUpdate('tag_ids')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n </ng-container>\n </div>\n </form>\n </mat-card-content>\n </mat-card>\n\n </div>\n\n <div>\n <div class=\"mat-typography\" *ngIf=\"!displayMode\">\n <div class=\"d-flex flex-row gap-3\">\n <mat-card class=\"flex-grow-1\">\n <mat-card-content>\n <div class=\"d-flex align-items-center\">\n <mat-icon>\n description\n </mat-icon>\n <h3 class=\"font-weight-bold mb-0\">\n {{title}}s\n </h3>\n <app-techlify-icon name=\"add\" class=\"clickable ms-2\" (click)=\"addEntityFile()\"\n *ngIf=\"!viewOnly && isShowCreateAction\" matTooltip=\"Add\"></app-techlify-icon>\n <span class=\"flex-grow-1\"></span>\n <form [formGroup]=\"filterForm\" class=\"d-flex gap-2\">\n <mat-form-field *ngIf=\"!removeSearch\" appearance=\"outline\">\n <mat-label>Search</mat-label>\n <input type=\"text\" matInput formControlName=\"title\" placeholder=\"Search\" name=\"title\"\n autocomplete=\"off\" />\n <button *ngIf=\"filters.title\" matSuffix mat-icon-button (click)=\"resetFilter('title')\">\n <mat-icon>close</mat-icon>\n </button>\n </mat-form-field>\n\n <ng-container *ngIf=\"useTechlifyTags\">\n <mat-form-field>\n <mat-label>Tag</mat-label>\n <app-techlify-tagger-tag-form-field [categories]=\"techlifyTagCategories\" formControlName=\"tag_ids\"\n placeholder=\"Select Tags\" [config]=\"techlifyTagConfig\"></app-techlify-tagger-tag-form-field>\n </mat-form-field>\n </ng-container>\n\n </form>\n </div>\n </mat-card-content>\n <mat-card-content class=\"entity-file-card p-0\">\n <table mat-table [dataSource]=\"models\" class=\"w-100\" matSort multiTemplateDataRows infiniteScroll\n [infiniteScrollDistance]=\"1.5\" [infiniteScrollThrottle]=\"50\" (scrolled)=\"onScroll()\">\n\n <!-- Select Column -->\n <ng-container matColumnDef=\"select\">\n <th mat-header-cell *matHeaderCellDef style=\"width:30px\">\n <mat-checkbox name=\"employee\" [(ngModel)]=\"isAllSelected\" (change)=\"selectAll()\">\n </mat-checkbox>\n </th>\n <td mat-cell *matCellDef=\"let element\" style=\"width:30px\">\n <mat-checkbox name=\"employee[{{element?.id}}]\" (click)=\"$event.stopPropagation()\"\n [(ngModel)]=\"element.is_selected\" (change)=\"isSelectionModified($event, element)\"\n [disabled]=\"!models.length\">\n </mat-checkbox>\n </td>\n </ng-container>\n\n <!-- Index Column -->\n <ng-container matColumnDef=\"index\">\n <th mat-header-cell *matHeaderCellDef> # </th>\n <td mat-cell *matCellDef=\"let element; let i = dataIndex\"> {{ i+1 }} </td>\n </ng-container>\n\n <!-- Title Column -->\n <ng-container matColumnDef=\"title\">\n <th mat-header-cell *matHeaderCellDef> Title </th>\n <td mat-cell *matCellDef=\"let element\">\n {{element.title}}\n <ng-container *ngIf=\"useTechlifyTags\">\n <br>\n <small class=\"badge badge-secondary mr-1\" *ngFor=\"let tag of element?.tags\">{{tag?.title}}</small>\n </ng-container>\n\n </td>\n </ng-container>\n\n <!-- Details Column -->\n <ng-container matColumnDef=\"details\">\n <th mat-header-cell *matHeaderCellDef> Details </th>\n <td mat-cell *matCellDef=\"let element\">\n <app-read-more [text]=\"element.details\" [maxLength]=\"50\"></app-read-more>\n </td>\n </ng-container>\n\n <!-- File size Column -->\n <ng-container matColumnDef=\"file_size\">\n <th mat-header-cell *matHeaderCellDef> File Size </th>\n <td mat-cell *matCellDef=\"let element\"> {{ sizeOf(element.file_size)}} </td>\n </ng-container>\n\n <!-- Uploaded On Column -->\n <ng-container matColumnDef=\"uploaded_on\">\n <th mat-header-cell *matHeaderCellDef> Uploaded On </th>\n <td mat-cell *matCellDef=\"let element\">\n <div>\n {{element.created_at | date: 'mediumDate'}}\n </div>\n <div class=\"text-muted\">\n By {{element.creator?.name}}\n </div>\n </td>\n </ng-container>\n\n <!-- Actions Column -->\n <ng-container matColumnDef=\"actions\">\n <th mat-header-cell *matHeaderCellDef> Actions </th>\n <td mat-cell *matCellDef=\"let element\" class=\"text-muted\">\n <div class=\"d-flex\">\n <a href=\"{{element.url}}\" target=\"_blank\" class=\"text-decoration-none text-muted clickable\">\n <mat-icon>download</mat-icon>\n </a>\n <app-techlify-icon name=\"edit\" class=\"clickable text-secondary\" (click)=\"editEntityFile(element)\"\n *ngIf=\"!viewOnly && isShowUpdateAction\" matTooltip=\"Edit\"></app-techlify-icon>\n <app-techlify-delete-button *ngIf=\"!viewOnly && isShowDeleteAction\" class='text-secondary ms-1'\n [model]=\"element\" [service]=\"entityFileService\"\n message=\"Are you sure to proceed delete the file {{element.title}}\"\n (deleted)=\"modelsDeletedById(element)\">\n </app-techlify-delete-button>\n </div>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"displayedColumns\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: displayedColumns;\"></tr>\n </table>\n\n <mat-progress-bar mode=\"indeterminate\" *ngIf=\"isWorking\"></mat-progress-bar>\n </mat-card-content>\n </mat-card>\n <ng-container *ngIf=\"isShowDragDropSection\">\n <section style=\"flex: 0 1 30%;\" *ngIf=\"!this.selectedModelIds.length && !viewOnly && isShowCreateAction\">\n <app-file-dropper [config]=\"fileConfig\" (fileChanged)=\"fileChanged($event)\" [fileArray]=\"models\">\n </app-file-dropper>\n </section>\n </ng-container>\n </div>\n </div>\n </div>\n\n <div class=\"d-flex flex-wrap gap-3 mat-typography p-4\" *ngIf=\"displayMode\">\n <div *ngFor=\"let efile of models\">\n <app-document-viewer [file]=\"efile.file\" [fileUrl]=\"efile.url\" [config]=\"this.viewerConfig\" [disableEdit]=\"true\">\n </app-document-viewer>\n <a href=\"{{efile.url}}\" target=\"_blank\">\n <button mat-button type=\"button\">View</button>\n </a>\n </div>\n </div>\n</div>\n\n<mat-card *ngIf=\"viewMode === 'timeline'\">\n <mat-card-content>\n <div class=\"d-flex justify-content-start align-items-center gap-2\">\n <mat-icon>\n description\n </mat-icon>\n <h3 class=\"font-weight-bold mb-0\">\n {{title}}s\n </h3>\n <app-techlify-icon name=\"add\" class=\"clickable\" (click)=\"addEntityFile()\" *ngIf=\"!viewOnly && isShowCreateAction\"\n matTooltip=\"Add\"></app-techlify-icon>\n </div>\n </mat-card-content>\n <mat-card-content *ngIf=\"!this.selectedModelIds.length && !viewOnly && isShowCreateAction\" class=\"mt-3\">\n <app-file-dropper [config]=\"fileConfig\" (fileChanged)=\"fileChanged($event)\" [fileArray]=\"models\">\n </app-file-dropper>\n </mat-card-content>\n\n <mat-card-content class=\"mt-3\">\n <div *ngFor=\"let entityFile of models\" class=\"d-flex flex-column gap-0\">\n <div class=\"d-flex flex-column gap-0\">\n <div class=\"d-flex justify-content-between align-items-center gap-1\">\n <p class=\"mb-0 fw-bold text-wrap\">{{ entityFile?.title | wrap:20 }}</p>\n <span class=\"badge bg-dark\" *ngFor=\"let tag of entityFile?.tags\">\n {{ tag?.title }}\n </span>\n <small class=\"text-dark\">{{ sizeOf(entityFile.file_size) }}</small>\n </div>\n </div>\n <app-read-more [text]=\"entityFile?.details\" [maxLength]=\"50\"></app-read-more>\n <div class=\"d-flex justify-content-between gap-2\">\n <small class=\"text-secondary\" style=\"max-width: 70%\">\n <i>Uploaded By {{ entityFile?.creator?.name }} {{ entityFile?.created_at | date: 'mediumDate'}}</i>\n </small>\n <div class=\"d-flex justify-content-end align-items-center gap-1\">\n <a href=\"{{entityFile?.url}}\" target=\"_blank\" class=\"text-decoration-none text-secondary mt-2\">\n <mat-icon>download</mat-icon>\n </a>\n <app-techlify-icon name=\"edit\" class=\"clickable text-secondary\" (click)=\"editEntityFile(entityFile)\"\n *ngIf=\"!viewOnly && isShowUpdateAction\" matTooltip=\"Edit\"></app-techlify-icon>\n <app-techlify-delete-button *ngIf=\"!viewOnly && isShowDeleteAction\" class='text-secondary ms-1'\n [model]=\"entityFile\" [service]=\"entityFileService\"\n message=\"Are you sure to proceed delete the file {{entityFile.title}}\"\n (deleted)=\"modelsDeletedById(entityFile)\">\n </app-techlify-delete-button>\n </div>\n </div>\n <hr style=\"margin: 0.5rem 0\">\n </div>\n <mat-progress-bar mode=\"indeterminate\" *ngIf=\"isWorking\"></mat-progress-bar>\n </mat-card-content>\n</mat-card>", styles: ["th.mat-header-cell,td.mat-cell,td.mat-footer-cell{padding:2px}.entity-file-card{overflow-x:auto}.clickable:hover{cursor:pointer}\n"], dependencies: [{ kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$5.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i1$5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1$5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1$5.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1$5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i1$5.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1$5.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: FileDropperComponent, selector: "app-file-dropper", inputs: ["fileArray", "config", "styles"], outputs: ["fileChanged"] }, { kind: "component", type: DocumentViewerComponent, selector: "app-document-viewer", inputs: ["config", "file", "fileUrl", "disableEdit"], outputs: ["remove"] }, { kind: "directive", type: i6$2.InfiniteScrollDirective, selector: "[infiniteScroll], [infinite-scroll], [data-infinite-scroll]", inputs: ["infiniteScrollDistance", "infiniteScrollUpDistance", "infiniteScrollThrottle", "infiniteScrollDisabled", "infiniteScrollContainer", "scrollWindow", "immediateCheck", "horizontal", "alwaysCallback", "fromRoot"], outputs: ["scrolled", "scrolledUp"] }, { kind: "component", type: i6.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "component", type: i6.MatIconButton, selector: "button[mat-icon-button]", exportAs: ["matButton"] }, { kind: "component", type: i8$1.MatCheckbox, selector: "mat-checkbox", inputs: ["aria-label", "aria-labelledby", "aria-describedby", "id", "required", "labelPosition", "name", "value", "disableRipple", "tabIndex", "color", "disabledInteractive", "checked", "disabled", "indeterminate"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { kind: "directive", type: i1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { kind: "component", type: i8$4.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i8$4.MatLabel, selector: "mat-label" }, { kind: "directive", type: i8$4.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "component", type: i8.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "directive", type: i9.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "directive", type: i11.MatSort, selector: "[matSort]", inputs: ["matSortActive", "matSortStart", "matSortDirection", "matSortDisableClear", "matSortDisabled"], outputs: ["matSortChange"], exportAs: ["matSort"] }, { kind: "component", type: i12.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i12.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i12.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i12.MatColumnDef, selector: "[matColumnDef]", inputs: ["matColumnDef"] }, { kind: "directive", type: i12.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i12.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i12.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i12.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i12.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i12.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }, { kind: "component", type: i4.MatCard, selector: "mat-card", inputs: ["appearance"], exportAs: ["matCard"] }, { kind: "directive", type: i4.MatCardContent, selector: "mat-card-content" }, { kind: "component", type: i4.MatCardHeader, selector: "mat-card-header" }, { kind: "directive", type: i4.MatCardTitle, selector: "mat-card-title, [mat-card-title], [matCardTitle]" }, { kind: "directive", type: i10.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: i11$1.MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "component", type: TechlifyTaggerTagFormFieldComponent, selector: "app-techlify-tagger-tag-form-field", inputs: ["config", "modelType", "modelId", "allTags", "categories", "defaultCreateCategory", "required", "disabled", "value", "placeholder"] }, { kind: "component", type: ReadMoreComponent, selector: "app-read-more", inputs: ["text", "maxLength"] }, { kind: "component", type: TechlifyIconComponent, selector: "app-techlify-icon", inputs: ["name", "size"] }, { kind: "component", type: TechlifyDeleteButtonComponent, selector: "app-techlify-delete-button", inputs: ["data", "model", "message", "service"], outputs: ["deleted"] }, { kind: "pipe", type: i3.DatePipe, name: "date" }, { kind: "pipe", type: WrapPipe, name: "wrap" }] }); }
|
|
5403
5326
|
};
|
|
5404
5327
|
EntityFilesViewAllComponent = __decorate([
|
|
5405
5328
|
UntilDestroy()
|
|
5406
5329
|
], EntityFilesViewAllComponent);
|
|
5407
5330
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: EntityFilesViewAllComponent, decorators: [{
|
|
5408
5331
|
type: Component,
|
|
5409
|
-
args: [{ selector: 'app-entity-files-view-all', template: "<div *ngIf=\"viewMode === 'list'\">\n <div *ngIf=\"this.documentIds.length\" class=\"d-none d-md-flex flex-column\">\n <mat-card class=\"update_card\" *ngIf=\"this.documentIds.length\">\n <mat-card-header>\n <mat-card-title>\n <div mat-dialog-title class=\"mt-2 ml-2 text-center\">\n <div>Update Selected Rows</div>\n </div>\n </mat-card-title>\n </mat-card-header>\n <mat-card-content class=\"d-flex flex-column\">\n <form [formGroup]=\"updateRowForm\">\n <div class=\"d-flex flex-column\">\n\n <mat-form-field class=\"w-100 px-1\">\n <input matInput formControlName=\"title\" placeholder=\"Title\" autocomplete=\"off\" />\n <button *ngIf=\"updateRowForm.get('title').value || updateRowForm.get('title').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"resetFieldValueOfRow('title', $event)\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('title').value || updateRowForm.get('title').value===0)\n && updateRowForm.get('title').valid\" (click)=\"bulkUpdate('title')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n\n <mat-form-field class=\"w-100 px-1\">\n <textarea matInput formControlName=\"details\" placeholder=\"Details\" autocomplete=\"off\"></textarea>\n <button *ngIf=\"updateRowForm.get('details').value || updateRowForm.get('details').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"resetFieldValueOfRow('details', $event)\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('details').value || updateRowForm.get('details').value===0)\n && updateRowForm.get('details').valid\" (click)=\"bulkUpdate('details')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n\n <ng-container *ngIf=\"useTechlifyTags\">\n <mat-form-field>\n <mat-label>Tag</mat-label>\n <app-techlify-tagger-tag-form-field modelType=\"entity-file\" formControlName=\"tag_ids\"\n placeholder=\"Enter new tag\">\n </app-techlify-tagger-tag-form-field>\n <button *ngIf=\"updateRowForm.get('tag_ids').value || updateRowForm.get('tag_ids').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"resetFieldValueOfRow('tag_ids', $event)\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('tag_ids').value || updateRowForm.get('tag_ids').value===0)\n && updateRowForm.get('tag_ids').valid\" (click)=\"bulkUpdate('tag_ids')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n </ng-container>\n </div>\n </form>\n </mat-card-content>\n </mat-card>\n\n </div>\n\n <div>\n <div class=\"mat-typography\" *ngIf=\"!displayMode\">\n <div class=\"d-flex flex-row gap-3\">\n <mat-card class=\"flex-grow-1\">\n <mat-card-content>\n <div class=\"d-flex align-items-center\">\n <mat-icon>\n description\n </mat-icon>\n <h3 class=\"font-weight-bold mb-0\">\n {{title}}s\n </h3>\n <mat-icon class=\"cursor-pointer\" *ngIf=\"!viewOnly && isShowCreateAction\" (click)=\"addEntityFile()\">\n add\n </mat-icon>\n <span class=\"flex-grow-1\"></span>\n <form [formGroup]=\"filterFormGroup\" class=\"d-flex gap-2\">\n <mat-form-field *ngIf=\"!removeSearch\" appearance=\"outline\">\n <mat-label>Search</mat-label>\n <input type=\"text\" matInput formControlName=\"title\" placeholder=\"Search\" name=\"title\"\n autocomplete=\"off\" />\n <button *ngIf=\"filters.title\" matSuffix mat-icon-button (click)=\"resetFieldValue($event, 'title')\">\n <mat-icon>close</mat-icon>\n </button>\n </mat-form-field>\n\n <ng-container *ngIf=\"useTechlifyTags\">\n <mat-form-field>\n <mat-label>Tag</mat-label>\n <app-techlify-tagger-tag-form-field [categories]=\"techlifyTagCategories\" formControlName=\"tag_ids\"\n placeholder=\"Select Tags\" [config]=\"techlifyTagConfig\"></app-techlify-tagger-tag-form-field>\n </mat-form-field>\n </ng-container>\n\n </form>\n </div>\n </mat-card-content>\n <mat-card-content class=\"entity-file-card p-0\">\n <table mat-table [dataSource]=\"entityFiles\" class=\"w-100\" matSort multiTemplateDataRows infiniteScroll\n [infiniteScrollDistance]=\"1.5\" [infiniteScrollThrottle]=\"50\" (scrolled)=\"onScroll()\">\n\n <!-- Select Column -->\n <ng-container matColumnDef=\"select\">\n <th mat-header-cell *matHeaderCellDef style=\"width:30px\">\n <mat-checkbox name=\"employee\" [(ngModel)]=\"isAllSelected\" (change)=\"selectAll()\">\n </mat-checkbox>\n </th>\n <td mat-cell *matCellDef=\"let element\" style=\"width:30px\">\n <mat-checkbox name=\"employee[{{element?.id}}]\" (click)=\"$event.stopPropagation()\"\n [(ngModel)]=\"element.is_selected\" (change)=\"employeeListModified($event, element)\"\n [disabled]=\"!entityFiles.length\">\n </mat-checkbox>\n </td>\n </ng-container>\n\n <!-- Index Column -->\n <ng-container matColumnDef=\"index\">\n <th mat-header-cell *matHeaderCellDef> # </th>\n <td mat-cell *matCellDef=\"let element; let i = dataIndex\"> {{ i+1 }} </td>\n </ng-container>\n\n <!-- Title Column -->\n <ng-container matColumnDef=\"title\">\n <th mat-header-cell *matHeaderCellDef> Title </th>\n <td mat-cell *matCellDef=\"let element\">\n {{element.title}}\n <ng-container *ngIf=\"useTechlifyTags\">\n <br>\n <small class=\"badge badge-secondary mr-1\" *ngFor=\"let tag of element?.tags\">{{tag?.title}}</small>\n </ng-container>\n\n </td>\n </ng-container>\n\n <!-- Details Column -->\n <ng-container matColumnDef=\"details\">\n <th mat-header-cell *matHeaderCellDef> Details </th>\n <td mat-cell *matCellDef=\"let element\">\n <app-read-more [text]=\"element.details\" [maxLength]=\"50\"></app-read-more>\n </td>\n </ng-container>\n\n <!-- File size Column -->\n <ng-container matColumnDef=\"file_size\">\n <th mat-header-cell *matHeaderCellDef> File Size </th>\n <td mat-cell *matCellDef=\"let element\"> {{ sizeOf(element.file_size)}} </td>\n </ng-container>\n\n <!-- Uploaded On Column -->\n <ng-container matColumnDef=\"uploaded_on\">\n <th mat-header-cell *matHeaderCellDef> Uploaded On </th>\n <td mat-cell *matCellDef=\"let element\">\n <div>\n {{element.created_at | date: 'mediumDate'}}\n </div>\n <div class=\"text-muted\">\n By {{element.creator?.name}}\n </div>\n </td>\n </ng-container>\n\n <!-- Actions Column -->\n <ng-container matColumnDef=\"actions\">\n <th mat-header-cell *matHeaderCellDef> Actions </th>\n <td mat-cell *matCellDef=\"let element\" class=\"text-muted\">\n <div class=\"d-flex\">\n <a href=\"{{element.url}}\" target=\"_blank\" class=\"text-decoration-none text-muted clickable\">\n <mat-icon>download</mat-icon>\n </a>\n <mat-icon class=\"clickable\" *ngIf=\"isShowUpdateAction\"\n (click)=\"editEntityFile(element)\">edit</mat-icon>\n <mat-icon class=\"clickable\" *ngIf=\"isShowDeleteAction\"\n (click)=\"deleteEntityFile(element)\">delete</mat-icon>\n </div>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"displayedColumns\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: displayedColumns;\"></tr>\n </table>\n\n <mat-progress-bar mode=\"indeterminate\" *ngIf=\"isWorking\"></mat-progress-bar>\n </mat-card-content>\n </mat-card>\n <ng-container *ngIf=\"isShowDragDropSection\">\n <section style=\"flex: 0 1 30%;\" *ngIf=\"!this.documentIds.length && !viewOnly && isShowCreateAction\">\n <app-file-dropper [config]=\"fileConfig\" (fileChanged)=\"fileChanged($event)\" [fileArray]=\"fileList\">\n </app-file-dropper>\n </section>\n </ng-container>\n </div>\n </div>\n </div>\n\n <div class=\"d-flex flex-wrap gap-3 mat-typography p-4\" *ngIf=\"displayMode\">\n <div *ngFor=\"let efile of entityFiles\">\n <app-document-viewer [file]=\"efile.file\" [fileUrl]=\"efile.url\" [config]=\"this.viewerConfig\" [disableEdit]=\"true\">\n </app-document-viewer>\n <a href=\"{{efile.url}}\" target=\"_blank\">\n <button mat-button type=\"button\">View</button>\n </a>\n </div>\n </div>\n</div>\n\n<mat-card *ngIf=\"viewMode === 'timeline'\">\n <mat-card-content>\n <div class=\"d-flex justify-content-start align-items-center gap-2\">\n <mat-icon>\n description\n </mat-icon>\n <h3 class=\"font-weight-bold primary-color mb-0\">\n {{title}}s\n </h3>\n <span class=\"badge bg-primary\" *ngIf=\"total > 0\">{{ total }}</span>\n <mat-icon color=\"primary\" class=\"cursor-pointer\" *ngIf=\"!viewOnly && isShowCreateAction\"\n (click)=\"addEntityFile()\">\n add\n </mat-icon>\n </div>\n </mat-card-content>\n <mat-card-content *ngIf=\"!this.documentIds.length && !viewOnly && isShowCreateAction\" class=\"mt-3\">\n <app-file-dropper [config]=\"fileConfig\" (fileChanged)=\"fileChanged($event)\" [fileArray]=\"fileList\">\n </app-file-dropper>\n </mat-card-content>\n\n <mat-card-content class=\"mt-3\">\n <div *ngFor=\"let entityFile of entityFiles\" class=\"d-flex flex-column gap-0\">\n <div class=\"d-flex flex-column gap-0\">\n <div class=\"d-flex justify-content-between align-items-center gap-1\">\n <p class=\"mb-0 fw-bold text-wrap\">{{ entityFile?.title | wrap:20 }}</p>\n <span class=\"badge bg-dark\" *ngFor=\"let tag of entityFile?.tags\">\n {{ tag?.title }}\n </span>\n <small class=\"text-dark\">{{ sizeOf(entityFile.file_size) }}</small>\n </div>\n </div>\n <app-read-more [text]=\"entityFile?.details\" [maxLength]=\"50\"></app-read-more>\n <div class=\"d-flex justify-content-between gap-2\">\n <small class=\"text-secondary\" style=\"max-width: 70%\">\n <i>Uploaded By {{ entityFile?.creator?.name }} {{ entityFile?.created_at | date: 'mediumDate'}}</i>\n </small>\n <div class=\"d-flex justify-content-end align-items-center gap-1\">\n <a href=\"{{entityFile?.url}}\" target=\"_blank\" class=\"text-decoration-none text-secondary mt-2\">\n <mat-icon>download</mat-icon>\n </a>\n <mat-icon *ngIf=\"isShowUpdateAction\" (click)=\"editEntityFile(entityFile)\"\n class=\"cursor-pointer text-secondary\">\n edit\n </mat-icon>\n <mat-icon *ngIf=\"isShowDeleteAction\" (click)=\"deleteEntityFile(entityFile)\"\n class=\"cursor-pointer text-secondary\">\n delete\n </mat-icon>\n </div>\n </div>\n <hr style=\"margin: 0.5rem 0\">\n </div>\n <mat-progress-bar mode=\"indeterminate\" *ngIf=\"isWorking\"></mat-progress-bar>\n </mat-card-content>\n</mat-card>\n", styles: ["th.mat-header-cell,td.mat-cell,td.mat-footer-cell{padding:2px}.entity-file-card{overflow-x:auto}.clickable:hover{cursor:pointer}\n"] }]
|
|
5332
|
+
args: [{ selector: 'app-entity-files-view-all', template: "<div *ngIf=\"viewMode === 'list'\">\n <div *ngIf=\"this.selectedModelIds.length\" class=\"d-none d-md-flex flex-column\">\n <mat-card class=\"update_card\" *ngIf=\"this.selectedModelIds.length\">\n <mat-card-header>\n <mat-card-title>\n <div mat-dialog-title class=\"mt-2 ml-2 text-center\">\n <div>Update Selected Rows</div>\n </div>\n </mat-card-title>\n </mat-card-header>\n <mat-card-content class=\"d-flex flex-column\">\n <form [formGroup]=\"updateRowForm\">\n <div class=\"d-flex flex-column\">\n\n <mat-form-field class=\"w-100 px-1\">\n <input matInput formControlName=\"title\" placeholder=\"Title\" autocomplete=\"off\" />\n <button *ngIf=\"updateRowForm.get('title').value || updateRowForm.get('title').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"updateRowForm.get('title').setValue('')\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('title').value || updateRowForm.get('title').value===0)\n && updateRowForm.get('title').valid\" (click)=\"bulkUpdate('title')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n\n <mat-form-field class=\"w-100 px-1\">\n <textarea matInput formControlName=\"details\" placeholder=\"Details\" autocomplete=\"off\"></textarea>\n <button *ngIf=\"updateRowForm.get('details').value || updateRowForm.get('details').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"updateRowForm.get('details').setValue('')\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('details').value || updateRowForm.get('details').value===0)\n && updateRowForm.get('details').valid\" (click)=\"bulkUpdate('details')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n\n <ng-container *ngIf=\"useTechlifyTags\">\n <mat-form-field>\n <mat-label>Tag</mat-label>\n <app-techlify-tagger-tag-form-field modelType=\"entity-file\" formControlName=\"tag_ids\"\n placeholder=\"Enter new tag\">\n </app-techlify-tagger-tag-form-field>\n <button *ngIf=\"updateRowForm.get('tag_ids').value || updateRowForm.get('tag_ids').value===0\" matSuffix\n mat-icon-button style=\"color:red\" (click)=\"updateRowForm.get('tag_ids').setValue('')\">\n <mat-icon>close</mat-icon>\n </button>\n <button matSuffix mat-icon-button type=\"button\" style=\"color:green\" *ngIf=\"(updateRowForm.get('tag_ids').value || updateRowForm.get('tag_ids').value===0)\n && updateRowForm.get('tag_ids').valid\" (click)=\"bulkUpdate('tag_ids')\">\n <mat-icon>done</mat-icon>\n </button>\n </mat-form-field>\n </ng-container>\n </div>\n </form>\n </mat-card-content>\n </mat-card>\n\n </div>\n\n <div>\n <div class=\"mat-typography\" *ngIf=\"!displayMode\">\n <div class=\"d-flex flex-row gap-3\">\n <mat-card class=\"flex-grow-1\">\n <mat-card-content>\n <div class=\"d-flex align-items-center\">\n <mat-icon>\n description\n </mat-icon>\n <h3 class=\"font-weight-bold mb-0\">\n {{title}}s\n </h3>\n <app-techlify-icon name=\"add\" class=\"clickable ms-2\" (click)=\"addEntityFile()\"\n *ngIf=\"!viewOnly && isShowCreateAction\" matTooltip=\"Add\"></app-techlify-icon>\n <span class=\"flex-grow-1\"></span>\n <form [formGroup]=\"filterForm\" class=\"d-flex gap-2\">\n <mat-form-field *ngIf=\"!removeSearch\" appearance=\"outline\">\n <mat-label>Search</mat-label>\n <input type=\"text\" matInput formControlName=\"title\" placeholder=\"Search\" name=\"title\"\n autocomplete=\"off\" />\n <button *ngIf=\"filters.title\" matSuffix mat-icon-button (click)=\"resetFilter('title')\">\n <mat-icon>close</mat-icon>\n </button>\n </mat-form-field>\n\n <ng-container *ngIf=\"useTechlifyTags\">\n <mat-form-field>\n <mat-label>Tag</mat-label>\n <app-techlify-tagger-tag-form-field [categories]=\"techlifyTagCategories\" formControlName=\"tag_ids\"\n placeholder=\"Select Tags\" [config]=\"techlifyTagConfig\"></app-techlify-tagger-tag-form-field>\n </mat-form-field>\n </ng-container>\n\n </form>\n </div>\n </mat-card-content>\n <mat-card-content class=\"entity-file-card p-0\">\n <table mat-table [dataSource]=\"models\" class=\"w-100\" matSort multiTemplateDataRows infiniteScroll\n [infiniteScrollDistance]=\"1.5\" [infiniteScrollThrottle]=\"50\" (scrolled)=\"onScroll()\">\n\n <!-- Select Column -->\n <ng-container matColumnDef=\"select\">\n <th mat-header-cell *matHeaderCellDef style=\"width:30px\">\n <mat-checkbox name=\"employee\" [(ngModel)]=\"isAllSelected\" (change)=\"selectAll()\">\n </mat-checkbox>\n </th>\n <td mat-cell *matCellDef=\"let element\" style=\"width:30px\">\n <mat-checkbox name=\"employee[{{element?.id}}]\" (click)=\"$event.stopPropagation()\"\n [(ngModel)]=\"element.is_selected\" (change)=\"isSelectionModified($event, element)\"\n [disabled]=\"!models.length\">\n </mat-checkbox>\n </td>\n </ng-container>\n\n <!-- Index Column -->\n <ng-container matColumnDef=\"index\">\n <th mat-header-cell *matHeaderCellDef> # </th>\n <td mat-cell *matCellDef=\"let element; let i = dataIndex\"> {{ i+1 }} </td>\n </ng-container>\n\n <!-- Title Column -->\n <ng-container matColumnDef=\"title\">\n <th mat-header-cell *matHeaderCellDef> Title </th>\n <td mat-cell *matCellDef=\"let element\">\n {{element.title}}\n <ng-container *ngIf=\"useTechlifyTags\">\n <br>\n <small class=\"badge badge-secondary mr-1\" *ngFor=\"let tag of element?.tags\">{{tag?.title}}</small>\n </ng-container>\n\n </td>\n </ng-container>\n\n <!-- Details Column -->\n <ng-container matColumnDef=\"details\">\n <th mat-header-cell *matHeaderCellDef> Details </th>\n <td mat-cell *matCellDef=\"let element\">\n <app-read-more [text]=\"element.details\" [maxLength]=\"50\"></app-read-more>\n </td>\n </ng-container>\n\n <!-- File size Column -->\n <ng-container matColumnDef=\"file_size\">\n <th mat-header-cell *matHeaderCellDef> File Size </th>\n <td mat-cell *matCellDef=\"let element\"> {{ sizeOf(element.file_size)}} </td>\n </ng-container>\n\n <!-- Uploaded On Column -->\n <ng-container matColumnDef=\"uploaded_on\">\n <th mat-header-cell *matHeaderCellDef> Uploaded On </th>\n <td mat-cell *matCellDef=\"let element\">\n <div>\n {{element.created_at | date: 'mediumDate'}}\n </div>\n <div class=\"text-muted\">\n By {{element.creator?.name}}\n </div>\n </td>\n </ng-container>\n\n <!-- Actions Column -->\n <ng-container matColumnDef=\"actions\">\n <th mat-header-cell *matHeaderCellDef> Actions </th>\n <td mat-cell *matCellDef=\"let element\" class=\"text-muted\">\n <div class=\"d-flex\">\n <a href=\"{{element.url}}\" target=\"_blank\" class=\"text-decoration-none text-muted clickable\">\n <mat-icon>download</mat-icon>\n </a>\n <app-techlify-icon name=\"edit\" class=\"clickable text-secondary\" (click)=\"editEntityFile(element)\"\n *ngIf=\"!viewOnly && isShowUpdateAction\" matTooltip=\"Edit\"></app-techlify-icon>\n <app-techlify-delete-button *ngIf=\"!viewOnly && isShowDeleteAction\" class='text-secondary ms-1'\n [model]=\"element\" [service]=\"entityFileService\"\n message=\"Are you sure to proceed delete the file {{element.title}}\"\n (deleted)=\"modelsDeletedById(element)\">\n </app-techlify-delete-button>\n </div>\n </td>\n </ng-container>\n\n <tr mat-header-row *matHeaderRowDef=\"displayedColumns\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: displayedColumns;\"></tr>\n </table>\n\n <mat-progress-bar mode=\"indeterminate\" *ngIf=\"isWorking\"></mat-progress-bar>\n </mat-card-content>\n </mat-card>\n <ng-container *ngIf=\"isShowDragDropSection\">\n <section style=\"flex: 0 1 30%;\" *ngIf=\"!this.selectedModelIds.length && !viewOnly && isShowCreateAction\">\n <app-file-dropper [config]=\"fileConfig\" (fileChanged)=\"fileChanged($event)\" [fileArray]=\"models\">\n </app-file-dropper>\n </section>\n </ng-container>\n </div>\n </div>\n </div>\n\n <div class=\"d-flex flex-wrap gap-3 mat-typography p-4\" *ngIf=\"displayMode\">\n <div *ngFor=\"let efile of models\">\n <app-document-viewer [file]=\"efile.file\" [fileUrl]=\"efile.url\" [config]=\"this.viewerConfig\" [disableEdit]=\"true\">\n </app-document-viewer>\n <a href=\"{{efile.url}}\" target=\"_blank\">\n <button mat-button type=\"button\">View</button>\n </a>\n </div>\n </div>\n</div>\n\n<mat-card *ngIf=\"viewMode === 'timeline'\">\n <mat-card-content>\n <div class=\"d-flex justify-content-start align-items-center gap-2\">\n <mat-icon>\n description\n </mat-icon>\n <h3 class=\"font-weight-bold mb-0\">\n {{title}}s\n </h3>\n <app-techlify-icon name=\"add\" class=\"clickable\" (click)=\"addEntityFile()\" *ngIf=\"!viewOnly && isShowCreateAction\"\n matTooltip=\"Add\"></app-techlify-icon>\n </div>\n </mat-card-content>\n <mat-card-content *ngIf=\"!this.selectedModelIds.length && !viewOnly && isShowCreateAction\" class=\"mt-3\">\n <app-file-dropper [config]=\"fileConfig\" (fileChanged)=\"fileChanged($event)\" [fileArray]=\"models\">\n </app-file-dropper>\n </mat-card-content>\n\n <mat-card-content class=\"mt-3\">\n <div *ngFor=\"let entityFile of models\" class=\"d-flex flex-column gap-0\">\n <div class=\"d-flex flex-column gap-0\">\n <div class=\"d-flex justify-content-between align-items-center gap-1\">\n <p class=\"mb-0 fw-bold text-wrap\">{{ entityFile?.title | wrap:20 }}</p>\n <span class=\"badge bg-dark\" *ngFor=\"let tag of entityFile?.tags\">\n {{ tag?.title }}\n </span>\n <small class=\"text-dark\">{{ sizeOf(entityFile.file_size) }}</small>\n </div>\n </div>\n <app-read-more [text]=\"entityFile?.details\" [maxLength]=\"50\"></app-read-more>\n <div class=\"d-flex justify-content-between gap-2\">\n <small class=\"text-secondary\" style=\"max-width: 70%\">\n <i>Uploaded By {{ entityFile?.creator?.name }} {{ entityFile?.created_at | date: 'mediumDate'}}</i>\n </small>\n <div class=\"d-flex justify-content-end align-items-center gap-1\">\n <a href=\"{{entityFile?.url}}\" target=\"_blank\" class=\"text-decoration-none text-secondary mt-2\">\n <mat-icon>download</mat-icon>\n </a>\n <app-techlify-icon name=\"edit\" class=\"clickable text-secondary\" (click)=\"editEntityFile(entityFile)\"\n *ngIf=\"!viewOnly && isShowUpdateAction\" matTooltip=\"Edit\"></app-techlify-icon>\n <app-techlify-delete-button *ngIf=\"!viewOnly && isShowDeleteAction\" class='text-secondary ms-1'\n [model]=\"entityFile\" [service]=\"entityFileService\"\n message=\"Are you sure to proceed delete the file {{entityFile.title}}\"\n (deleted)=\"modelsDeletedById(entityFile)\">\n </app-techlify-delete-button>\n </div>\n </div>\n <hr style=\"margin: 0.5rem 0\">\n </div>\n <mat-progress-bar mode=\"indeterminate\" *ngIf=\"isWorking\"></mat-progress-bar>\n </mat-card-content>\n</mat-card>", styles: ["th.mat-header-cell,td.mat-cell,td.mat-footer-cell{padding:2px}.entity-file-card{overflow-x:auto}.clickable:hover{cursor:pointer}\n"] }]
|
|
5410
5333
|
}], ctorParameters: () => [{ type: EntityFileService }, { type: i3.Location }, { type: AlertService }, { type: i1.MatDialog }, { type: i1$5.UntypedFormBuilder }, { type: ErrorHandlerService }, { type: CurrentUserService }], propDecorators: { entityId: [{
|
|
5411
5334
|
type: Input
|
|
5412
5335
|
}], entityType: [{
|
|
@@ -6160,7 +6083,9 @@ class EntityFilesViewAllModule {
|
|
|
6160
6083
|
SearchableSelectorModule,
|
|
6161
6084
|
ReadMoreModule,
|
|
6162
6085
|
MatProgressBarModule,
|
|
6163
|
-
WrapPipe
|
|
6086
|
+
WrapPipe,
|
|
6087
|
+
TechlifyIconModule,
|
|
6088
|
+
TechlifyDeleteButtonComponent], exports: [EntityFilesViewAllComponent] }); }
|
|
6164
6089
|
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: EntityFilesViewAllModule, imports: [CommonModule,
|
|
6165
6090
|
FormsModule,
|
|
6166
6091
|
ReactiveFormsModule,
|
|
@@ -6171,7 +6096,9 @@ class EntityFilesViewAllModule {
|
|
|
6171
6096
|
TechlifyTaggerTagFormFieldModule,
|
|
6172
6097
|
SearchableSelectorModule,
|
|
6173
6098
|
ReadMoreModule,
|
|
6174
|
-
MatProgressBarModule
|
|
6099
|
+
MatProgressBarModule,
|
|
6100
|
+
TechlifyIconModule,
|
|
6101
|
+
TechlifyDeleteButtonComponent] }); }
|
|
6175
6102
|
}
|
|
6176
6103
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: EntityFilesViewAllModule, decorators: [{
|
|
6177
6104
|
type: NgModule,
|
|
@@ -6190,7 +6117,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
6190
6117
|
SearchableSelectorModule,
|
|
6191
6118
|
ReadMoreModule,
|
|
6192
6119
|
MatProgressBarModule,
|
|
6193
|
-
WrapPipe
|
|
6120
|
+
WrapPipe,
|
|
6121
|
+
TechlifyIconModule,
|
|
6122
|
+
TechlifyDeleteButtonComponent
|
|
6194
6123
|
],
|
|
6195
6124
|
exports: [
|
|
6196
6125
|
EntityFilesViewAllComponent
|