clean up localization
This commit is contained in:
@@ -6,6 +6,7 @@ import 'package:fcs/helpers/theme.dart';
|
||||
import 'package:fcs/localization/app_translations.dart';
|
||||
import 'package:fcs/pages/rates/model/shipment_rate_model.dart';
|
||||
import 'package:fcs/pages/widgets/bottom_up_page_route.dart';
|
||||
import 'package:fcs/pages/widgets/input_text.dart';
|
||||
import 'package:fcs/pages/widgets/my_data_table.dart';
|
||||
import 'package:fcs/pages/widgets/progress.dart';
|
||||
import 'package:font_awesome_flutter/font_awesome_flutter.dart';
|
||||
@@ -27,10 +28,16 @@ class ShipmentRatesEdit extends StatefulWidget {
|
||||
|
||||
class _ShipmentRatesEditState extends State<ShipmentRatesEdit> {
|
||||
bool _isLoading = false;
|
||||
TextEditingController _minWeight = new TextEditingController();
|
||||
TextEditingController _deliveryFee = new TextEditingController();
|
||||
TextEditingController _volumetricRatio = new TextEditingController();
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
_minWeight.text = "10";
|
||||
_deliveryFee.text = "5";
|
||||
_volumetricRatio.text = "166.36";
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -42,6 +49,19 @@ class _ShipmentRatesEditState extends State<ShipmentRatesEdit> {
|
||||
Widget build(BuildContext context) {
|
||||
var shipmentRateModel = Provider.of<ShipmentRateModel>(context);
|
||||
|
||||
final minWigBox = InputText(
|
||||
labelTextKey: 'rate.min_weight',
|
||||
iconData: FontAwesomeIcons.weightHanging,
|
||||
controller: _minWeight);
|
||||
final feeBox = InputText(
|
||||
labelTextKey: 'rate.delivery_fee',
|
||||
iconData: Icons.attach_money,
|
||||
controller: _deliveryFee);
|
||||
final ratioBox = InputText(
|
||||
labelTextKey: 'rate.volumetric_ratio',
|
||||
iconData: Icons.attach_money,
|
||||
controller: _volumetricRatio);
|
||||
|
||||
return LocalProgress(
|
||||
inAsyncCall: _isLoading,
|
||||
child: Scaffold(
|
||||
@@ -63,13 +83,16 @@ class _ShipmentRatesEditState extends State<ShipmentRatesEdit> {
|
||||
Expanded(
|
||||
child: ListView(
|
||||
children: <Widget>[
|
||||
fcsInput("Min Weight for Free delivery within Yangon",
|
||||
FontAwesomeIcons.weightHanging,
|
||||
value: "10"),
|
||||
fcsInput("Delivery fees", Icons.attach_money, value: "5"),
|
||||
SizedBox(height: 10),
|
||||
fcsInput("Volumetric Ratio", Icons.attach_money,
|
||||
value: "166.36"),
|
||||
minWigBox,
|
||||
feeBox,
|
||||
ratioBox,
|
||||
// fcsInput("Min Weight for Free delivery within Yangon",
|
||||
// FontAwesomeIcons.weightHanging,
|
||||
// value: "10"),
|
||||
// fcsInput("Delivery fees", Icons.attach_money, value: "5"),
|
||||
// SizedBox(height: 10),
|
||||
// fcsInput("Volumetric Ratio", Icons.attach_money,
|
||||
// value: "166.36"),
|
||||
SizedBox(height: 10),
|
||||
ExpansionTile(
|
||||
title: Text(
|
||||
|
||||
Reference in New Issue
Block a user