pull/2/head
zaid_daoud 3 years ago
parent 7ed8f86ba2
commit 7828e52c64

@ -403,7 +403,7 @@ class _RequestGasRefillState extends State<RequestGasRefill> {
height: 8,
),
ASubTitle(_subtitle.quantity),
if (_validate && _currentDetails.requestedQuantity == null)
if (_validate && _currentDetails?.requestedQuantity == null)
ASubTitle(
_subtitle.requiredWord,
color: Colors.red,
@ -418,8 +418,8 @@ class _RequestGasRefillState extends State<RequestGasRefill> {
style: Theme.of(context).textTheme.subtitle1,
validator: (value) => Validator.isNumeric(value) ? null : "allow numbers only",
textInputType: TextInputType.number,
onSaved: (value) {
_currentDetails.requestedQuantity = double.tryParse(value);
onChange: (value) {
_currentDetails?.requestedQuantity = double.tryParse(value);
},
),
const SizedBox(height: 16),

Loading…
Cancel
Save