Browse Source

fix show supply nursery

master
daivph 5 years ago
parent
commit
d1ef60937e
2 changed files with 8 additions and 16 deletions
  1. +1
    -1
      lib/presentation/screens/actions/nursery/sc_edit_action_nursery.dart
  2. +7
    -15
      lib/presentation/screens/actions/plant/widget_plant_supply.dart

+ 1
- 1
lib/presentation/screens/actions/nursery/sc_edit_action_nursery.dart View File

.push(MaterialPageRoute( .push(MaterialPageRoute(
builder: (_) => ResourceHelperScreen( builder: (_) => ResourceHelperScreen(
titleName: "Giá thể", titleName: "Giá thể",
type: ConstCommon.supplyTypeAll,
type: ConstCommon.supplyTypeSubStrate,
selectedId: Get.find<ChangeSupply>().selectedSupplyId), selectedId: Get.find<ChangeSupply>().selectedSupplyId),
fullscreenDialog: false)) fullscreenDialog: false))
.then((value) { .then((value) {

+ 7
- 15
lib/presentation/screens/actions/plant/widget_plant_supply.dart View File

color: Colors.redAccent, color: Colors.redAccent,
), ),
onPressed: () { onPressed: () {
print("Delete");
changeSupplyUsing.deleteSupply(index); changeSupplyUsing.deleteSupply(index);
}), }),
) )


_quantityField() { _quantityField() {
return TextFormField( return TextFormField(
keyboardType: TextInputType.numberWithOptions(decimal: true),
inputFormatters: [
ThousandsFormatter(
formatter: NumberFormat("#,###.##", "es"), allowFraction: true)
],
decoration: InputDecoration(labelText: "Tổng lượng sử dụng"),
controller: _quantityController,
onSaved: (newValue) {
print(newValue);
},
onChanged: (v) {
print(v);
},
);
keyboardType: TextInputType.numberWithOptions(decimal: true),
inputFormatters: [
ThousandsFormatter(
formatter: NumberFormat("#,###.##", "es"), allowFraction: true)
],
decoration: InputDecoration(labelText: "Tổng lượng sử dụng"),
controller: _quantityController);
} }


_buttonInForm() { _buttonInForm() {

Loading…
Cancel
Save