copyWith method
Creates a new instance of the ClockBodyModel
class by copying the existing instance and overriding certain attributes.
The copyWith method allows you to create a new ClockBodyModel
instance by
providing new values for specific attributes while keeping the rest unchanged.
Implementation
ClockBodyModel copyWith({
DateTime? date,
String? clock,
AttendanceType? type,
String? notes,
double? latitude,
double? longitude,
int? imageId,
String? address,
int? overtimeId,
List<int>? filesId,
WorkingFromType? workingFrom,
}) =>
ClockBodyModel(
date: date ?? this.date,
clock: clock ?? this.clock,
type: type ?? this.type,
notes: notes ?? this.notes,
latitude: latitude ?? this.latitude,
longitude: longitude ?? this.longitude,
imageId: imageId ?? this.imageId,
address: address ?? this.address,
overtimeId: overtimeId ?? this.overtimeId,
filesId: filesId ?? this.filesId,
workingFrom: workingFrom ?? this.workingFrom,
);