Skip to content

Commit

Permalink
fix: form block not displayed when adding a create form via a popup a…
Browse files Browse the repository at this point in the history
…ction in a table row (nocobase#6190)
  • Loading branch information
katherinehhh authored Feb 11, 2025
1 parent 7a2b990 commit 59c467b
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions packages/core/client/src/block-provider/FormBlockProvider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export const useIsDetailBlock = () => {

export const FormBlockProvider = withDynamicSchemaProps((props) => {
const parentRecordData = useCollectionParentRecordData();
const { parentRecord } = props;
const { parentRecord, action } = props;
const record = useCollectionRecordData();
const { association } = props;
const cm = useCollectionManager();
Expand All @@ -129,12 +129,11 @@ export const FormBlockProvider = withDynamicSchemaProps((props) => {

const refresh = useUpdate();

if (!designable && __collection) {
if (!designable && __collection && action) {
if (__collection !== collection) {
return null;
}
}

return (
<TemplateBlockProvider onTemplateLoaded={refresh}>
<BlockProvider
Expand Down

0 comments on commit 59c467b

Please sign in to comment.