4/10/5
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import 'package:SEFER/controller/home/captin/home_captain_controller.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/widgets.dart';
|
||||
import 'package:get/get.dart';
|
||||
import 'package:SEFER/constant/box_name.dart';
|
||||
import 'package:SEFER/controller/firebase/firbase_messge.dart';
|
||||
@@ -63,6 +62,7 @@ class OrderRequestPage extends StatelessWidget {
|
||||
);
|
||||
// void addCustomStartIcon() async {
|
||||
// Create the marker with the resized image
|
||||
orderRequestController.calculateConsumptionFuel();
|
||||
|
||||
ImageConfiguration config = ImageConfiguration(
|
||||
size: const Size(25, 25), devicePixelRatio: Get.pixelRatio);
|
||||
@@ -79,13 +79,8 @@ class OrderRequestPage extends StatelessWidget {
|
||||
endIcon = value;
|
||||
});
|
||||
// }
|
||||
double mpg = 0;
|
||||
calculateConsumptionFuel() {
|
||||
mpg = Get.find<HomeCaptainController>().fuelPrice /
|
||||
12; //todo in register car add mpg in box
|
||||
}
|
||||
// orderRequestController.calculateConsumptionFuel();
|
||||
|
||||
calculateConsumptionFuel();
|
||||
return MyScafolld(
|
||||
title: 'Order Details'.tr,
|
||||
body: [
|
||||
@@ -284,11 +279,8 @@ class OrderRequestPage extends StatelessWidget {
|
||||
style: AppStyle.title,
|
||||
children: [
|
||||
TextSpan(
|
||||
text: ((Get.find<HomeCaptainController>()
|
||||
.fuelPrice /
|
||||
12) *
|
||||
double.parse(myList[5]))
|
||||
.toStringAsFixed(2),
|
||||
text:
|
||||
orderRequestController.mpg.toStringAsFixed(0),
|
||||
style: AppStyle.headTitle2),
|
||||
],
|
||||
),
|
||||
|
||||
@@ -65,6 +65,7 @@ class OrderSpeedRequest extends StatelessWidget {
|
||||
);
|
||||
// void addCustomStartIcon() async {
|
||||
// Create the marker with the resized image
|
||||
orderRequestController.calculateConsumptionFuel();
|
||||
|
||||
ImageConfiguration config = ImageConfiguration(
|
||||
size: const Size(25, 25), devicePixelRatio: Get.pixelRatio);
|
||||
@@ -292,11 +293,7 @@ class OrderSpeedRequest extends StatelessWidget {
|
||||
style: AppStyle.title,
|
||||
children: [
|
||||
TextSpan(
|
||||
text:
|
||||
((Get.find<HomeCaptainController>().fuelPrice /
|
||||
12) *
|
||||
double.parse(myList[5]))
|
||||
.toStringAsFixed(2),
|
||||
text: orderRequestController.mpg.toStringAsFixed(0),
|
||||
style: AppStyle.headTitle2),
|
||||
],
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user