注册登录

This commit is contained in:
huang 2016-06-15 17:58:02 +08:00
parent 06f97d5cb7
commit aa42044199
1 changed files with 11 additions and 59 deletions

View File

@ -165,7 +165,7 @@
</div>
</div>
<%# 注册 %>
<div class="new_register">
<div class="new_register" id = "signUpBox">
<div class="new_register_con">
<div class="new_login_txt fl new_register_left">
<h3> 欢迎加入Trustie创新实践社区</h3>
@ -182,21 +182,22 @@
<p class="new_login_error" id="mail_req" style="display: none" >请输入正确的邮箱</p>
</li>
<li>
<input type="text" class="new_loggin_input " placeholder="请输入密码">
<p class="new_login_error" style="display:none;">请输入6-16位密码区分大小写不能使用空格</p>
<%= f.password_field :password, :size => 25, :placeholder => "请输入密码", :class => 'new_loggin_input' %>
<p class="new_login_error" id="passwd_req" style="display: none">请输入6-16位密码区分大小写不能使用空格</p>
</li>
<li>
<input type="text" class="new_loggin_input " placeholder="请输入密码">
<p class="new_login_error" style="display:none;">两次密码不一致!</p>
<%= f.password_field :password_confirmation, :size => 25, :placeholder => "请再次输入密码", :class=> 'new_loggin_input' %>
<p class="new_login_error" id="confirm_req" style="display: none">两次密码不一致!</p>
</li>
<li>
<input type="text" class="new_loggin_input " placeholder="请输入登录名">
<p class="new_login_error" style="display:none;" >登录名已使用!</p>
<%= f.text_field :login, :size => 25, :placeholder => "请输入用户登录名", :class => 'new_loggin_input'%>
<p class="new_login_error" id="login_req" style="display: none">用户登录名为2-18个中英文数字或下划线</p>
</li>
<li>
<label><input type="checkbox" checked=" checked" class=" new_login_check">我已阅读并接受<a href="javascript:void(0);" >Trustie服务协议条款</a></label>
<label><input type="checkbox" id="read_and_confirm" onchange="changeRegisterBtn(this);" class=" new_login_check">我已阅读并接受<a href="<%= agreement_path %>" >Trustie服务协议条款</a></label>
</li>
<li><button type="submit" class="new_login_submit">注册</button></li>
<li>
<button type="submit" class="new_login_submit"><a href="javascript:void(0);" class="new_login_submit" id="regist_btn" onclick="register();" >注册</a></button></li>
</ul>
<% end %>
</div>
@ -206,52 +207,3 @@
</div>
</div>
<div class="loginContentContainer">
<div class="loginContent">
<div class="loginRight">
<div id="signUpBox">
<div class="loginChooseBox">
<ul class="loginChooseList">
<li class="loginChoose fl"><span class="loginChooseTab">注册<%= link_to l(:label_login_with_open_id_option), signin_url if Setting.openid? %></a></span>
<li class="loginChooseBorder fl"></li>
</ul>
</div>
<div class="loginIn">
<%= form_for :user, :url => register_path,:method=>'post',:html=>{:id=>'main_reg_form'} do |f| %>
<%= error_messages_for 'user' %>
<div class="loginSignRow">
<!--<input type="text" placeholder="请输入邮箱地址" class="loginSignBox" />-->
<%= f.text_field :mail,:size => 25, :class=>'loginSignBox' ,:placeholder=>"请输入邮箱地址"%>
<div class="loginSignAlert" id="mail_req" style="display: none" >请输入有效邮箱地址</div>
</div>
<div class="loginSignRow">
<!--<input type="text" placeholder="请输入密码" class="loginSignBox" />-->
<%= f.password_field :password, :size => 25,:placeholder=>"请输入密码",:class=>'loginSignBox' %>
<div class="loginSignAlert" id="passwd_req" style="display: none">至少需要 6 个字符</div>
</div>
<div class="loginSignRow">
<!--<input type="text" placeholder="请再次输入密码" class="loginSignBox" />-->
<%= f.password_field :password_confirmation, :size => 25,:placeholder=>"请再次输入密码",:class=>'loginSignBox' %>
<div class="loginSignAlert" id="confirm_req" style="display: none">密码不一致</div>
</div>
<div class="loginSignRow">
<!--<input type="text" placeholder="请输入用户昵称" class="loginSignBox" />-->
<%= f.text_field :login, :size => 25,:placeholder=>"请输入用户登录名",:class=>'loginSignBox'%>
<div class="loginSignAlert" id="login_req" style="display: none">用户登录名为2-18个中英文数字或下划线</div>
</div>
<div class="loginSignOption">
<div class="fl mt3 mr5">
<input type="checkbox" id="read_and_confirm" onchange="changeRegisterBtn(this);"/>
</div>
我已阅读并接受<a href="<%= agreement_path %>" class="newsBlue"><u>Trustie服务协议</u></a>条款</div>
<div class="loginUpDisableButton" id="loginUpButton">
<a href="javascript:void(0);" class="c_white db" id="regist_btn" onclick="register();" >注册</a>
</div>
<% end %>
</div>
</div>
</div>
<div class="cl"></div>
</div>
</div>