1
0
mirror of https://github.com/bitwarden/cli synced 2025-12-17 00:33:20 +00:00

refactor req/res models

This commit is contained in:
Kyle Spearrin
2018-05-15 12:18:47 -04:00
parent 1d3ed93bff
commit 07cc64c0b8
25 changed files with 363 additions and 229 deletions

View File

@@ -2,21 +2,15 @@ import { CipherView } from 'jslib/models/view/cipherView';
import { BaseResponse } from './baseResponse';
import { CipherType } from 'jslib/enums';
import { Cipher } from '../cipher';
export class CipherResponse extends BaseResponse {
export class CipherResponse extends Cipher implements BaseResponse {
object: string;
id: string;
organizationId: string;
type: CipherType;
name: string;
notes: string;
constructor(o: CipherView) {
super('item');
super(o);
this.object = 'item';
this.id = o.id;
this.organizationId = o.organizationId;
this.type = o.type;
this.name = o.name;
this.notes = o.notes;
}
}