Skip to content
Snippets Groups Projects
Commit 7c3aed07 authored by pkupczyk's avatar pkupczyk
Browse files

SP-557 / BIS-151 : openbis.js - replace /resources/js/* with...

SP-557 / BIS-151 : openbis.js - replace /resources/js/* with resources/js-new/* and make sure the webapps still work - examples fix

SVN: 28667
parent a5b996d5
No related branches found
No related tags found
No related merge requests found
......@@ -19,7 +19,7 @@
<script>
$(document).ready(function() {
configureLoginPage(openbisServer, enterApp);
new openbisLoginPage(openbisServer, enterApp).configure();
});
</script>
......
......@@ -19,7 +19,7 @@
<script>
$(document).ready(function() {
configureLoginPage(openbisServer, enterApp);
new openbisLoginPage(openbisServer, enterApp).configure();
});
</script>
......
......@@ -19,7 +19,7 @@
<script>
$(document).ready(function() {
configureLoginPage(openbisServer, enterApp);
new openbisLoginPage(openbisServer, enterApp).configure();
});
</script>
......
......@@ -40,6 +40,8 @@ function openbisLoginPage(openbis, onLogin)
}
openbisLoginPage.prototype.configure = function(){
var loginPage = this;
$('#main').hide();
var username = $("#username").value;
......@@ -50,7 +52,7 @@ openbisLoginPage.prototype.configure = function(){
}
$('#logout-button').click(function() {
openbis.logout(function(data) {
loginPage.openbis.logout(function(data) {
$("#login-form-div").show();
$("#main").hide();
$("#username").focus();
......@@ -58,10 +60,10 @@ openbisLoginPage.prototype.configure = function(){
});
$('#login-form').submit(function() {
openbis.login( $.trim($('#username').val()), $.trim($('#password').val()), function(data) { onLogin(data) })
loginPage.openbis.login( $.trim($('#username').val()), $.trim($('#password').val()), function(data) { loginPage.onLogin(data) })
});
openbis.ifRestoredSessionActive(function(data) { onLogin(data) });
loginPage.openbis.ifRestoredSessionActive(function(data) { loginPage.onLogin(data) });
// Make the ENTER key the default button
$("login-form input").keypress(function (e) {
......
......@@ -154,7 +154,7 @@ function enterApp(data)
$(document).ready(function() {
configureLoginPage(openbisServer, enterApp);
new openbisLoginPage(openbisServer, enterApp).configure();
});
</script>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment