@volo/abp.ng.audit-logging 5.0.1 → 5.1.3
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/common/package.json +5 -5
- package/config/package.json +5 -5
- package/esm2020/common/enums/index.mjs +2 -0
- package/esm2020/common/enums/route-names.mjs +2 -0
- package/esm2020/common/public-api.mjs +3 -0
- package/esm2020/common/tokens/features.token.mjs +31 -0
- package/esm2020/common/tokens/index.mjs +2 -0
- package/esm2020/common/volo-abp.ng.audit-logging-common.mjs +5 -0
- package/esm2020/config/audit-logging-config.module.mjs +34 -0
- package/esm2020/config/components/entity-change-details.component.mjs +45 -0
- package/esm2020/config/components/entity-change-modal.component.mjs +22 -0
- package/esm2020/config/components/index.mjs +3 -0
- package/esm2020/config/enums/index.mjs +3 -0
- package/esm2020/config/enums/policy-names.mjs +2 -0
- package/esm2020/config/enums/route-names.mjs +2 -0
- package/esm2020/config/providers/entity-details.provider.mjs +13 -0
- package/esm2020/config/providers/entity-history.provider.mjs +13 -0
- package/esm2020/config/providers/index.mjs +4 -0
- package/esm2020/config/providers/route.provider.mjs +21 -0
- package/esm2020/config/public-api.mjs +6 -0
- package/esm2020/config/services/entity-change-modal.service.mjs +51 -0
- package/esm2020/config/services/index.mjs +2 -0
- package/esm2020/config/volo-abp.ng.audit-logging-config.mjs +5 -0
- package/esm2020/lib/audit-logging-routing.module.mjs +41 -0
- package/esm2020/lib/audit-logging.module.mjs +95 -0
- package/esm2020/lib/components/audit-logs/audit-logs.component.mjs +113 -0
- package/esm2020/lib/components/entity-change/entity-changes.component.mjs +70 -0
- package/esm2020/lib/components/index.mjs +5 -0
- package/esm2020/lib/components/widgets/average-execution-duration-widget.component.mjs +115 -0
- package/esm2020/lib/components/widgets/error-rate-widget.component.mjs +116 -0
- package/esm2020/lib/constants/http.mjs +64 -0
- package/esm2020/lib/constants/index.mjs +2 -0
- package/esm2020/lib/defaults/default-audit-logs-entity-actions.mjs +13 -0
- package/esm2020/lib/defaults/default-audit-logs-entity-props.mjs +57 -0
- package/esm2020/lib/defaults/default-audit-logs-toolbar-actions.mjs +3 -0
- package/esm2020/lib/defaults/default-entity-changes-entity-actions.mjs +22 -0
- package/esm2020/lib/enums/components.mjs +2 -0
- package/esm2020/lib/enums/entity-change.mjs +7 -0
- package/esm2020/lib/enums/index.mjs +3 -0
- package/esm2020/lib/guards/audit-logging.guard.mjs +23 -0
- package/esm2020/lib/guards/extensions.guard.mjs +31 -0
- package/esm2020/lib/guards/index.mjs +3 -0
- package/esm2020/lib/models/audit-logging.mjs +2 -0
- package/esm2020/lib/models/config-options.mjs +2 -0
- package/esm2020/lib/models/index.mjs +3 -0
- package/esm2020/lib/tokens/entity-details.token.mjs +3 -0
- package/esm2020/lib/tokens/extensions.token.mjs +19 -0
- package/esm2020/lib/tokens/index.mjs +3 -0
- package/esm2020/proxy/lib/index.mjs +3 -0
- package/esm2020/proxy/lib/proxy/audit-logging/audit-logs.service.mjs +56 -0
- package/esm2020/proxy/lib/proxy/audit-logging/index.mjs +3 -0
- package/esm2020/proxy/lib/proxy/audit-logging/models.mjs +2 -0
- package/esm2020/proxy/lib/proxy/auditing/entity-change-type.enum.mjs +9 -0
- package/esm2020/proxy/lib/proxy/auditing/index.mjs +2 -0
- package/esm2020/proxy/public-api.mjs +2 -0
- package/esm2020/proxy/volo-abp.ng.audit-logging-proxy.mjs +5 -0
- package/esm2020/public-api.mjs +8 -0
- package/esm2020/volo-abp.ng.audit-logging.mjs +5 -0
- package/fesm2015/{volo-abp.ng.audit-logging-common.js → volo-abp.ng.audit-logging-common.mjs} +1 -1
- package/fesm2015/volo-abp.ng.audit-logging-common.mjs.map +1 -0
- package/fesm2015/{volo-abp.ng.audit-logging-config.js → volo-abp.ng.audit-logging-config.mjs} +16 -25
- package/fesm2015/volo-abp.ng.audit-logging-config.mjs.map +1 -0
- package/fesm2015/{volo-abp.ng.audit-logging-proxy.js → volo-abp.ng.audit-logging-proxy.mjs} +6 -6
- package/fesm2015/volo-abp.ng.audit-logging-proxy.mjs.map +1 -0
- package/fesm2015/{volo-abp.ng.audit-logging.js → volo-abp.ng.audit-logging.mjs} +40 -49
- package/fesm2015/volo-abp.ng.audit-logging.mjs.map +1 -0
- package/fesm2020/volo-abp.ng.audit-logging-common.mjs +38 -0
- package/fesm2020/volo-abp.ng.audit-logging-common.mjs.map +1 -0
- package/fesm2020/volo-abp.ng.audit-logging-config.mjs +182 -0
- package/fesm2020/volo-abp.ng.audit-logging-config.mjs.map +1 -0
- package/fesm2020/volo-abp.ng.audit-logging-proxy.mjs +71 -0
- package/fesm2020/volo-abp.ng.audit-logging-proxy.mjs.map +1 -0
- package/fesm2020/volo-abp.ng.audit-logging.mjs +723 -0
- package/fesm2020/volo-abp.ng.audit-logging.mjs.map +1 -0
- package/package.json +46 -9
- package/proxy/package.json +5 -5
- package/proxy/src/lib/proxy/README.md +17 -0
- package/bundles/volo-abp.ng.audit-logging-common.umd.js +0 -1
- package/bundles/volo-abp.ng.audit-logging-config.umd.js +0 -1
- package/bundles/volo-abp.ng.audit-logging-proxy.umd.js +0 -1
- package/bundles/volo-abp.ng.audit-logging.umd.js +0 -1
- package/esm2015/common/enums/index.js +0 -1
- package/esm2015/common/enums/route-names.js +0 -1
- package/esm2015/common/public-api.js +0 -1
- package/esm2015/common/tokens/features.token.js +0 -1
- package/esm2015/common/tokens/index.js +0 -1
- package/esm2015/common/volo-abp.ng.audit-logging-common.js +0 -1
- package/esm2015/config/audit-logging-config.module.js +0 -1
- package/esm2015/config/components/entity-change-details.component.js +0 -1
- package/esm2015/config/components/entity-change-modal.component.js +0 -1
- package/esm2015/config/components/index.js +0 -1
- package/esm2015/config/enums/index.js +0 -1
- package/esm2015/config/enums/policy-names.js +0 -1
- package/esm2015/config/enums/route-names.js +0 -1
- package/esm2015/config/providers/entity-details.provider.js +0 -1
- package/esm2015/config/providers/entity-history.provider.js +0 -1
- package/esm2015/config/providers/index.js +0 -1
- package/esm2015/config/providers/route.provider.js +0 -1
- package/esm2015/config/public-api.js +0 -1
- package/esm2015/config/services/entity-change-modal.service.js +0 -1
- package/esm2015/config/services/index.js +0 -1
- package/esm2015/config/volo-abp.ng.audit-logging-config.js +0 -1
- package/esm2015/lib/audit-logging-routing.module.js +0 -1
- package/esm2015/lib/audit-logging.module.js +0 -1
- package/esm2015/lib/components/audit-logs/audit-logs.component.js +0 -1
- package/esm2015/lib/components/entity-change/entity-changes.component.js +0 -1
- package/esm2015/lib/components/index.js +0 -1
- package/esm2015/lib/components/widgets/average-execution-duration-widget.component.js +0 -1
- package/esm2015/lib/components/widgets/error-rate-widget.component.js +0 -1
- package/esm2015/lib/constants/http.js +0 -1
- package/esm2015/lib/constants/index.js +0 -1
- package/esm2015/lib/defaults/default-audit-logs-entity-actions.js +0 -1
- package/esm2015/lib/defaults/default-audit-logs-entity-props.js +0 -1
- package/esm2015/lib/defaults/default-audit-logs-toolbar-actions.js +0 -1
- package/esm2015/lib/defaults/default-entity-changes-entity-actions.js +0 -1
- package/esm2015/lib/enums/components.js +0 -1
- package/esm2015/lib/enums/entity-change.js +0 -1
- package/esm2015/lib/enums/index.js +0 -1
- package/esm2015/lib/guards/audit-logging.guard.js +0 -1
- package/esm2015/lib/guards/extensions.guard.js +0 -1
- package/esm2015/lib/guards/index.js +0 -1
- package/esm2015/lib/models/audit-logging.js +0 -1
- package/esm2015/lib/models/config-options.js +0 -1
- package/esm2015/lib/models/index.js +0 -1
- package/esm2015/lib/tokens/entity-details.token.js +0 -1
- package/esm2015/lib/tokens/extensions.token.js +0 -1
- package/esm2015/lib/tokens/index.js +0 -1
- package/esm2015/proxy/lib/index.js +0 -1
- package/esm2015/proxy/lib/proxy/audit-logging/audit-logs.service.js +0 -1
- package/esm2015/proxy/lib/proxy/audit-logging/index.js +0 -1
- package/esm2015/proxy/lib/proxy/audit-logging/models.js +0 -1
- package/esm2015/proxy/lib/proxy/auditing/entity-change-type.enum.js +0 -1
- package/esm2015/proxy/lib/proxy/auditing/index.js +0 -1
- package/esm2015/proxy/public-api.js +0 -1
- package/esm2015/proxy/volo-abp.ng.audit-logging-proxy.js +0 -1
- package/esm2015/public-api.js +0 -1
- package/esm2015/volo-abp.ng.audit-logging.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"volo-abp.ng.audit-logging.mjs","sources":["../../../../packages/audit-logging/src/lib/constants/http.ts","../../../../packages/audit-logging/src/lib/components/entity-change/entity-changes.component.ts","../../../../packages/audit-logging/src/lib/components/entity-change/entity-changes.component.html","../../../../packages/audit-logging/src/lib/components/audit-logs/audit-logs.component.ts","../../../../packages/audit-logging/src/lib/components/audit-logs/audit-logs.component.html","../../../../packages/audit-logging/src/lib/guards/audit-logging.guard.ts","../../../../packages/audit-logging/src/lib/defaults/default-audit-logs-entity-actions.ts","../../../../packages/audit-logging/src/lib/defaults/default-audit-logs-entity-props.ts","../../../../packages/audit-logging/src/lib/defaults/default-audit-logs-toolbar-actions.ts","../../../../packages/audit-logging/src/lib/tokens/entity-details.token.ts","../../../../packages/audit-logging/src/lib/defaults/default-entity-changes-entity-actions.ts","../../../../packages/audit-logging/src/lib/tokens/extensions.token.ts","../../../../packages/audit-logging/src/lib/guards/extensions.guard.ts","../../../../packages/audit-logging/src/lib/audit-logging-routing.module.ts","../../../../packages/audit-logging/src/lib/components/widgets/average-execution-duration-widget.component.ts","../../../../packages/audit-logging/src/lib/components/widgets/error-rate-widget.component.ts","../../../../packages/audit-logging/src/lib/audit-logging.module.ts","../../../../packages/audit-logging/src/lib/enums/entity-change.ts","../../../../packages/audit-logging/src/volo-abp.ng.audit-logging.ts"],"sourcesContent":["export const HTTP_METHODS = ['GET', 'POST', 'DELETE', 'PUT', 'HEAD', 'CONNECT', 'OPTIONS', 'TRACE'];\r\n\r\nexport const HTTP_STATUS_CODES = [\r\n { code: 100, message: 'Continue' },\r\n { code: 101, message: 'Switching Protocols' },\r\n { code: 102, message: 'Processing' },\r\n { code: 103, message: 'Early Hints' },\r\n { code: 200, message: 'OK' },\r\n { code: 201, message: 'Created' },\r\n { code: 202, message: 'Accepted' },\r\n { code: 203, message: 'Non-authoritative Information' },\r\n { code: 204, message: 'No Content' },\r\n { code: 205, message: 'Reset Content' },\r\n { code: 206, message: 'Partial Content' },\r\n { code: 207, message: 'Multi-Status' },\r\n { code: 208, message: 'Already Registered' },\r\n { code: 226, message: 'IM Used' },\r\n { code: 300, message: 'Multiple Choices' },\r\n { code: 301, message: 'Moved Permanently' },\r\n { code: 302, message: 'Found' },\r\n { code: 303, message: 'See Other' },\r\n { code: 304, message: 'Not Modified' },\r\n { code: 305, message: 'Use Proxy' },\r\n { code: 306, message: 'Switch Proxy' },\r\n { code: 307, message: 'Temporary Redirect' },\r\n { code: 308, message: 'Permanent Redirect' },\r\n { code: 400, message: 'Bad Request' },\r\n { code: 401, message: 'Unauthorized' },\r\n { code: 402, message: 'Payment Required' },\r\n { code: 403, message: 'Forbidden' },\r\n { code: 404, message: 'Not Found' },\r\n { code: 405, message: 'Method Not Allowed' },\r\n { code: 406, message: 'Not Acceptable' },\r\n { code: 407, message: 'Proxy Authentication Required' },\r\n { code: 408, message: 'Request Timeout' },\r\n { code: 409, message: 'Conflict' },\r\n { code: 410, message: 'Gone' },\r\n { code: 411, message: 'Length Required' },\r\n { code: 412, message: 'Precondition Failed' },\r\n { code: 413, message: 'Payload Too Large' },\r\n { code: 414, message: 'Request-URI Too Long' },\r\n { code: 415, message: 'Unsupported Media Type' },\r\n { code: 416, message: 'Requested Range Not Satisfiable' },\r\n { code: 417, message: 'Expectation Failed' },\r\n { code: 421, message: 'Misdirected Request' },\r\n { code: 423, message: 'Locked' },\r\n { code: 424, message: 'Failed Dependency' },\r\n { code: 426, message: 'Upgrade Required' },\r\n { code: 428, message: 'Precondition Required' },\r\n { code: 429, message: 'Too Many Requests' },\r\n { code: 431, message: 'Request Header Fields Too Large' },\r\n { code: 451, message: 'Unavailable For Legal Reasons' },\r\n { code: 500, message: 'Internal Server Error' },\r\n { code: 501, message: 'Not Implemented' },\r\n { code: 502, message: 'Bad Gateway' },\r\n { code: 503, message: 'Service Unavailable' },\r\n { code: 504, message: 'Gateway Timeout' },\r\n { code: 505, message: 'HTTP Version Not Supported' },\r\n { code: 506, message: 'Variant Also Negotiates' },\r\n { code: 507, message: 'Insufficient Storage' },\r\n { code: 508, message: 'Loop Detected' },\r\n { code: 510, message: 'Not Extended' },\r\n { code: 511, message: 'Network Authentication Required' },\r\n];\r\n","import { ListService, mapEnumToOptions, PagedResultDto, TrackByService } from '@abp/ng.core';\r\nimport { DateAdapter, EXTENSIONS_IDENTIFIER } from '@abp/ng.theme.shared/extensions';\r\nimport { AfterViewInit, ChangeDetectionStrategy, Component } from '@angular/core';\r\nimport { FormBuilder } from '@angular/forms';\r\nimport { NgbDateAdapter } from '@ng-bootstrap/ng-bootstrap';\r\nimport {\r\n AuditLogsService,\r\n EntityChangeDto,\r\n EntityChangeType,\r\n} from '@volo/abp.ng.audit-logging/proxy';\r\nimport { eAuditLoggingComponents } from '../../enums/components';\r\n\r\n@Component({\r\n selector: 'abp-entity-changes',\r\n templateUrl: './entity-changes.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n providers: [\r\n ListService,\r\n {\r\n provide: EXTENSIONS_IDENTIFIER,\r\n useValue: eAuditLoggingComponents.EntityChanges,\r\n },\r\n { provide: NgbDateAdapter, useClass: DateAdapter },\r\n ],\r\n})\r\nexport class EntityChangesComponent implements AfterViewInit {\r\n form = this.fb.group({\r\n entityChangeType: [''],\r\n entityTypeFullName: [''],\r\n startDate: [''],\r\n endDate: [''],\r\n });\r\n\r\n private response = { items: [], totalCount: 0 } as PagedResultDto<EntityChangeDto>;\r\n\r\n get data() {\r\n return this.response.items;\r\n }\r\n\r\n get count() {\r\n return this.response.totalCount;\r\n }\r\n\r\n changeType = EntityChangeType;\r\n\r\n changeTypes = mapEnumToOptions(EntityChangeType);\r\n\r\n constructor(\r\n public readonly list: ListService,\r\n private fb: FormBuilder,\r\n private auditLogsService: AuditLogsService,\r\n public readonly track: TrackByService,\r\n ) {}\r\n\r\n ngAfterViewInit() {\r\n this.hookToQuery();\r\n }\r\n\r\n private hookToQuery() {\r\n this.list\r\n .hookToQuery(query =>\r\n this.auditLogsService.getEntityChanges({ ...this.form.value, ...query }),\r\n )\r\n .subscribe(res => (this.response = res));\r\n }\r\n\r\n handleSubmit() {\r\n this.list.get();\r\n }\r\n}\r\n","<div class=\"card\">\r\n <div class=\"card-body pb-lg-3\">\r\n <form [formGroup]=\"form\" (ngSubmit)=\"handleSubmit()\">\r\n <div class=\"row\">\r\n <div class=\"col-md-6 col-xl-3\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"start-date\">{{\r\n 'AbpAuditLogging::EntityChangeStartTime' | abpLocalization\r\n }}</label\r\n ><input\r\n ngbDatepicker\r\n #pickerStart=\"ngbDatepicker\"\r\n id=\"start-date\"\r\n class=\"form-control\"\r\n formControlName=\"startDate\"\r\n readonly\r\n (click)=\"pickerStart.toggle()\"\r\n (keyup.space)=\"pickerStart.open()\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-xl-3\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"end-date\">{{\r\n 'AbpAuditLogging::EntityChangeEndTime' | abpLocalization\r\n }}</label\r\n ><input\r\n ngbDatepicker\r\n #pickerEnd=\"ngbDatepicker\"\r\n id=\"end-date\"\r\n class=\"form-control\"\r\n formControlName=\"endDate\"\r\n readonly\r\n (click)=\"pickerEnd.toggle()\"\r\n (keyup.space)=\"pickerEnd.open()\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-xl-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-xl-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>\r\n <div class=\"row\">\r\n <div class=\"col-12 d-grid d-md-block 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 </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","import { ListService, PagedResultDto } from '@abp/ng.core';\r\nimport { collapse, fadeIn } from '@abp/ng.theme.shared';\r\nimport { DateAdapter, EXTENSIONS_IDENTIFIER } from '@abp/ng.theme.shared/extensions';\r\nimport { transition, trigger, useAnimation } from '@angular/animations';\r\nimport { Component, OnInit } from '@angular/core';\r\nimport { FormGroup } from '@angular/forms';\r\nimport { NgbDateAdapter } from '@ng-bootstrap/ng-bootstrap';\r\nimport {\r\n AuditLogDto,\r\n AuditLogsService,\r\n GetAuditLogListDto,\r\n} from '@volo/abp.ng.audit-logging/proxy';\r\nimport { take } from 'rxjs/operators';\r\nimport { HTTP_METHODS, HTTP_STATUS_CODES } from '../../constants/http';\r\nimport { eAuditLoggingComponents } from '../../enums/components';\r\n\r\n@Component({\r\n selector: 'abp-audit-logs',\r\n templateUrl: './audit-logs.component.html',\r\n animations: [collapse, trigger('fadeIn', [transition('* <=> *', useAnimation(fadeIn))])],\r\n providers: [\r\n ListService,\r\n {\r\n provide: EXTENSIONS_IDENTIFIER,\r\n useValue: eAuditLoggingComponents.AuditLogs,\r\n },\r\n { provide: NgbDateAdapter, useClass: DateAdapter },\r\n ],\r\n})\r\nexport class AuditLogsComponent implements OnInit {\r\n data: PagedResultDto<AuditLogDto> = { items: [], totalCount: 0 };\r\n\r\n selected = {} as AuditLogDto;\r\n\r\n pageQuery = {\r\n maxResultCount: 10,\r\n skipCount: 0,\r\n } as GetAuditLogListDto;\r\n\r\n filterForm: FormGroup;\r\n\r\n httpMethods = HTTP_METHODS;\r\n\r\n httpStatusCodes = HTTP_STATUS_CODES;\r\n\r\n modalVisible = false;\r\n\r\n collapseActionStates = [true];\r\n\r\n collapseChangeStates = [true];\r\n\r\n sortOrder = '';\r\n\r\n sortKey = '';\r\n\r\n selectedTab = 'audit-logs';\r\n\r\n constructor(\r\n public readonly list: ListService<GetAuditLogListDto>,\r\n protected service: AuditLogsService,\r\n ) {}\r\n\r\n ngOnInit() {\r\n this.hookToQuery();\r\n }\r\n\r\n private hookToQuery() {\r\n this.list\r\n .hookToQuery(query =>\r\n this.service.getList({\r\n ...this.pageQuery,\r\n ...(this.pageQuery.minExecutionDuration === null && {\r\n minExecutionDuration: undefined,\r\n }),\r\n ...(this.pageQuery.maxExecutionDuration === null && {\r\n maxExecutionDuration: undefined,\r\n }),\r\n ...query,\r\n }),\r\n )\r\n .subscribe(res => (this.data = res));\r\n }\r\n\r\n openModal(id: string) {\r\n this.service\r\n .get(id)\r\n .pipe(take(1))\r\n .subscribe(log => {\r\n this.selected = log;\r\n this.modalVisible = true;\r\n });\r\n }\r\n\r\n httpCodeClass(httpStatusCode: number): string {\r\n switch (httpStatusCode?.toString()[0]) {\r\n case '2':\r\n return 'badge-success';\r\n case '3':\r\n return 'badge-warning';\r\n case '4':\r\n case '5':\r\n return 'badge-danger';\r\n default:\r\n return 'badge-light';\r\n }\r\n }\r\n\r\n httpMethodClass(httpMethod: string): string {\r\n switch (httpMethod) {\r\n case 'GET':\r\n return 'badge-info';\r\n case 'POST':\r\n return 'badge-success';\r\n case 'DELETE':\r\n return 'badge-danger';\r\n case 'PUT':\r\n return 'badge-warning';\r\n default:\r\n return '';\r\n }\r\n }\r\n}\r\n","<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\">\r\n <div class=\"card-body pb-lg-3\">\r\n <form (keyup.enter)=\"list.get()\">\r\n <div class=\"row\">\r\n <div class=\"col-md-6 col-lg-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"startTime\" class=\"form-label\">{{\r\n 'AbpAuditLogging::StartTime' | abpLocalization\r\n }}</label\r\n ><input\r\n #startTime=\"ngbDatepicker\"\r\n class=\"form-control\"\r\n id=\"startTime\"\r\n name=\"startTime\"\r\n readonly\r\n [(ngModel)]=\"pageQuery.startTime\"\r\n ngbDatepicker\r\n (click)=\"startTime.toggle()\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"endTime\" class=\"form-label\">{{\r\n 'AbpAuditLogging::EndTime' | abpLocalization\r\n }}</label\r\n ><input\r\n #endTime=\"ngbDatepicker\"\r\n class=\"form-control\"\r\n id=\"endTime\"\r\n name=\"endTime\"\r\n readonly\r\n [(ngModel)]=\"pageQuery.endTime\"\r\n ngbDatepicker\r\n (click)=\"endTime.toggle()\"\r\n />\r\n </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-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-2\">\r\n <div class=\"mb-3\">\r\n <label class=\"form-label\" for=\"url\">{{\r\n 'AbpAuditLogging::UrlFilter' | 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\">\r\n <div class=\"mb-3\">\r\n <label for=\"minDuration\" class=\"form-label\">{{\r\n 'AbpAuditLogging::MinDuration' | abpLocalization\r\n }}</label\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 </div>\r\n </div>\r\n <div class=\"col-md-6 col-lg-2\">\r\n <div class=\"mb-3\">\r\n <label for=\"maxDuration\" class=\"form-label\">{{\r\n 'AbpAuditLogging::MaxDuration' | abpLocalization\r\n }}</label\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=\"row justify-content-end\">\r\n <div class=\"col-md-6 col-lg-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-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-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-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-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-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-2 d-grid\">\r\n <button type=\"button\" class=\"btn btn-primary mt-0\" (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 </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 />\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 />\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 />\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 />\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 />\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\">\r\n {{ selected.exceptions }}\r\n </pre>\r\n </div>\r\n </div>\r\n <hr />\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 />\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 />\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 />\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 />\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 />\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 />\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 />\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\"\r\n type=\"button\"\r\n (click)=\"collapseActionStates[i] = !collapseActionStates[i]\"\r\n >\r\n {{ action.serviceName }}\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 />\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","import { Inject, Injectable } from '@angular/core';\r\nimport { CanActivate } from '@angular/router';\r\nimport { AUDIT_LOGGING_FEATURES } from '@volo/abp.ng.audit-logging/common';\r\nimport { Observable } from 'rxjs';\r\nimport { map } from 'rxjs/operators';\r\nimport { ModuleVisibility } from '@volo/abp.commercial.ng.ui/config';\r\n\r\n@Injectable()\r\nexport class AuditLoggingGuard implements CanActivate {\r\n constructor(\r\n @Inject(AUDIT_LOGGING_FEATURES) private auditLoggingFeatures: Observable<ModuleVisibility>,\r\n ) {}\r\n\r\n canActivate() {\r\n return this.auditLoggingFeatures.pipe(map(features => features.enable));\r\n }\r\n}\r\n","import { EntityAction } from '@abp/ng.theme.shared/extensions';\r\nimport { AuditLogDto } from '@volo/abp.ng.audit-logging/proxy';\r\nimport { AuditLogsComponent } from '../components/audit-logs/audit-logs.component';\r\n\r\nexport const DEFAULT_AUDIT_LOGS_ENTITY_ACTIONS = EntityAction.createMany<AuditLogDto>([\r\n {\r\n text: 'AbpAuditLogging::Detail',\r\n action: data => {\r\n const component = data.getInjected(AuditLogsComponent);\r\n component.openModal(data.record.id);\r\n },\r\n icon: 'fa fa-search',\r\n },\r\n]);\r\n","import { EntityProp, ePropType } from '@abp/ng.theme.shared/extensions';\r\nimport { AuditLogDto } from '@volo/abp.ng.audit-logging/proxy';\r\nimport { of } from 'rxjs';\r\nimport { AuditLogsComponent } from '../components/audit-logs/audit-logs.component';\r\n\r\nexport const DEFAULT_AUDIT_LOGS_ENTITY_PROPS = EntityProp.createMany<AuditLogDto>([\r\n {\r\n type: ePropType.String,\r\n name: 'url',\r\n displayName: 'AbpAuditLogging::HttpRequest',\r\n sortable: true,\r\n columnWidth: 600,\r\n valueResolver: data => {\r\n const component = data.getInjected(AuditLogsComponent);\r\n const { httpMethod, httpStatusCode, url } = data.record;\r\n const methodClass = component.httpMethodClass(httpMethod);\r\n const statusClass = component.httpCodeClass(httpStatusCode);\r\n\r\n return of(\r\n `<span class=\"badge ${statusClass} me-1\">${httpStatusCode}</span>` +\r\n `<span class=\"badge ${methodClass} me-1\">${httpMethod}</span>` +\r\n (url || ''),\r\n );\r\n },\r\n },\r\n {\r\n type: ePropType.String,\r\n name: 'userName',\r\n displayName: 'AbpAuditLogging::User',\r\n sortable: true,\r\n columnWidth: 150,\r\n },\r\n {\r\n type: ePropType.String,\r\n name: 'clientIpAddress',\r\n displayName: 'AbpAuditLogging::IpAddress',\r\n sortable: true,\r\n columnWidth: 150,\r\n },\r\n {\r\n type: ePropType.DateTime,\r\n name: 'executionTime',\r\n displayName: 'AbpAuditLogging::Time',\r\n sortable: true,\r\n columnWidth: 150,\r\n },\r\n {\r\n type: ePropType.Number,\r\n name: 'executionDuration',\r\n displayName: 'AbpAuditLogging::Duration',\r\n sortable: true,\r\n columnWidth: 150,\r\n },\r\n {\r\n type: ePropType.String,\r\n name: 'applicationName',\r\n displayName: 'AbpAuditLogging::ApplicationName',\r\n sortable: true,\r\n columnWidth: 200,\r\n },\r\n]);\r\n","import { ToolbarAction } from '@abp/ng.theme.shared/extensions';\r\nimport { AuditLogDto } from '@volo/abp.ng.audit-logging/proxy';\r\n\r\nexport const DEFAULT_AUDIT_LOGS_TOOLBAR_ACTIONS = ToolbarAction.createMany<AuditLogDto[]>([]);\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const SHOW_ENTITY_DETAILS = new InjectionToken<(entityChangeId: string) => void>(\r\n 'SHOW_ENTITY_DETAILS',\r\n);\r\n","import { EntityAction } from '@abp/ng.theme.shared/extensions';\r\nimport { SHOW_ENTITY_HISTORY } from '@volo/abp.commercial.ng.ui';\r\nimport { EntityChangeDto } from '@volo/abp.ng.audit-logging/proxy';\r\nimport { SHOW_ENTITY_DETAILS } from '../tokens/entity-details.token';\r\n\r\nexport const DEFAULT_ENTITY_CHANGES_ENTITY_ACTIONS = EntityAction.createMany<EntityChangeDto>([\r\n {\r\n text: 'AbpAuditLogging::ChangeDetails',\r\n action: data => {\r\n const showDetails = data.getInjected(SHOW_ENTITY_DETAILS);\r\n showDetails(data.record.id);\r\n },\r\n icon: 'fa fa-search',\r\n },\r\n {\r\n text: 'AbpAuditLogging::FullChangeHistory',\r\n action: data => {\r\n const showHistory = data.getInjected(SHOW_ENTITY_HISTORY);\r\n showHistory(data.record.entityId, data.record.entityTypeFullName);\r\n },\r\n icon: 'fa fa-history',\r\n },\r\n]);\r\n","import {\r\n EntityActionContributorCallback,\r\n EntityPropContributorCallback,\r\n ToolbarActionContributorCallback,\r\n} from '@abp/ng.theme.shared/extensions';\r\nimport { InjectionToken } from '@angular/core';\r\nimport { AuditLogDto, EntityChangeDto } from '@volo/abp.ng.audit-logging/proxy';\r\nimport { DEFAULT_AUDIT_LOGS_ENTITY_ACTIONS } from '../defaults/default-audit-logs-entity-actions';\r\nimport { DEFAULT_AUDIT_LOGS_ENTITY_PROPS } from '../defaults/default-audit-logs-entity-props';\r\nimport { DEFAULT_AUDIT_LOGS_TOOLBAR_ACTIONS } from '../defaults/default-audit-logs-toolbar-actions';\r\nimport { DEFAULT_ENTITY_CHANGES_ENTITY_ACTIONS } from '../defaults/default-entity-changes-entity-actions';\r\nimport { eAuditLoggingComponents } from '../enums/components';\r\n\r\nexport const DEFAULT_AUDIT_LOGGING_ENTITY_ACTIONS = {\r\n [eAuditLoggingComponents.AuditLogs]: DEFAULT_AUDIT_LOGS_ENTITY_ACTIONS,\r\n [eAuditLoggingComponents.EntityChanges]: DEFAULT_ENTITY_CHANGES_ENTITY_ACTIONS,\r\n};\r\n\r\nexport const DEFAULT_AUDIT_LOGGING_TOOLBAR_ACTIONS = {\r\n [eAuditLoggingComponents.AuditLogs]: DEFAULT_AUDIT_LOGS_TOOLBAR_ACTIONS,\r\n};\r\nexport const DEFAULT_AUDIT_LOGGING_ENTITY_PROPS = {\r\n [eAuditLoggingComponents.AuditLogs]: DEFAULT_AUDIT_LOGS_ENTITY_PROPS,\r\n};\r\n\r\nexport const AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS =\r\n new InjectionToken<EntityActionContributors>('AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS');\r\n\r\nexport const AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS =\r\n new InjectionToken<ToolbarActionContributors>('AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS');\r\n\r\nexport const AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS = new InjectionToken<EntityPropContributors>(\r\n 'AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS',\r\n);\r\n\r\n// https://github.com/microsoft/TypeScript/issues/9944#issuecomment-254693497\r\ntype EntityActionContributors = Partial<{\r\n [eAuditLoggingComponents.AuditLogs]: EntityActionContributorCallback<AuditLogDto>[];\r\n [eAuditLoggingComponents.EntityChanges]: EntityActionContributorCallback<EntityChangeDto>[];\r\n}>;\r\ntype ToolbarActionContributors = Partial<{\r\n [eAuditLoggingComponents.AuditLogs]: ToolbarActionContributorCallback<AuditLogDto[]>[];\r\n}>;\r\ntype EntityPropContributors = Partial<{\r\n [eAuditLoggingComponents.AuditLogs]: EntityPropContributorCallback<AuditLogDto>[];\r\n}>;\r\n","import { ConfigStateService } from '@abp/ng.core';\r\nimport {\r\n ExtensionsService,\r\n getObjectExtensionEntitiesFromStore,\r\n mapEntitiesToContributors,\r\n mergeWithDefaultActions,\r\n mergeWithDefaultProps,\r\n} from '@abp/ng.theme.shared/extensions';\r\nimport { Injectable, Injector } from '@angular/core';\r\nimport { CanActivate } from '@angular/router';\r\nimport { Observable } from 'rxjs';\r\nimport { map, mapTo, tap } from 'rxjs/operators';\r\nimport { eAuditLoggingComponents } from '../enums/components';\r\nimport {\r\n AuditLoggingEntityActionContributors,\r\n AuditLoggingEntityPropContributors,\r\n AuditLoggingToolbarActionContributors,\r\n} from '../models/config-options';\r\nimport {\r\n AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS,\r\n AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS,\r\n AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS,\r\n DEFAULT_AUDIT_LOGGING_ENTITY_ACTIONS,\r\n DEFAULT_AUDIT_LOGGING_ENTITY_PROPS,\r\n DEFAULT_AUDIT_LOGGING_TOOLBAR_ACTIONS,\r\n} from '../tokens/extensions.token';\r\n\r\n@Injectable()\r\nexport class AuditLoggingExtensionsGuard implements CanActivate {\r\n constructor(private injector: Injector) {}\r\n\r\n canActivate(): Observable<boolean> {\r\n const extensions: ExtensionsService = this.injector.get(ExtensionsService);\r\n const actionContributors: AuditLoggingEntityActionContributors =\r\n this.injector.get(AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS, null) || {};\r\n const toolbarContributors: AuditLoggingToolbarActionContributors =\r\n this.injector.get(AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS, null) || {};\r\n const propContributors: AuditLoggingEntityPropContributors =\r\n this.injector.get(AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS, null) || {};\r\n\r\n const configState = this.injector.get(ConfigStateService);\r\n return getObjectExtensionEntitiesFromStore(configState, 'AuditLogging').pipe(\r\n map(entities => ({\r\n [eAuditLoggingComponents.AuditLogs]: entities.AuditLog,\r\n })),\r\n mapEntitiesToContributors(configState, 'AuditLogging'),\r\n tap(objectExtensionContributors => {\r\n mergeWithDefaultActions(\r\n extensions.entityActions,\r\n DEFAULT_AUDIT_LOGGING_ENTITY_ACTIONS,\r\n actionContributors,\r\n );\r\n mergeWithDefaultActions(\r\n extensions.toolbarActions,\r\n DEFAULT_AUDIT_LOGGING_TOOLBAR_ACTIONS,\r\n toolbarContributors,\r\n );\r\n mergeWithDefaultProps(\r\n extensions.entityProps,\r\n DEFAULT_AUDIT_LOGGING_ENTITY_PROPS,\r\n objectExtensionContributors.prop,\r\n propContributors,\r\n );\r\n }),\r\n mapTo(true),\r\n );\r\n }\r\n}\r\n","import {\r\n AuthGuard,\r\n PermissionGuard,\r\n ReplaceableComponents,\r\n ReplaceableRouteContainerComponent,\r\n RouterOutletComponent,\r\n} from '@abp/ng.core';\r\nimport { NgModule } from '@angular/core';\r\nimport { RouterModule, Routes } from '@angular/router';\r\nimport { AuditLogsComponent } from './components/audit-logs/audit-logs.component';\r\nimport { eAuditLoggingComponents } from './enums/components';\r\nimport { AuditLoggingGuard } from './guards/audit-logging.guard';\r\nimport { AuditLoggingExtensionsGuard } from './guards/extensions.guard';\r\n\r\nconst routes: Routes = [\r\n {\r\n path: '',\r\n component: RouterOutletComponent,\r\n canActivate: [AuthGuard, PermissionGuard, AuditLoggingExtensionsGuard, AuditLoggingGuard],\r\n children: [\r\n {\r\n path: '',\r\n component: ReplaceableRouteContainerComponent,\r\n data: {\r\n requiredPolicy: 'AuditLogging.AuditLogs',\r\n replaceableComponent: {\r\n key: eAuditLoggingComponents.AuditLogs,\r\n defaultComponent: AuditLogsComponent,\r\n } as ReplaceableComponents.RouteData<AuditLogsComponent>,\r\n },\r\n },\r\n ],\r\n },\r\n];\r\n\r\n@NgModule({\r\n imports: [RouterModule.forChild(routes)],\r\n exports: [RouterModule],\r\n})\r\nexport class AuditLoggingRoutingModule {}\r\n","import { ChartComponent } from '@abp/ng.components/chart.js';\r\nimport { LocalizationService, PermissionService } from '@abp/ng.core';\r\nimport { Statistics } from '@abp/ng.theme.shared';\r\nimport { Component, Input, Output, ViewChild } from '@angular/core';\r\nimport { AuditLogsService } from '@volo/abp.ng.audit-logging/proxy';\r\nimport { BehaviorSubject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'abp-average-execution-duration-widget',\r\n template: `\r\n <div *abpPermission=\"'AuditLogging.AuditLogs'\" class=\"abp-widget-wrapper\">\r\n <div class=\"card\">\r\n <div class=\"card-header\">\r\n <h5 class=\"card-title\">\r\n {{ 'AbpAuditLogging::AverageExecutionDurationInLogsPerDay' | abpLocalization }}\r\n </h5>\r\n </div>\r\n <div class=\"card-body\">\r\n <div class=\"row\">\r\n <abp-chart\r\n #chart\r\n class=\"w-100\"\r\n type=\"bar\"\r\n [data]=\"chartData\"\r\n [width]=\"width\"\r\n [height]=\"height\"\r\n ></abp-chart>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n `,\r\n})\r\nexport class AverageExecutionDurationWidgetComponent {\r\n data: Statistics.Data = {};\r\n\r\n @Output() initialized = new BehaviorSubject(this);\r\n\r\n @Input() width = 273;\r\n\r\n @Input() height = 136;\r\n\r\n @ViewChild(ChartComponent) chart: ChartComponent;\r\n\r\n chartData: any = {};\r\n\r\n draw = (filter: { startDate: string; endDate: string }) => {\r\n if (!this.permissionService.getGrantedPolicy('AuditLogging.AuditLogs')) {\r\n return;\r\n }\r\n\r\n this.service\r\n .getAverageExecutionDurationPerDay({ startDate: filter.startDate, endDate: filter.endDate })\r\n .subscribe(res => {\r\n this.data = res.data;\r\n this.setChartData();\r\n });\r\n };\r\n\r\n constructor(\r\n protected localizationService: LocalizationService,\r\n protected permissionService: PermissionService,\r\n protected service: AuditLogsService,\r\n ) {}\r\n\r\n private setChartData() {\r\n if (!this.data || JSON.stringify(this.data) === '{}') {\r\n this.chartData = {};\r\n return;\r\n }\r\n const dataKeys = Object.keys(this.data);\r\n\r\n setTimeout(() => {\r\n this.chartData = {\r\n labels: dataKeys,\r\n datasets: [\r\n {\r\n label: this.localizationService.instant(\r\n 'AbpAuditLogging::AverageExecutionDurationInMilliseconds',\r\n ),\r\n backgroundColor: '#fa6e6e',\r\n data: dataKeys.map(key => this.data[key]),\r\n },\r\n ],\r\n };\r\n this.chart.refresh();\r\n }, 0);\r\n }\r\n}\r\n","import { ChartComponent } from '@abp/ng.components/chart.js';\r\nimport { PermissionService } from '@abp/ng.core';\r\nimport { Statistics } from '@abp/ng.theme.shared';\r\nimport { Component, Input, Output, ViewChild } from '@angular/core';\r\nimport { AuditLogsService } from '@volo/abp.ng.audit-logging/proxy';\r\nimport { BehaviorSubject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'abp-error-rate-widget',\r\n template: `\r\n <div *abpPermission=\"'AuditLogging.AuditLogs'\" class=\"abp-widget-wrapper\">\r\n <div class=\"card\">\r\n <div class=\"card-header\">\r\n <h5 class=\"card-title\">\r\n {{ 'AbpAuditLogging::ErrorRateInLogs' | abpLocalization }}\r\n </h5>\r\n </div>\r\n <div class=\"card-body\">\r\n <div class=\"row\">\r\n <abp-chart\r\n #chart\r\n class=\"w-100\"\r\n type=\"pie\"\r\n [data]=\"chartData\"\r\n [width]=\"width\"\r\n [height]=\"height\"\r\n ></abp-chart>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n `,\r\n})\r\nexport class ErrorRateWidgetComponent {\r\n data: Statistics.Data = {};\r\n\r\n @Output() initialized = new BehaviorSubject(this);\r\n\r\n @Input() width = 273;\r\n\r\n @Input() height = 136;\r\n\r\n @ViewChild(ChartComponent) chart: ChartComponent;\r\n\r\n chartData: any = {};\r\n\r\n draw = (filter: { startDate: string; endDate: string }) => {\r\n if (!this.permissionService.getGrantedPolicy('AuditLogging.AuditLogs')) {\r\n return;\r\n }\r\n\r\n this.service\r\n .getErrorRate({\r\n startDate: filter.startDate,\r\n endDate: filter.endDate,\r\n })\r\n .subscribe(res => {\r\n this.data = res.data;\r\n this.setChartData();\r\n });\r\n };\r\n\r\n constructor(\r\n protected permissionService: PermissionService,\r\n protected service: AuditLogsService,\r\n ) {}\r\n\r\n private setChartData() {\r\n if (!this.data || JSON.stringify(this.data) === '{}') {\r\n this.chartData = {};\r\n return;\r\n }\r\n const dataKeys = Object.keys(this.data);\r\n\r\n setTimeout(() => {\r\n this.chartData = {\r\n labels: dataKeys,\r\n datasets: [\r\n {\r\n data: dataKeys.map(key => this.data[key]),\r\n backgroundColor: ['#d76e6e', '#63ac44'],\r\n },\r\n ],\r\n };\r\n\r\n this.chart.refresh();\r\n }, 0);\r\n }\r\n}\r\n","import { ChartModule } from '@abp/ng.components/chart.js';\r\nimport { PageModule } from '@abp/ng.components/page';\r\nimport { CoreModule, LazyModuleFactory } from '@abp/ng.core';\r\nimport { ThemeSharedModule } from '@abp/ng.theme.shared';\r\nimport { ModuleWithProviders, NgModule, NgModuleFactory } from '@angular/core';\r\nimport { NgbDatepickerModule, NgbNavModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { CommercialUiModule } from '@volo/abp.commercial.ng.ui';\r\nimport { AuditLoggingRoutingModule } from './audit-logging-routing.module';\r\nimport { AuditLogsComponent } from './components/audit-logs/audit-logs.component';\r\nimport { EntityChangesComponent } from './components/entity-change/entity-changes.component';\r\nimport { AverageExecutionDurationWidgetComponent } from './components/widgets/average-execution-duration-widget.component';\r\nimport { ErrorRateWidgetComponent } from './components/widgets/error-rate-widget.component';\r\nimport { AuditLoggingGuard } from './guards/audit-logging.guard';\r\nimport { AuditLoggingExtensionsGuard } from './guards/extensions.guard';\r\nimport { AuditLoggingConfigOptions } from './models/config-options';\r\nimport {\r\n AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS,\r\n AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS,\r\n AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS,\r\n} from './tokens/extensions.token';\r\n\r\n@NgModule({\r\n declarations: [\r\n AuditLogsComponent,\r\n EntityChangesComponent,\r\n ErrorRateWidgetComponent,\r\n AverageExecutionDurationWidgetComponent,\r\n ],\r\n exports: [\r\n AuditLogsComponent,\r\n EntityChangesComponent,\r\n ErrorRateWidgetComponent,\r\n AverageExecutionDurationWidgetComponent,\r\n ],\r\n imports: [\r\n AuditLoggingRoutingModule,\r\n CoreModule,\r\n CommercialUiModule,\r\n ThemeSharedModule,\r\n NgbNavModule,\r\n NgbDatepickerModule,\r\n PageModule,\r\n ChartModule,\r\n ],\r\n})\r\nexport class AuditLoggingModule {\r\n static forChild(\r\n options: AuditLoggingConfigOptions = {},\r\n ): ModuleWithProviders<AuditLoggingModule> {\r\n return {\r\n ngModule: AuditLoggingModule,\r\n providers: [\r\n {\r\n provide: AUDIT_LOGGING_ENTITY_ACTION_CONTRIBUTORS,\r\n useValue: options.entityActionContributors,\r\n },\r\n {\r\n provide: AUDIT_LOGGING_TOOLBAR_ACTION_CONTRIBUTORS,\r\n useValue: options.toolbarActionContributors,\r\n },\r\n {\r\n provide: AUDIT_LOGGING_ENTITY_PROP_CONTRIBUTORS,\r\n useValue: options.entityPropContributors,\r\n },\r\n AuditLoggingGuard,\r\n AuditLoggingExtensionsGuard,\r\n ],\r\n };\r\n }\r\n\r\n static forLazy(options: AuditLoggingConfigOptions = {}): NgModuleFactory<AuditLoggingModule> {\r\n return new LazyModuleFactory(AuditLoggingModule.forChild(options));\r\n }\r\n}\r\n","export enum eEntityChangeType {\r\n Created = 0,\r\n Updated = 1,\r\n Deleted = 2,\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;MAAa,YAAY,GAAG,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,SAAS,EAAE,OAAO,EAAE;MAEvF,iBAAiB,GAAG;IAC/B,EAAE,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,UAAU,EAAE;IAClC,EAAE,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,qBAAqB,EAAE;IAC7C,EAAE,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,YAAY,EAAE;IACpC,EAAE,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,aAAa,EAAE;IACrC,EAAE,IA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;aAC5B;SACF,CAAC;KACH;IAED,OAAO,OAAO,CAAC,UAAqC,EAAE;QACpD,OAAO,IAAI,iBAAiB,CAAC,kBAAkB,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;KACpE;;+GA3BU,kBAAkB;gHAAlB,kBAAkB,iBAtB3B,kBAAkB;QAClB,sBAAsB;QACtB,wBAAwB;QACxB,uCAAuC,aASvC,yBAAyB;QACzB,UAAU;QACV,kBAAkB;QAClB,iBAAiB;QACjB,YAAY;QACZ,mBAAmB;QACnB,UAAU;QACV,WAAW,aAbX,kBAAkB;QAClB,sBAAsB;QACtB,wBAAwB;QACxB,uCAAuC;gHAa9B,kBAAkB,YAXpB;YACP,yBAAyB;YACzB,UAAU;YACV,kBAAkB;YAClB,iBAAiB;YACjB,YAAY;YACZ,mBAAmB;YACnB,UAAU;YACV,WAAW;SACZ;2FAEU,kBAAkB;kBAxB9B,QAAQ;mBAAC;oBACR,YAAY,EAAE;wBACZ,kBAAkB;wBAClB,sBAAsB;wBACtB,wBAAwB;wBACxB,uCAAuC;qBACxC;oBACD,OAAO,EAAE;wBACP,kBAAkB;wBAClB,sBAAsB;wBACtB,wBAAwB;wBACxB,uCAAuC;qBACxC;oBACD,OAAO,EAAE;wBACP,yBAAyB;wBACzB,UAAU;wBACV,kBAAkB;wBAClB,iBAAiB;wBACjB,YAAY;wBACZ,mBAAmB;wBACnB,UAAU;wBACV,WAAW;qBACZ;iBACF;;;IC5CW;AAAZ,WAAY,iBAAiB;IAC3B,+DAAW,CAAA;IACX,+DAAW,CAAA;IACX,+DAAW,CAAA;AACb,CAAC,EAJW,iBAAiB,KAAjB,iBAAiB;;ACA7B;;;;;;"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { ConfigStateService, featuresFactory, RoutesService, noop } from '@abp/ng.core';
|
|
2
|
+
import { InjectionToken, inject, APP_INITIALIZER } from '@angular/core';
|
|
3
|
+
import { setModuleVisibilityFactory } from '@volo/abp.commercial.ng.ui/config';
|
|
4
|
+
|
|
5
|
+
const AUDIT_LOGGING_FEATURES = new InjectionToken('AUDIT_LOGGING_FEATURES', {
|
|
6
|
+
providedIn: 'root',
|
|
7
|
+
factory: () => {
|
|
8
|
+
const configState = inject(ConfigStateService);
|
|
9
|
+
const featureKey = 'AuditLogging.Enable';
|
|
10
|
+
const mapFn = features => ({
|
|
11
|
+
enable: features[featureKey].toLowerCase() !== 'false',
|
|
12
|
+
});
|
|
13
|
+
return featuresFactory(configState, [featureKey], mapFn);
|
|
14
|
+
},
|
|
15
|
+
});
|
|
16
|
+
const SET_AUDIT_LOGGING_ROUTE_VISIBILITY = new InjectionToken('SET_AUDIT_LOGGING_ROUTE_VISIBILITY', {
|
|
17
|
+
providedIn: 'root',
|
|
18
|
+
factory: () => {
|
|
19
|
+
const routes = inject(RoutesService);
|
|
20
|
+
const stream = inject(AUDIT_LOGGING_FEATURES);
|
|
21
|
+
setModuleVisibilityFactory(stream, routes, "AbpAuditLogging::Menu:AuditLogging" /* AuditLogging */).subscribe();
|
|
22
|
+
},
|
|
23
|
+
});
|
|
24
|
+
const AUDIT_LOGGING_FEATURES_PROVIDERS = [
|
|
25
|
+
{
|
|
26
|
+
provide: APP_INITIALIZER,
|
|
27
|
+
useFactory: noop,
|
|
28
|
+
deps: [SET_AUDIT_LOGGING_ROUTE_VISIBILITY],
|
|
29
|
+
multi: true,
|
|
30
|
+
},
|
|
31
|
+
];
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* Generated bundle index. Do not edit.
|
|
35
|
+
*/
|
|
36
|
+
|
|
37
|
+
export { AUDIT_LOGGING_FEATURES, AUDIT_LOGGING_FEATURES_PROVIDERS, SET_AUDIT_LOGGING_ROUTE_VISIBILITY };
|
|
38
|
+
//# sourceMappingURL=volo-abp.ng.audit-logging-common.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"volo-abp.ng.audit-logging-common.mjs","sources":["../../../../packages/audit-logging/common/src/tokens/features.token.ts","../../../../packages/audit-logging/common/src/volo-abp.ng.audit-logging-common.ts"],"sourcesContent":["import { ConfigStateService, featuresFactory, noop, RoutesService } from '@abp/ng.core';\r\nimport { APP_INITIALIZER, inject, InjectionToken } from '@angular/core';\r\nimport { ModuleVisibility, setModuleVisibilityFactory } from '@volo/abp.commercial.ng.ui/config';\r\nimport { Observable } from 'rxjs';\r\nimport { eAuditLoggingRouteNames } from '../enums/route-names';\r\n\r\nexport const AUDIT_LOGGING_FEATURES = new InjectionToken<Observable<ModuleVisibility>>(\r\n 'AUDIT_LOGGING_FEATURES',\r\n {\r\n providedIn: 'root',\r\n factory: () => {\r\n const configState = inject(ConfigStateService);\r\n const featureKey = 'AuditLogging.Enable';\r\n const mapFn = features => ({\r\n enable: features[featureKey].toLowerCase() !== 'false',\r\n });\r\n\r\n return featuresFactory(configState, [featureKey], mapFn);\r\n },\r\n },\r\n);\r\n\r\nexport const SET_AUDIT_LOGGING_ROUTE_VISIBILITY = new InjectionToken(\r\n 'SET_AUDIT_LOGGING_ROUTE_VISIBILITY',\r\n {\r\n providedIn: 'root',\r\n factory: () => {\r\n const routes = inject(RoutesService);\r\n const stream = inject(AUDIT_LOGGING_FEATURES);\r\n\r\n setModuleVisibilityFactory(stream, routes, eAuditLoggingRouteNames.AuditLogging).subscribe();\r\n },\r\n },\r\n);\r\n\r\nexport const AUDIT_LOGGING_FEATURES_PROVIDERS = [\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: noop,\r\n deps: [SET_AUDIT_LOGGING_ROUTE_VISIBILITY],\r\n multi: true,\r\n },\r\n];\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;MAMa,sBAAsB,GAAG,IAAI,cAAc,CACtD,wBAAwB,EACxB;IACE,UAAU,EAAE,MAAM;IAClB,OAAO,EAAE;QACP,MAAM,WAAW,GAAG,MAAM,CAAC,kBAAkB,CAAC,CAAC;QAC/C,MAAM,UAAU,GAAG,qBAAqB,CAAC;QACzC,MAAM,KAAK,GAAG,QAAQ,KAAK;YACzB,MAAM,EAAE,QAAQ,CAAC,UAAU,CAAC,CAAC,WAAW,EAAE,KAAK,OAAO;SACvD,CAAC,CAAC;QAEH,OAAO,eAAe,CAAC,WAAW,EAAE,CAAC,UAAU,CAAC,EAAE,KAAK,CAAC,CAAC;KAC1D;CACF,EACD;MAEW,kCAAkC,GAAG,IAAI,cAAc,CAClE,oCAAoC,EACpC;IACE,UAAU,EAAE,MAAM;IAClB,OAAO,EAAE;QACP,MAAM,MAAM,GAAG,MAAM,CAAC,aAAa,CAAC,CAAC;QACrC,MAAM,MAAM,GAAG,MAAM,CAAC,sBAAsB,CAAC,CAAC;QAE9C,0BAA0B,CAAC,MAAM,EAAE,MAAM,0DAAuC,CAAC,SAAS,EAAE,CAAC;KAC9F;CACF,EACD;MAEW,gCAAgC,GAAG;IAC9C;QACE,OAAO,EAAE,eAAe;QACxB,UAAU,EAAE,IAAI;QAChB,IAAI,EAAE,CAAC,kCAAkC,CAAC;QAC1C,KAAK,EAAE,IAAI;KACZ;;;ACzCH;;;;;;"}
|
|
@@ -0,0 +1,182 @@
|
|
|
1
|
+
import * as i1 from '@abp/ng.core';
|
|
2
|
+
import { uuid, PROJECTION_STRATEGY, RoutesService, CoreModule } from '@abp/ng.core';
|
|
3
|
+
import * as i2$1 from '@abp/ng.theme.shared';
|
|
4
|
+
import { collapse, ThemeSharedModule } from '@abp/ng.theme.shared';
|
|
5
|
+
import * as i0 from '@angular/core';
|
|
6
|
+
import { Component, Input, ChangeDetectionStrategy, Injectable, APP_INITIALIZER, NgModule } from '@angular/core';
|
|
7
|
+
import * as i1$1 from '@volo/abp.ng.audit-logging/proxy';
|
|
8
|
+
import { EntityChangeType } from '@volo/abp.ng.audit-logging/proxy';
|
|
9
|
+
import * as i2 from '@angular/common';
|
|
10
|
+
import { SHOW_ENTITY_DETAILS } from '@volo/abp.ng.audit-logging';
|
|
11
|
+
import { SHOW_ENTITY_HISTORY } from '@volo/abp.commercial.ng.ui';
|
|
12
|
+
import { AUDIT_LOGGING_FEATURES_PROVIDERS } from '@volo/abp.ng.audit-logging/common';
|
|
13
|
+
|
|
14
|
+
class EntityChangeDetailsComponent {
|
|
15
|
+
constructor(track) {
|
|
16
|
+
this.track = track;
|
|
17
|
+
this.isCollapsed = false;
|
|
18
|
+
this.colors = {
|
|
19
|
+
[EntityChangeType.Created]: 'success',
|
|
20
|
+
[EntityChangeType.Updated]: 'info',
|
|
21
|
+
[EntityChangeType.Deleted]: 'danger',
|
|
22
|
+
};
|
|
23
|
+
this.uuid = uuid();
|
|
24
|
+
}
|
|
25
|
+
set itemWithUserName(item) {
|
|
26
|
+
this.changeType = EntityChangeType[item.entityChange.changeType];
|
|
27
|
+
this.color = this.colors[item.entityChange.changeType];
|
|
28
|
+
this.userName = item.userName;
|
|
29
|
+
this.entityChange = item.entityChange;
|
|
30
|
+
}
|
|
31
|
+
getPropColor(propertyChange) {
|
|
32
|
+
return this.entityChange.changeType === EntityChangeType.Updated &&
|
|
33
|
+
propertyChange.newValue !== propertyChange.originalValue
|
|
34
|
+
? 'red'
|
|
35
|
+
: undefined;
|
|
36
|
+
}
|
|
37
|
+
getInterpolationParams(changeTime) {
|
|
38
|
+
return [this.changeType, changeTime, this.userName];
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
EntityChangeDetailsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EntityChangeDetailsComponent, deps: [{ token: i1.TrackByService }], target: i0.ɵɵFactoryTarget.Component });
|
|
42
|
+
EntityChangeDetailsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: EntityChangeDetailsComponent, selector: "abp-entity-change-details", inputs: { itemWithUserName: "itemWithUserName", isCollapsed: "isCollapsed" }, ngImport: i0, template: "<div\r\n class=\"mb-3 border border-dark rounded\"\r\n *ngIf=\"getInterpolationParams(entityChange.changeTime | date: 'medium') as params\"\r\n>\r\n <div class=\"d-grid\">\r\n <button\r\n type=\"button\"\r\n class=\"btn btn-{{ color }}\"\r\n (click)=\"isCollapsed = !isCollapsed\"\r\n [attr.aria-expanded]=\"!isCollapsed\"\r\n [attr.aria-controls]=\"uuid\"\r\n >\r\n {{ 'AbpAuditLogging::DaysAgoWithUserTitle' | abpLocalization: params }}\r\n </button>\r\n </div>\r\n <div [id]=\"uuid\" [@collapse]=\"isCollapsed ? 'collapsed' : 'expanded'\">\r\n <div class=\"m-3\">\r\n <table class=\"table table-striped\">\r\n <thead>\r\n <tr>\r\n <th>{{ 'AbpAuditLogging::PropertyName' | abpLocalization }}</th>\r\n <th>{{ 'AbpAuditLogging::OriginalValue' | abpLocalization }}</th>\r\n <th>{{ 'AbpAuditLogging::NewValue' | abpLocalization }}</th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <tr *ngFor=\"let prop of entityChange.propertyChanges; trackBy: track.by('id')\">\r\n <td>{{ prop.propertyName }}</td>\r\n <td>{{ prop.originalValue }}</td>\r\n <td [style.color]=\"getPropColor(prop)\">{{ prop.newValue }}</td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </div>\r\n </div>\r\n</div>\r\n", directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], pipes: { "date": i2.DatePipe, "abpLocalization": i1.LocalizationPipe }, animations: [collapse] });
|
|
43
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EntityChangeDetailsComponent, decorators: [{
|
|
44
|
+
type: Component,
|
|
45
|
+
args: [{ selector: 'abp-entity-change-details', animations: [collapse], template: "<div\r\n class=\"mb-3 border border-dark rounded\"\r\n *ngIf=\"getInterpolationParams(entityChange.changeTime | date: 'medium') as params\"\r\n>\r\n <div class=\"d-grid\">\r\n <button\r\n type=\"button\"\r\n class=\"btn btn-{{ color }}\"\r\n (click)=\"isCollapsed = !isCollapsed\"\r\n [attr.aria-expanded]=\"!isCollapsed\"\r\n [attr.aria-controls]=\"uuid\"\r\n >\r\n {{ 'AbpAuditLogging::DaysAgoWithUserTitle' | abpLocalization: params }}\r\n </button>\r\n </div>\r\n <div [id]=\"uuid\" [@collapse]=\"isCollapsed ? 'collapsed' : 'expanded'\">\r\n <div class=\"m-3\">\r\n <table class=\"table table-striped\">\r\n <thead>\r\n <tr>\r\n <th>{{ 'AbpAuditLogging::PropertyName' | abpLocalization }}</th>\r\n <th>{{ 'AbpAuditLogging::OriginalValue' | abpLocalization }}</th>\r\n <th>{{ 'AbpAuditLogging::NewValue' | abpLocalization }}</th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <tr *ngFor=\"let prop of entityChange.propertyChanges; trackBy: track.by('id')\">\r\n <td>{{ prop.propertyName }}</td>\r\n <td>{{ prop.originalValue }}</td>\r\n <td [style.color]=\"getPropColor(prop)\">{{ prop.newValue }}</td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </div>\r\n </div>\r\n</div>\r\n" }]
|
|
46
|
+
}], ctorParameters: function () { return [{ type: i1.TrackByService }]; }, propDecorators: { itemWithUserName: [{
|
|
47
|
+
type: Input
|
|
48
|
+
}], isCollapsed: [{
|
|
49
|
+
type: Input
|
|
50
|
+
}] } });
|
|
51
|
+
|
|
52
|
+
class EntityChangeModalComponent {
|
|
53
|
+
constructor(cdRef, track) {
|
|
54
|
+
this.cdRef = cdRef;
|
|
55
|
+
this.track = track;
|
|
56
|
+
this.history = [];
|
|
57
|
+
this.visible = false;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
EntityChangeModalComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EntityChangeModalComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1.TrackByService }], target: i0.ɵɵFactoryTarget.Component });
|
|
61
|
+
EntityChangeModalComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.1.1", type: EntityChangeModalComponent, selector: "abp-entity-change-modal", ngImport: i0, template: "<abp-modal [(visible)]=\"visible\" [options]=\"{ size: 'lg' }\">\r\n <ng-template #abpHeader>\r\n <h5 class=\"modal-title\">\r\n {{ entityTypeFullName }}\r\n <br />\r\n <span style=\"font-size: small\">({{ entityId }})</span>\r\n </h5>\r\n </ng-template>\r\n <ng-template #abpBody>\r\n <ng-container *ngIf=\"history.length; else noChanges\">\r\n <abp-entity-change-details\r\n *ngFor=\"let change of history; first as f; trackBy: track.byDeep('entityChange', 'id')\"\r\n [itemWithUserName]=\"change\"\r\n [isCollapsed]=\"!f\"\r\n ></abp-entity-change-details>\r\n </ng-container>\r\n\r\n <ng-template #noChanges\r\n ><div class=\"text-center\">\r\n {{ 'AbpAuditLogging::NoChanges' | abpLocalization }}\r\n </div></ng-template\r\n >\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", components: [{ type: i2$1.ModalComponent, selector: "abp-modal", inputs: ["visible", "busy", "options", "suppressUnsavedChangesWarning"], outputs: ["visibleChange", "init", "appear", "disappear"] }, { type: EntityChangeDetailsComponent, selector: "abp-entity-change-details", inputs: ["itemWithUserName", "isCollapsed"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2$1.ModalCloseDirective, selector: "[abpClose]" }], pipes: { "abpLocalization": i1.LocalizationPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
62
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EntityChangeModalComponent, decorators: [{
|
|
63
|
+
type: Component,
|
|
64
|
+
args: [{ selector: 'abp-entity-change-modal', changeDetection: ChangeDetectionStrategy.OnPush, template: "<abp-modal [(visible)]=\"visible\" [options]=\"{ size: 'lg' }\">\r\n <ng-template #abpHeader>\r\n <h5 class=\"modal-title\">\r\n {{ entityTypeFullName }}\r\n <br />\r\n <span style=\"font-size: small\">({{ entityId }})</span>\r\n </h5>\r\n </ng-template>\r\n <ng-template #abpBody>\r\n <ng-container *ngIf=\"history.length; else noChanges\">\r\n <abp-entity-change-details\r\n *ngFor=\"let change of history; first as f; trackBy: track.byDeep('entityChange', 'id')\"\r\n [itemWithUserName]=\"change\"\r\n [isCollapsed]=\"!f\"\r\n ></abp-entity-change-details>\r\n </ng-container>\r\n\r\n <ng-template #noChanges\r\n ><div class=\"text-center\">\r\n {{ 'AbpAuditLogging::NoChanges' | abpLocalization }}\r\n </div></ng-template\r\n >\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" }]
|
|
65
|
+
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i1.TrackByService }]; } });
|
|
66
|
+
|
|
67
|
+
class EntityChangeModalService {
|
|
68
|
+
constructor(auditLogsService, contentProjectionService) {
|
|
69
|
+
this.auditLogsService = auditLogsService;
|
|
70
|
+
this.contentProjectionService = contentProjectionService;
|
|
71
|
+
this.projectModal();
|
|
72
|
+
}
|
|
73
|
+
projectModal() {
|
|
74
|
+
this.modalRef = this.contentProjectionService.projectContent(PROJECTION_STRATEGY.AppendComponentToBody(EntityChangeModalComponent));
|
|
75
|
+
this.modalRef.changeDetectorRef.detectChanges();
|
|
76
|
+
}
|
|
77
|
+
detectChanges() {
|
|
78
|
+
this.modalRef.changeDetectorRef.detectChanges();
|
|
79
|
+
this.modalRef.instance.cdRef.detectChanges();
|
|
80
|
+
}
|
|
81
|
+
showDetails(entityChangeId) {
|
|
82
|
+
this.auditLogsService.getEntityChangeWithUsername(entityChangeId).subscribe(change => {
|
|
83
|
+
this.modalRef.instance.entityId = change.entityChange.entityId;
|
|
84
|
+
this.modalRef.instance.entityTypeFullName = change.entityChange.entityTypeFullName;
|
|
85
|
+
this.modalRef.instance.history = [change].filter(Boolean);
|
|
86
|
+
this.modalRef.instance.visible = true;
|
|
87
|
+
this.detectChanges();
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
showHistory(entityId, entityTypeFullName) {
|
|
91
|
+
this.auditLogsService
|
|
92
|
+
.getEntityChangesWithUsername({ entityId, entityTypeFullName })
|
|
93
|
+
.subscribe(changes => {
|
|
94
|
+
this.modalRef.instance.entityId = entityId;
|
|
95
|
+
this.modalRef.instance.entityTypeFullName = entityTypeFullName;
|
|
96
|
+
this.modalRef.instance.history = changes;
|
|
97
|
+
this.modalRef.instance.visible = true;
|
|
98
|
+
this.detectChanges();
|
|
99
|
+
});
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
EntityChangeModalService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EntityChangeModalService, deps: [{ token: i1$1.AuditLogsService }, { token: i1.ContentProjectionService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
103
|
+
EntityChangeModalService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EntityChangeModalService, providedIn: 'root' });
|
|
104
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: EntityChangeModalService, decorators: [{
|
|
105
|
+
type: Injectable,
|
|
106
|
+
args: [{
|
|
107
|
+
providedIn: 'root',
|
|
108
|
+
}]
|
|
109
|
+
}], ctorParameters: function () { return [{ type: i1$1.AuditLogsService }, { type: i1.ContentProjectionService }]; } });
|
|
110
|
+
|
|
111
|
+
const ENTITY_DETAILS_PROVIDERS = [
|
|
112
|
+
{
|
|
113
|
+
provide: SHOW_ENTITY_DETAILS,
|
|
114
|
+
useFactory: bindShowDetails,
|
|
115
|
+
deps: [EntityChangeModalService],
|
|
116
|
+
},
|
|
117
|
+
];
|
|
118
|
+
function bindShowDetails(service) {
|
|
119
|
+
return service.showDetails.bind(service);
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
const ENTITY_HISTORY_PROVIDERS = [
|
|
123
|
+
{
|
|
124
|
+
provide: SHOW_ENTITY_HISTORY,
|
|
125
|
+
useFactory: bindShowHistory,
|
|
126
|
+
deps: [EntityChangeModalService],
|
|
127
|
+
},
|
|
128
|
+
];
|
|
129
|
+
function bindShowHistory(service) {
|
|
130
|
+
return service.showHistory.bind(service);
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
const AUDIT_LOGGING_ROUTE_PROVIDERS = [
|
|
134
|
+
{ provide: APP_INITIALIZER, useFactory: configureRoutes, deps: [RoutesService], multi: true },
|
|
135
|
+
];
|
|
136
|
+
function configureRoutes(routes) {
|
|
137
|
+
return () => {
|
|
138
|
+
routes.add([
|
|
139
|
+
{
|
|
140
|
+
name: "AbpAuditLogging::Menu:AuditLogging" /* AuditLogging */,
|
|
141
|
+
path: '/audit-logs',
|
|
142
|
+
parentName: "AbpUiNavigation::Menu:Administration" /* Administration */,
|
|
143
|
+
layout: "application" /* application */,
|
|
144
|
+
iconClass: 'fa fa-file-text',
|
|
145
|
+
order: 6,
|
|
146
|
+
requiredPolicy: "AuditLogging.AuditLogs" /* AuditLogging */,
|
|
147
|
+
},
|
|
148
|
+
]);
|
|
149
|
+
};
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
class AuditLoggingConfigModule {
|
|
153
|
+
static forRoot() {
|
|
154
|
+
return {
|
|
155
|
+
ngModule: AuditLoggingConfigModule,
|
|
156
|
+
providers: [
|
|
157
|
+
AUDIT_LOGGING_ROUTE_PROVIDERS,
|
|
158
|
+
ENTITY_DETAILS_PROVIDERS,
|
|
159
|
+
ENTITY_HISTORY_PROVIDERS,
|
|
160
|
+
AUDIT_LOGGING_FEATURES_PROVIDERS,
|
|
161
|
+
],
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
AuditLoggingConfigModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AuditLoggingConfigModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
166
|
+
AuditLoggingConfigModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AuditLoggingConfigModule, declarations: [EntityChangeDetailsComponent, EntityChangeModalComponent], imports: [CoreModule, ThemeSharedModule], exports: [EntityChangeDetailsComponent, EntityChangeModalComponent] });
|
|
167
|
+
AuditLoggingConfigModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AuditLoggingConfigModule, imports: [[CoreModule, ThemeSharedModule]] });
|
|
168
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AuditLoggingConfigModule, decorators: [{
|
|
169
|
+
type: NgModule,
|
|
170
|
+
args: [{
|
|
171
|
+
declarations: [EntityChangeDetailsComponent, EntityChangeModalComponent],
|
|
172
|
+
exports: [EntityChangeDetailsComponent, EntityChangeModalComponent],
|
|
173
|
+
imports: [CoreModule, ThemeSharedModule],
|
|
174
|
+
}]
|
|
175
|
+
}] });
|
|
176
|
+
|
|
177
|
+
/**
|
|
178
|
+
* Generated bundle index. Do not edit.
|
|
179
|
+
*/
|
|
180
|
+
|
|
181
|
+
export { AUDIT_LOGGING_ROUTE_PROVIDERS, AuditLoggingConfigModule, ENTITY_DETAILS_PROVIDERS, ENTITY_HISTORY_PROVIDERS, EntityChangeDetailsComponent, EntityChangeModalComponent, EntityChangeModalService, bindShowDetails, bindShowHistory, configureRoutes };
|
|
182
|
+
//# sourceMappingURL=volo-abp.ng.audit-logging-config.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"volo-abp.ng.audit-logging-config.mjs","sources":["../../../../packages/audit-logging/config/src/components/entity-change-details.component.ts","../../../../packages/audit-logging/config/src/components/entity-change-details.component.html","../../../../packages/audit-logging/config/src/components/entity-change-modal.component.ts","../../../../packages/audit-logging/config/src/components/entity-change-modal.component.html","../../../../packages/audit-logging/config/src/services/entity-change-modal.service.ts","../../../../packages/audit-logging/config/src/providers/entity-details.provider.ts","../../../../packages/audit-logging/config/src/providers/entity-history.provider.ts","../../../../packages/audit-logging/config/src/providers/route.provider.ts","../../../../packages/audit-logging/config/src/audit-logging-config.module.ts","../../../../packages/audit-logging/config/src/volo-abp.ng.audit-logging-config.ts"],"sourcesContent":["import { TrackByService, uuid } from '@abp/ng.core';\r\nimport { collapse } from '@abp/ng.theme.shared';\r\nimport { Component, Input } from '@angular/core';\r\nimport {\r\n EntityChangeDto,\r\n EntityChangeType,\r\n EntityChangeWithUsernameDto,\r\n EntityPropertyChangeDto,\r\n} from '@volo/abp.ng.audit-logging/proxy';\r\n\r\n@Component({\r\n selector: 'abp-entity-change-details',\r\n templateUrl: './entity-change-details.component.html',\r\n animations: [collapse],\r\n})\r\nexport class EntityChangeDetailsComponent {\r\n @Input() set itemWithUserName(item: EntityChangeWithUsernameDto) {\r\n this.changeType = EntityChangeType[item.entityChange.changeType];\r\n this.color = this.colors[item.entityChange.changeType];\r\n this.userName = item.userName;\r\n this.entityChange = item.entityChange;\r\n }\r\n\r\n @Input() isCollapsed = false;\r\n\r\n entityChange: EntityChangeDto;\r\n\r\n userName: string;\r\n\r\n changeType: string;\r\n\r\n color: 'success' | 'info' | 'danger';\r\n\r\n private colors = {\r\n [EntityChangeType.Created]: 'success',\r\n [EntityChangeType.Updated]: 'info',\r\n [EntityChangeType.Deleted]: 'danger',\r\n } as const;\r\n\r\n uuid = uuid();\r\n\r\n constructor(public readonly track: TrackByService<EntityPropertyChangeDto>) {}\r\n\r\n getPropColor(propertyChange: EntityPropertyChangeDto): 'red' | undefined {\r\n return this.entityChange.changeType === EntityChangeType.Updated &&\r\n propertyChange.newValue !== propertyChange.originalValue\r\n ? 'red'\r\n : undefined;\r\n }\r\n\r\n getInterpolationParams(changeTime: string): string[] {\r\n return [this.changeType, changeTime, this.userName];\r\n }\r\n}\r\n","<div\r\n class=\"mb-3 border border-dark rounded\"\r\n *ngIf=\"getInterpolationParams(entityChange.changeTime | date: 'medium') as params\"\r\n>\r\n <div class=\"d-grid\">\r\n <button\r\n type=\"button\"\r\n class=\"btn btn-{{ color }}\"\r\n (click)=\"isCollapsed = !isCollapsed\"\r\n [attr.aria-expanded]=\"!isCollapsed\"\r\n [attr.aria-controls]=\"uuid\"\r\n >\r\n {{ 'AbpAuditLogging::DaysAgoWithUserTitle' | abpLocalization: params }}\r\n </button>\r\n </div>\r\n <div [id]=\"uuid\" [@collapse]=\"isCollapsed ? 'collapsed' : 'expanded'\">\r\n <div class=\"m-3\">\r\n <table class=\"table table-striped\">\r\n <thead>\r\n <tr>\r\n <th>{{ 'AbpAuditLogging::PropertyName' | abpLocalization }}</th>\r\n <th>{{ 'AbpAuditLogging::OriginalValue' | abpLocalization }}</th>\r\n <th>{{ 'AbpAuditLogging::NewValue' | abpLocalization }}</th>\r\n </tr>\r\n </thead>\r\n <tbody>\r\n <tr *ngFor=\"let prop of entityChange.propertyChanges; trackBy: track.by('id')\">\r\n <td>{{ prop.propertyName }}</td>\r\n <td>{{ prop.originalValue }}</td>\r\n <td [style.color]=\"getPropColor(prop)\">{{ prop.newValue }}</td>\r\n </tr>\r\n </tbody>\r\n </table>\r\n </div>\r\n </div>\r\n</div>\r\n","import { TrackByService } from '@abp/ng.core';\r\nimport { ChangeDetectionStrategy, ChangeDetectorRef, Component } from '@angular/core';\r\nimport { EntityChangeWithUsernameDto } from '@volo/abp.ng.audit-logging/proxy';\r\n\r\n@Component({\r\n selector: 'abp-entity-change-modal',\r\n templateUrl: './entity-change-modal.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n})\r\nexport class EntityChangeModalComponent {\r\n history: EntityChangeWithUsernameDto[] = [];\r\n\r\n entityId: string;\r\n\r\n entityTypeFullName: string;\r\n\r\n visible = false;\r\n\r\n constructor(public readonly cdRef: ChangeDetectorRef, public readonly track: TrackByService) {}\r\n}\r\n","<abp-modal [(visible)]=\"visible\" [options]=\"{ size: 'lg' }\">\r\n <ng-template #abpHeader>\r\n <h5 class=\"modal-title\">\r\n {{ entityTypeFullName }}\r\n <br />\r\n <span style=\"font-size: small\">({{ entityId }})</span>\r\n </h5>\r\n </ng-template>\r\n <ng-template #abpBody>\r\n <ng-container *ngIf=\"history.length; else noChanges\">\r\n <abp-entity-change-details\r\n *ngFor=\"let change of history; first as f; trackBy: track.byDeep('entityChange', 'id')\"\r\n [itemWithUserName]=\"change\"\r\n [isCollapsed]=\"!f\"\r\n ></abp-entity-change-details>\r\n </ng-container>\r\n\r\n <ng-template #noChanges\r\n ><div class=\"text-center\">\r\n {{ 'AbpAuditLogging::NoChanges' | abpLocalization }}\r\n </div></ng-template\r\n >\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","import { ContentProjectionService, PROJECTION_STRATEGY } from '@abp/ng.core';\r\nimport { ComponentRef, Injectable } from '@angular/core';\r\nimport { AuditLogsService } from '@volo/abp.ng.audit-logging/proxy';\r\nimport { EntityChangeModalComponent } from '../components/entity-change-modal.component';\r\n\r\n@Injectable({\r\n providedIn: 'root',\r\n})\r\nexport class EntityChangeModalService {\r\n private modalRef: ComponentRef<EntityChangeModalComponent>;\r\n\r\n constructor(\r\n private auditLogsService: AuditLogsService,\r\n private contentProjectionService: ContentProjectionService,\r\n ) {\r\n this.projectModal();\r\n }\r\n\r\n private projectModal() {\r\n this.modalRef = this.contentProjectionService.projectContent(\r\n PROJECTION_STRATEGY.AppendComponentToBody(EntityChangeModalComponent),\r\n );\r\n\r\n this.modalRef.changeDetectorRef.detectChanges();\r\n }\r\n\r\n detectChanges() {\r\n this.modalRef.changeDetectorRef.detectChanges();\r\n this.modalRef.instance.cdRef.detectChanges();\r\n }\r\n\r\n showDetails(entityChangeId: string) {\r\n this.auditLogsService.getEntityChangeWithUsername(entityChangeId).subscribe(change => {\r\n this.modalRef.instance.entityId = change.entityChange.entityId;\r\n this.modalRef.instance.entityTypeFullName = change.entityChange.entityTypeFullName;\r\n this.modalRef.instance.history = [change].filter(Boolean);\r\n this.modalRef.instance.visible = true;\r\n this.detectChanges();\r\n });\r\n }\r\n\r\n showHistory(entityId: string, entityTypeFullName: string) {\r\n this.auditLogsService\r\n .getEntityChangesWithUsername({ entityId, entityTypeFullName })\r\n .subscribe(changes => {\r\n this.modalRef.instance.entityId = entityId;\r\n this.modalRef.instance.entityTypeFullName = entityTypeFullName;\r\n this.modalRef.instance.history = changes;\r\n this.modalRef.instance.visible = true;\r\n this.detectChanges();\r\n });\r\n }\r\n}\r\n","import { SHOW_ENTITY_DETAILS } from '@volo/abp.ng.audit-logging';\r\nimport { EntityChangeModalService } from '../services/entity-change-modal.service';\r\n\r\nexport const ENTITY_DETAILS_PROVIDERS = [\r\n {\r\n provide: SHOW_ENTITY_DETAILS,\r\n useFactory: bindShowDetails,\r\n deps: [EntityChangeModalService],\r\n },\r\n];\r\n\r\nexport function bindShowDetails(service: EntityChangeModalService) {\r\n return service.showDetails.bind(service);\r\n}\r\n","import { SHOW_ENTITY_HISTORY } from '@volo/abp.commercial.ng.ui';\r\nimport { EntityChangeModalService } from '../services/entity-change-modal.service';\r\n\r\nexport const ENTITY_HISTORY_PROVIDERS = [\r\n {\r\n provide: SHOW_ENTITY_HISTORY,\r\n useFactory: bindShowHistory,\r\n deps: [EntityChangeModalService],\r\n },\r\n];\r\n\r\nexport function bindShowHistory(service: EntityChangeModalService) {\r\n return service.showHistory.bind(service);\r\n}\r\n","import { eLayoutType, RoutesService } from '@abp/ng.core';\r\nimport { eThemeSharedRouteNames } from '@abp/ng.theme.shared';\r\nimport { APP_INITIALIZER } from '@angular/core';\r\nimport { eAuditLoggingPolicyNames } from '../enums/policy-names';\r\nimport { eAuditLoggingRouteNames } from '../enums/route-names';\r\n\r\nexport const AUDIT_LOGGING_ROUTE_PROVIDERS = [\r\n { provide: APP_INITIALIZER, useFactory: configureRoutes, deps: [RoutesService], multi: true },\r\n];\r\n\r\nexport function configureRoutes(routes: RoutesService) {\r\n return () => {\r\n routes.add([\r\n {\r\n name: eAuditLoggingRouteNames.AuditLogging,\r\n path: '/audit-logs',\r\n parentName: eThemeSharedRouteNames.Administration,\r\n layout: eLayoutType.application,\r\n iconClass: 'fa fa-file-text',\r\n order: 6,\r\n requiredPolicy: eAuditLoggingPolicyNames.AuditLogging,\r\n },\r\n ]);\r\n };\r\n}\r\n","import { CoreModule } from '@abp/ng.core';\r\nimport { ThemeSharedModule } from '@abp/ng.theme.shared';\r\nimport { ModuleWithProviders, NgModule } from '@angular/core';\r\nimport { EntityChangeDetailsComponent } from './components/entity-change-details.component';\r\nimport { EntityChangeModalComponent } from './components/entity-change-modal.component';\r\nimport { ENTITY_DETAILS_PROVIDERS, ENTITY_HISTORY_PROVIDERS } from './providers';\r\nimport { AUDIT_LOGGING_ROUTE_PROVIDERS } from './providers/route.provider';\r\nimport { AUDIT_LOGGING_FEATURES_PROVIDERS } from '@volo/abp.ng.audit-logging/common';\r\n\r\n@NgModule({\r\n declarations: [EntityChangeDetailsComponent, EntityChangeModalComponent],\r\n exports: [EntityChangeDetailsComponent, EntityChangeModalComponent],\r\n imports: [CoreModule, ThemeSharedModule],\r\n})\r\nexport class AuditLoggingConfigModule {\r\n static forRoot(): ModuleWithProviders<AuditLoggingConfigModule> {\r\n return {\r\n ngModule: AuditLoggingConfigModule,\r\n providers: [\r\n AUDIT_LOGGING_ROUTE_PROVIDERS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C;KACjC;EACD;SAEc,eAAe,CAAC,OAAiC;IAC/D,OAAO,OAAO,CAAC,WAAW,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;AAC3C;;MCPa,6BAA6B,GAAG;IAC3C,EAAE,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,eAAe,EAAE,IAAI,EAAE,CAAC,aAAa,CAAC,EAAE,KAAK,EAAE,IAAI,EAAE;EAC7F;SAEc,eAAe,CAAC,MAAqB;IACnD,OAAO;QACL,MAAM,CAAC,GAAG,CAAC;YACT;gBACE,IAAI;gBACJ,IAAI,EAAE,aAAa;gBACnB,UAAU;gBACV,MAAM;gBACN,SAAS,EAAE,iBAAiB;gBAC5B,KAAK,EAAE,CAAC;gBACR,cAAc;aACf;SACF,CAAC,CAAC;KACJ,CAAC;AACJ;;MCVa,wBAAwB;IACnC,OAAO,OAAO;QACZ,OAAO;YACL,QAAQ,EAAE,wBAAwB;YAClC,SAAS,EAAE;gBACT,6BAA6B;gBAC7B,wBAAwB;gBACxB,wBAAwB;gBACxB,gCAAgC;aACjC;SACF,CAAC;KACH;;qHAXU,wBAAwB;sHAAxB,wBAAwB,iBAJpB,4BAA4B,EAAE,0BAA0B,aAE7D,UAAU,EAAE,iBAAiB,aAD7B,4BAA4B,EAAE,0BAA0B;sHAGvD,wBAAwB,YAF1B,CAAC,UAAU,EAAE,iBAAiB,CAAC;2FAE7B,wBAAwB;kBALpC,QAAQ;mBAAC;oBACR,YAAY,EAAE,CAAC,4BAA4B,EAAE,0BAA0B,CAAC;oBACxE,OAAO,EAAE,CAAC,4BAA4B,EAAE,0BAA0B,CAAC;oBACnE,OAAO,EAAE,CAAC,UAAU,EAAE,iBAAiB,CAAC;iBACzC;;;ACbD;;;;;;"}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import * as i1 from '@abp/ng.core';
|
|
2
|
+
import { mapEnumToOptions } from '@abp/ng.core';
|
|
3
|
+
import * as i0 from '@angular/core';
|
|
4
|
+
import { Injectable } from '@angular/core';
|
|
5
|
+
|
|
6
|
+
class AuditLogsService {
|
|
7
|
+
constructor(restService) {
|
|
8
|
+
this.restService = restService;
|
|
9
|
+
this.apiName = 'AbpAuditLogging';
|
|
10
|
+
this.get = (id) => this.restService.request({
|
|
11
|
+
method: 'GET',
|
|
12
|
+
url: `/api/audit-logging/audit-logs/${id}`,
|
|
13
|
+
}, { apiName: this.apiName });
|
|
14
|
+
this.getAverageExecutionDurationPerDay = (filter) => this.restService.request({
|
|
15
|
+
method: 'GET',
|
|
16
|
+
url: '/api/audit-logging/audit-logs/statistics/average-execution-duration-per-day',
|
|
17
|
+
params: { startDate: filter.startDate, endDate: filter.endDate },
|
|
18
|
+
}, { apiName: this.apiName });
|
|
19
|
+
this.getEntityChange = (entityChangeId) => this.restService.request({
|
|
20
|
+
method: 'GET',
|
|
21
|
+
url: `/api/audit-logging/audit-logs/entity-changes/${entityChangeId}`,
|
|
22
|
+
}, { apiName: this.apiName });
|
|
23
|
+
this.getEntityChangeWithUsername = (entityChangeId) => this.restService.request({
|
|
24
|
+
method: 'GET',
|
|
25
|
+
url: `/api/audit-logging/audit-logs/entity-change-with-username/${entityChangeId}`,
|
|
26
|
+
}, { apiName: this.apiName });
|
|
27
|
+
this.getEntityChanges = (input) => this.restService.request({
|
|
28
|
+
method: 'GET',
|
|
29
|
+
url: '/api/audit-logging/audit-logs/entity-changes',
|
|
30
|
+
params: { auditLogId: input.auditLogId, entityChangeType: input.entityChangeType, entityId: input.entityId, entityTypeFullName: input.entityTypeFullName, startDate: input.startDate, endDate: input.endDate, sorting: input.sorting, skipCount: input.skipCount, maxResultCount: input.maxResultCount },
|
|
31
|
+
}, { apiName: this.apiName });
|
|
32
|
+
this.getEntityChangesWithUsername = (input) => this.restService.request({
|
|
33
|
+
method: 'GET',
|
|
34
|
+
url: '/api/audit-logging/audit-logs/entity-changes-with-username',
|
|
35
|
+
params: { entityId: input.entityId, entityTypeFullName: input.entityTypeFullName },
|
|
36
|
+
}, { apiName: this.apiName });
|
|
37
|
+
this.getErrorRate = (filter) => this.restService.request({
|
|
38
|
+
method: 'GET',
|
|
39
|
+
url: '/api/audit-logging/audit-logs/statistics/error-rate',
|
|
40
|
+
params: { startDate: filter.startDate, endDate: filter.endDate },
|
|
41
|
+
}, { apiName: this.apiName });
|
|
42
|
+
this.getList = (input) => this.restService.request({
|
|
43
|
+
method: 'GET',
|
|
44
|
+
url: '/api/audit-logging/audit-logs',
|
|
45
|
+
params: { startTime: input.startTime, endTime: input.endTime, url: input.url, userName: input.userName, applicationName: input.applicationName, clientIpAddress: input.clientIpAddress, correlationId: input.correlationId, httpMethod: input.httpMethod, httpStatusCode: input.httpStatusCode, maxExecutionDuration: input.maxExecutionDuration, minExecutionDuration: input.minExecutionDuration, hasException: input.hasException, sorting: input.sorting, skipCount: input.skipCount, maxResultCount: input.maxResultCount },
|
|
46
|
+
}, { apiName: this.apiName });
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
AuditLogsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AuditLogsService, deps: [{ token: i1.RestService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
50
|
+
AuditLogsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AuditLogsService, providedIn: 'root' });
|
|
51
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: AuditLogsService, decorators: [{
|
|
52
|
+
type: Injectable,
|
|
53
|
+
args: [{
|
|
54
|
+
providedIn: 'root',
|
|
55
|
+
}]
|
|
56
|
+
}], ctorParameters: function () { return [{ type: i1.RestService }]; } });
|
|
57
|
+
|
|
58
|
+
var EntityChangeType;
|
|
59
|
+
(function (EntityChangeType) {
|
|
60
|
+
EntityChangeType[EntityChangeType["Created"] = 0] = "Created";
|
|
61
|
+
EntityChangeType[EntityChangeType["Updated"] = 1] = "Updated";
|
|
62
|
+
EntityChangeType[EntityChangeType["Deleted"] = 2] = "Deleted";
|
|
63
|
+
})(EntityChangeType || (EntityChangeType = {}));
|
|
64
|
+
const entityChangeTypeOptions = mapEnumToOptions(EntityChangeType);
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Generated bundle index. Do not edit.
|
|
68
|
+
*/
|
|
69
|
+
|
|
70
|
+
export { AuditLogsService, EntityChangeType, entityChangeTypeOptions };
|
|
71
|
+
//# sourceMappingURL=volo-abp.ng.audit-logging-proxy.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"volo-abp.ng.audit-logging-proxy.mjs","sources":["../../../../packages/audit-logging/proxy/src/lib/proxy/audit-logging/audit-logs.service.ts","../../../../packages/audit-logging/proxy/src/lib/proxy/auditing/entity-change-type.enum.ts","../../../../packages/audit-logging/proxy/src/volo-abp.ng.audit-logging-proxy.ts"],"sourcesContent":["import type { AuditLogDto, EntityChangeDto, EntityChangeFilter, EntityChangeWithUsernameDto, GetAuditLogListDto, GetAverageExecutionDurationPerDayInput, GetAverageExecutionDurationPerDayOutput, GetEntityChangesDto, GetErrorRateFilter, GetErrorRateOutput } from './models';\r\nimport { RestService } from '@abp/ng.core';\r\nimport type { PagedResultDto } from '@abp/ng.core';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable({\r\n providedIn: 'root',\r\n})\r\nexport class AuditLogsService {\r\n apiName = 'AbpAuditLogging';\r\n\r\n get = (id: string) =>\r\n this.restService.request<any, AuditLogDto>({\r\n method: 'GET',\r\n url: `/api/audit-logging/audit-logs/${id}`,\r\n },\r\n { apiName: this.apiName });\r\n\r\n getAverageExecutionDurationPerDay = (filter: GetAverageExecutionDurationPerDayInput) =>\r\n this.restService.request<any, GetAverageExecutionDurationPerDayOutput>({\r\n method: 'GET',\r\n url: '/api/audit-logging/audit-logs/statistics/average-execution-duration-per-day',\r\n params: { startDate: filter.startDate, endDate: filter.endDate },\r\n },\r\n { apiName: this.apiName });\r\n\r\n getEntityChange = (entityChangeId: string) =>\r\n this.restService.request<any, EntityChangeDto>({\r\n method: 'GET',\r\n url: `/api/audit-logging/audit-logs/entity-changes/${entityChangeId}`,\r\n },\r\n { apiName: this.apiName });\r\n\r\n getEntityChangeWithUsername = (entityChangeId: string) =>\r\n this.restService.request<any, EntityChangeWithUsernameDto>({\r\n method: 'GET',\r\n url: `/api/audit-logging/audit-logs/entity-change-with-username/${entityChangeId}`,\r\n },\r\n { apiName: this.apiName });\r\n\r\n getEntityChanges = (input: GetEntityChangesDto) =>\r\n this.restService.request<any, PagedResultDto<EntityChangeDto>>({\r\n method: 'GET',\r\n url: '/api/audit-logging/audit-logs/entity-changes',\r\n params: { auditLogId: input.auditLogId, entityChangeType: input.entityChangeType, entityId: input.entityId, entityTypeFullName: input.entityTypeFullName, startDate: input.startDate, endDate: input.endDate, sorting: input.sorting, skipCount: input.skipCount, maxResultCount: input.maxResultCount },\r\n },\r\n { apiName: this.apiName });\r\n\r\n getEntityChangesWithUsername = (input: EntityChangeFilter) =>\r\n this.restService.request<any, EntityChangeWithUsernameDto[]>({\r\n method: 'GET',\r\n url: '/api/audit-logging/audit-logs/entity-changes-with-username',\r\n params: { entityId: input.entityId, entityTypeFullName: input.entityTypeFullName },\r\n },\r\n { apiName: this.apiName });\r\n\r\n getErrorRate = (filter: GetErrorRateFilter) =>\r\n this.restService.request<any, GetErrorRateOutput>({\r\n method: 'GET',\r\n url: '/api/audit-logging/audit-logs/statistics/error-rate',\r\n params: { startDate: filter.startDate, endDate: filter.endDate },\r\n },\r\n { apiName: this.apiName });\r\n\r\n getList = (input: GetAuditLogListDto) =>\r\n this.restService.request<any, PagedResultDto<AuditLogDto>>({\r\n method: 'GET',\r\n url: '/api/audit-logging/audit-logs',\r\n params: { startTime: input.startTime, endTime: input.endTime, url: input.url, userName: input.userName, applicationName: input.applicationName, clientIpAddress: input.clientIpAddress, correlationId: input.correlationId, httpMethod: input.httpMethod, httpStatusCode: input.httpStatusCode, maxExecutionDuration: input.maxExecutionDuration, minExecutionDuration: input.minExecutionDuration, hasException: input.hasException, sorting: input.sorting, skipCount: input.skipCount, maxResultCount: input.maxResultCount },\r\n },\r\n { apiName: this.apiName });\r\n\r\n constructor(private restService: RestService) {}\r\n}\r\n","import { mapEnumToOptions } from '@abp/ng.core';\r\n\r\nexport enum EntityChangeType {\r\n Created = 0,\r\n Updated = 1,\r\n Deleted = 2,\r\n}\r\n\r\nexport const entityChangeTypeOptions = mapEnumToOptions(EntityChangeType);\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;MAQa,gBAAgB;IAgE3B,YAAoB,WAAwB;QAAxB,gBAAW,GAAX,WAAW,CAAa;QA/D5C,YAAO,GAAG,iBAAiB,CAAC;QAE5B,QAAG,GAAG,CAAC,EAAU,KACf,IAAI,CAAC,WAAW,CAAC,OAAO,CAAmB;YACzC,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,iCAAiC,EAAE,EAAE;SAC3C,EACD,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC;QAE7B,sCAAiC,GAAG,CAAC,MAA8C,KACjF,IAAI,CAAC,WAAW,CAAC,OAAO,CAA+C;YACrE,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,6EAA6E;YAClF,MAAM,EAAE,EAAE,SAAS,EAAE,MAAM,CAAC,SAAS,EAAE,OAAO,EAAE,MAAM,CAAC,OAAO,EAAE;SACjE,EACD,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC;QAE7B,oBAAe,GAAG,CAAC,cAAsB,KACvC,IAAI,CAAC,WAAW,CAAC,OAAO,CAAuB;YAC7C,MAAM,EAAE,KAAK;YACb,GAAG,EAAE,gDAAgD,cAAc,EAAE;SACtE,EACD,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,CAAC,CAAC;QAE7B,gCAA2B,GAAG,CAAC,cAAsB,KACnD,IAAI,CA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