update delete & edit data
This commit is contained in:
@ -162,6 +162,7 @@ const EditDialog = () => {
|
|||||||
doFetchPostoAdms([{ id: 'name', desc: false }]);
|
doFetchPostoAdms([{ id: 'name', desc: false }]);
|
||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
|
console.log(selectedSucos);
|
||||||
return (
|
return (
|
||||||
<Dialog open={showEditDialog} onOpenChange={(open) => handleEditDialog(open, null)}>
|
<Dialog open={showEditDialog} onOpenChange={(open) => handleEditDialog(open, null)}>
|
||||||
<DialogContent className="container-fixed max-w-[768px] flex flex-col p-5 overflow-hidden">
|
<DialogContent className="container-fixed max-w-[768px] flex flex-col p-5 overflow-hidden">
|
||||||
|
|||||||
@ -16,7 +16,7 @@ const ListToolbar = () => {
|
|||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="Search Sucos"
|
placeholder="Search Sucos"
|
||||||
value={table.getColumn(`sucos_id`)?.getFilterValue() as string}
|
value={table.getColumn(`id`)?.getFilterValue() as string}
|
||||||
onChange={(event) =>
|
onChange={(event) =>
|
||||||
table.getColumn('sucos_name')?.setFilterValue(event.target.value)
|
table.getColumn('sucos_name')?.setFilterValue(event.target.value)
|
||||||
}
|
}
|
||||||
|
|||||||
@ -126,13 +126,13 @@ const ManageSucosContextProvider = ({ children }: { children: React.ReactNode })
|
|||||||
<>
|
<>
|
||||||
<button
|
<button
|
||||||
className="btn btn-sm btn-icon btn-clear btn-light"
|
className="btn btn-sm btn-icon btn-clear btn-light"
|
||||||
onClick={() => handleEditDialog(true, row.id)}
|
onClick={() => handleEditDialog(true, row.sucos_id)}
|
||||||
>
|
>
|
||||||
<KeenIcon icon="notepad-edit" />
|
<KeenIcon icon="notepad-edit" />
|
||||||
</button>
|
</button>
|
||||||
<button
|
<button
|
||||||
className="btn btn-sm btn-icon btn-clear btn-light"
|
className="btn btn-sm btn-icon btn-clear btn-light"
|
||||||
onClick={() => handleDeleteDialog(true, row.id)}
|
onClick={() => handleDeleteDialog(true, row.sucos_id)}
|
||||||
>
|
>
|
||||||
<KeenIcon icon="trash" />
|
<KeenIcon icon="trash" />
|
||||||
</button>
|
</button>
|
||||||
|
|||||||
Reference in New Issue
Block a user