mirror of
https://github.com/bitwarden/browser
synced 2025-12-16 08:13:42 +00:00
[SM-288] Rename requests and responses to follow naming convention (#3806)
This commit is contained in:
43
libs/common/src/models/response/event.response.ts
Normal file
43
libs/common/src/models/response/event.response.ts
Normal file
@@ -0,0 +1,43 @@
|
||||
import { DeviceType } from "../../enums/deviceType";
|
||||
import { EventType } from "../../enums/eventType";
|
||||
|
||||
import { BaseResponse } from "./base.response";
|
||||
|
||||
export class EventResponse extends BaseResponse {
|
||||
type: EventType;
|
||||
userId: string;
|
||||
organizationId: string;
|
||||
providerId: string;
|
||||
cipherId: string;
|
||||
collectionId: string;
|
||||
groupId: string;
|
||||
policyId: string;
|
||||
organizationUserId: string;
|
||||
providerUserId: string;
|
||||
providerOrganizationId: string;
|
||||
actingUserId: string;
|
||||
date: string;
|
||||
deviceType: DeviceType;
|
||||
ipAddress: string;
|
||||
installationId: string;
|
||||
|
||||
constructor(response: any) {
|
||||
super(response);
|
||||
this.type = this.getResponseProperty("Type");
|
||||
this.userId = this.getResponseProperty("UserId");
|
||||
this.organizationId = this.getResponseProperty("OrganizationId");
|
||||
this.providerId = this.getResponseProperty("ProviderId");
|
||||
this.cipherId = this.getResponseProperty("CipherId");
|
||||
this.collectionId = this.getResponseProperty("CollectionId");
|
||||
this.groupId = this.getResponseProperty("GroupId");
|
||||
this.policyId = this.getResponseProperty("PolicyId");
|
||||
this.organizationUserId = this.getResponseProperty("OrganizationUserId");
|
||||
this.providerUserId = this.getResponseProperty("ProviderUserId");
|
||||
this.providerOrganizationId = this.getResponseProperty("ProviderOrganizationId");
|
||||
this.actingUserId = this.getResponseProperty("ActingUserId");
|
||||
this.date = this.getResponseProperty("Date");
|
||||
this.deviceType = this.getResponseProperty("DeviceType");
|
||||
this.ipAddress = this.getResponseProperty("IpAddress");
|
||||
this.installationId = this.getResponseProperty("InstallationId");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user