File

core/audit-log/audit-log.component.ts

Description

Audit log component allows to show audits list. Component fetches audit records for the source object given as input.

Example

Example :
 <c8y-audit-log [source]="sourceId"></c8y-audit-log>

Implements

OnInit

Metadata

Index

Properties
Methods
Inputs

Inputs

source
Type : string | number

The source ID for which audits will be shown in the list.

type
Type : AuditRecordType

The type of audit record to search for.

Methods

ngOnInit
ngOnInit()

After page view is initialized, component gets audit records from auditRecords endpoint.

Returns : void

Properties

records
Type : Promise<IResultList<IAuditRecord>>

Audit records retrieved from auditRecords endpoint.

<div class="inner-scroll">
  <ul class="c8y-list__group c8y-list--timeline m-t-16">
    <li
      class="c8y-list--timeline__item"
      *c8yFor="let record of records | async"
    >
      <small class="c8y-list--timeline__item__date">
        {{ record.time | c8yDate }}
      </small>
      <div class="c8y-list__item">
        <div class="c8y-list__item__block">
          <div class="c8y-list__item__body text-truncate-wrap">
            <div class="row">
              <div class="col-md-5 d-flex a-i-baseline">
                <span
                  class="text-truncate"
                  title="{{ record.activity | translate }}"
                >
                  {{ record.activity | translate }}
                </span>
                <small class="m-l-4 text-muted flex-no-shrink">{{ record.user }}</small>
              </div>
              <div class="col-md-7">
                <div class="small text-truncate-wrap">{{ record.text | translate }}</div>
              </div>
            </div>
          </div>
        </div>
      </div>
    </li>
  </ul>
</div>

results matching ""

    No results matching ""