<p>password <input type="password" class="form-control" name="login-password" value=""
id="login-password" style="width: 50%"
oninput="clear_authenticate_error()"></input></p>
- <input type="hidden" name="return_to" value="<%= "#{Rails.configuration.Services.Workbench1.ExternalURL}" %>" id="login-return-to">
+ <input type="hidden" name="return_to" value="<%= params[:return_to] || "#{Rails.configuration.Services.Workbench1.ExternalURL}" %>" id="login-return-to">
<span style="color: red"><p id="login-authenticate-error"></p></span>
<button type="submit" class="btn btn-primary">Log in</button>
</form>