79361434

Date: 2025-01-16 11:47:16
Score: 0.5
Natty:
Report link

I got the solution. The searching works with the item.value, not with item.child. I prepared the "DropdownMenuItem" like below:

DropdownMenuItem<String>(
    value: "$rawmatCode-$serialNocapture-$rawmatName2",
    child: Text("$rawmatCode ($rawmatName2)"),
      );
}).toList();

And the search match function works like below:

searchMatchFn: (item, searchValue) {
   return item.value.toString().toLowerCase().contains(searchValue);
},
Reasons:
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: Ayan