copyWith method
复制并修改
Implementation
UserBean copyWith({
int? id,
int? staffId,
int? fromUserId,
int? fromStaffId,
int? region,
int? rmId,
int? createTime,
int? updateTime,
int? status,
int? isActive,
int? cc,
String? mobile,
String? name,
String? password,
String? salt,
int? score,
String? label,
int? gender,
int? age,
}) {
return UserBean(
id: id ?? this.id,
staffId: staffId ?? this.staffId,
fromUserId: fromUserId ?? this.fromUserId,
fromStaffId: fromStaffId ?? this.fromStaffId,
region: region ?? this.region,
rmId: rmId ?? this.rmId,
createTime: createTime ?? this.createTime,
updateTime: updateTime ?? this.updateTime,
status: status ?? this.status,
isActive: isActive ?? this.isActive,
cc: cc ?? this.cc,
mobile: mobile ?? this.mobile,
name: name ?? this.name,
password: password ?? this.password,
salt: salt ?? this.salt,
score: score ?? this.score,
label: label ?? this.label,
gender: gender ?? this.gender,
age: age ?? this.age,
);
}