PageRenderTime 439ms CodeModel.GetById 222ms app.highlight 1ms RepoModel.GetById 214ms app.codeStats 0ms

/src/main/webapp/public/js/users/activate.js

http://thoughtsite.googlecode.com/
JavaScript | 32 lines | 11 code | 2 blank | 19 comment | 2 complexity | a65a032b895c0bea73dcee86b0a1ba0a MD5 | raw file
 1/* Copyright 2010 Google Inc.
 2 * 
 3 * Licensed under the Apache License, Version 2.0 (the "License");
 4 * you may not use this file except in compliance with the License.
 5 * You may obtain a copy of the License at
 6 * 
 7 *      http://www.apache.org/licenses/LICENSE-2.0
 8 * 
 9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS.
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License
14 */
15
16/**
17 * file is responsible to handle all javascript tasks on home page
18 * require jquery 1.3.2 
19 */
20// onload set form focus validations
21google.setOnLoadCallback(function() {
22    ie.Login.setLoggedinUserCallback('activate');
23});
24
25function activate (isUserLoggedIn) {
26    if(isUserLoggedIn) {
27       location.href = ie.buildUrl(ie.config.REQUEST_IDEA_EXCHANGE, 'projects/show/' + PROJECT_KEY);
28    }
29    else {
30        $('#activateLogin').show();
31    }
32}