Commit fd096e79 by 施宇

Merge branch 'master' of http://119.23.72.7/shiyu/icsales

parents 937d315d 8aa1f4d2
......@@ -91,3 +91,4 @@
.search_content .search_condition .condition_content .condition_right_content div:hover {
color: #0D84D1;
}
/*# sourceMappingURL=search.css.map */
\ No newline at end of file
{"version":3,"sources":["search.less"],"names":[],"mappings":"AAAA,eACI;EACI,yBAAA;;AAFR,eAII;EACI,YAAA;EACA,mBAAA;;AANR,eAII,gBAGI;EACI,YAAA;EACA,sBAAA;EACA,qDAAA;EACA,YAAA;;AAXZ,eAII,gBAGI,YAMI;EACI,YAAA;EACA,YAAA;EACA,8BAAA;EACA,kBAAA;EACA,sBAAA;;AAlBhB,eAII,gBAGI,YAMI,WAOI;EACI,eAAA;EACA,kBAAA;EACA,QAAA;EACA,cAAA;EACA,UAAA;;AAzBpB,eAII,gBAGI,YAMI,WAeI;EACI,YAAA;EACA,WAAA;EACA,eAAA;EACA,cAAA;EACA,iBAAA;;AAjCpB,eAII,gBAGI,YA+BI;EACI,YAAA;EACA,8BAAA;;AAxChB,eA6CI;EACI,kBAAA;EACA,sBAAA;EACA,oBAAA;;AAhDR,eA6CI,kBAII;EACI,gCAAA;EACA,mBAAA;;AAnDZ,eA6CI,kBAII,YAII;EACI,gBAAA;EACA,eAAA;EACA,cAAA;EACA,eAAA;;AAEA,eAdZ,kBAII,YAII,GAMK;EACG,cAAA;EACA,gBAAA;;AAGJ,eAnBZ,kBAII,YAII,GAWK;EACG,iBAAA;;AAjEpB,eA6CI,kBAyBI;EACI,eAAA;EACA,cAAA;EACA,kBAAA;EACA,gBAAA;;AA1EZ,eA6CI,kBAyBI,mBAMI;EACI,cAAA;EACA,kBAAA;EACA,MAAA;EACA,OAAA;EACA,SAAA;;AAjFhB,eA6CI,kBAyBI,mBAeI;EACI,iBAAA;;AAtFhB,eA6CI,kBAyBI,mBAeI,yBAGI;EACI,gBAAA;EACA,kBAAA;EACA,eAAA;EACA,oBAAA;;AAEA,eAjDhB,kBAyBI,mBAeI,yBAGI,IAMK;EACG,yBAAA;EACA,WAAA;EACA,kBAAA;;AAGJ,eAvDhB,kBAyBI,mBAeI,yBAGI,IAYK;EACG,cAAA","file":"search.css"}
\ No newline at end of file
{"version":3,"sources":["search.less"],"names":[],"mappings":"AAAA,eACI;EACI,yBAAA;;AAFR,eACI,WAEI;EACI,cAAA;;AAJZ,eAOI;EACI,YAAA;EACA,mBAAA;;AATR,eAOI,gBAGI;EACI,YAAA;EACA,sBAAA;EACA,qDAAA;EACA,YAAA;;AAdZ,eAOI,gBAGI,YAMI;EACI,YAAA;EACA,YAAA;EACA,8BAAA;EACA,kBAAA;EACA,sBAAA;;AArBhB,eAOI,gBAGI,YAMI,WAOI;EACI,eAAA;EACA,kBAAA;EACA,QAAA;EACA,cAAA;EACA,UAAA;;AA5BpB,eAOI,gBAGI,YAMI,WAeI;EACI,YAAA;EACA,WAAA;EACA,eAAA;EACA,cAAA;EACA,iBAAA;;AApCpB,eAOI,gBAGI,YA+BI;EACI,YAAA;EACA,8BAAA;;AA3ChB,eAgDI;EACI,kBAAA;EACA,sBAAA;EACA,oBAAA;;AAnDR,eAgDI,kBAII;EACI,gCAAA;EACA,mBAAA;;AAtDZ,eAgDI,kBAII,YAII;EACI,gBAAA;EACA,eAAA;EACA,cAAA;EACA,eAAA;;AAEA,eAdZ,kBAII,YAII,GAMK;EACG,cAAA;EACA,gBAAA;;AAGJ,eAnBZ,kBAII,YAII,GAWK;EACG,iBAAA;;AApEpB,eAgDI,kBAyBI;EACI,eAAA;EACA,cAAA;EACA,kBAAA;EACA,gBAAA;;AA7EZ,eAgDI,kBAyBI,mBAMI;EACI,cAAA;EACA,kBAAA;EACA,MAAA;EACA,OAAA;EACA,SAAA;;AApFhB,eAgDI,kBAyBI,mBAeI;EACI,iBAAA;;AAzFhB,eAgDI,kBAyBI,mBAeI,yBAGI;EACI,gBAAA;EACA,kBAAA;EACA,eAAA;EACA,oBAAA;;AAEA,eAjDhB,kBAyBI,mBAeI,yBAGI,IAMK;EACG,yBAAA;EACA,WAAA;EACA,kBAAA;;AAGJ,eAvDhB,kBAyBI,mBAeI,yBAGI,IAYK;EACG,cAAA","file":"search.css"}
\ No newline at end of file
......@@ -76,7 +76,15 @@
}
});
});
} else if (res.errcode == 110001) {
} else if(res.errcode === 501){
layer.msg(res.errmsg,function () {
window.location.href = home_url + '/login';
});
}else if (res.errcode == 110001) {
layui.laytpl(getTpl).render([], function (html) {
......
......@@ -20,7 +20,7 @@
var str = '期货';
data.value == '期货' ? str='期货':str='现货';
data.value == '现货' ? str='现货':str='期货';
var getTpl = deliveryHtml.innerHTML;
......
......@@ -287,7 +287,7 @@
IcController.getData(apis.resetPassword, 'POST', params, function (res) {
if (res.err_msg == 0) {
if (res.err_code == 0) {
$(".status").find('li').eq(2).addClass('curr').siblings('li').removeClass('curr');
......
......@@ -98,7 +98,6 @@
}
},
calcForm: function (ele, type) {
var $mobile = $(ele).find('input[name="mobile"]'),
$password = $(ele).find('input[name="password"]'),
......@@ -134,7 +133,7 @@
}
if (!$code.val() && type ===2) {
if (!$code.val() && type === 2) {
$code.parent('.input-wrap').addClass('error');
......@@ -257,24 +256,25 @@
});
//密码提交
layui.form.on('submit(login)', function (data) {
if (opt.calcForm(data.form, 1)) {
//验证码提交
layui.form.on('submit(verifyCode)', function (data) {
if (opt.calcForm(data.form, 2)) {
$(data.elem).addClass("layui-btn-disabled");
if (!opt.isClick) {
opt.isClick = true;
IcController.getData(apis.authlogin, 'POST', data.field, function (res) {
IcController.getData(apis.authMobilelogin, 'POST', data.field, function (res) {
if (res.err_code == 0) {
//注入token
Util.setCookie('token', res.data.access_token, 1, cookieHostname);
window.location.href = home_url + '/homes';
} else {
layer.msg(res.err_msg);
......@@ -283,28 +283,26 @@
$(data.elem).removeClass("layui-btn-disabled");
}
});
}
} else {
}
});
//验证码提交
layui.form.on('submit(verifyCode)', function (data) {
//密码提交
layui.form.on('submit(login)', function (data) {
if (opt.calcForm(data.form, 1)) {
if (opt.calcForm(data.form, 2)) {
$(data.elem).addClass("layui-btn-disabled");
if (!opt.isClick) {
opt.isClick = true;
IcController.getData(apis.authMobilelogin, 'POST', data.field, function (res) {
IcController.getData(apis.authlogin, 'POST', data.field, function (res) {
if (res.err_msg == 0) {
if (res.err_code == 0) {
//注入token
Util.setCookie('token', res.data.access_token, 1, cookieHostname);
......@@ -319,16 +317,29 @@
$(data.elem).removeClass("layui-btn-disabled");
}
});
}
} else {
}
});
$("body").keydown(function () {
if (event.keyCode == "13") {
if ($(".layui-form").is(":visible")) {
$(".layui-form").find('a.btn').trigger('click');
}
}
});
return this;
},
}
}, $(function () {
LoginController.init();
})
......
......@@ -267,7 +267,7 @@
IcController.getData(apis.authRegister, 'POST', data.field, function (res) {
if (res.err_msg == 0) {
if (res.err_code == 0) {
//注入token
Util.setCookie('token', res.access_token, 1, cookieHostname);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment