Fix link to no longer pre-selecting last used app

This commit is contained in:
Nathan Gray 2015-02-17 16:29:05 +00:00
parent a7708a8773
commit e906d4f67a

View File

@ -582,7 +582,6 @@ var et2_link_entry = et2_inputWidget.extend(
// Application selection // Application selection
this.app_select = $j(document.createElement("select")).appendTo(this.div) this.app_select = $j(document.createElement("select")).appendTo(this.div)
.val(this.options.value.app||'')
.change(function(e) { .change(function(e) {
// Clear cache when app changes // Clear cache when app changes
self.cache = {}; self.cache = {};
@ -607,6 +606,11 @@ var et2_link_entry = et2_inputWidget.extend(
this.app_select.hide(); this.app_select.hide();
this.div.addClass("no_app"); this.div.addClass("no_app");
} }
else
{
// Now that options are in, set to last used app
this.app_select.val(this.options.value.app||'');
}
// Search input // Search input
this.search = $j(document.createElement("input")) this.search = $j(document.createElement("input"))