update the app

This commit is contained in:
root
2026-05-25 15:56:00 -04:00
parent 277db06d26
commit 7ca43ba2f3
19 changed files with 1854 additions and 210 deletions
@@ -1,5 +1,3 @@
import 'dart:io';
import 'package:cached_network_image/cached_network_image.dart';
import 'package:flutter/material.dart';
import '../../../../core/models/marketplace.dart';
@@ -142,7 +140,7 @@ class MarketplaceVehicleCard extends StatelessWidget {
crossAxisAlignment: CrossAxisAlignment.end,
children: [
Text(
'\$${vehicle.dailyRate.toStringAsFixed(0)}',
'${vehicle.dailyRate.toStringAsFixed(0)} MAD',
style: const TextStyle(
fontSize: 22,
fontWeight: FontWeight.bold,
@@ -166,7 +164,7 @@ class MarketplaceVehicleCard extends StatelessWidget {
color: cs.onSurfaceVariant),
),
Text(
'\$${(totalCents / 100).toStringAsFixed(0)} total',
'${(totalCents / 100).toStringAsFixed(0)} MAD total',
style: TextStyle(
fontWeight: FontWeight.w700,
fontSize: 14,
@@ -211,15 +209,7 @@ class _VehicleImage extends StatelessWidget {
);
}
String _resolveUrl(String photo) {
if (!photo.startsWith('http')) {
return '${AppConstants.baseUrl.replaceAll('/api/v1', '')}$photo';
}
if (Platform.isAndroid) {
return photo.replaceFirst('localhost', '10.0.2.2');
}
return photo;
}
String _resolveUrl(String photo) => AppConstants.resolveMediaUrl(photo);
Widget _placeholder() => Container(
height: 180,