optionTile method

dynamic optionTile(
  1. String title,
  2. String type,
  3. String property,
  4. String optionsStr,
)

Implementation

optionTile(String title, String type, String property, String optionsStr) {
  return """
  DropDownTile<${type}>(
        title: "${title}",
        selected: obj!.${property},
        options: ${optionsStr},
        itemBuilder: (selectValue) {
          return Text(selectValue.toString(), textAlign: TextAlign.end);
        },
        onChanged: (value){
          obj!.${property} = value;
          onChanged?.call("${property}");
        },
      ),
""";
}