mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-01-16 03:18:11 +00:00
Merge branch 'feat/rax-miniapp' of http://gitlab.alibaba-inc.com/ali-lowcode/ali-lowcode-engine into feat/rax-miniapp
This commit is contained in:
commit
d85ca25fca
@ -132,6 +132,18 @@ export class SettingField extends SettingPropEntry implements SettingEntry {
|
||||
return this.transducer.toHot(v);
|
||||
}
|
||||
|
||||
setMiniAppDataSourceValue(data: any, options?: any) {
|
||||
this.hotValue = data;
|
||||
const v = this.transducer.toNative(data);
|
||||
this.setValue(v, false, false, options);
|
||||
// dirty fix list setter
|
||||
if (Array.isArray(data) && data[0] && data[0].__sid__) {
|
||||
return;
|
||||
}
|
||||
|
||||
this.valueChange();
|
||||
}
|
||||
|
||||
setHotValue(data: any, options?: any) {
|
||||
this.hotValue = data;
|
||||
const v = this.transducer.toNative(data);
|
||||
|
||||
@ -181,20 +181,16 @@ export async function webTableProxy(req) {
|
||||
const sheetId = OneAPIConfig['x-model'];
|
||||
const sheet = await Table.find({ id: sheetId });
|
||||
const result = await sheet.instance.fetch({ code }, params);
|
||||
// const result = await Table.find({ id: 'vip_info' });
|
||||
return result;
|
||||
}
|
||||
return new Promise((resolve, reject) => {
|
||||
Bus.emitter.on('table.ready', async (table) => {
|
||||
// const { name } = req;
|
||||
// const result = table.fetch({ id: name });
|
||||
const { options } = req;
|
||||
const { params, OneAPIConfig } = options;
|
||||
const { code } = OneAPIConfig;
|
||||
const sheetId = OneAPIConfig['x-model'];
|
||||
const sheet = await table.find({ id: sheetId });
|
||||
const result = await sheet.instance.fetch({ code }, params);
|
||||
// const result = await Table.find({ id: 'vip_info' });
|
||||
resolve(result);
|
||||
});
|
||||
});
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user