This commit is contained in:
Juan Felipe Duarte
2023-06-20 11:21:14 -05:00
parent 05fa9438a1
commit a190833b53
10 changed files with 279 additions and 136 deletions
+20 -9
View File
@@ -52,8 +52,13 @@ class _MyServicesScreenState extends State<MyServicesScreen> {
stream: FirebaseFirestore.instance
.collection('services')
.where('user_id', isEqualTo: uid)
.where('status',
whereIn: ['aprobado', 'denegado', 'iniciado', 'terminado'])
.where('status', whereIn: [
'aprobado',
'denegado',
'iniciado',
'terminado',
'pendiente'
])
.snapshots()
.asyncMap((snapshot) async {
try {
@@ -123,17 +128,23 @@ class _MyServicesScreenState extends State<MyServicesScreen> {
color: Colors.blue,
size: 40,
)
: event.status == 'terminado'
: event.status == 'pendiente'
? const Icon(
Icons.rocket_launch,
Icons.access_time_outlined,
color: Colors.blue,
size: 40,
)
: const Icon(
Icons.close,
color: Colors.red,
size: 40,
),
: event.status == 'terminado'
? const Icon(
Icons.rocket_launch,
color: Colors.blue,
size: 40,
)
: const Icon(
Icons.close,
color: Colors.red,
size: 40,
),
title: RichText(
text: TextSpan(
children: [