Skip to content

Commit

Permalink
fix(data-source): 多页面时数据源依赖中可能包含其他页面的,导致更新时失败
Browse files Browse the repository at this point in the history
  • Loading branch information
roymondchen committed Jun 13, 2024
1 parent 948c194 commit 5c43fbf
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/data-source/src/createDataSourceManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,11 @@ export const createDataSourceManager = (app: AppCore, useMock?: boolean, initial

const nodeIds = union([...Object.keys(condDep), ...Object.keys(dep)]);

const pages = app.page?.data && app.platform !== 'editor' ? [app.page.data] : dsl.items;

dataSourceManager.emit(
'update-data',
getNodes(nodeIds, dsl.items).map((node) => {
getNodes(nodeIds, pages).map((node) => {
if (app.platform !== 'editor') {
node.condResult = dataSourceManager.compliedConds(node);
}
Expand Down

0 comments on commit 5c43fbf

Please sign in to comment.