getStatusInfo static method
Implementation
static Map<String, dynamic> getStatusInfo(int? status) {
switch (status) {
case 0:
return {
'backgroundColor': Colors.grey.shade300,
'text': 'Not Finished',
'textColor': Colors.grey.shade700,
};
case 1:
return {
'backgroundColor': Colors.green.shade100,
'text': 'Success',
'textColor': Colors.green.shade700,
};
case 2:
return {
'backgroundColor': Colors.red.shade100,
'text': 'Invalid',
'textColor': Colors.red.shade700,
};
default:
return {
'backgroundColor': Colors.grey.shade300,
'text': 'Unknown',
'textColor': Colors.grey.shade700,
};
}
}