form_builder_extra_fields icon indicating copy to clipboard operation
form_builder_extra_fields copied to clipboard

[FormBuilderSearchableDropdown]: Another exception was thrown: 'package:form_builder_extra_fields/src/fields/form_builder_searchable_dropdown.dart': Failed assertion: line 128 pos 16: 'T == String || compareFn != null': is not true.

Open dedyksuntoro opened this issue 1 year ago • 2 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Package/Plugin version

10.1.0

Platforms

  • [X] Android
  • [ ] iOS
  • [ ] Linux
  • [ ] MacOS
  • [ ] Web
  • [ ] Windows

Flutter doctor

Flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 3.13.9, on Microsoft Windows [Version 10.0.22621.2283], locale en-ID)
[√] Windows Version (Installed version of Windows is version 10 or higher)
[√] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
[√] Chrome - develop for the web
[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.1.0)
[√] Android Studio (version 2022.3)
[√] VS Code (version 1.84.2)
[√] Connected device (4 available)
[√] Network resources

• No issues found!

Minimal code example

Code sample
List selectBan = [];

_futureSelectSerahTerimaKendaraanListBan =
    _apiDatabase.geSelectSerahTerimaKendaraanListBan();
_futureSelectSerahTerimaKendaraanListBan.then((value) {
  setState(() {
    selectBan = value;
  });
});

FormBuilderSearchableDropdown(
  name: 'al',
  decoration: InputDecoration(
    label: Text('AL'),
    border: OutlineInputBorder(),
  ),
  items: selectBan
      .map(
        (e) => DropdownMenuItem(
          value: e.id,
          child: Text(
            e.sparepart.toString(),
          ),
        ),
      )
      .toList(),
  onChanged: (value) {},
),

Current Behavior

Error Message: Another exception was thrown: 'package:form_builder_extra_fields/src/fields/form_builder_searchable_dropdown.dart': Failed assertion: line 128 pos 16: 'T == String || compareFn != null': is not true.

Expected Behavior

Maybe this can be fixed soon

Steps To Reproduce

Aditional information

No response

dedyksuntoro avatar Nov 30 '23 03:11 dedyksuntoro