Updated to angular 11
Now compiling with strict mode in typescript Need to error checking now
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
import { Section } from './section';
|
||||
|
||||
export class Device {
|
||||
id: string;
|
||||
id: string | undefined;
|
||||
name: string;
|
||||
enabled: boolean;
|
||||
section: Section;
|
||||
@ -10,6 +10,12 @@ export class Device {
|
||||
lastDate?: string;
|
||||
|
||||
public constructor(init?: Partial<Device>) {
|
||||
this.id = undefined;
|
||||
this.name = '';
|
||||
this.enabled = false;
|
||||
this.section = new Section();
|
||||
this.creationDate = '';
|
||||
this.lastUser = '';
|
||||
Object.assign(this, init);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user