copyWith method

PayrollItem copyWith({
  1. String? itemId,
  2. String? institutionId,
  3. String? institutionName,
  4. List<PayrollIncomeAccountData>? accounts,
  5. List<PayrollIncomeObject>? payrollIncome,
  6. PayrollItemStatus? status,
  7. DateTime? updatedAt,
})

Implementation

PayrollItem copyWith(
    {String? itemId,
    String? institutionId,
    String? institutionName,
    List<PayrollIncomeAccountData>? accounts,
    List<PayrollIncomeObject>? payrollIncome,
    PayrollItemStatus? status,
    DateTime? updatedAt}) {
  return PayrollItem(
      itemId: itemId ?? this.itemId,
      institutionId: institutionId ?? this.institutionId,
      institutionName: institutionName ?? this.institutionName,
      accounts: accounts ?? this.accounts,
      payrollIncome: payrollIncome ?? this.payrollIncome,
      status: status ?? this.status,
      updatedAt: updatedAt ?? this.updatedAt);
}