Skip to content
This repository was archived by the owner on Nov 25, 2020. It is now read-only.

Commit b917930

Browse files
committed
Reset MetaSource selector after adding (to focus on the new instance).
1 parent e5df617 commit b917930

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

core/src/plugins/editor.ajxp_repository/class.RepositoryEditor.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,7 @@ Class.create("RepositoryEditor", AbstractEditor, {
348348

349349
this.metaSelector.observe("change", function(){
350350
var plugId = this.metaSelector.getValue();
351+
if(!addFormDetail) return;
351352
addFormDetail.update("");
352353
addFormDetail.addClassName("empty");
353354
if(plugId){
@@ -426,6 +427,13 @@ Class.create("RepositoryEditor", AbstractEditor, {
426427
button.addClassName("SF_disabled");
427428
this.setClean();
428429
}
430+
if(action == "meta_source_add"){
431+
this.metaSelector.setValue("");
432+
this.metaSelector.fire("chosen:updated");
433+
var addFormD = form.down(".meta_plugin_new_form");
434+
addFormD.update("");
435+
addFormD.addClassName("empty");
436+
}
429437
}.bind(this);
430438
conn.sendAsync();
431439

0 commit comments

Comments
 (0)