@ironcode/vas-lib 0.0.22 → 0.0.24

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.
@@ -80,7 +80,7 @@ class VasFireUserModel extends VasUserModel {
80
80
  this.accounts = accounts;
81
81
  }
82
82
  static fromDto(dto) {
83
- return new VasFireUserModel(dto.id, dto.created, dto.serverCreated, dto.createdBy, dto.modified, dto.serverModified, dto.modifiedBy, dto.email, dto.username, dto.accounts);
83
+ return new VasFireUserModel(dto.id || '', dto.created || '', dto.serverCreated || '', dto.createdBy || '', dto.modified || '', dto.serverModified || '', dto.modifiedBy || '', dto.email || '', dto.username || '', dto.accounts || {});
84
84
  }
85
85
  static newUser(uid, displayName, email) {
86
86
  return new VasFireUserModel(uid, moment().toISOString(), uid, moment().toISOString(), uid, moment().toISOString(), moment().toISOString(), email, displayName, {});
@@ -978,6 +978,37 @@ class VasFormModel extends VasRestrictedAccountObjectModel {
978
978
  }
979
979
  }
980
980
 
981
+ class VasInvitationModel extends VasAccountObjectModel {
982
+ constructor(id, created, serverCreated, createdBy, modified, serverModified, modifiedBy, account, secret) {
983
+ super(id, created, serverCreated, createdBy, modified, serverModified, modifiedBy, account);
984
+ this.id = id;
985
+ this.created = created;
986
+ this.serverCreated = serverCreated;
987
+ this.createdBy = createdBy;
988
+ this.modified = modified;
989
+ this.serverModified = serverModified;
990
+ this.modifiedBy = modifiedBy;
991
+ this.account = account;
992
+ this.secret = secret;
993
+ }
994
+ toDto() {
995
+ return {
996
+ id: this.id,
997
+ created: this.created,
998
+ serverCreated: this.serverCreated,
999
+ createdBy: this.createdBy,
1000
+ modified: this.modified,
1001
+ serverModified: this.serverModified,
1002
+ modifiedBy: this.modifiedBy,
1003
+ account: this.account,
1004
+ secret: this.secret,
1005
+ };
1006
+ }
1007
+ static fromDto(dto) {
1008
+ return new VasInvitationModel(dto.id || '', dto.created || '', dto.serverCreated || '', dto.createdBy || '', dto.modified || '', dto.serverModified || '', dto.modifiedBy || '', dto.account || '', dto.secret || '');
1009
+ }
1010
+ }
1011
+
981
1012
  /**
982
1013
  * A non sophisticated way to get values from the job via paths. For example:
983
1014
  *
@@ -1663,5 +1694,5 @@ class VasReportRequestModel extends VasAccountObjectModel {
1663
1694
  * Generated bundle index. Do not edit.
1664
1695
  */
1665
1696
 
1666
- export { VasAccountObjectModel, VasBaseModel, VasBranchModel, VasContactModel, VasControlConfigDirection, VasControlModel, VasControlTypeModel, VasFieldModel, VasFileModel, VasFireUserModel, VasFormModel, VasGroupModel, VasJobDataModel, VasJobModel, VasMembershipModel, VasReportLayoutModel, VasReportModel, VasReportRequestModel, VasRestrictedAccountObjectModel, VasUserModel };
1697
+ export { VasAccountObjectModel, VasBaseModel, VasBranchModel, VasContactModel, VasControlConfigDirection, VasControlModel, VasControlTypeModel, VasFieldModel, VasFileModel, VasFireUserModel, VasFormModel, VasGroupModel, VasInvitationModel, VasJobDataModel, VasJobModel, VasMembershipModel, VasReportLayoutModel, VasReportModel, VasReportRequestModel, VasRestrictedAccountObjectModel, VasUserModel };
1667
1698
  //# sourceMappingURL=ironcode-vas-lib.mjs.map