mirror of
https://github.com/inventree/InvenTree.git
synced 2025-10-16 14:12:21 +00:00
UI panels fix (#10341)
* Tweak sample plugin * Re-fetch panels when instance changes * Unit test fix
This commit is contained in:
@@ -52,7 +52,7 @@ export function usePluginPanels({
|
||||
// API query to fetch initial information on available plugin panels
|
||||
const pluginQuery = useQuery({
|
||||
enabled: pluginPanelsEnabled && !!model && id !== undefined,
|
||||
queryKey: ['custom-plugin-panels', model, id],
|
||||
queryKey: ['custom-plugin-panels', model, id, instance],
|
||||
throwOnError: (error: any) => {
|
||||
console.error('ERR: Failed to fetch plugin panels');
|
||||
return false;
|
||||
|
Reference in New Issue
Block a user