fix: resource conflict with nocobase settings
This commit is contained in:
parent
16342247be
commit
e69e9b9940
@ -35,8 +35,8 @@ export const DataBlockResourceProvider: FC<{ children?: ReactNode }> = ({ childr
|
|||||||
if (association) {
|
if (association) {
|
||||||
return api.resource(association, sourceIdValue, headers);
|
return api.resource(association, sourceIdValue, headers);
|
||||||
}
|
}
|
||||||
return api.resource(dataBlockProps.resource ?? collectionName, undefined, headers);
|
return api.resource(dataBlockProps.resource_deprecated ?? collectionName, undefined, headers);
|
||||||
}, [api, association, collection, sourceIdValue, headers, dataBlockProps.resource]);
|
}, [api, association, collection, sourceIdValue, headers, dataBlockProps.resource_deprecated]);
|
||||||
return <DataBlockResourceContext.Provider value={resource}>{children}</DataBlockResourceContext.Provider>;
|
return <DataBlockResourceContext.Provider value={resource}>{children}</DataBlockResourceContext.Provider>;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -77,7 +77,7 @@ const createGroupBlockSchema = (options) => {
|
|||||||
'x-decorator': 'GroupBlockProvider',
|
'x-decorator': 'GroupBlockProvider',
|
||||||
'x-decorator-props': {
|
'x-decorator-props': {
|
||||||
collection: collection.name,
|
collection: collection.name,
|
||||||
resource: 'charts',
|
resource_deprecated: 'charts',
|
||||||
action: 'query',
|
action: 'query',
|
||||||
groupField,
|
groupField,
|
||||||
params: {
|
params: {
|
||||||
|
Loading…
Reference in New Issue
Block a user