1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-19 01:33:33 +00:00

[SM-288] Rename models to follow naming convention (#3795)

This commit is contained in:
Oscar Hinton
2022-10-14 18:25:50 +02:00
committed by GitHub
parent 1fd8d316a1
commit e941f06bac
445 changed files with 939 additions and 938 deletions

View File

@@ -0,0 +1,31 @@
import { SecureNoteType } from "../../enums/secureNoteType";
import { SecureNote as SecureNoteDomain } from "../domain/secure-note";
import { SecureNoteView } from "../view/secure-note.view";
export class SecureNoteExport {
static template(): SecureNoteExport {
const req = new SecureNoteExport();
req.type = SecureNoteType.Generic;
return req;
}
static toView(req: SecureNoteExport, view = new SecureNoteView()) {
view.type = req.type;
return view;
}
static toDomain(req: SecureNoteExport, view = new SecureNoteDomain()) {
view.type = req.type;
return view;
}
type: SecureNoteType;
constructor(o?: SecureNoteView | SecureNoteDomain) {
if (o == null) {
return;
}
this.type = o.type;
}
}