scored true
This commit is contained in:
@@ -647,7 +647,8 @@ class _UserServiceScreenState extends State<UserServiceScreen> {
|
||||
// ],
|
||||
// );
|
||||
// }
|
||||
if (service.status == ServiceStatus.completed) {
|
||||
if (service.status == ServiceStatus.completed &&
|
||||
service.professionalScored == false) {
|
||||
return Stack(
|
||||
alignment: AlignmentDirectional.topCenter,
|
||||
clipBehavior: Clip.none,
|
||||
@@ -662,11 +663,11 @@ class _UserServiceScreenState extends State<UserServiceScreen> {
|
||||
'Completado',
|
||||
style: TextStyle(fontSize: 32, color: Colors.green),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
const Text(
|
||||
'Califica el servicio',
|
||||
style: TextStyle(fontSize: 28, color: Colors.green),
|
||||
style: TextStyle(fontSize: 20, color: Colors.green),
|
||||
),
|
||||
const SizedBox(height: 15),
|
||||
FilledButton(
|
||||
onPressed: () {
|
||||
Navigator.push(
|
||||
@@ -678,7 +679,64 @@ class _UserServiceScreenState extends State<UserServiceScreen> {
|
||||
),
|
||||
);
|
||||
},
|
||||
child: const Text('Calificar'),
|
||||
style: FilledButton.styleFrom(
|
||||
backgroundColor: Theme.of(context).colorScheme.primary,
|
||||
padding: const EdgeInsets.symmetric(vertical: 15),
|
||||
shape: RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(10),
|
||||
),
|
||||
),
|
||||
child: Container(
|
||||
alignment: Alignment.center,
|
||||
width: MediaQuery.of(context).size.width * 0.4,
|
||||
child: const Text(
|
||||
'Calificar',
|
||||
style: TextStyle(
|
||||
color: Colors.white,
|
||||
fontSize: 18,
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
Positioned(
|
||||
top: -40,
|
||||
child: Container(
|
||||
padding: const EdgeInsets.all(16),
|
||||
decoration: BoxDecoration(
|
||||
color: Colors.white,
|
||||
border: Border.all(color: Colors.green.shade50, width: 4),
|
||||
shape: BoxShape.circle,
|
||||
),
|
||||
child: const Icon(
|
||||
Icons.star,
|
||||
color: Colors.green,
|
||||
size: 48,
|
||||
),
|
||||
),
|
||||
)
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
if (service.status == ServiceStatus.completed &&
|
||||
service.professionalScored == true) {
|
||||
return Stack(
|
||||
alignment: AlignmentDirectional.topCenter,
|
||||
clipBehavior: Clip.none,
|
||||
children: [
|
||||
Card(
|
||||
color: Colors.green.shade50,
|
||||
child: const Padding(
|
||||
padding: EdgeInsets.fromLTRB(32, 56, 32, 32),
|
||||
child: Column(
|
||||
children: [
|
||||
Text(
|
||||
'Completado',
|
||||
style: TextStyle(fontSize: 32, color: Colors.green),
|
||||
),
|
||||
],
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user