
<title>登入页面</title>

<div class="layui-card layadmin-header">
  <div class="layui-breadcrumb" lay-filter="breadcrumb">
    <a lay-href="">主页</a>
    <a><cite>模板</cite></a>
    <a><cite>登入</cite></a>
  </div>
</div>

<div class="layui-fluid">
  <div class="layui-card">
    <div class="layui-card-header">说明：正式登入页面将在 beta3 开放</div>
    <div class="layui-card-body" style="padding: 30px; 15px">
      
      <div class="layui-form">
        <div class="layui-form-item">
          <label for="L_email" class="layui-form-label">邮箱</label>
          <div class="layui-input-inline">
            <input type="text" id="L_email" name="email" required lay-verify="email" autocomplete="off" class="layui-input">
          </div>
        </div>
        <div class="layui-form-item">
          <label for="L_pass" class="layui-form-label">密码</label>
          <div class="layui-input-inline">
            <input type="password" id="L_pass" name="pass" required lay-verify="required" autocomplete="off" class="layui-input">
          </div>
        </div>
        <div class="layui-form-item">
          <label for="L_vercode" class="layui-form-label">人类验证</label>
          <div class="layui-input-inline">
            <input type="text" id="L_vercode" name="vercode" required lay-verify="required" placeholder="请回答后面的问题" autocomplete="off" class="layui-input">
          </div>
          <div class="layui-form-mid">
            <span style="color: #c00;">layui 怎么念？</span>
          </div>
        </div>
        <div class="layui-form-item">
          <div class="layui-input-block">
            <button class="layui-btn" lay-filter="template-user-login" lay-submit>立即登录</button>
            <span style="padding-left:20px;">
              <a href="/user/forget">忘记密码？</a>
            </span>
          </div>
        </div>
      </div>
      
    </div>
  </div>
</div>
</div>

<script>
layui.use(['admin', 'form'], function(){
  var $ = layui.$
  ,admin = layui.admin
  ,element = layui.element
  ,form = layui.form
  ,router = layui.router();
  
  
  form.on('submit(template-user-login)', function(obj){
    layer.msg('将得到的数据提交给服务端：<br>'+ JSON.stringify(obj.field));
    console.log(obj)
  });
  
});
</script>