From d35f1fa014d443297d29f181227462f8ebe19ab8 Mon Sep 17 00:00:00 2001 From: Justin Richer Date: Thu, 26 Jun 2014 11:11:12 -0400 Subject: [PATCH] added element scope to query for logo preview, closes #624 --- .../src/main/webapp/resources/js/client.js | 2 +- .../src/main/webapp/resources/js/dynreg.js | 2 +- .../src/main/webapp/resources/js/rsreg.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/openid-connect-server-webapp/src/main/webapp/resources/js/client.js b/openid-connect-server-webapp/src/main/webapp/resources/js/client.js index 1c124a578..b180133f5 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/js/client.js +++ b/openid-connect-server-webapp/src/main/webapp/resources/js/client.js @@ -542,7 +542,7 @@ var ClientFormView = Backbone.View.extend({ previewLogo:function() { if ($('#logoUri input', this.el).val()) { $('#logoPreview', this.el).empty(); - $('#logoPreview', this.el).attr('src', $('#logoUri input').val()); + $('#logoPreview', this.el).attr('src', $('#logoUri input', this.el).val()); } else { //$('#logoBlock', this.el).hide(); $('#logoPreview', this.el).attr('src', 'resources/images/logo_placeholder.gif'); diff --git a/openid-connect-server-webapp/src/main/webapp/resources/js/dynreg.js b/openid-connect-server-webapp/src/main/webapp/resources/js/dynreg.js index 112359cf7..2345a4be7 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/js/dynreg.js +++ b/openid-connect-server-webapp/src/main/webapp/resources/js/dynreg.js @@ -235,7 +235,7 @@ var DynRegEditView = Backbone.View.extend({ previewLogo:function() { if ($('#logoUri input', this.el).val()) { $('#logoPreview', this.el).empty(); - $('#logoPreview', this.el).attr('src', $('#logoUri input').val()); + $('#logoPreview', this.el).attr('src', $('#logoUri input', this.el).val()); } else { //$('#logoBlock', this.el).hide(); $('#logoPreview', this.el).attr('src', 'resources/images/logo_placeholder.gif'); diff --git a/openid-connect-server-webapp/src/main/webapp/resources/js/rsreg.js b/openid-connect-server-webapp/src/main/webapp/resources/js/rsreg.js index 08f45140d..a36717a01 100644 --- a/openid-connect-server-webapp/src/main/webapp/resources/js/rsreg.js +++ b/openid-connect-server-webapp/src/main/webapp/resources/js/rsreg.js @@ -210,7 +210,7 @@ var ResRegEditView = Backbone.View.extend({ previewLogo:function() { if ($('#logoUri input', this.el).val()) { $('#logoPreview', this.el).empty(); - $('#logoPreview', this.el).attr('src', $('#logoUri input').val()); + $('#logoPreview', this.el).attr('src', $('#logoUri input', this.el).val()); } else { //$('#logoBlock', this.el).hide(); $('#logoPreview', this.el).attr('src', 'resources/images/logo_placeholder.gif');