mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-01-18 21:38:14 +00:00
feat: 支持获取组件引用的提案
This commit is contained in:
parent
e371092952
commit
f0d2d56910
@ -464,7 +464,7 @@ export default function baseRenererFactory() {
|
|||||||
Comp = compWrapper(Comp);
|
Comp = compWrapper(Comp);
|
||||||
}
|
}
|
||||||
otherProps.ref = (ref: any) => {
|
otherProps.ref = (ref: any) => {
|
||||||
this.$(props.fieldId, ref); // 收集ref
|
this.$(props.fieldId || props.ref, ref); // 收集ref
|
||||||
const refProps = props.ref;
|
const refProps = props.ref;
|
||||||
if (refProps && typeof refProps === 'string') {
|
if (refProps && typeof refProps === 'string') {
|
||||||
this[refProps] = ref;
|
this[refProps] = ref;
|
||||||
@ -691,7 +691,7 @@ export default function baseRenererFactory() {
|
|||||||
|
|
||||||
$(filedId: string, instance?: any) {
|
$(filedId: string, instance?: any) {
|
||||||
this.__instanceMap = this.__instanceMap || {};
|
this.__instanceMap = this.__instanceMap || {};
|
||||||
if (!filedId) {
|
if (!filedId || typeof filedId !== 'string') {
|
||||||
return this.__instanceMap;
|
return this.__instanceMap;
|
||||||
}
|
}
|
||||||
if (instance) {
|
if (instance) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user