toCompanion method
Implementation
UsersCompanion toCompanion(bool nullToAbsent) {
return UsersCompanion(
id: Value(id),
fetchedAt: fetchedAt == null && nullToAbsent
? const Value.absent()
: Value(fetchedAt),
studentId: Value(studentId),
nameZh: Value(nameZh),
nameEn: nameEn == null && nullToAbsent
? const Value.absent()
: Value(nameEn),
dateOfBirth: dateOfBirth == null && nullToAbsent
? const Value.absent()
: Value(dateOfBirth),
programZh: programZh == null && nullToAbsent
? const Value.absent()
: Value(programZh),
programEn: programEn == null && nullToAbsent
? const Value.absent()
: Value(programEn),
departmentZh: departmentZh == null && nullToAbsent
? const Value.absent()
: Value(departmentZh),
departmentEn: departmentEn == null && nullToAbsent
? const Value.absent()
: Value(departmentEn),
avatarFilename: Value(avatarFilename),
email: Value(email),
passwordExpiresInDays: passwordExpiresInDays == null && nullToAbsent
? const Value.absent()
: Value(passwordExpiresInDays),
semestersFetchedAt: semestersFetchedAt == null && nullToAbsent
? const Value.absent()
: Value(semestersFetchedAt),
);
}