@volo/abp.ng.audit-logging 7.2.1 → 7.3.0-rc.1

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.
Files changed (147) hide show
  1. package/common/enums/index.d.ts +1 -1
  2. package/common/enums/route-names.d.ts +3 -3
  3. package/common/index.d.ts +5 -5
  4. package/common/public-api.d.ts +2 -2
  5. package/common/tokens/features.token.d.ts +12 -12
  6. package/common/tokens/index.d.ts +1 -1
  7. package/config/audit-logging-config.module.d.ts +12 -12
  8. package/config/components/entity-change-details.component.d.ts +19 -19
  9. package/config/components/entity-change-modal.component.d.ts +15 -15
  10. package/config/components/index.d.ts +2 -2
  11. package/config/enums/index.d.ts +2 -2
  12. package/config/enums/policy-names.d.ts +3 -3
  13. package/config/enums/route-names.d.ts +2 -2
  14. package/config/index.d.ts +5 -5
  15. package/config/providers/entity-details.provider.d.ts +7 -7
  16. package/config/providers/entity-history.provider.d.ts +7 -7
  17. package/config/providers/index.d.ts +3 -3
  18. package/config/providers/route.provider.d.ts +8 -8
  19. package/config/public-api.d.ts +5 -5
  20. package/config/services/entity-change-modal.service.d.ts +15 -15
  21. package/config/services/index.d.ts +1 -1
  22. package/{esm2020 → esm2022}/common/enums/index.mjs +1 -1
  23. package/{esm2020 → esm2022}/common/enums/route-names.mjs +1 -1
  24. package/{esm2020 → esm2022}/common/public-api.mjs +2 -2
  25. package/{esm2020 → esm2022}/common/tokens/features.token.mjs +30 -30
  26. package/{esm2020 → esm2022}/common/tokens/index.mjs +1 -1
  27. package/{esm2020 → esm2022}/common/volo-abp.ng.audit-logging-common.mjs +4 -4
  28. package/esm2022/config/audit-logging-config.module.mjs +35 -0
  29. package/esm2022/config/components/entity-change-details.component.mjs +46 -0
  30. package/esm2022/config/components/entity-change-modal.component.mjs +23 -0
  31. package/{esm2020 → esm2022}/config/components/index.mjs +2 -2
  32. package/{esm2020 → esm2022}/config/enums/index.mjs +2 -2
  33. package/{esm2020 → esm2022}/config/enums/policy-names.mjs +1 -1
  34. package/{esm2020 → esm2022}/config/enums/route-names.mjs +1 -1
  35. package/{esm2020 → esm2022}/config/providers/entity-details.provider.mjs +12 -12
  36. package/{esm2020 → esm2022}/config/providers/entity-history.provider.mjs +12 -12
  37. package/{esm2020 → esm2022}/config/providers/index.mjs +3 -3
  38. package/{esm2020 → esm2022}/config/providers/route.provider.mjs +20 -20
  39. package/{esm2020 → esm2022}/config/public-api.mjs +5 -5
  40. package/esm2022/config/services/entity-change-modal.service.mjs +52 -0
  41. package/{esm2020 → esm2022}/config/services/index.mjs +1 -1
  42. package/{esm2020 → esm2022}/config/volo-abp.ng.audit-logging-config.mjs +4 -4
  43. package/esm2022/lib/audit-logging-routing.module.mjs +42 -0
  44. package/esm2022/lib/audit-logging.module.mjs +98 -0
  45. package/esm2022/lib/components/audit-log-datetime-picker/audit-log-datetime-picker.component.mjs +63 -0
  46. package/esm2022/lib/components/audit-logs/audit-logs.component.mjs +115 -0
  47. package/esm2022/lib/components/entity-change/entity-changes.component.mjs +82 -0
  48. package/{esm2020 → esm2022}/lib/components/index.mjs +4 -4
  49. package/esm2022/lib/components/widgets/average-execution-duration-widget.component.mjs +116 -0
  50. package/esm2022/lib/components/widgets/error-rate-widget.component.mjs +117 -0
  51. package/{esm2020 → esm2022}/lib/constants/http.mjs +63 -63
  52. package/{esm2020 → esm2022}/lib/constants/index.mjs +1 -1
  53. package/{esm2020 → esm2022}/lib/defaults/default-audit-logs-entity-actions.mjs +12 -12
  54. package/{esm2020 → esm2022}/lib/defaults/default-audit-logs-entity-props.mjs +56 -56
  55. package/{esm2020 → esm2022}/lib/defaults/default-audit-logs-toolbar-actions.mjs +2 -2
  56. package/{esm2020 → esm2022}/lib/defaults/default-entity-changes-entity-actions.mjs +21 -21
  57. package/{esm2020 → esm2022}/lib/enums/components.mjs +1 -1
  58. package/{esm2020 → esm2022}/lib/enums/entity-change.mjs +6 -6
  59. package/{esm2020 → esm2022}/lib/enums/index.mjs +2 -2
  60. package/esm2022/lib/guards/audit-logging.guard.mjs +24 -0
  61. package/esm2022/lib/guards/extensions.guard.mjs +32 -0
  62. package/{esm2020 → esm2022}/lib/guards/index.mjs +2 -2
  63. package/{esm2020 → esm2022}/lib/models/audit-logging.mjs +1 -1
  64. package/{esm2020 → esm2022}/lib/models/config-options.mjs +1 -1
  65. package/{esm2020 → esm2022}/lib/models/index.mjs +2 -2
  66. package/{esm2020 → esm2022}/lib/tokens/entity-details.token.mjs +2 -2
  67. package/{esm2020 → esm2022}/lib/tokens/extensions.token.mjs +18 -18
  68. package/{esm2020 → esm2022}/lib/tokens/index.mjs +2 -2
  69. package/{esm2020 → esm2022}/proxy/lib/index.mjs +2 -2
  70. package/esm2022/proxy/lib/proxy/audit-logging/audit-logs.service.mjs +57 -0
  71. package/{esm2020 → esm2022}/proxy/lib/proxy/audit-logging/index.mjs +2 -2
  72. package/{esm2020 → esm2022}/proxy/lib/proxy/audit-logging/models.mjs +1 -1
  73. package/{esm2020 → esm2022}/proxy/lib/proxy/auditing/entity-change-type.enum.mjs +8 -8
  74. package/{esm2020 → esm2022}/proxy/lib/proxy/auditing/index.mjs +1 -1
  75. package/{esm2020 → esm2022}/proxy/public-api.mjs +1 -1
  76. package/{esm2020 → esm2022}/proxy/volo-abp.ng.audit-logging-proxy.mjs +4 -4
  77. package/{esm2020 → esm2022}/public-api.mjs +7 -7
  78. package/{esm2020 → esm2022}/volo-abp.ng.audit-logging.mjs +4 -4
  79. package/{fesm2015 → fesm2022}/volo-abp.ng.audit-logging-common.mjs +28 -28
  80. package/{fesm2020 → fesm2022}/volo-abp.ng.audit-logging-config.mjs +151 -151
  81. package/{fesm2020 → fesm2022}/volo-abp.ng.audit-logging-config.mjs.map +1 -1
  82. package/{fesm2015 → fesm2022}/volo-abp.ng.audit-logging-proxy.mjs +60 -60
  83. package/{fesm2020 → fesm2022}/volo-abp.ng.audit-logging-proxy.mjs.map +1 -1
  84. package/{fesm2020 → fesm2022}/volo-abp.ng.audit-logging.mjs +635 -635
  85. package/fesm2022/volo-abp.ng.audit-logging.mjs.map +1 -0
  86. package/index.d.ts +5 -5
  87. package/lib/audit-logging-routing.module.d.ts +7 -7
  88. package/lib/audit-logging.module.d.ts +22 -22
  89. package/lib/components/audit-log-datetime-picker/audit-log-datetime-picker.component.d.ts +19 -19
  90. package/lib/components/audit-logs/audit-logs.component.d.ts +32 -32
  91. package/lib/components/entity-change/entity-changes.component.d.ts +24 -24
  92. package/lib/components/index.d.ts +4 -4
  93. package/lib/components/widgets/average-execution-duration-widget.component.d.ts +25 -25
  94. package/lib/components/widgets/error-rate-widget.component.d.ts +24 -24
  95. package/lib/constants/http.d.ts +5 -5
  96. package/lib/constants/index.d.ts +1 -1
  97. package/lib/defaults/default-audit-logs-entity-actions.d.ts +3 -3
  98. package/lib/defaults/default-audit-logs-entity-props.d.ts +3 -3
  99. package/lib/defaults/default-audit-logs-toolbar-actions.d.ts +3 -3
  100. package/lib/defaults/default-entity-changes-entity-actions.d.ts +3 -3
  101. package/lib/enums/components.d.ts +4 -4
  102. package/lib/enums/entity-change.d.ts +5 -5
  103. package/lib/enums/index.d.ts +2 -2
  104. package/lib/guards/audit-logging.guard.d.ts +10 -11
  105. package/lib/guards/extensions.guard.d.ts +10 -11
  106. package/lib/guards/index.d.ts +2 -2
  107. package/lib/models/audit-logging.d.ts +9 -9
  108. package/lib/models/config-options.d.ts +18 -18
  109. package/lib/models/index.d.ts +2 -2
  110. package/lib/tokens/entity-details.token.d.ts +2 -2
  111. package/lib/tokens/extensions.token.d.ts +23 -23
  112. package/lib/tokens/index.d.ts +2 -2
  113. package/package.json +17 -29
  114. package/proxy/index.d.ts +5 -5
  115. package/proxy/lib/index.d.ts +2 -2
  116. package/proxy/lib/proxy/audit-logging/audit-logs.service.d.ts +19 -19
  117. package/proxy/lib/proxy/audit-logging/index.d.ts +2 -2
  118. package/proxy/lib/proxy/audit-logging/models.d.ts +93 -93
  119. package/proxy/lib/proxy/auditing/entity-change-type.enum.d.ts +6 -6
  120. package/proxy/lib/proxy/auditing/index.d.ts +1 -1
  121. package/proxy/public-api.d.ts +1 -1
  122. package/public-api.d.ts +7 -7
  123. package/esm2020/config/audit-logging-config.module.mjs +0 -34
  124. package/esm2020/config/components/entity-change-details.component.mjs +0 -45
  125. package/esm2020/config/components/entity-change-modal.component.mjs +0 -22
  126. package/esm2020/config/services/entity-change-modal.service.mjs +0 -51
  127. package/esm2020/lib/audit-logging-routing.module.mjs +0 -41
  128. package/esm2020/lib/audit-logging.module.mjs +0 -97
  129. package/esm2020/lib/components/audit-log-datetime-picker/audit-log-datetime-picker.component.mjs +0 -62
  130. package/esm2020/lib/components/audit-logs/audit-logs.component.mjs +0 -114
  131. package/esm2020/lib/components/entity-change/entity-changes.component.mjs +0 -81
  132. package/esm2020/lib/components/widgets/average-execution-duration-widget.component.mjs +0 -115
  133. package/esm2020/lib/components/widgets/error-rate-widget.component.mjs +0 -116
  134. package/esm2020/lib/guards/audit-logging.guard.mjs +0 -23
  135. package/esm2020/lib/guards/extensions.guard.mjs +0 -31
  136. package/esm2020/proxy/lib/proxy/audit-logging/audit-logs.service.mjs +0 -56
  137. package/fesm2015/volo-abp.ng.audit-logging-common.mjs.map +0 -1
  138. package/fesm2015/volo-abp.ng.audit-logging-config.mjs +0 -182
  139. package/fesm2015/volo-abp.ng.audit-logging-config.mjs.map +0 -1
  140. package/fesm2015/volo-abp.ng.audit-logging-proxy.mjs.map +0 -1
  141. package/fesm2015/volo-abp.ng.audit-logging.mjs +0 -785
  142. package/fesm2015/volo-abp.ng.audit-logging.mjs.map +0 -1
  143. package/fesm2020/volo-abp.ng.audit-logging-common.mjs +0 -38
  144. package/fesm2020/volo-abp.ng.audit-logging-proxy.mjs +0 -71
  145. package/fesm2020/volo-abp.ng.audit-logging.mjs.map +0 -1
  146. package/proxy/src/lib/proxy/README.md +0 -17
  147. /package/{fesm2020 → fesm2022}/volo-abp.ng.audit-logging-common.mjs.map +0 -0
@@ -1,785 +0,0 @@
1
- import * as i3$1 from '@abp/ng.components/chart.js';
2
- import { ChartComponent, ChartModule } from '@abp/ng.components/chart.js';
3
- import * as i8$1 from '@abp/ng.components/page';
4
- import { PageModule } from '@abp/ng.components/page';
5
- import * as i1 from '@abp/ng.core';
6
- import { AbstractNgModelComponent, mapEnumToOptions, ListService, ConfigStateService, RouterOutletComponent, AuthGuard, PermissionGuard, ReplaceableRouteContainerComponent, LazyModuleFactory, CoreModule } from '@abp/ng.core';
7
- import * as i8 from '@abp/ng.theme.shared';
8
- import { collapse, fadeIn, ThemeSharedModule } from '@abp/ng.theme.shared';
9
- import * as i0 from '@angular/core';
10
- import { inject, Injector, forwardRef, Component, ChangeDetectionStrategy, Injectable, Inject, InjectionToken, NgModule, Output, Input, ViewChild } from '@angular/core';
11
- import * as i7 from '@ng-bootstrap/ng-bootstrap';
12
- import { NgbDateParserFormatter, NgbDateAdapter, NgbDateStructAdapter, NgbDatepickerModule, NgbTimepicker, NgbPopoverModule, NgbNavModule } from '@ng-bootstrap/ng-bootstrap';
13
- import * as i5 from '@volo/abp.commercial.ng.ui';
14
- import { SHOW_ENTITY_HISTORY, CommercialUiModule } from '@volo/abp.commercial.ng.ui';
15
- import * as i1$2 from '@angular/router';
16
- import { RouterModule } from '@angular/router';
17
- import * as i6 from '@abp/ng.theme.shared/extensions';
18
- import { DateTimeAdapter, TimeAdapter, EXTENSIONS_IDENTIFIER, DateAdapter, EntityAction, EntityProp, ToolbarAction, ExtensionsService, getObjectExtensionEntitiesFromStore, mapEntitiesToContributors, mergeWithDefaultActions, mergeWithDefaultProps } from '@abp/ng.theme.shared/extensions';
19
- import { trigger, transition, useAnimation } from '@angular/animations';
20
- import { take, map, tap, mapTo } from 'rxjs/operators';
21
- import * as i2$1 from '@volo/abp.ng.audit-logging/proxy';
22
- import { EntityChangeType } from '@volo/abp.ng.audit-logging/proxy';
23
- import * as i3 from '@angular/common';
24
- import { CommonModule } from '@angular/common';
25
- import * as i2 from '@angular/forms';
26
- import { NG_VALUE_ACCESSOR, FormsModule } from '@angular/forms';
27
- import * as i7$1 from '@swimlane/ngx-datatable';
28
- import * as i9 from '@ngx-validate/core';
29
- import { AUDIT_LOGGING_FEATURES } from '@volo/abp.ng.audit-logging/common';
30
- import * as i1$1 from 'rxjs';
31
- import { of, BehaviorSubject } from 'rxjs';
32
-
33
- const HTTP_METHODS = ['GET', 'POST', 'DELETE', 'PUT', 'HEAD', 'CONNECT', 'OPTIONS', 'TRACE'];
34
- const HTTP_STATUS_CODES = [
35
- { code: 100, message: 'Continue' },
36
- { code: 101, message: 'Switching Protocols' },
37
- { code: 102, message: 'Processing' },
38
- { code: 103, message: 'Early Hints' },
39
- { code: 200, message: 'OK' },
40
- { code: 201, message: 'Created' },
41
- { code: 202, message: 'Accepted' },
42
- { code: 203, message: 'Non-authoritative Information' },
43
- { code: 204, message: 'No Content' },
44
- { code: 205, message: 'Reset Content' },
45
- { code: 206, message: 'Partial Content' },
46
- { code: 207, message: 'Multi-Status' },
47
- { code: 208, message: 'Already Registered' },
48
- { code: 226, message: 'IM Used' },
49
- { code: 300, message: 'Multiple Choices' },
50
- { code: 301, message: 'Moved Permanently' },
51
- { code: 302, message: 'Found' },
52
- { code: 303, message: 'See Other' },
53
- { code: 304, message: 'Not Modified' },
54
- { code: 305, message: 'Use Proxy' },
55
- { code: 306, message: 'Switch Proxy' },
56
- { code: 307, message: 'Temporary Redirect' },
57
- { code: 308, message: 'Permanent Redirect' },
58
- { code: 400, message: 'Bad Request' },
59
- { code: 401, message: 'Unauthorized' },
60
- { code: 402, message: 'Payment Required' },
61
- { code: 403, message: 'Forbidden' },
62
- { code: 404, message: 'Not Found' },
63
- { code: 405, message: 'Method Not Allowed' },
64
- { code: 406, message: 'Not Acceptable' },
65
- { code: 407, message: 'Proxy Authentication Required' },
66
- { code: 408, message: 'Request Timeout' },
67
- { code: 409, message: 'Conflict' },
68
- { code: 410, message: 'Gone' },
69
- { code: 411, message: 'Length Required' },
70
- { code: 412, message: 'Precondition Failed' },
71
- { code: 413, message: 'Payload Too Large' },
72
- { code: 414, message: 'Request-URI Too Long' },
73
- { code: 415, message: 'Unsupported Media Type' },
74
- { code: 416, message: 'Requested Range Not Satisfiable' },
75
- { code: 417, message: 'Expectation Failed' },
76
- { code: 421, message: 'Misdirected Request' },
77
- { code: 423, message: 'Locked' },
78
- { code: 424, message: 'Failed Dependency' },
79
- { code: 426, message: 'Upgrade Required' },
80
- { code: 428, message: 'Precondition Required' },
81
- { code: 429, message: 'Too Many Requests' },
82
- { code: 431, message: 'Request Header Fields Too Large' },
83
- { code: 451, message: 'Unavailable For Legal Reasons' },
84
- { code: 500, message: 'Internal Server Error' },
85
- { code: 501, message: 'Not Implemented' },
86
- { code: 502, message: 'Bad Gateway' },
87
- { code: 503, message: 'Service Unavailable' },
88
- { code: 504, message: 'Gateway Timeout' },
89
- { code: 505, message: 'HTTP Version Not Supported' },
90
- { code: 506, message: 'Variant Also Negotiates' },
91
- { code: 507, message: 'Insufficient Storage' },
92
- { code: 508, message: 'Loop Detected' },
93
- { code: 510, message: 'Not Extended' },
94
- { code: 511, message: 'Network Authentication Required' },
95
- ];
96
-
97
- class AuditLogDatetimePickerComponent extends AbstractNgModelComponent {
98
- constructor() {
99
- const injector = inject(Injector);
100
- super(injector);
101
- this.dateTimeAdapter = inject(DateTimeAdapter);
102
- this.timeAdapter = inject(TimeAdapter);
103
- this.formatter = inject(NgbDateParserFormatter);
104
- this.separator = ' - ';
105
- this.formattedValue = '';
106
- }
107
- setTime(val) {
108
- this.time = val;
109
- this.change();
110
- }
111
- setDate(val) {
112
- this.date = val;
113
- this.change();
114
- }
115
- change() {
116
- if (!this.date) {
117
- return;
118
- }
119
- this.value = this.dateTimeAdapter.toModel(Object.assign(Object.assign({}, this.date), this.time));
120
- const date = this.formatter.format(this.date);
121
- const time = this.timeAdapter.toModel(this.time);
122
- this.formattedValue = [date, time].filter(x => !!x).join(this.separator);
123
- }
124
- }
125
- AuditLogDatetimePickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLogDatetimePickerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
126
- AuditLogDatetimePickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.1", type: AuditLogDatetimePickerComponent, isStandalone: true, selector: "abp-audit-log-datetime-picker", providers: [
127
- {
128
- provide: NG_VALUE_ACCESSOR,
129
- useExisting: forwardRef(() => AuditLogDatetimePickerComponent),
130
- multi: true,
131
- },
132
- { provide: DateTimeAdapter, useClass: DateTimeAdapter },
133
- { provide: TimeAdapter, useClass: TimeAdapter },
134
- { provide: NgbDateAdapter, useClass: NgbDateStructAdapter },
135
- ], usesInheritance: true, ngImport: i0, template: "<input\r\n [value]=\"formattedValue\"\r\n (dateSelect)=\"setDate($event)\"\r\n (click)=\"datepicker.open()\"\r\n (keyup.space)=\"datepicker.open()\"\r\n ngbDatepicker\r\n [autoClose]=\"'outside'\"\r\n #datepicker=\"ngbDatepicker\"\r\n [footerTemplate]=\"footer\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n/>\r\n<ng-template #footer>\r\n <div class=\"d-flex justify-content-center\">\r\n <ngb-timepicker\r\n [ngModel]=\"time\"\r\n (ngModelChange)=\"setTime($event)\"\r\n ></ngb-timepicker>\r\n </div>\r\n</ng-template>\r\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: NgbDatepickerModule }, { kind: "directive", type: i7.NgbInputDatepicker, selector: "input[ngbDatepicker]", inputs: ["autoClose", "datepickerClass", "dayTemplate", "dayTemplateData", "displayMonths", "firstDayOfWeek", "footerTemplate", "markDisabled", "minDate", "maxDate", "navigation", "outsideDays", "placement", "popperOptions", "restoreFocus", "showWeekNumbers", "startDate", "container", "positionTarget", "weekdays", "disabled"], outputs: ["dateSelect", "navigate", "closed"], exportAs: ["ngbDatepicker"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: NgbTimepicker, selector: "ngb-timepicker", inputs: ["meridian", "spinners", "seconds", "hourStep", "minuteStep", "secondStep", "readonlyInputs", "size"], exportAs: ["ngbTimepicker"] }, { kind: "ngmodule", type: NgbPopoverModule }] });
136
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLogDatetimePickerComponent, decorators: [{
137
- type: Component,
138
- args: [{ selector: 'abp-audit-log-datetime-picker', standalone: true, imports: [CommonModule, NgbDatepickerModule, FormsModule, NgbTimepicker, NgbPopoverModule], providers: [
139
- {
140
- provide: NG_VALUE_ACCESSOR,
141
- useExisting: forwardRef(() => AuditLogDatetimePickerComponent),
142
- multi: true,
143
- },
144
- { provide: DateTimeAdapter, useClass: DateTimeAdapter },
145
- { provide: TimeAdapter, useClass: TimeAdapter },
146
- { provide: NgbDateAdapter, useClass: NgbDateStructAdapter },
147
- ], template: "<input\r\n [value]=\"formattedValue\"\r\n (dateSelect)=\"setDate($event)\"\r\n (click)=\"datepicker.open()\"\r\n (keyup.space)=\"datepicker.open()\"\r\n ngbDatepicker\r\n [autoClose]=\"'outside'\"\r\n #datepicker=\"ngbDatepicker\"\r\n [footerTemplate]=\"footer\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n/>\r\n<ng-template #footer>\r\n <div class=\"d-flex justify-content-center\">\r\n <ngb-timepicker\r\n [ngModel]=\"time\"\r\n (ngModelChange)=\"setTime($event)\"\r\n ></ngb-timepicker>\r\n </div>\r\n</ng-template>\r\n" }]
148
- }], ctorParameters: function () { return []; } });
149
-
150
- class EntityChangesComponent {
151
- constructor(list, fb, auditLogsService, track, cdr) {
152
- this.list = list;
153
- this.fb = fb;
154
- this.auditLogsService = auditLogsService;
155
- this.track = track;
156
- this.cdr = cdr;
157
- this.form = this.fb.group({
158
- entityChangeType: [''],
159
- entityTypeFullName: [''],
160
- times: [{}],
161
- });
162
- this.response = { items: [], totalCount: 0 };
163
- this.changeType = EntityChangeType;
164
- this.changeTypes = mapEnumToOptions(EntityChangeType);
165
- }
166
- get data() {
167
- return this.response.items;
168
- }
169
- get count() {
170
- return this.response.totalCount;
171
- }
172
- ngAfterViewInit() {
173
- this.hookToQuery();
174
- this.list.get();
175
- }
176
- hookToQuery() {
177
- this.list
178
- .hookToQuery(query => {
179
- const value = Object.assign(Object.assign({}, this.form.value), this.form.value.times);
180
- return this.auditLogsService.getEntityChanges(Object.assign(Object.assign({}, value), query));
181
- })
182
- .subscribe(res => {
183
- this.response = res;
184
- this.cdr.detectChanges();
185
- });
186
- }
187
- handleSubmit() {
188
- this.list.get();
189
- }
190
- }
191
- EntityChangesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: EntityChangesComponent, deps: [{ token: i1.ListService }, { token: i2.UntypedFormBuilder }, { token: i2$1.AuditLogsService }, { token: i1.TrackByService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
192
- EntityChangesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.1", type: EntityChangesComponent, selector: "abp-entity-changes", providers: [
193
- ListService,
194
- {
195
- provide: EXTENSIONS_IDENTIFIER,
196
- useValue: "AuditLogging.EntityChangesComponent" /* eAuditLoggingComponents.EntityChanges */,
197
- },
198
- { provide: NgbDateAdapter, useClass: DateAdapter },
199
- ], ngImport: i0, template: "<div class=\"card\">\r\n <div class=\"card-body pb-lg-3 px-0\">\r\n <form [formGroup]=\"form\" (ngSubmit)=\"handleSubmit()\">\r\n <div class=\"row\">\r\n <div class=\"col-md-12 col-lg-4 col-xxl-3\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\">{{ 'AbpAuditLogging::ChangeTime' | abpLocalization }}</label>\r\n <abp-date-range-picker\r\n formControlName=\"times\"\r\n startDateProp=\"startTime\"\r\n endDateProp=\"endTime\"\r\n >\r\n </abp-date-range-picker>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-3\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"change-type\">{{\r\n 'AbpAuditLogging::ChangeType' | abpLocalization\r\n }}</label\r\n ><select\r\n id=\"change-type\"\r\n class=\"form-select form-control\"\r\n formControlName=\"entityChangeType\"\r\n (change)=\"handleSubmit()\"\r\n >\r\n <option [ngValue]=\"\"></option>\r\n <option\r\n *ngFor=\"let type of changeTypes; trackBy: track.by('id')\"\r\n [ngValue]=\"type.value\"\r\n >\r\n {{ 'AbpAuditLogging::' + type.key | abpLocalization }}\r\n </option>\r\n </select>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-3\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"entity-type-full-name\">{{\r\n 'AbpAuditLogging::EntityTypeFullName' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"entity-type-full-name\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n formControlName=\"entityTypeFullName\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-12 col-lg-2\">\r\n <div class=\"mt-3\">\r\n <div class=\"col-6 d-grid text-end\">\r\n <button type=\"submit\" class=\"btn btn-primary\">\r\n <span>\r\n {{ 'AbpAuditLogging::Refresh' | abpLocalization }}\r\n </span>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </form>\r\n </div>\r\n</div>\r\n<div class=\"card\">\r\n <div class=\"card-body p-0\">\r\n <ngx-datatable default [rows]=\"data\" [count]=\"count\" [list]=\"list\">\r\n <ngx-datatable-column\r\n [name]=\"'AbpAuditLogging::Detail' | abpLocalization\"\r\n [maxWidth]=\"150\"\r\n [width]=\"150\"\r\n [sortable]=\"false\"\r\n >\r\n <ng-template let-row=\"row\" let-i=\"rowIndex\" ngx-datatable-cell-template>\r\n <abp-grid-actions\r\n [index]=\"i\"\r\n [record]=\"row\"\r\n text=\"AbpAuditLogging::Actions\"\r\n ></abp-grid-actions>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n <ngx-datatable-column\r\n [name]=\"'AbpAuditLogging::Time' | abpLocalization\"\r\n [width]=\"230\"\r\n prop=\"changeTime\"\r\n >\r\n </ngx-datatable-column>\r\n <ngx-datatable-column\r\n [name]=\"'AbpAuditLogging::ChangeType' | abpLocalization\"\r\n [width]=\"140\"\r\n [sortable]=\"false\"\r\n >\r\n <ng-template let-row=\"row\" ngx-datatable-cell-template>\r\n {{ 'AbpAuditLogging::' + changeType[row.changeType] | abpLocalization }}\r\n </ng-template>\r\n </ngx-datatable-column>\r\n <ngx-datatable-column name=\"TenantId\" [width]=\"150\" [sortable]=\"false\">\r\n <ng-template let-row=\"row\" ngx-datatable-cell-template>\r\n <div abpEllipsis>{{ row.tenantId }}</div>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n <ngx-datatable-column\r\n [name]=\"'AbpAuditLogging::EntityTypeFullName' | abpLocalization\"\r\n [width]=\"150\"\r\n [sortable]=\"false\"\r\n >\r\n <ng-template let-row=\"row\" ngx-datatable-cell-template>\r\n <div abpEllipsis>{{ row.entityTypeFullName }}</div>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n </ngx-datatable>\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "directive", type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.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: i2.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1.FormSubmitDirective, selector: "form[ngSubmit][formGroup]", inputs: ["debounce", "notValidateOnSubmit", "markAsDirtyWhenSubmit"], outputs: ["ngSubmit"] }, { kind: "component", type: i5.DateRangePickerComponent, selector: "abp-date-range-picker", inputs: ["startDateProp", "endDateProp", "labelText"] }, { kind: "component", type: i6.GridActionsComponent, selector: "abp-grid-actions", inputs: ["icon", "index", "text"], exportAs: ["abpGridActions"] }, { kind: "component", type: i7$1.DatatableComponent, selector: "ngx-datatable", inputs: ["targetMarkerTemplate", "rows", "groupRowsBy", "groupedRows", "columns", "selected", "scrollbarV", "scrollbarH", "rowHeight", "columnMode", "headerHeight", "footerHeight", "externalPaging", "externalSorting", "limit", "count", "offset", "loadingIndicator", "selectionType", "reorderable", "swapColumns", "sortType", "sorts", "cssClasses", "messages", "rowClass", "selectCheck", "displayCheck", "groupExpansionDefault", "trackByProp", "selectAllRowsOnPage", "virtualization", "treeFromRelation", "treeToRelation", "summaryRow", "summaryHeight", "summaryPosition", "rowIdentity"], outputs: ["scroll", "activate", "select", "sort", "page", "reorder", "resize", "tableContextmenu", "treeAction"] }, { kind: "directive", type: i7$1.DataTableColumnDirective, selector: "ngx-datatable-column", inputs: ["name", "prop", "frozenLeft", "frozenRight", "flexGrow", "resizeable", "comparator", "pipe", "sortable", "draggable", "canAutoResize", "minWidth", "width", "maxWidth", "checkboxable", "headerCheckboxable", "headerClass", "cellClass", "isTreeColumn", "treeLevelIndent", "summaryFunc", "summaryTemplate", "cellTemplate", "headerTemplate", "treeToggleTemplate"] }, { kind: "directive", type: i7$1.DataTableColumnCellDirective, selector: "[ngx-datatable-cell-template]" }, { kind: "directive", type: i8.EllipsisDirective, selector: "[abpEllipsis]", inputs: ["abpEllipsis", "title", "abpEllipsisEnabled"] }, { kind: "directive", type: i9.ValidationGroupDirective, selector: "[formGroup],[formGroupName]", exportAs: ["validationGroup"] }, { kind: "directive", type: i9.ValidationDirective, selector: "[formControl],[formControlName]", exportAs: ["validationDirective"] }, { kind: "directive", type: i8.NgxDatatableDefaultDirective, selector: "ngx-datatable[default]", inputs: ["class"], exportAs: ["ngxDatatableDefault"] }, { kind: "directive", type: i8.NgxDatatableListDirective, selector: "ngx-datatable[list]", inputs: ["list"], exportAs: ["ngxDatatableList"] }, { kind: "pipe", type: i1.LocalizationPipe, name: "abpLocalization" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
200
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: EntityChangesComponent, decorators: [{
201
- type: Component,
202
- args: [{ selector: 'abp-entity-changes', changeDetection: ChangeDetectionStrategy.OnPush, providers: [
203
- ListService,
204
- {
205
- provide: EXTENSIONS_IDENTIFIER,
206
- useValue: "AuditLogging.EntityChangesComponent" /* eAuditLoggingComponents.EntityChanges */,
207
- },
208
- { provide: NgbDateAdapter, useClass: DateAdapter },
209
- ], template: "<div class=\"card\">\r\n <div class=\"card-body pb-lg-3 px-0\">\r\n <form [formGroup]=\"form\" (ngSubmit)=\"handleSubmit()\">\r\n <div class=\"row\">\r\n <div class=\"col-md-12 col-lg-4 col-xxl-3\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\">{{ 'AbpAuditLogging::ChangeTime' | abpLocalization }}</label>\r\n <abp-date-range-picker\r\n formControlName=\"times\"\r\n startDateProp=\"startTime\"\r\n endDateProp=\"endTime\"\r\n >\r\n </abp-date-range-picker>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-3\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"change-type\">{{\r\n 'AbpAuditLogging::ChangeType' | abpLocalization\r\n }}</label\r\n ><select\r\n id=\"change-type\"\r\n class=\"form-select form-control\"\r\n formControlName=\"entityChangeType\"\r\n (change)=\"handleSubmit()\"\r\n >\r\n <option [ngValue]=\"\"></option>\r\n <option\r\n *ngFor=\"let type of changeTypes; trackBy: track.by('id')\"\r\n [ngValue]=\"type.value\"\r\n >\r\n {{ 'AbpAuditLogging::' + type.key | abpLocalization }}\r\n </option>\r\n </select>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-3\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"entity-type-full-name\">{{\r\n 'AbpAuditLogging::EntityTypeFullName' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"entity-type-full-name\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n formControlName=\"entityTypeFullName\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-12 col-lg-2\">\r\n <div class=\"mt-3\">\r\n <div class=\"col-6 d-grid text-end\">\r\n <button type=\"submit\" class=\"btn btn-primary\">\r\n <span>\r\n {{ 'AbpAuditLogging::Refresh' | abpLocalization }}\r\n </span>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </form>\r\n </div>\r\n</div>\r\n<div class=\"card\">\r\n <div class=\"card-body p-0\">\r\n <ngx-datatable default [rows]=\"data\" [count]=\"count\" [list]=\"list\">\r\n <ngx-datatable-column\r\n [name]=\"'AbpAuditLogging::Detail' | abpLocalization\"\r\n [maxWidth]=\"150\"\r\n [width]=\"150\"\r\n [sortable]=\"false\"\r\n >\r\n <ng-template let-row=\"row\" let-i=\"rowIndex\" ngx-datatable-cell-template>\r\n <abp-grid-actions\r\n [index]=\"i\"\r\n [record]=\"row\"\r\n text=\"AbpAuditLogging::Actions\"\r\n ></abp-grid-actions>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n <ngx-datatable-column\r\n [name]=\"'AbpAuditLogging::Time' | abpLocalization\"\r\n [width]=\"230\"\r\n prop=\"changeTime\"\r\n >\r\n </ngx-datatable-column>\r\n <ngx-datatable-column\r\n [name]=\"'AbpAuditLogging::ChangeType' | abpLocalization\"\r\n [width]=\"140\"\r\n [sortable]=\"false\"\r\n >\r\n <ng-template let-row=\"row\" ngx-datatable-cell-template>\r\n {{ 'AbpAuditLogging::' + changeType[row.changeType] | abpLocalization }}\r\n </ng-template>\r\n </ngx-datatable-column>\r\n <ngx-datatable-column name=\"TenantId\" [width]=\"150\" [sortable]=\"false\">\r\n <ng-template let-row=\"row\" ngx-datatable-cell-template>\r\n <div abpEllipsis>{{ row.tenantId }}</div>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n <ngx-datatable-column\r\n [name]=\"'AbpAuditLogging::EntityTypeFullName' | abpLocalization\"\r\n [width]=\"150\"\r\n [sortable]=\"false\"\r\n >\r\n <ng-template let-row=\"row\" ngx-datatable-cell-template>\r\n <div abpEllipsis>{{ row.entityTypeFullName }}</div>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n </ngx-datatable>\r\n </div>\r\n</div>\r\n" }]
210
- }], ctorParameters: function () { return [{ type: i1.ListService }, { type: i2.UntypedFormBuilder }, { type: i2$1.AuditLogsService }, { type: i1.TrackByService }, { type: i0.ChangeDetectorRef }]; } });
211
-
212
- class AuditLogsComponent {
213
- constructor(list, service) {
214
- this.list = list;
215
- this.service = service;
216
- this.data = { items: [], totalCount: 0 };
217
- this.selected = {};
218
- this.pageQuery = {
219
- maxResultCount: 10,
220
- skipCount: 0,
221
- };
222
- this.httpMethods = HTTP_METHODS;
223
- this.httpStatusCodes = HTTP_STATUS_CODES;
224
- this.modalVisible = false;
225
- this.collapseActionStates = [true];
226
- this.collapseChangeStates = [true];
227
- this.sortOrder = '';
228
- this.sortKey = '';
229
- this.selectedTab = 'audit-logs';
230
- }
231
- ngOnInit() {
232
- this.hookToQuery();
233
- }
234
- hookToQuery() {
235
- this.list
236
- .hookToQuery(query => this.service.getList(Object.assign(Object.assign(Object.assign(Object.assign({}, this.pageQuery), (this.pageQuery.minExecutionDuration === null && {
237
- minExecutionDuration: undefined,
238
- })), (this.pageQuery.maxExecutionDuration === null && {
239
- maxExecutionDuration: undefined,
240
- })), query)))
241
- .subscribe(res => (this.data = res));
242
- }
243
- openModal(id) {
244
- this.service
245
- .get(id)
246
- .pipe(take(1))
247
- .subscribe(log => {
248
- this.selected = log;
249
- this.modalVisible = true;
250
- });
251
- }
252
- httpCodeClass(httpStatusCode) {
253
- switch (httpStatusCode === null || httpStatusCode === void 0 ? void 0 : httpStatusCode.toString()[0]) {
254
- case '2':
255
- return 'bg-success';
256
- case '3':
257
- return 'bg-warning';
258
- case '4':
259
- case '5':
260
- return 'bg-danger';
261
- default:
262
- return 'bg-light';
263
- }
264
- }
265
- httpMethodClass(httpMethod) {
266
- switch (httpMethod) {
267
- case 'GET':
268
- return 'bg-info';
269
- case 'POST':
270
- return 'bg-success';
271
- case 'DELETE':
272
- return 'bg-danger';
273
- case 'PUT':
274
- return 'bg-warning';
275
- default:
276
- return '';
277
- }
278
- }
279
- }
280
- AuditLogsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLogsComponent, deps: [{ token: i1.ListService }, { token: i2$1.AuditLogsService }], target: i0.ɵɵFactoryTarget.Component });
281
- AuditLogsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.1", type: AuditLogsComponent, selector: "abp-audit-logs", providers: [
282
- ListService,
283
- {
284
- provide: EXTENSIONS_IDENTIFIER,
285
- useValue: "AuditLogging.AuditLogsComponent" /* eAuditLoggingComponents.AuditLogs */,
286
- },
287
- { provide: NgbDateAdapter, useClass: DateAdapter },
288
- ], ngImport: i0, template: "<div id=\"wrapper\">\r\n <abp-page [title]=\"'AbpAuditLogging::AuditLogs' | abpLocalization\" [toolbar]=\"data.items\">\r\n <ul class=\"nav nav-tabs\">\r\n <li class=\"nav-item\">\r\n <a\r\n class=\"nav-link pointer\"\r\n [class.active]=\"selectedTab === 'audit-logs'\"\r\n (click)=\"selectedTab = 'audit-logs'\"\r\n >{{ 'AbpAuditLogging::AuditLogs' | abpLocalization }}</a\r\n >\r\n </li>\r\n <li class=\"nav-item\">\r\n <a\r\n class=\"nav-link pointer\"\r\n [class.active]=\"selectedTab === 'entity-changes'\"\r\n (click)=\"selectedTab = 'entity-changes'\"\r\n >{{ 'AbpAuditLogging::EntityChanges' | abpLocalization }}</a\r\n >\r\n </li>\r\n </ul>\r\n <div class=\"tab-content\" [class.p-0]=\"selectedTab !== 'audit-logs'\">\r\n <div class=\"tab-pane\" [class.active]=\"selectedTab === 'audit-logs'\" [@fadeIn]=\"selectedTab\">\r\n <div class=\"card mb-0\">\r\n <div class=\"card-body pb-lg-3 px-0\">\r\n <form (keyup.enter)=\"list.get()\">\r\n <div class=\"row\">\r\n\r\n <div class=\"col-md-6 col-lg-2 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\">{{ 'AbpAuditLogging::StartDate' | abpLocalization }}</label>\r\n <abp-audit-log-datetime-picker [(ngModel)]=\"this.pageQuery.startTime\" [ngModelOptions]=\"{ standalone: true }\"\r\n ></abp-audit-log-datetime-picker>\r\n </div>\r\n </div>\r\n\r\n <div class=\"col-md-6 col-lg-2 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\">{{ 'AbpAuditLogging::EndDate' | abpLocalization }}</label>\r\n <abp-audit-log-datetime-picker [(ngModel)]=\"this.pageQuery.endTime\" [ngModelOptions]=\"{ standalone: true }\"\r\n ></abp-audit-log-datetime-picker>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"userName\" class=\"form-label\">{{\r\n 'AbpAuditLogging::UserName' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"userName\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.userName\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"url\">{{\r\n 'AbpAuditLogging::Url' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"url\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.url\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-2 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"minDuration\"\r\n class=\"form-label\">{{ 'AbpAuditLogging::MinMaxDuration' | abpLocalization }}</label>\r\n <div class=\"input-group\">\r\n <input\r\n id=\"minDuration\"\r\n type=\"number\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.minExecutionDuration\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n <span class=\"input-group-text px-1\">-</span>\r\n <input\r\n id=\"maxDuration\"\r\n type=\"number\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.maxExecutionDuration\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"httpMethod\" class=\"form-label\">{{\r\n 'AbpAuditLogging::HttpMethod' | abpLocalization\r\n }}</label\r\n ><select\r\n id=\"httpMethod\"\r\n class=\"form-select form-control\"\r\n [(ngModel)]=\"pageQuery.httpMethod\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n (change)=\"list.get()\"\r\n >\r\n <option [ngValue]=\"\"></option>\r\n <option *ngFor=\"let method of httpMethods\" [ngValue]=\"method\">\r\n {{ method }}\r\n </option>\r\n </select>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"httpStatusCode\" class=\"form-label\">{{\r\n 'AbpAuditLogging::HttpStatusCode' | abpLocalization\r\n }}</label\r\n ><select\r\n id=\"httpStatusCode\"\r\n class=\"form-select form-control\"\r\n [(ngModel)]=\"pageQuery.httpStatusCode\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n (change)=\"list.get()\"\r\n >\r\n <option [ngValue]=\"\"></option>\r\n <option *ngFor=\"let h of httpStatusCodes\" [ngValue]=\"h.code\">\r\n {{ h.code }} - {{ h.message }}\r\n </option>\r\n </select>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3 mb-lg-0\">\r\n <label for=\"applicationName\" class=\"form-label\">{{\r\n 'AbpAuditLogging::ApplicationName' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"applicationName\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.applicationName\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3 mb-lg-0\">\r\n <label for=\"correlationId\" class=\"form-label\">{{\r\n 'AbpAuditLogging::ClientIpAddress' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"clientIpAddress\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.clientIpAddress\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3 mb-lg-0\">\r\n <label for=\"correlationId\" class=\"form-label\">{{\r\n 'AbpAuditLogging::CorrelationId' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"correlationId\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.correlationId\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3 mb-lg-0\">\r\n <label for=\"hasException\" class=\"form-label\">{{\r\n 'AbpAuditLogging::HasException' | abpLocalization\r\n }}</label>\r\n <select\r\n name=\"hasException\"\r\n id=\"hasException\"\r\n class=\"form-select form-control\"\r\n [(ngModel)]=\"pageQuery.hasException\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n (change)=\"list.get()\"\r\n >\r\n <option [ngValue]=\"\"></option>\r\n <option [ngValue]=\"true\">\r\n {{ 'AbpAuditLogging::Yes' | abpLocalization }}\r\n </option>\r\n <option [ngValue]=\"false\">\r\n {{ 'AbpAuditLogging::No' | abpLocalization }}\r\n </option>\r\n </select>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mt-3 mb-lg-0 d-grid\">\r\n <button type=\"button\" class=\"btn btn-primary\" (click)=\"list.get()\">\r\n <span>\r\n {{ 'AbpAuditLogging::Refresh' | abpLocalization }}\r\n </span>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n </form>\r\n </div>\r\n </div>\r\n <div class=\"card\">\r\n <div class=\"card-body p-0\">\r\n <abp-extensible-table\r\n [data]=\"data.items\"\r\n [recordsTotal]=\"data.totalCount\"\r\n [list]=\"list\"\r\n ></abp-extensible-table>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"tab-content\" [class.p-0]=\"selectedTab !== 'entity-changes'\">\r\n <div\r\n class=\"tab-pane\"\r\n [class.active]=\"selectedTab === 'entity-changes'\"\r\n [@fadeIn]=\"selectedTab\"\r\n >\r\n <abp-entity-changes *ngIf=\"selectedTab === 'entity-changes'\"></abp-entity-changes>\r\n </div>\r\n </div>\r\n </abp-page>\r\n</div>\r\n\r\n<abp-modal *ngIf=\"selected\" [(visible)]=\"modalVisible\" [options]=\"{ size: 'lg' }\">\r\n <ng-template #abpHeader>\r\n <h5 class=\"modal-title\">\r\n {{ 'AbpAuditLogging::Detail' | abpLocalization }}\r\n </h5>\r\n </ng-template>\r\n <ng-template #abpBody>\r\n <ul ngbNav #nav=\"ngbNav\" class=\"nav-tabs\">\r\n <li ngbNavItem>\r\n <a ngbNavLink>{{ 'AbpAuditLogging::Overall' | abpLocalization }}</a>\r\n <ng-template ngbNavContent>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::HttpStatusCode' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <span class=\"badge\" [ngClass]=\"httpCodeClass(selected.httpStatusCode)\">{{\r\n selected.httpStatusCode\r\n }}</span>\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::HttpMethod' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <span class=\"badge\" [ngClass]=\"httpMethodClass(selected.httpMethod)\">{{\r\n selected.httpMethod\r\n }}</span>\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Url' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.url }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::ClientIpAddress' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.clientIpAddress }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::ClientName' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.clientName }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Exceptions' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <pre lang=\"c-sharp\" *ngIf=\"selected.exceptions\">\r\n {{ selected.exceptions }}\r\n </pre>\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::UserName' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.userName }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <ng-container *ngIf=\"selected.impersonatorTenantId\">\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::TenantImpersonator' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n {{ selected.impersonatorTenantName || selected.impersonatorTenantId }}\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n </ng-container>\r\n <ng-container *ngIf=\"selected.impersonatorUserId\">\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::UserImpersonator' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <ng-container *ngIf=\"selected.impersonatorUserName; else onlyImpersonatorUserId\">\r\n {{ selected.impersonatorUserName }} ({{ selected.impersonatorUserId }})\r\n </ng-container>\r\n <ng-template #onlyImpersonatorUserId>\r\n {{ selected.impersonatorUserId }}\r\n </ng-template>\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n </ng-container>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Time' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.executionTime }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Duration' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.executionDuration }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::BrowserInfo' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.browserInfo }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::ApplicationName' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.applicationName }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::CorrelationId' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.correlationId }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Comments' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.comments }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::ExtraProperties' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <pre lang=\"json\" class=\"p-2\">\r\n {{ selected.extraProperties | json }}\r\n </pre>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </li>\r\n <li ngbNavItem>\r\n <a ngbNavLink\r\n >{{ 'AbpAuditLogging::Actions' | abpLocalization }} ({{ selected.actions.length }})</a\r\n >\r\n <ng-template ngbNavContent>\r\n <div\r\n class=\"mb-3 border border-dark rounded\"\r\n *ngFor=\"let action of selected.actions; let i = index\"\r\n >\r\n <div class=\"d-grid\">\r\n <button\r\n class=\"btn btn-primary d-flex justify-content-between text-break\"\r\n type=\"button\"\r\n (click)=\"collapseActionStates[i] = !collapseActionStates[i]\"\r\n >\r\n {{ action.serviceName }} - {{ action.methodName }}\r\n <i\r\n class=\"fa align-self-center\"\r\n [ngClass]=\"collapseActionStates[i] ? 'fa-chevron-up' : 'fa-chevron-down'\"\r\n ></i>\r\n </button>\r\n </div>\r\n <div [@collapse]=\"collapseActionStates[i] ? 'expanded' : 'collapsed'\">\r\n <div class=\"m-3\">\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Duration' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n {{ action.executionDuration ? action.executionDuration + ' ms' : '' }}\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Parameters' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <pre lang=\"json\" class=\"p-2\">{{ action.parameters }}</pre>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </li>\r\n </ul>\r\n <div [ngbNavOutlet]=\"nav\"></div>\r\n </ng-template>\r\n <ng-template #abpFooter>\r\n <button class=\"btn btn-secondary\" abpClose>\r\n {{ 'AbpAuditLogging::Close' | abpLocalization }}\r\n </button>\r\n </ng-template>\r\n</abp-modal>\r\n", dependencies: [{ kind: "directive", type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { 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: i2.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.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: i2.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i2.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i6.ExtensibleTableComponent, selector: "abp-extensible-table", inputs: ["actionsText", "data", "list", "recordsTotal", "actionsColumnWidth", "actionsTemplate"], outputs: ["tableActivate"], exportAs: ["abpExtensibleTable"] }, { kind: "component", type: i8.ModalComponent, selector: "abp-modal", inputs: ["visible", "busy", "options", "suppressUnsavedChangesWarning"], outputs: ["visibleChange", "init", "appear", "disappear"] }, { kind: "directive", type: i8.ModalCloseDirective, selector: "[abpClose]" }, { kind: "directive", type: i7.NgbNavContent, selector: "ng-template[ngbNavContent]" }, { kind: "directive", type: i7.NgbNav, selector: "[ngbNav]", inputs: ["activeId", "animation", "destroyOnHide", "orientation", "roles", "keyboard"], outputs: ["activeIdChange", "shown", "hidden", "navChange"], exportAs: ["ngbNav"] }, { kind: "directive", type: i7.NgbNavItem, selector: "[ngbNavItem]", inputs: ["destroyOnHide", "disabled", "domId", "ngbNavItem"], outputs: ["shown", "hidden"], exportAs: ["ngbNavItem"] }, { kind: "directive", type: i7.NgbNavItemRole, selector: "[ngbNavItem]:not(ng-container)" }, { kind: "directive", type: i7.NgbNavLink, selector: "a[ngbNavLink]" }, { kind: "directive", type: i7.NgbNavLinkBase, selector: "[ngbNavLink]" }, { kind: "component", type: i7.NgbNavOutlet, selector: "[ngbNavOutlet]", inputs: ["paneRole", "ngbNavOutlet"] }, { kind: "component", type: i8$1.PageComponent, selector: "abp-page", inputs: ["title", "toolbar", "breadcrumb"] }, { kind: "component", type: AuditLogDatetimePickerComponent, selector: "abp-audit-log-datetime-picker" }, { kind: "component", type: EntityChangesComponent, selector: "abp-entity-changes" }, { kind: "pipe", type: i3.JsonPipe, name: "json" }, { kind: "pipe", type: i1.LocalizationPipe, name: "abpLocalization" }], animations: [collapse, trigger('fadeIn', [transition('* <=> *', useAnimation(fadeIn))])] });
289
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLogsComponent, decorators: [{
290
- type: Component,
291
- args: [{ selector: 'abp-audit-logs', animations: [collapse, trigger('fadeIn', [transition('* <=> *', useAnimation(fadeIn))])], providers: [
292
- ListService,
293
- {
294
- provide: EXTENSIONS_IDENTIFIER,
295
- useValue: "AuditLogging.AuditLogsComponent" /* eAuditLoggingComponents.AuditLogs */,
296
- },
297
- { provide: NgbDateAdapter, useClass: DateAdapter },
298
- ], template: "<div id=\"wrapper\">\r\n <abp-page [title]=\"'AbpAuditLogging::AuditLogs' | abpLocalization\" [toolbar]=\"data.items\">\r\n <ul class=\"nav nav-tabs\">\r\n <li class=\"nav-item\">\r\n <a\r\n class=\"nav-link pointer\"\r\n [class.active]=\"selectedTab === 'audit-logs'\"\r\n (click)=\"selectedTab = 'audit-logs'\"\r\n >{{ 'AbpAuditLogging::AuditLogs' | abpLocalization }}</a\r\n >\r\n </li>\r\n <li class=\"nav-item\">\r\n <a\r\n class=\"nav-link pointer\"\r\n [class.active]=\"selectedTab === 'entity-changes'\"\r\n (click)=\"selectedTab = 'entity-changes'\"\r\n >{{ 'AbpAuditLogging::EntityChanges' | abpLocalization }}</a\r\n >\r\n </li>\r\n </ul>\r\n <div class=\"tab-content\" [class.p-0]=\"selectedTab !== 'audit-logs'\">\r\n <div class=\"tab-pane\" [class.active]=\"selectedTab === 'audit-logs'\" [@fadeIn]=\"selectedTab\">\r\n <div class=\"card mb-0\">\r\n <div class=\"card-body pb-lg-3 px-0\">\r\n <form (keyup.enter)=\"list.get()\">\r\n <div class=\"row\">\r\n\r\n <div class=\"col-md-6 col-lg-2 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\">{{ 'AbpAuditLogging::StartDate' | abpLocalization }}</label>\r\n <abp-audit-log-datetime-picker [(ngModel)]=\"this.pageQuery.startTime\" [ngModelOptions]=\"{ standalone: true }\"\r\n ></abp-audit-log-datetime-picker>\r\n </div>\r\n </div>\r\n\r\n <div class=\"col-md-6 col-lg-2 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\">{{ 'AbpAuditLogging::EndDate' | abpLocalization }}</label>\r\n <abp-audit-log-datetime-picker [(ngModel)]=\"this.pageQuery.endTime\" [ngModelOptions]=\"{ standalone: true }\"\r\n ></abp-audit-log-datetime-picker>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"userName\" class=\"form-label\">{{\r\n 'AbpAuditLogging::UserName' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"userName\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.userName\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"url\">{{\r\n 'AbpAuditLogging::Url' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"url\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.url\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-2 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"minDuration\"\r\n class=\"form-label\">{{ 'AbpAuditLogging::MinMaxDuration' | abpLocalization }}</label>\r\n <div class=\"input-group\">\r\n <input\r\n id=\"minDuration\"\r\n type=\"number\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.minExecutionDuration\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n <span class=\"input-group-text px-1\">-</span>\r\n <input\r\n id=\"maxDuration\"\r\n type=\"number\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.maxExecutionDuration\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"httpMethod\" class=\"form-label\">{{\r\n 'AbpAuditLogging::HttpMethod' | abpLocalization\r\n }}</label\r\n ><select\r\n id=\"httpMethod\"\r\n class=\"form-select form-control\"\r\n [(ngModel)]=\"pageQuery.httpMethod\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n (change)=\"list.get()\"\r\n >\r\n <option [ngValue]=\"\"></option>\r\n <option *ngFor=\"let method of httpMethods\" [ngValue]=\"method\">\r\n {{ method }}\r\n </option>\r\n </select>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"httpStatusCode\" class=\"form-label\">{{\r\n 'AbpAuditLogging::HttpStatusCode' | abpLocalization\r\n }}</label\r\n ><select\r\n id=\"httpStatusCode\"\r\n class=\"form-select form-control\"\r\n [(ngModel)]=\"pageQuery.httpStatusCode\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n (change)=\"list.get()\"\r\n >\r\n <option [ngValue]=\"\"></option>\r\n <option *ngFor=\"let h of httpStatusCodes\" [ngValue]=\"h.code\">\r\n {{ h.code }} - {{ h.message }}\r\n </option>\r\n </select>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3 mb-lg-0\">\r\n <label for=\"applicationName\" class=\"form-label\">{{\r\n 'AbpAuditLogging::ApplicationName' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"applicationName\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.applicationName\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3 mb-lg-0\">\r\n <label for=\"correlationId\" class=\"form-label\">{{\r\n 'AbpAuditLogging::ClientIpAddress' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"clientIpAddress\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.clientIpAddress\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3 mb-lg-0\">\r\n <label for=\"correlationId\" class=\"form-label\">{{\r\n 'AbpAuditLogging::CorrelationId' | abpLocalization\r\n }}</label\r\n ><input\r\n id=\"correlationId\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n [(ngModel)]=\"pageQuery.correlationId\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mb-3 mb-lg-0\">\r\n <label for=\"hasException\" class=\"form-label\">{{\r\n 'AbpAuditLogging::HasException' | abpLocalization\r\n }}</label>\r\n <select\r\n name=\"hasException\"\r\n id=\"hasException\"\r\n class=\"form-select form-control\"\r\n [(ngModel)]=\"pageQuery.hasException\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n (change)=\"list.get()\"\r\n >\r\n <option [ngValue]=\"\"></option>\r\n <option [ngValue]=\"true\">\r\n {{ 'AbpAuditLogging::Yes' | abpLocalization }}\r\n </option>\r\n <option [ngValue]=\"false\">\r\n {{ 'AbpAuditLogging::No' | abpLocalization }}\r\n </option>\r\n </select>\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-3 col-xxl-2\">\r\n <div class=\"mt-3 mb-lg-0 d-grid\">\r\n <button type=\"button\" class=\"btn btn-primary\" (click)=\"list.get()\">\r\n <span>\r\n {{ 'AbpAuditLogging::Refresh' | abpLocalization }}\r\n </span>\r\n </button>\r\n </div>\r\n </div>\r\n </div>\r\n </form>\r\n </div>\r\n </div>\r\n <div class=\"card\">\r\n <div class=\"card-body p-0\">\r\n <abp-extensible-table\r\n [data]=\"data.items\"\r\n [recordsTotal]=\"data.totalCount\"\r\n [list]=\"list\"\r\n ></abp-extensible-table>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"tab-content\" [class.p-0]=\"selectedTab !== 'entity-changes'\">\r\n <div\r\n class=\"tab-pane\"\r\n [class.active]=\"selectedTab === 'entity-changes'\"\r\n [@fadeIn]=\"selectedTab\"\r\n >\r\n <abp-entity-changes *ngIf=\"selectedTab === 'entity-changes'\"></abp-entity-changes>\r\n </div>\r\n </div>\r\n </abp-page>\r\n</div>\r\n\r\n<abp-modal *ngIf=\"selected\" [(visible)]=\"modalVisible\" [options]=\"{ size: 'lg' }\">\r\n <ng-template #abpHeader>\r\n <h5 class=\"modal-title\">\r\n {{ 'AbpAuditLogging::Detail' | abpLocalization }}\r\n </h5>\r\n </ng-template>\r\n <ng-template #abpBody>\r\n <ul ngbNav #nav=\"ngbNav\" class=\"nav-tabs\">\r\n <li ngbNavItem>\r\n <a ngbNavLink>{{ 'AbpAuditLogging::Overall' | abpLocalization }}</a>\r\n <ng-template ngbNavContent>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::HttpStatusCode' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <span class=\"badge\" [ngClass]=\"httpCodeClass(selected.httpStatusCode)\">{{\r\n selected.httpStatusCode\r\n }}</span>\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::HttpMethod' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <span class=\"badge\" [ngClass]=\"httpMethodClass(selected.httpMethod)\">{{\r\n selected.httpMethod\r\n }}</span>\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Url' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.url }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::ClientIpAddress' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.clientIpAddress }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::ClientName' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.clientName }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Exceptions' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <pre lang=\"c-sharp\" *ngIf=\"selected.exceptions\">\r\n {{ selected.exceptions }}\r\n </pre>\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::UserName' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.userName }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <ng-container *ngIf=\"selected.impersonatorTenantId\">\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::TenantImpersonator' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n {{ selected.impersonatorTenantName || selected.impersonatorTenantId }}\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n </ng-container>\r\n <ng-container *ngIf=\"selected.impersonatorUserId\">\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::UserImpersonator' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <ng-container *ngIf=\"selected.impersonatorUserName; else onlyImpersonatorUserId\">\r\n {{ selected.impersonatorUserName }} ({{ selected.impersonatorUserId }})\r\n </ng-container>\r\n <ng-template #onlyImpersonatorUserId>\r\n {{ selected.impersonatorUserId }}\r\n </ng-template>\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n </ng-container>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Time' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.executionTime }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Duration' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.executionDuration }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::BrowserInfo' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.browserInfo }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::ApplicationName' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.applicationName }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::CorrelationId' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.correlationId }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Comments' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">{{ selected.comments }}</div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::ExtraProperties' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <pre lang=\"json\" class=\"p-2\">\r\n {{ selected.extraProperties | json }}\r\n </pre>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </li>\r\n <li ngbNavItem>\r\n <a ngbNavLink\r\n >{{ 'AbpAuditLogging::Actions' | abpLocalization }} ({{ selected.actions.length }})</a\r\n >\r\n <ng-template ngbNavContent>\r\n <div\r\n class=\"mb-3 border border-dark rounded\"\r\n *ngFor=\"let action of selected.actions; let i = index\"\r\n >\r\n <div class=\"d-grid\">\r\n <button\r\n class=\"btn btn-primary d-flex justify-content-between text-break\"\r\n type=\"button\"\r\n (click)=\"collapseActionStates[i] = !collapseActionStates[i]\"\r\n >\r\n {{ action.serviceName }} - {{ action.methodName }}\r\n <i\r\n class=\"fa align-self-center\"\r\n [ngClass]=\"collapseActionStates[i] ? 'fa-chevron-up' : 'fa-chevron-down'\"\r\n ></i>\r\n </button>\r\n </div>\r\n <div [@collapse]=\"collapseActionStates[i] ? 'expanded' : 'collapsed'\">\r\n <div class=\"m-3\">\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Duration' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n {{ action.executionDuration ? action.executionDuration + ' ms' : '' }}\r\n </div>\r\n </div>\r\n <hr class=\"m-0\"/>\r\n <div class=\"row\">\r\n <div class=\"col-form-label col col-lg-3\">\r\n <strong>{{ 'AbpAuditLogging::Parameters' | abpLocalization }}</strong>\r\n </div>\r\n <div class=\"col-form-label col col-lg-9\">\r\n <pre lang=\"json\" class=\"p-2\">{{ action.parameters }}</pre>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </ng-template>\r\n </li>\r\n </ul>\r\n <div [ngbNavOutlet]=\"nav\"></div>\r\n </ng-template>\r\n <ng-template #abpFooter>\r\n <button class=\"btn btn-secondary\" abpClose>\r\n {{ 'AbpAuditLogging::Close' | abpLocalization }}\r\n </button>\r\n </ng-template>\r\n</abp-modal>\r\n" }]
299
- }], ctorParameters: function () { return [{ type: i1.ListService }, { type: i2$1.AuditLogsService }]; } });
300
-
301
- class AuditLoggingGuard {
302
- constructor(auditLoggingFeatures) {
303
- this.auditLoggingFeatures = auditLoggingFeatures;
304
- }
305
- canActivate() {
306
- return this.auditLoggingFeatures.pipe(map(features => features.enable));
307
- }
308
- }
309
- AuditLoggingGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingGuard, deps: [{ token: AUDIT_LOGGING_FEATURES }], target: i0.ɵɵFactoryTarget.Injectable });
310
- AuditLoggingGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingGuard });
311
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingGuard, decorators: [{
312
- type: Injectable
313
- }], ctorParameters: function () {
314
- return [{ type: i1$1.Observable, decorators: [{
315
- type: Inject,
316
- args: [AUDIT_LOGGING_FEATURES]
317
- }] }];
318
- } });
319
-
320
- const DEFAULT_AUDIT_LOGS_ENTITY_ACTIONS = EntityAction.createMany([
321
- {
322
- text: 'AbpAuditLogging::Detail',
323
- action: data => {
324
- const component = data.getInjected(AuditLogsComponent);
325
- component.openModal(data.record.id);
326
- },
327
- icon: 'fa fa-search',
328
- },
329
- ]);
330
-
331
- const DEFAULT_AUDIT_LOGS_ENTITY_PROPS = EntityProp.createMany([
332
- {
333
- type: "string" /* ePropType.String */,
334
- name: 'url',
335
- displayName: 'AbpAuditLogging::HttpRequest',
336
- sortable: true,
337
- columnWidth: 600,
338
- valueResolver: data => {
339
- const component = data.getInjected(AuditLogsComponent);
340
- const { httpMethod, httpStatusCode, url } = data.record;
341
- const methodClass = component.httpMethodClass(httpMethod);
342
- const statusClass = component.httpCodeClass(httpStatusCode);
343
- return of(`<span class="badge ${statusClass} me-1">${httpStatusCode}</span>` +
344
- `<span class="badge ${methodClass} me-1">${httpMethod}</span>` +
345
- (url || ''));
346
- },
347
- },
348
- {
349
- type: "string" /* ePropType.String */,
350
- name: 'userName',
351
- displayName: 'AbpAuditLogging::User',
352
- sortable: true,
353
- columnWidth: 150,
354
- },
355
- {
356
- type: "string" /* ePropType.String */,
357
- name: 'clientIpAddress',
358
- displayName: 'AbpAuditLogging::IpAddress',
359
- sortable: true,
360
- columnWidth: 150,
361
- },
362
- {
363
- type: "datetime" /* ePropType.DateTime */,
364
- name: 'executionTime',
365
- displayName: '::Date',
366
- sortable: true,
367
- columnWidth: 150,
368
- },
369
- {
370
- type: "number" /* ePropType.Number */,
371
- name: 'executionDuration',
372
- displayName: 'AbpAuditLogging::Duration',
373
- sortable: true,
374
- columnWidth: 150,
375
- },
376
- {
377
- type: "string" /* ePropType.String */,
378
- name: 'applicationName',
379
- displayName: 'AbpAuditLogging::ApplicationName',
380
- sortable: true,
381
- columnWidth: 200,
382
- },
383
- ]);
384
-
385
- const DEFAULT_AUDIT_LOGS_TOOLBAR_ACTIONS = ToolbarAction.createMany([]);
386
-
387
- const SHOW_ENTITY_DETAILS = new InjectionToken('SHOW_ENTITY_DETAILS');
388
-
389
- const DEFAULT_ENTITY_CHANGES_ENTITY_ACTIONS = EntityAction.createMany([
390
- {
391
- text: 'AbpAuditLogging::ChangeDetails',
392
- action: data => {
393
- const showDetails = data.getInjected(SHOW_ENTITY_DETAILS);
394
- showDetails(data.record.id);
395
- },
396
- icon: 'fa fa-search',
397
- },
398
- {
399
- text: 'AbpAuditLogging::FullChangeHistory',
400
- action: data => {
401
- const showHistory = data.getInjected(SHOW_ENTITY_HISTORY);
402
- showHistory(data.record.entityId, data.record.entityTypeFullName);
403
- },
404
- icon: 'fa fa-history',
405
- },
406
- ]);
407
-
408
- const DEFAULT_AUDIT_LOGGING_ENTITY_ACTIONS = {
409
- ["AuditLogging.AuditLogsComponent" /* eAuditLoggingComponents.AuditLogs */]: DEFAULT_AUDIT_LOGS_ENTITY_ACTIONS,
410
- ["AuditLogging.EntityChangesComponent" /* eAuditLoggingComponents.EntityChanges */]: DEFAULT_ENTITY_CHANGES_ENTITY_ACTIONS,
411
- };
412
- const DEFAULT_AUDIT_LOGGING_TOOLBAR_ACTIONS = {
413
- ["AuditLogging.AuditLogsComponent" /* eAuditLoggingComponents.AuditLogs */]: DEFAULT_AUDIT_LOGS_TOOLBAR_ACTIONS,
414
- };
415
- const DEFAULT_AUDIT_LOGGING_ENTITY_PROPS = {
416
- ["AuditLogging.AuditLogsComponent" /* eAuditLoggingComponents.AuditLogs */]: DEFAULT_AUDIT_LOGS_ENTITY_PROPS,
417
- };
418
- const AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS = new InjectionToken('AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS');
419
- const AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS = new InjectionToken('AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS');
420
- const AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS = new InjectionToken('AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS');
421
-
422
- class AuditLoggingExtensionsGuard {
423
- constructor(injector) {
424
- this.injector = injector;
425
- }
426
- canActivate() {
427
- const extensions = this.injector.get(ExtensionsService);
428
- const actionContributors = this.injector.get(AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS, null) || {};
429
- const toolbarContributors = this.injector.get(AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS, null) || {};
430
- const propContributors = this.injector.get(AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS, null) || {};
431
- const configState = this.injector.get(ConfigStateService);
432
- return getObjectExtensionEntitiesFromStore(configState, 'AuditLogging').pipe(map(entities => ({
433
- ["AuditLogging.AuditLogsComponent" /* eAuditLoggingComponents.AuditLogs */]: entities.AuditLog,
434
- })), mapEntitiesToContributors(configState, 'AuditLogging'), tap(objectExtensionContributors => {
435
- mergeWithDefaultActions(extensions.entityActions, DEFAULT_AUDIT_LOGGING_ENTITY_ACTIONS, actionContributors);
436
- mergeWithDefaultActions(extensions.toolbarActions, DEFAULT_AUDIT_LOGGING_TOOLBAR_ACTIONS, toolbarContributors);
437
- mergeWithDefaultProps(extensions.entityProps, DEFAULT_AUDIT_LOGGING_ENTITY_PROPS, objectExtensionContributors.prop, propContributors);
438
- }), mapTo(true));
439
- }
440
- }
441
- AuditLoggingExtensionsGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingExtensionsGuard, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable });
442
- AuditLoggingExtensionsGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingExtensionsGuard });
443
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingExtensionsGuard, decorators: [{
444
- type: Injectable
445
- }], ctorParameters: function () { return [{ type: i0.Injector }]; } });
446
-
447
- const routes = [
448
- {
449
- path: '',
450
- component: RouterOutletComponent,
451
- canActivate: [AuthGuard, PermissionGuard, AuditLoggingExtensionsGuard, AuditLoggingGuard],
452
- children: [
453
- {
454
- path: '',
455
- component: ReplaceableRouteContainerComponent,
456
- data: {
457
- requiredPolicy: 'AuditLogging.AuditLogs',
458
- replaceableComponent: {
459
- key: "AuditLogging.AuditLogsComponent" /* eAuditLoggingComponents.AuditLogs */,
460
- defaultComponent: AuditLogsComponent,
461
- },
462
- },
463
- },
464
- ],
465
- },
466
- ];
467
- class AuditLoggingRoutingModule {
468
- }
469
- AuditLoggingRoutingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
470
- AuditLoggingRoutingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingRoutingModule, imports: [i1$2.RouterModule], exports: [RouterModule] });
471
- AuditLoggingRoutingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingRoutingModule, imports: [RouterModule.forChild(routes), RouterModule] });
472
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingRoutingModule, decorators: [{
473
- type: NgModule,
474
- args: [{
475
- imports: [RouterModule.forChild(routes)],
476
- exports: [RouterModule],
477
- }]
478
- }] });
479
-
480
- class AverageExecutionDurationWidgetComponent {
481
- constructor(localizationService, permissionService, service) {
482
- this.localizationService = localizationService;
483
- this.permissionService = permissionService;
484
- this.service = service;
485
- this.data = {};
486
- this.initialized = new BehaviorSubject(this);
487
- this.width = 273;
488
- this.height = 136;
489
- this.chartData = {};
490
- this.draw = (filter) => {
491
- if (!this.permissionService.getGrantedPolicy('AuditLogging.AuditLogs')) {
492
- return;
493
- }
494
- this.service
495
- .getAverageExecutionDurationPerDay({ startDate: filter.startDate, endDate: filter.endDate })
496
- .subscribe(res => {
497
- this.data = res.data;
498
- this.setChartData();
499
- });
500
- };
501
- }
502
- setChartData() {
503
- if (!this.data || JSON.stringify(this.data) === '{}') {
504
- this.chartData = {};
505
- return;
506
- }
507
- const dataKeys = Object.keys(this.data);
508
- setTimeout(() => {
509
- this.chartData = {
510
- labels: dataKeys,
511
- datasets: [
512
- {
513
- label: this.localizationService.instant('AbpAuditLogging::AverageExecutionDurationInMilliseconds'),
514
- backgroundColor: '#fa6e6e',
515
- data: dataKeys.map(key => this.data[key]),
516
- },
517
- ],
518
- };
519
- this.chart.refresh();
520
- }, 0);
521
- }
522
- }
523
- AverageExecutionDurationWidgetComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AverageExecutionDurationWidgetComponent, deps: [{ token: i1.LocalizationService }, { token: i1.PermissionService }, { token: i2$1.AuditLogsService }], target: i0.ɵɵFactoryTarget.Component });
524
- AverageExecutionDurationWidgetComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.1", type: AverageExecutionDurationWidgetComponent, selector: "abp-average-execution-duration-widget", inputs: { width: "width", height: "height" }, outputs: { initialized: "initialized" }, viewQueries: [{ propertyName: "chart", first: true, predicate: ChartComponent, descendants: true }], ngImport: i0, template: `
525
- <div *abpPermission="'AuditLogging.AuditLogs'" class="abp-widget-wrapper">
526
- <div class="card">
527
- <div class="card-header">
528
- <h5 class="card-title">
529
- {{ 'AbpAuditLogging::AverageExecutionDurationInLogsPerDay' | abpLocalization }}
530
- </h5>
531
- </div>
532
- <div class="card-body">
533
- <div class="row">
534
- <abp-chart
535
- #chart
536
- class="w-100"
537
- type="bar"
538
- [data]="chartData"
539
- [width]="width"
540
- [height]="height"
541
- ></abp-chart>
542
- </div>
543
- </div>
544
- </div>
545
- </div>
546
- `, isInline: true, dependencies: [{ kind: "directive", type: i1.PermissionDirective, selector: "[abpPermission]", inputs: ["abpPermission", "abpPermissionRunChangeDetection"] }, { kind: "component", type: i3$1.ChartComponent, selector: "abp-chart", inputs: ["type", "data", "options", "plugins", "width", "height", "responsive"], outputs: ["dataSelect", "initialized"], exportAs: ["abpChart"] }, { kind: "pipe", type: i1.LocalizationPipe, name: "abpLocalization" }] });
547
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AverageExecutionDurationWidgetComponent, decorators: [{
548
- type: Component,
549
- args: [{
550
- selector: 'abp-average-execution-duration-widget',
551
- template: `
552
- <div *abpPermission="'AuditLogging.AuditLogs'" class="abp-widget-wrapper">
553
- <div class="card">
554
- <div class="card-header">
555
- <h5 class="card-title">
556
- {{ 'AbpAuditLogging::AverageExecutionDurationInLogsPerDay' | abpLocalization }}
557
- </h5>
558
- </div>
559
- <div class="card-body">
560
- <div class="row">
561
- <abp-chart
562
- #chart
563
- class="w-100"
564
- type="bar"
565
- [data]="chartData"
566
- [width]="width"
567
- [height]="height"
568
- ></abp-chart>
569
- </div>
570
- </div>
571
- </div>
572
- </div>
573
- `,
574
- }]
575
- }], ctorParameters: function () { return [{ type: i1.LocalizationService }, { type: i1.PermissionService }, { type: i2$1.AuditLogsService }]; }, propDecorators: { initialized: [{
576
- type: Output
577
- }], width: [{
578
- type: Input
579
- }], height: [{
580
- type: Input
581
- }], chart: [{
582
- type: ViewChild,
583
- args: [ChartComponent]
584
- }] } });
585
-
586
- class ErrorRateWidgetComponent {
587
- constructor(permissionService, service) {
588
- this.permissionService = permissionService;
589
- this.service = service;
590
- this.data = {};
591
- this.initialized = new BehaviorSubject(this);
592
- this.width = 273;
593
- this.height = 136;
594
- this.chartData = {};
595
- this.draw = (filter) => {
596
- if (!this.permissionService.getGrantedPolicy('AuditLogging.AuditLogs')) {
597
- return;
598
- }
599
- this.service
600
- .getErrorRate({
601
- startDate: filter.startDate,
602
- endDate: filter.endDate,
603
- })
604
- .subscribe(res => {
605
- this.data = res.data;
606
- this.setChartData();
607
- });
608
- };
609
- }
610
- setChartData() {
611
- if (!this.data || JSON.stringify(this.data) === '{}') {
612
- this.chartData = {};
613
- return;
614
- }
615
- const dataKeys = Object.keys(this.data);
616
- setTimeout(() => {
617
- this.chartData = {
618
- labels: dataKeys,
619
- datasets: [
620
- {
621
- data: dataKeys.map(key => this.data[key]),
622
- backgroundColor: ['#d76e6e', '#63ac44'],
623
- },
624
- ],
625
- };
626
- this.chart.refresh();
627
- }, 0);
628
- }
629
- }
630
- ErrorRateWidgetComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: ErrorRateWidgetComponent, deps: [{ token: i1.PermissionService }, { token: i2$1.AuditLogsService }], target: i0.ɵɵFactoryTarget.Component });
631
- ErrorRateWidgetComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.0.1", type: ErrorRateWidgetComponent, selector: "abp-error-rate-widget", inputs: { width: "width", height: "height" }, outputs: { initialized: "initialized" }, viewQueries: [{ propertyName: "chart", first: true, predicate: ChartComponent, descendants: true }], ngImport: i0, template: `
632
- <div *abpPermission="'AuditLogging.AuditLogs'" class="abp-widget-wrapper">
633
- <div class="card">
634
- <div class="card-header">
635
- <h5 class="card-title">
636
- {{ 'AbpAuditLogging::ErrorRateInLogs' | abpLocalization }}
637
- </h5>
638
- </div>
639
- <div class="card-body">
640
- <div class="row">
641
- <abp-chart
642
- #chart
643
- class="w-100"
644
- type="pie"
645
- [data]="chartData"
646
- [width]="width"
647
- [height]="height"
648
- ></abp-chart>
649
- </div>
650
- </div>
651
- </div>
652
- </div>
653
- `, isInline: true, dependencies: [{ kind: "directive", type: i1.PermissionDirective, selector: "[abpPermission]", inputs: ["abpPermission", "abpPermissionRunChangeDetection"] }, { kind: "component", type: i3$1.ChartComponent, selector: "abp-chart", inputs: ["type", "data", "options", "plugins", "width", "height", "responsive"], outputs: ["dataSelect", "initialized"], exportAs: ["abpChart"] }, { kind: "pipe", type: i1.LocalizationPipe, name: "abpLocalization" }] });
654
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: ErrorRateWidgetComponent, decorators: [{
655
- type: Component,
656
- args: [{
657
- selector: 'abp-error-rate-widget',
658
- template: `
659
- <div *abpPermission="'AuditLogging.AuditLogs'" class="abp-widget-wrapper">
660
- <div class="card">
661
- <div class="card-header">
662
- <h5 class="card-title">
663
- {{ 'AbpAuditLogging::ErrorRateInLogs' | abpLocalization }}
664
- </h5>
665
- </div>
666
- <div class="card-body">
667
- <div class="row">
668
- <abp-chart
669
- #chart
670
- class="w-100"
671
- type="pie"
672
- [data]="chartData"
673
- [width]="width"
674
- [height]="height"
675
- ></abp-chart>
676
- </div>
677
- </div>
678
- </div>
679
- </div>
680
- `,
681
- }]
682
- }], ctorParameters: function () { return [{ type: i1.PermissionService }, { type: i2$1.AuditLogsService }]; }, propDecorators: { initialized: [{
683
- type: Output
684
- }], width: [{
685
- type: Input
686
- }], height: [{
687
- type: Input
688
- }], chart: [{
689
- type: ViewChild,
690
- args: [ChartComponent]
691
- }] } });
692
-
693
- class AuditLoggingModule {
694
- static forChild(options = {}) {
695
- return {
696
- ngModule: AuditLoggingModule,
697
- providers: [
698
- {
699
- provide: AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS,
700
- useValue: options.entityActionContributors,
701
- },
702
- {
703
- provide: AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS,
704
- useValue: options.toolbarActionContributors,
705
- },
706
- {
707
- provide: AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS,
708
- useValue: options.entityPropContributors,
709
- },
710
- AuditLoggingGuard,
711
- AuditLoggingExtensionsGuard,
712
- ],
713
- };
714
- }
715
- static forLazy(options = {}) {
716
- return new LazyModuleFactory(AuditLoggingModule.forChild(options));
717
- }
718
- }
719
- AuditLoggingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
720
- AuditLoggingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingModule, declarations: [AuditLogsComponent,
721
- EntityChangesComponent,
722
- ErrorRateWidgetComponent,
723
- AverageExecutionDurationWidgetComponent], imports: [AuditLoggingRoutingModule,
724
- CoreModule,
725
- CommercialUiModule,
726
- ThemeSharedModule,
727
- NgbNavModule,
728
- NgbDatepickerModule,
729
- PageModule,
730
- ChartModule,
731
- AuditLogDatetimePickerComponent], exports: [AuditLogsComponent,
732
- EntityChangesComponent,
733
- ErrorRateWidgetComponent,
734
- AverageExecutionDurationWidgetComponent] });
735
- AuditLoggingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingModule, imports: [AuditLoggingRoutingModule,
736
- CoreModule,
737
- CommercialUiModule,
738
- ThemeSharedModule,
739
- NgbNavModule,
740
- NgbDatepickerModule,
741
- PageModule,
742
- ChartModule,
743
- AuditLogDatetimePickerComponent] });
744
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.0.1", ngImport: i0, type: AuditLoggingModule, decorators: [{
745
- type: NgModule,
746
- args: [{
747
- declarations: [
748
- AuditLogsComponent,
749
- EntityChangesComponent,
750
- ErrorRateWidgetComponent,
751
- AverageExecutionDurationWidgetComponent,
752
- ],
753
- exports: [
754
- AuditLogsComponent,
755
- EntityChangesComponent,
756
- ErrorRateWidgetComponent,
757
- AverageExecutionDurationWidgetComponent,
758
- ],
759
- imports: [
760
- AuditLoggingRoutingModule,
761
- CoreModule,
762
- CommercialUiModule,
763
- ThemeSharedModule,
764
- NgbNavModule,
765
- NgbDatepickerModule,
766
- PageModule,
767
- ChartModule,
768
- AuditLogDatetimePickerComponent,
769
- ],
770
- }]
771
- }] });
772
-
773
- var eEntityChangeType;
774
- (function (eEntityChangeType) {
775
- eEntityChangeType[eEntityChangeType["Created"] = 0] = "Created";
776
- eEntityChangeType[eEntityChangeType["Updated"] = 1] = "Updated";
777
- eEntityChangeType[eEntityChangeType["Deleted"] = 2] = "Deleted";
778
- })(eEntityChangeType || (eEntityChangeType = {}));
779
-
780
- /**
781
- * Generated bundle index. Do not edit.
782
- */
783
-
784
- export { AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS, AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS, AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS, AuditLoggingExtensionsGuard, AuditLoggingGuard, AuditLoggingModule, AuditLogsComponent, AverageExecutionDurationWidgetComponent, DEFAULT_AUDIT_LOGGING_ENTITY_ACTIONS, DEFAULT_AUDIT_LOGGING_ENTITY_PROPS, DEFAULT_AUDIT_LOGGING_TOOLBAR_ACTIONS, EntityChangesComponent, ErrorRateWidgetComponent, HTTP_METHODS, HTTP_STATUS_CODES, SHOW_ENTITY_DETAILS, eEntityChangeType };
785
- //# sourceMappingURL=volo-abp.ng.audit-logging.mjs.map