Files
kent_logistics_app/lib/models/user_profile.dart
2025-12-03 11:57:05 +05:30

47 lines
1.2 KiB
Dart

class UserProfile {
final String customerId;
final String customerName;
final String companyName;
final String? designation;
final String email;
final String mobile;
final String? address;
final String? pincode;
final String? status;
final String? customerType;
final String? profileImage;
final String? date;
UserProfile({
required this.customerId,
required this.customerName,
required this.companyName,
this.designation,
required this.email,
required this.mobile,
this.address,
this.pincode,
this.status,
this.customerType,
this.profileImage,
required this.date,
});
factory UserProfile.fromJson(Map<String, dynamic> json) {
return UserProfile(
customerId: json['customer_id'],
customerName: json['customer_name'],
companyName: json['company_name'],
designation: json['designation'],
email: json['email'],
mobile: json['mobile'],
address: json['address'],
pincode: json['pincode'],
status: json['status'],
customerType: json['customer_type'],
profileImage: json['profile_image'],
date: json['date'], // nullable ok now
);
}
}