PcoServicesPerson constructor

PcoServicesPerson({
  1. String? id,
  2. String? photoUrl,
  3. String? photoThumbnailUrl,
  4. String? preferredApp,
  5. bool? isAssignedToRehearsalTeam,
  6. DateTime? archivedAt,
  7. DateTime? createdAt,
  8. String? firstName,
  9. String? lastName,
  10. String? namePrefix,
  11. String? nameSuffix,
  12. DateTime? updatedAt,
  13. String? facebookId,
  14. String? legacyId,
  15. String? fullName,
  16. String? maxPermissions,
  17. String? permissions,
  18. String? status,
  19. DateTime? anniversary,
  20. DateTime? birthdate,
  21. String? givenName,
  22. String? middleName,
  23. String? nickname,
  24. bool? isAccessMediaAttachments,
  25. bool? isAccessPlanAttachments,
  26. bool? isAccessSongAttachments,
  27. bool? isArchived,
  28. bool? isSiteAdministrator,
  29. DateTime? loggedInAt,
  30. String? notes,
  31. bool? isPassedBackgroundCheck,
  32. String? icalCode,
  33. int? preferredMaxPlansPerDay,
  34. int? preferredMaxPlansPerMonth,
  35. bool? isPraiseChartsEnabled,
  36. String? meTab,
  37. String? plansTab,
  38. String? songsTab,
  39. String? mediaTab,
  40. String? peopleTab,
  41. bool? isCanEditAllPeople,
  42. bool? isCanViewAllPeople,
  43. List? onboardings,
  44. String? currentFolderId,
  45. Map<String, List<PcoResource>>? withRelationships,
  46. List<PcoResource>? withIncluded,
})

Create a new PcoServicesPerson object. This object cannot be created with the API

NOTES:

  • Creating an instance of a class this way does not save it on the server.
  • This object cannot be saved directly to the server.
  • Only set the id field if you know what you are doing. Save operations will overwrite data when the id is set.
  • Dummy data can be supplied for a required parameter, but if so, .save() should not be called on the object
  • FIELDS USED WHEN CREATING: none
  • FIELDS USED WHEN UPDATING: preferredApp, onboardings, isAccessMediaAttachments, isAccessPlanAttachments, isAccessSongAttachments, currentFolderId, permissions

Implementation

factory PcoServicesPerson(
    {String? id,
    String? photoUrl,
    String? photoThumbnailUrl,
    String? preferredApp,
    bool? isAssignedToRehearsalTeam,
    DateTime? archivedAt,
    DateTime? createdAt,
    String? firstName,
    String? lastName,
    String? namePrefix,
    String? nameSuffix,
    DateTime? updatedAt,
    String? facebookId,
    String? legacyId,
    String? fullName,
    String? maxPermissions,
    String? permissions,
    String? status,
    DateTime? anniversary,
    DateTime? birthdate,
    String? givenName,
    String? middleName,
    String? nickname,
    bool? isAccessMediaAttachments,
    bool? isAccessPlanAttachments,
    bool? isAccessSongAttachments,
    bool? isArchived,
    bool? isSiteAdministrator,
    DateTime? loggedInAt,
    String? notes,
    bool? isPassedBackgroundCheck,
    String? icalCode,
    int? preferredMaxPlansPerDay,
    int? preferredMaxPlansPerMonth,
    bool? isPraiseChartsEnabled,
    String? meTab,
    String? plansTab,
    String? songsTab,
    String? mediaTab,
    String? peopleTab,
    bool? isCanEditAllPeople,
    bool? isCanViewAllPeople,
    List? onboardings,
    String? currentFolderId,
    Map<String, List<PcoResource>>? withRelationships,
    List<PcoResource>? withIncluded}) {
  var obj = PcoServicesPerson.empty();
  obj._id = id;
  if (photoUrl != null) obj._attributes['photo_url'] = photoUrl;
  if (photoThumbnailUrl != null)
    obj._attributes['photo_thumbnail_url'] = photoThumbnailUrl;
  if (preferredApp != null) obj._attributes['preferred_app'] = preferredApp;
  if (isAssignedToRehearsalTeam != null)
    obj._attributes['assigned_to_rehearsal_team'] = isAssignedToRehearsalTeam;
  if (archivedAt != null)
    obj._attributes['archived_at'] = archivedAt.toIso8601String();
  if (createdAt != null)
    obj._attributes['created_at'] = createdAt.toIso8601String();
  if (firstName != null) obj._attributes['first_name'] = firstName;
  if (lastName != null) obj._attributes['last_name'] = lastName;
  if (namePrefix != null) obj._attributes['name_prefix'] = namePrefix;
  if (nameSuffix != null) obj._attributes['name_suffix'] = nameSuffix;
  if (updatedAt != null)
    obj._attributes['updated_at'] = updatedAt.toIso8601String();
  if (facebookId != null) obj._attributes['facebook_id'] = facebookId;
  if (legacyId != null) obj._attributes['legacy_id'] = legacyId;
  if (fullName != null) obj._attributes['full_name'] = fullName;
  if (maxPermissions != null)
    obj._attributes['max_permissions'] = maxPermissions;
  if (permissions != null) obj._attributes['permissions'] = permissions;
  if (status != null) obj._attributes['status'] = status;
  if (anniversary != null)
    obj._attributes['anniversary'] = anniversary.toIso8601String();
  if (birthdate != null)
    obj._attributes['birthdate'] = birthdate.toIso8601String();
  if (givenName != null) obj._attributes['given_name'] = givenName;
  if (middleName != null) obj._attributes['middle_name'] = middleName;
  if (nickname != null) obj._attributes['nickname'] = nickname;
  if (isAccessMediaAttachments != null)
    obj._attributes['access_media_attachments'] = isAccessMediaAttachments;
  if (isAccessPlanAttachments != null)
    obj._attributes['access_plan_attachments'] = isAccessPlanAttachments;
  if (isAccessSongAttachments != null)
    obj._attributes['access_song_attachments'] = isAccessSongAttachments;
  if (isArchived != null) obj._attributes['archived'] = isArchived;
  if (isSiteAdministrator != null)
    obj._attributes['site_administrator'] = isSiteAdministrator;
  if (loggedInAt != null)
    obj._attributes['logged_in_at'] = loggedInAt.toIso8601String();
  if (notes != null) obj._attributes['notes'] = notes;
  if (isPassedBackgroundCheck != null)
    obj._attributes['passed_background_check'] = isPassedBackgroundCheck;
  if (icalCode != null) obj._attributes['ical_code'] = icalCode;
  if (preferredMaxPlansPerDay != null)
    obj._attributes['preferred_max_plans_per_day'] = preferredMaxPlansPerDay;
  if (preferredMaxPlansPerMonth != null)
    obj._attributes['preferred_max_plans_per_month'] =
        preferredMaxPlansPerMonth;
  if (isPraiseChartsEnabled != null)
    obj._attributes['praise_charts_enabled'] = isPraiseChartsEnabled;
  if (meTab != null) obj._attributes['me_tab'] = meTab;
  if (plansTab != null) obj._attributes['plans_tab'] = plansTab;
  if (songsTab != null) obj._attributes['songs_tab'] = songsTab;
  if (mediaTab != null) obj._attributes['media_tab'] = mediaTab;
  if (peopleTab != null) obj._attributes['people_tab'] = peopleTab;
  if (isCanEditAllPeople != null)
    obj._attributes['can_edit_all_people'] = isCanEditAllPeople;
  if (isCanViewAllPeople != null)
    obj._attributes['can_view_all_people'] = isCanViewAllPeople;
  if (onboardings != null) obj._attributes['onboardings'] = onboardings;
  if (currentFolderId != null)
    obj._attributes['current_folder_id'] = currentFolderId;

  if (withRelationships != null) {
    for (var r in withRelationships.entries) {
      obj._relationships[r.key] = r.value;
    }
    obj._hasManualRelationships = true;
  }

  if (withIncluded != null) {
    obj._included.addAll(withIncluded);
    obj._hasManualIncluded = true;
  }

  return obj;
}