prescription changes

merge-requests/655/head
hussam al-habibeh 5 years ago
parent d2814f610e
commit 6107f88c16

@ -445,85 +445,39 @@ class _PrescriptionFormWidgetState extends State<PrescriptionFormWidget> {
child: Row( child: Row(
children: [ children: [
Container( Container(
// height: MediaQuery.of(context) color: Colors.white,
// .size
// .height *
// 0.02,
width: MediaQuery.of(context) width: MediaQuery.of(context)
.size .size
.width * .width *
0.35, 0.35,
child: AppTextFieldCustom( child: TextField(
isPrscription: true, decoration:
inputFormatters: [ textFieldSelectorDecoration(
LengthLimitingTextInputFormatter( "",
5), 'Strength', //strengthController.text,
// WhitelistingTextInputFormatter false),
// .digitsOnly enabled: true,
], controller:
hintText: strengthController,
TranslationBase.of( onChanged:
context) (String value) {
.strength, setState(() {
strengthChar =
// fontWeight: FontWeight.w500, value.length;
// fontSize: 14.0, });
// borderWidth: 0.2, if (strengthChar >= 5) {
DrAppToastMsg
controller: .showErrorToast(
strengthController, TranslationBase.of(
// keyboardType: TextInputType context)
// .numberWithOptions( .only5DigitsAllowedForStrength,
// decimal: true, );
// ), }
onChanged: (String value) { },
setState(() { keyboardType: TextInputType
strengthChar = .numberWithOptions(
value.length; decimal: true,
}); )),
if (strengthChar >= 5) {
DrAppToastMsg
.showErrorToast(
TranslationBase.of(
context)
.only5DigitsAllowedForStrength,
);
}
},
// onClick: (_) {
// if (_selectedMedication !=
// null &&
// duration != null &&
// frequency != null &&
// strengthController
// .text !=
// null) {
// model.getBoxQuantity(
// freq: frequency[
// 'parameterCode'],
// duration:
// duration['id'],
// itemCode:
// _selectedMedication
// .itemId,
// strength: double.parse(
// strengthController
// .text));
// box = model.boxQuintity;
//
// return;
// }
// },
// validator: (value) {
// if (value.isEmpty &&
// strengthController.text.length >
// 4)
// return TranslationBase.of(context)
// .emptyMessage;
// else
// return null;
// },
),
), ),
SizedBox( SizedBox(
width: 5.0, width: 5.0,

Loading…
Cancel
Save