Resolve #571 by allowing to give an account a name/label

This commit is contained in:
the-djmaze
2022-11-08 17:40:12 +01:00
parent 2ee9d973e2
commit decbbd8817
13 changed files with 168 additions and 122 deletions

View File

@@ -7,11 +7,14 @@ export class AccountModel extends AbstractModel {
* @param {boolean=} canBeDelete = true
* @param {number=} count = 0
*/
constructor(email/*, count = 0*/, isAdditional = true) {
constructor(email, name/*, count = 0*/, isAdditional = true) {
super();
this.name = name;
this.email = email;
this.displayName = name ? name + ' <' + email + '>' : email;
addObservablesTo(this, {
// count: count || 0,
askDelete: false,