add two decimal and add confirm dialog if press back button
This commit is contained in:
@@ -138,10 +138,12 @@ class _ShipmentRatesState extends State<ShipmentRates> {
|
||||
color: Colors.grey,
|
||||
),
|
||||
_row("Free delivery within Yangon \nfor shipments over",
|
||||
"${rate.freeDeliveryWeight}", "pounds"),
|
||||
_row("Delivery fees", "\$ ${rate.deliveryFee}",
|
||||
"below ${rate.freeDeliveryWeight} pounds"),
|
||||
_row("Volumetric Ratio", "${rate.volumetricRatio}",
|
||||
"${rate.freeDeliveryWeight.toStringAsFixed(2)}", "pounds"),
|
||||
_row("Delivery fees", "\$ ${rate.deliveryFee.toStringAsFixed(2)}",
|
||||
"below ${rate.freeDeliveryWeight.toStringAsFixed(2)} pounds"),
|
||||
_row(
|
||||
"Volumetric Ratio",
|
||||
"${rate.volumetricRatio.toStringAsFixed(2)}",
|
||||
"in3 per pound"),
|
||||
Divider(
|
||||
color: Colors.grey,
|
||||
@@ -179,7 +181,8 @@ class _ShipmentRatesState extends State<ShipmentRates> {
|
||||
List<Widget> getCargoWidget(List<CargoType> cargos) {
|
||||
return cargos.map((cargo) {
|
||||
return Container(
|
||||
child: _row(cargo.name, "\$ " + cargo.rate.toString(), 'per pound'),
|
||||
child: _row(
|
||||
cargo.name, "\$ " + cargo.rate.toStringAsFixed(2), 'per pound'),
|
||||
);
|
||||
}).toList();
|
||||
}
|
||||
@@ -187,7 +190,7 @@ class _ShipmentRatesState extends State<ShipmentRates> {
|
||||
List<Widget> getCustonWidget(List<CustomDuty> customs) {
|
||||
return customs.map((c) {
|
||||
return Container(
|
||||
child: _row(c.productType, "\$ " + c.fee.toString(), ''),
|
||||
child: _row(c.productType, "\$ " + c.fee.toStringAsFixed(2), ''),
|
||||
);
|
||||
}).toList();
|
||||
}
|
||||
@@ -197,7 +200,7 @@ class _ShipmentRatesState extends State<ShipmentRates> {
|
||||
return discounts.map((d) {
|
||||
return Container(
|
||||
child: _row("${d.weight.toStringAsFixed(2)} lb",
|
||||
"\$ " + d.discount.toString(), ''),
|
||||
"\$ " + d.discount.toStringAsFixed(2), ''),
|
||||
);
|
||||
}).toList();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user