2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-17 10:16:30 +00:00

[PUI] Refactoring forms ()

* Refactor "plugin activate" dialog

- Use hooked modal

* Remove actions from drawer

- Used dynamic modal code which is super buggy

* Update plugin drawer / table

* Refactor settings management:

- Use proper hooked form
- Reduce code duplication
- Run single callback for each <SettingList>

* Add error boundary

* Update ErrorTable

- Use useDeleteApiFormModal

* Refactor ManufacturerPartParameter table

- Use hooked modals

* Refactor existing tables

- Pass table state to forms

* Ensure table is reloaded

* Refactor ManufacturerPartTable

* Code cleanup

* More cleanup
This commit is contained in:
Oliver
2024-05-16 11:58:50 +10:00
committed by GitHub
parent 548ecf58a2
commit b7b320cf61
29 changed files with 442 additions and 471 deletions

@@ -268,7 +268,7 @@ export default function StockItemTestResultTable({
result: true
},
title: t`Add Test Result`,
onFormSuccess: () => table.refreshTable(),
table: table,
successMessage: t`Test result added`
});
@@ -279,7 +279,7 @@ export default function StockItemTestResultTable({
pk: selectedTest,
fields: resultFields,
title: t`Edit Test Result`,
onFormSuccess: () => table.refreshTable(),
table: table,
successMessage: t`Test result updated`
});
@@ -287,7 +287,7 @@ export default function StockItemTestResultTable({
url: ApiEndpoints.stock_test_result_list,
pk: selectedTest,
title: t`Delete Test Result`,
onFormSuccess: () => table.refreshTable(),
table: table,
successMessage: t`Test result deleted`
});