|
@@ -10,25 +10,6 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
-<script type="text/javascript">
|
|
|
- $(function () {
|
|
|
- $(".search_label").click(function () {
|
|
|
- $(this).children(".input_ys").addClass("input_checked");
|
|
|
- $(this).siblings().children(".input_ys").removeClass("input_checked");
|
|
|
- })
|
|
|
-
|
|
|
- $(".gzh_top").click(function () {
|
|
|
- if ($(this).hasClass("gzh_topcur")) {
|
|
|
- $(".erweima_con").slideUp();
|
|
|
- $(this).removeClass("gzh_topcur");
|
|
|
- } else {
|
|
|
- $(".erweima_con").slideDown();
|
|
|
- $(this).addClass("gzh_topcur");
|
|
|
- }
|
|
|
-
|
|
|
- })
|
|
|
- })
|
|
|
-</script>
|
|
|
<!-- 导航 -->
|
|
|
<div class="nav">
|
|
|
<div class="mainbox clearfix">
|
|
@@ -105,17 +86,17 @@
|
|
|
<p class="login_index_tit">账户登录</p>
|
|
|
<p class="login_index_input">
|
|
|
<i class="icon_login_name"></i>
|
|
|
- <input type="text" placeholder="用户名">
|
|
|
+ <input type="text" name="phone" id="phone" placeholder="用户名">
|
|
|
</p>
|
|
|
<p class="login_index_input">
|
|
|
<i class="icon_login_pass"></i>
|
|
|
- <input type="password" placeholder="密码">
|
|
|
+ <input type="password" name="pwds" id="pwds" placeholder="密码">
|
|
|
</p>
|
|
|
<div class="login_index_enter">
|
|
|
<a href="reg">注册</a>
|
|
|
<a href="forget.html">忘记密码</a>
|
|
|
</div>
|
|
|
- <a class="index_sc_btn" href="index.html">登录</a>
|
|
|
+ <a class="index_sc_btn" id="loginHref" href="javascript:void(0)" onclick="">登录</a>
|
|
|
</div>
|
|
|
#end
|
|
|
</div>
|
|
@@ -290,4 +271,61 @@
|
|
|
|
|
|
</div>
|
|
|
|
|
|
+#define js()
|
|
|
+<script type="text/javascript" src="/assets/layer/layer/layer.js"></script>
|
|
|
+<script type="text/javascript">
|
|
|
+ $(document).ready(function () {
|
|
|
+ $("#loginHref").click(function () {
|
|
|
+ $.ajax({
|
|
|
+ url: "/login/doLogin",
|
|
|
+ dataType: "json",
|
|
|
+ beforeSubmit: function (formData, jqForm, options) {
|
|
|
+ // 表单提交之前回调
|
|
|
+ },
|
|
|
+ data: {phone:$("#phone").val(), pwds:$("#pwds").val(),type:2},
|
|
|
+ success: function (ret) {
|
|
|
+ if (ret.state == "ok") {
|
|
|
+ location.href = ret.returnUrl;
|
|
|
+ } else {
|
|
|
+ layer.msg(ret.msg, {
|
|
|
+ shift: 6
|
|
|
+ , shade: 0.3
|
|
|
+ , time: 7000 // 0 为不自动关闭窗口
|
|
|
+ , offset: "165px"
|
|
|
+ , closeBtn: 1
|
|
|
+ , shadeClose: true
|
|
|
+ }, function () {
|
|
|
+ updateCaptcha(captchaImg, captchaInputId);
|
|
|
+ }
|
|
|
+ );
|
|
|
+ }
|
|
|
+ },
|
|
|
+ error: function (ret) {
|
|
|
+ } // ret.status != 200 时回调
|
|
|
+ , complete: function (ret) {
|
|
|
+ } // 无论是 success 还是 error,最终都会被回调
|
|
|
+ });
|
|
|
+ });
|
|
|
+ });
|
|
|
+
|
|
|
+ $(function () {
|
|
|
+ $(".search_label").click(function () {
|
|
|
+ $(this).children(".input_ys").addClass("input_checked");
|
|
|
+ $(this).siblings().children(".input_ys").removeClass("input_checked");
|
|
|
+ })
|
|
|
+
|
|
|
+ $(".gzh_top").click(function () {
|
|
|
+ if ($(this).hasClass("gzh_topcur")) {
|
|
|
+ $(".erweima_con").slideUp();
|
|
|
+ $(this).removeClass("gzh_topcur");
|
|
|
+ } else {
|
|
|
+ $(".erweima_con").slideDown();
|
|
|
+ $(this).addClass("gzh_topcur");
|
|
|
+ }
|
|
|
+
|
|
|
+ })
|
|
|
+ });
|
|
|
+</script>
|
|
|
+#end
|
|
|
+
|
|
|
#end
|