CheckWidget function

Widget CheckWidget(
  1. dynamic Item,
  2. dynamic map,
  3. dynamic pType, {
  4. dynamic show = false,
})

Implementation

Widget CheckWidget(Item, map, pType,{show=false}) {

     return FormBuilderCheckbox(
           enabled: !show,
           name:Item["key"],
           title: Item['hideLabel'] ? Text('') : Text("${Item['label']}",style: ThemeApp!.headline1 ,),
           initialValue: false,
           activeColor: ThemeApp?.primaryColor,
           onSaved: (value) {
            if(value!=null)
     map[Item["key"]] = value;
           },
         );

}