mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-01-19 22:58:15 +00:00
fix: 🐛 小程序里面不支持可选链 "?.", 先直接访问 dataSourceEngine 吧
This commit is contained in:
parent
eba172ce51
commit
36c486b9cd
@ -11,7 +11,7 @@ import { RAX_CHUNK_NAME } from './const';
|
|||||||
|
|
||||||
type PluginConfig = {
|
type PluginConfig = {
|
||||||
fileType: string;
|
fileType: string;
|
||||||
}
|
};
|
||||||
|
|
||||||
const pluginFactory: BuilderComponentPluginFactory<PluginConfig> = (config?) => {
|
const pluginFactory: BuilderComponentPluginFactory<PluginConfig> = (config?) => {
|
||||||
const cfg: PluginConfig = {
|
const cfg: PluginConfig = {
|
||||||
@ -50,10 +50,10 @@ const pluginFactory: BuilderComponentPluginFactory<PluginConfig> = (config?) =>
|
|||||||
self.setState(newState);
|
self.setState(newState);
|
||||||
},
|
},
|
||||||
get dataSourceMap() {
|
get dataSourceMap() {
|
||||||
return self._dataSourceEngine?.dataSourceMap || {};
|
return self._dataSourceEngine.dataSourceMap || {};
|
||||||
},
|
},
|
||||||
async reloadDataSource() {
|
async reloadDataSource() {
|
||||||
self._dataSourceEngine?.reloadDataSource();
|
self._dataSourceEngine.reloadDataSource();
|
||||||
},
|
},
|
||||||
get utils() {
|
get utils() {
|
||||||
return self._utils;
|
return self._utils;
|
||||||
@ -72,9 +72,7 @@ const pluginFactory: BuilderComponentPluginFactory<PluginConfig> = (config?) =>
|
|||||||
return context;
|
return context;
|
||||||
}
|
}
|
||||||
`,
|
`,
|
||||||
linkAfter: [
|
linkAfter: [RAX_CHUNK_NAME.ClassRenderEnd],
|
||||||
RAX_CHUNK_NAME.ClassRenderEnd
|
|
||||||
],
|
|
||||||
});
|
});
|
||||||
|
|
||||||
return next;
|
return next;
|
||||||
|
|||||||
@ -39,10 +39,10 @@ class Home$$Page extends Component {
|
|||||||
self.setState(newState);
|
self.setState(newState);
|
||||||
},
|
},
|
||||||
get dataSourceMap() {
|
get dataSourceMap() {
|
||||||
return self._dataSourceEngine?.dataSourceMap || {};
|
return self._dataSourceEngine.dataSourceMap || {};
|
||||||
},
|
},
|
||||||
async reloadDataSource() {
|
async reloadDataSource() {
|
||||||
self._dataSourceEngine?.reloadDataSource();
|
self._dataSourceEngine.reloadDataSource();
|
||||||
},
|
},
|
||||||
get utils() {
|
get utils() {
|
||||||
return self._utils;
|
return self._utils;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user