Skip to content

Body Action

Inside the new tab and please implement the SidebarBodyAction under SidebarBodyCard.

Body action

  SidebarBodyAction(
      onSearch: (value) {},
      onAdd: () => AppDialog.form(
        context: context,
        title: 'Add Card',
        heightReduce: AppDimens.size4XL,
        content: const ListCardAddForm(),
        onSubmitted: () {},
      ),
      onFilter: () => AppDialog.filter<bool>(
        context: context,
        title: 'Filter Card',
        content: const ListCardFilterForm(),
        onSubmitted: () {},
        onReset: () {},
      ),
      onImport: () => AppDialog.import(
        context: context,
        title: 'Import Card',
        description: `Please add the file excel here. Then be sure the data matches with the template.`,
        content: TextFieldPicker(
          fileType: FileType.media,
          onDone: (i) {},
        ),
        onSubmitted: () {},
        onDownload: () {},
      ),
      onExport: () => AppDialog.confirm(
        context: context,
        title: 'Export Card',
        description: 'Download file excel',
        submitted: 'Export',
        onSubmitted: () {},
      ),
    ),

Constructors

  • onAdd please use metode AppDialog.form.
  • onFilter use metode AppDialog.filter.
  • onImport use metode AppDialog.import.
  • onExport use metode AppDialog.confim.
  • onSearch use this property to retrieve data string.
  • dropdownButton for example you can use
    DateRangeButton<String>(
      items: const ['Mingguan', 'Bulanan', 'Tahunan'],
      onChanged: (value) {},
      selectedItem: 'Bulanan',
    )
    

Warning

For more information please learn more in the Dialog

Authors: Nanang Prasetya