diff --git a/packages/app/src/components/pages/CollectionLoader/CollectionTabPane.tsx b/packages/app/src/components/pages/CollectionLoader/CollectionTabPane.tsx
index d09ff5120c..573745c70a 100644
--- a/packages/app/src/components/pages/CollectionLoader/CollectionTabPane.tsx
+++ b/packages/app/src/components/pages/CollectionLoader/CollectionTabPane.tsx
@@ -29,6 +29,7 @@ export function CollectionTabPane(props) {
diff --git a/packages/app/src/components/views/index.tsx b/packages/app/src/components/views/index.tsx
index ff4f4a8795..22b509971d 100644
--- a/packages/app/src/components/views/index.tsx
+++ b/packages/app/src/components/views/index.tsx
@@ -49,6 +49,7 @@ export default function ViewFactory(props: ViewProps) {
viewName,
mode,
reference,
+ isAssociationView = false,
} = props;
console.log('propspropspropspropspropspropsprops', props);
const { data = {}, loading } = useRequest(() => {
@@ -67,7 +68,10 @@ export default function ViewFactory(props: ViewProps) {
if (loading) {
return ;
}
- const { template } = data;
+ let { template } = data;
+ if (isAssociationView && template === 'Table') {
+ template = 'SimpleTable';
+ }
const Template = getViewTemplate(template);
return Template && ;
}
diff --git a/packages/plugin-pages/src/actions/getView.ts b/packages/plugin-pages/src/actions/getView.ts
index b8cf65ddf9..a08cb76e93 100644
--- a/packages/plugin-pages/src/actions/getView.ts
+++ b/packages/plugin-pages/src/actions/getView.ts
@@ -185,7 +185,7 @@ export default async (ctx, next) => {
view.setDataValue('defaultTabName', get(defaultTabs, [0, 'name']));
}
- if (view.get('template') === 'SimpleTable') {
+ if (view.get('type') === 'table') {
view.setDataValue('rowViewName', 'form');
}
if (view.get('updateViewName')) {