@stevenkellner/team-conduct-api 1.0.16 → 1.0.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -9,6 +9,7 @@ export declare class Person implements Flattable<Person.Flatten> {
|
|
|
9
9
|
signInProperties: PersonSignInProperties | null;
|
|
10
10
|
constructor(id: Person.Id, properties: PersonPrivateProperties, fineIds?: Fine.Id[], signInProperties?: PersonSignInProperties | null);
|
|
11
11
|
get flatten(): Person.Flatten;
|
|
12
|
+
get name(): string;
|
|
12
13
|
}
|
|
13
14
|
export declare namespace Person {
|
|
14
15
|
type Id = Tagged<Guid, 'person'>;
|
package/lib/src/types/Person.js
CHANGED
|
@@ -24,6 +24,11 @@ class Person {
|
|
|
24
24
|
signInProperties: this.signInProperties?.flatten ?? null
|
|
25
25
|
};
|
|
26
26
|
}
|
|
27
|
+
get name() {
|
|
28
|
+
if (this.properties.lastName === null)
|
|
29
|
+
return this.properties.firstName;
|
|
30
|
+
return `${this.properties.firstName} ${this.properties.lastName}`;
|
|
31
|
+
}
|
|
27
32
|
}
|
|
28
33
|
exports.Person = Person;
|
|
29
34
|
(function (Person) {
|
package/package.json
CHANGED
package/src/types/Person.ts
CHANGED
|
@@ -20,6 +20,12 @@ export class Person implements Flattable<Person.Flatten> {
|
|
|
20
20
|
signInProperties: this.signInProperties?.flatten ?? null
|
|
21
21
|
};
|
|
22
22
|
}
|
|
23
|
+
|
|
24
|
+
public get name(): string {
|
|
25
|
+
if (this.properties.lastName === null)
|
|
26
|
+
return this.properties.firstName;
|
|
27
|
+
return `${this.properties.firstName} ${this.properties.lastName}`;
|
|
28
|
+
}
|
|
23
29
|
}
|
|
24
30
|
|
|
25
31
|
export namespace Person {
|