diff --git a/avalon.js b/avalon.js index 95e6f1188..3f5ae4c8c 100644 --- a/avalon.js +++ b/avalon.js @@ -3335,6 +3335,7 @@ data.value = [widget, id, optName].join(",") data[widget + "Id"] = id data.evaluator = noop + elem.msData["ms-widget-id"] = id var options = data[widget + "Options"] = avalon.mix({}, constructor.defaults, vmOptions || {}, widgetData) elem.removeAttribute("ms-widget") var vmodel = constructor(elem, data, vmodels) || {} //防止组件不返回VM diff --git a/avalon.modern.js b/avalon.modern.js index 2d289b21e..306e13e73 100644 --- a/avalon.modern.js +++ b/avalon.modern.js @@ -2637,6 +2637,7 @@ var widgetData = avalon.getWidgetData(elem, widget) data.value = [widget, id, optName].join(",") data[widget + "Id"] = id + elem.msData["ms-widget-id"] = id data.evaluator = noop var options = data[widget + "Options"] = avalon.mix({}, constructor.defaults, vmOptions || {}, widgetData) elem.removeAttribute("ms-widget")