Skip to content

Commit d6b964b

Browse files
author
minjk-bl
committed
Instance's inner subset popup fixed, Instance shows error as alert
1 parent f34ad70 commit d6b964b

File tree

2 files changed

+27
-0
lines changed

2 files changed

+27
-0
lines changed

js/com/component/InstanceEditor.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -433,6 +433,14 @@ define([
433433
if (callback) {
434434
callback(varObj);
435435
}
436+
}).catch(function(resultObj) {
437+
let { result } = resultObj;
438+
// show alert
439+
com_util.renderAlertModal(result.ename + ': ' + result.evalue);
440+
// callback
441+
if (callback) {
442+
callback('');
443+
}
436444
});
437445

438446

js/m_apps/Instance.js

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -157,6 +157,10 @@ define([
157157
let component = evt.component;
158158
component.close();
159159
});
160+
$(this.wrapSelector('#vp_instanceVariable')).on('focus_option_page', function(evt) {
161+
let component = evt.component;
162+
component.focus();
163+
});
160164
$(this.wrapSelector('#vp_instanceVariable')).on('apply_option_page', function(evt) {
161165
let component = evt.component;
162166
// apply its value
@@ -219,6 +223,21 @@ define([
219223
return sbCode.toString();
220224
}
221225

226+
hide() {
227+
super.hide();
228+
this.state.subsetEditor && this.state.subsetEditor.hide();
229+
}
230+
231+
close() {
232+
super.close();
233+
this.state.subsetEditor && this.state.subsetEditor.close();
234+
}
235+
236+
remove() {
237+
super.remove();
238+
this.state.subsetEditor && this.state.subsetEditor.remove();
239+
}
240+
222241
updateValue(value) {
223242
let cmObj = this.getCodemirror('vp_instanceVariable');
224243
if (cmObj && cmObj.cm) {

0 commit comments

Comments
 (0)