2010-10-29 19:12:40 +00:00
|
|
|
<#-- $This file is distributed under the terms of the license in /doc/license.txt$ -->
|
|
|
|
|
|
|
|
<#-- Login widget -->
|
|
|
|
|
2010-11-03 02:26:48 +00:00
|
|
|
<#macro assets>
|
2011-02-07 18:23:42 +00:00
|
|
|
<#-- RY This test should be replaced by login widget controller logic which displays different assets macros depending
|
|
|
|
on login status, but currently there's no widget-specific doAssets() method. See NIHVIVO-1357. The test doesn't work
|
|
|
|
because we don't have the user in the template data model when we generate the assets. This can also be fixed by
|
|
|
|
NIHVIVO-1357.
|
2010-11-23 01:28:39 +00:00
|
|
|
<#if ! user.loggedIn> -->
|
2010-11-10 19:50:28 +00:00
|
|
|
${stylesheets.add("/css/login.css")}
|
2011-01-14 22:00:30 +00:00
|
|
|
<#-- ${scripts.add("")} -->
|
|
|
|
${headScripts.add("/js/login/loginUtils.js")}
|
2010-11-15 22:17:20 +00:00
|
|
|
<#-- </#if> -->
|
2010-10-29 19:12:40 +00:00
|
|
|
</#macro>
|
|
|
|
|
2010-11-15 22:17:20 +00:00
|
|
|
<#macro loginForm>
|
2011-02-08 13:23:59 +00:00
|
|
|
<#-- Don't display the JavaScript required to edit message on the home page even if JavaScript is unavailable -->
|
|
|
|
<#if ( currentPage != 'home' && currentPage != 'index.jsp')>
|
|
|
|
<noscript>
|
|
|
|
<section id="error-alert">
|
|
|
|
<img src="${urls.images}/iconAlertBig.png" alt="Alert Icon"/>
|
|
|
|
<p>In order to edit VIVO content, you'll need to enable JavaScript.</p>
|
|
|
|
</section>
|
|
|
|
</noscript>
|
|
|
|
</#if>
|
2010-11-05 19:29:27 +00:00
|
|
|
|
2011-01-16 19:26:15 +00:00
|
|
|
<section id="login" class="hidden">
|
2010-11-15 22:17:20 +00:00
|
|
|
<h2>Log in</h2>
|
|
|
|
|
|
|
|
<#if infoMessage??>
|
|
|
|
<h3>${infoMessage}</h3>
|
|
|
|
</#if>
|
|
|
|
|
|
|
|
<#if errorMessage??>
|
2010-12-21 15:11:50 +00:00
|
|
|
<section id="error-alert" role="alert"><img src="${urls.images}/iconAlert.png" alert="Error alert icon" />
|
2011-02-01 17:34:49 +00:00
|
|
|
<p class="login-alert">${errorMessage}</p>
|
2010-12-21 15:11:50 +00:00
|
|
|
</section>
|
2010-11-15 22:17:20 +00:00
|
|
|
</#if>
|
|
|
|
|
2010-11-24 18:21:23 +00:00
|
|
|
<form role="form" id="login-form" action="${formAction}" method="post" name="login-form" />
|
2010-12-21 15:11:50 +00:00
|
|
|
<#if externalAuthUrl??>
|
2010-12-21 19:22:25 +00:00
|
|
|
<p class="external-auth"><a class="blue button" href="${externalAuthUrl}">${externalAuthName}</a></p>
|
|
|
|
<p class="or-auth">or</p>
|
|
|
|
|
2011-01-04 18:23:11 +00:00
|
|
|
<h3 class="internal-auth" >Log in using your ${siteName} account</h3>
|
2010-12-21 15:11:50 +00:00
|
|
|
</#if>
|
2010-12-21 19:22:25 +00:00
|
|
|
|
2010-11-19 14:52:41 +00:00
|
|
|
<label for="email">Email</label>
|
2011-01-16 19:26:15 +00:00
|
|
|
<input class="text-field focus" name="loginName" id="loginName" type="text" value="${loginName!}" required />
|
2010-11-19 14:52:41 +00:00
|
|
|
|
|
|
|
<label for="password">Password</label>
|
|
|
|
<input class="text-field" name="loginPassword" id="password" type="password" required />
|
|
|
|
|
|
|
|
<p class="submit"><input name="loginForm" type="submit" class="green button" value="Log in"/></p>
|
2011-01-16 19:26:15 +00:00
|
|
|
<#-- NC: remember me won't be ready for r1.2
|
2010-11-19 14:52:41 +00:00
|
|
|
<input class="checkbox-remember-me" name="remember-me" type="checkbox" value="" />
|
2010-12-17 23:19:19 +00:00
|
|
|
<label class="label-remember-me" for="remember-me">Remember me</label> -->
|
2010-11-30 20:21:52 +00:00
|
|
|
<#-- mb863: forgot password and request an account won't be part of VIVO r1.2
|
2010-11-23 02:32:09 +00:00
|
|
|
<p class="forgot-password"><a href="#">Forgot your password?</a></p>
|
2010-12-21 15:11:50 +00:00
|
|
|
<p class="request-account"><a class="blue button" href="#">Request an account</a> </p> -->
|
2010-11-19 14:52:41 +00:00
|
|
|
</form>
|
|
|
|
|
2010-11-15 22:17:20 +00:00
|
|
|
</section><!-- #log-in -->
|
|
|
|
</#macro>
|
|
|
|
|
|
|
|
<#macro forcePasswordChange>
|
2010-11-24 18:21:23 +00:00
|
|
|
<section id="login">
|
2011-01-18 20:57:02 +00:00
|
|
|
<h2>Change Password to Log in</h2>
|
2010-11-15 22:17:20 +00:00
|
|
|
|
|
|
|
<#if errorMessage??>
|
2010-12-14 18:39:19 +00:00
|
|
|
<div id="error-alert" role="alert"><img src="${urls.images}/iconAlert.png" width="24" height="24" alert="Error alert icon"/>
|
2010-11-15 22:17:20 +00:00
|
|
|
<p>${errorMessage}</p>
|
|
|
|
</div>
|
|
|
|
</#if>
|
|
|
|
|
2010-11-24 18:21:23 +00:00
|
|
|
<form role="form" id="login-form" action="${formAction}" method="post" name="login-form" required />
|
2010-11-29 18:26:16 +00:00
|
|
|
<label for="new-password">New Password</label>
|
2011-01-16 19:26:15 +00:00
|
|
|
<input id="new-password" class="text-field focus" type="password" name="newPassword" required />
|
2010-11-19 14:52:41 +00:00
|
|
|
|
2010-11-29 18:26:16 +00:00
|
|
|
<p class="password-note">Minimum of 6 characters in length.</p>
|
2010-11-19 14:52:41 +00:00
|
|
|
|
2010-11-29 18:26:16 +00:00
|
|
|
<label for="confirm-password">Confirm Password</label>
|
|
|
|
<input id="confirm-password" class="text-field" type="password" name="confirmPassword" />
|
2010-11-19 14:52:41 +00:00
|
|
|
|
2010-11-19 20:54:16 +00:00
|
|
|
<p class="submit-password"><input name="passwordChangeForm" type="submit" class="green button" value="Log in"/> <span class="or">or <a class="cancel" href="${cancelUrl}">Cancel</a></span></p>
|
2010-11-15 22:17:20 +00:00
|
|
|
</form>
|
|
|
|
</section>
|
|
|
|
</#macro>
|
|
|
|
|
2010-11-16 16:53:50 +00:00
|
|
|
<#macro alreadyLoggedIn>
|
|
|
|
<h2>Log in</h2>
|
2010-11-30 19:29:23 +00:00
|
|
|
<p>You are already logged in.</p>
|
2010-11-16 16:53:50 +00:00
|
|
|
</#macro>
|
|
|
|
|
2010-11-15 22:17:20 +00:00
|
|
|
<#macro error>
|
|
|
|
<p>There was an error in the system.</p>
|
|
|
|
</#macro>
|