of static method

Employee of({
  1. IReliveItContact? creator,
  2. required DateTime? dateCreated,
  3. ITaskFactForMModel? assistedTask,
  4. bool? isActive = false,
  5. required MKey? contactKey,
  6. required IEmployer? company,
  7. String? position,
  8. IPhoneWithExtension? workPhone,
  9. FlexiDate? startDate,
  10. FlexiDate? endDate,
})

Implementation

static Employee of({
  IReliveItContact? creator,
  required DateTime? dateCreated,
  ITaskFactForMModel? assistedTask,
  bool? isActive = false,
  required MKey? contactKey,
  required IEmployer? company,
  String? position,
  IPhoneWithExtension? workPhone,
  FlexiDate? startDate,
  FlexiDate? endDate
  }) {
  final self = Employee(<String, dynamic>{}, mtype: EmployeeRef, update: true);
  if (creator != null) self.creator = creator;
  if (dateCreated != null) self.dateCreated = dateCreated;
  if (assistedTask != null) self.assistedTask = assistedTask;
  if (isActive != null) self.isActive = isActive;
  if (contactKey != null) self.contactKey = contactKey;
  if (company != null) self.company = company;
  if (position != null) self.position = position;
  if (workPhone != null) self.workPhone = workPhone;
  if (startDate != null) self.startDate = startDate;
  if (endDate != null) self.endDate = endDate;
  return self;
}