验证码位置校准;部分交互逻辑调整
This commit is contained in:
parent
52d12e891d
commit
a5dccd5392
@ -68,6 +68,7 @@
|
||||
padding: 0;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
min-height: 190px;
|
||||
}
|
||||
|
||||
/*#user-login-dialog .verify-code input {
|
||||
|
@ -14,8 +14,8 @@
|
||||
console.log.apply(console, arguments);
|
||||
};
|
||||
exports.stationReportApi = "http://srv.12306.liebao.cn/tt/ls2";
|
||||
//exports.trainSuggestApi = "http://srv.12306.liebao.cn/ts";
|
||||
exports.trainSuggestApi = "http://test.fishlee.net/ts.axd";
|
||||
exports.trainSuggestApi = "http://srv.12306.liebao.cn/ts";
|
||||
//exports.trainSuggestApi = "http://test.fishlee.net/ts.axd";
|
||||
exports.onceTransitApi = "http://srv.12306.liebao.cn/tt/tor";
|
||||
exports.chatServerGetAddressApi = "http://12306.liebao.cn/index.php?r=Api/GetRoomKey";
|
||||
exports.sysNoticeUrl = "http://12306.liebao.cn/index.php?r=Api/GetNotificationList";
|
||||
|
@ -134,7 +134,7 @@
|
||||
|
||||
btn.prop("disabled", false);
|
||||
vc.refresh(dlg.find(".verify-code"), true);
|
||||
$("#user-login-dialog input:text:last").val("");
|
||||
//$("#user-login-dialog input:text:last").val("");
|
||||
|
||||
loginTip.content = msg;
|
||||
loginTip.type = "error";
|
||||
|
@ -30,6 +30,7 @@
|
||||
|
||||
//imageEle.css({ "background-image": "url(/images/loading.gif)", "background-size": "auto" });
|
||||
imageEle.attr({ "src": "/images/loading.gif" });
|
||||
imageEle.trigger("verifyCodeOnLoad");
|
||||
ajax.loadImage(config.url, config.refer, function (e) {
|
||||
if (this.url.indexOf("base64,eyJ2YWxpZGF0ZU1lc3") !== -1) {
|
||||
//网络繁忙
|
||||
@ -60,7 +61,7 @@
|
||||
if (delay) {
|
||||
target.find("img").attr({ "src": "/images/loading.gif" });
|
||||
//target.find("span").css({ "background-image": "url(/images/loading.gif)", "background-size": "auto" });
|
||||
setTimeout(reloadCode, 2000);
|
||||
setTimeout(reloadCode, 1);
|
||||
} else {
|
||||
reloadCode();
|
||||
}
|
||||
|
@ -2,9 +2,11 @@
|
||||
|
||||
|
||||
var init = function () {
|
||||
$(document).on("verifyCodeLoaded", "img.vc-touchclick", initEle)
|
||||
.on("click", "img.vc-touchclick", touchClick)
|
||||
.on("click", "span.vc-touchclick-marker", removeClickMarker);
|
||||
$(document)
|
||||
.on("verifyCodeLoaded", "img.vc-touchclick", initEle)
|
||||
.on("verifyCodeOnLoad", "img.vc-touchclick", initEle)
|
||||
.on("click", "img.vc-touchclick", touchClick)
|
||||
.on("click", "span.vc-touchclick-marker", removeClickMarker);
|
||||
}
|
||||
|
||||
var initEle = function () {
|
||||
@ -34,8 +36,13 @@
|
||||
var img = $(this);
|
||||
var parent = img.parent();
|
||||
var pos = { x: e.offsetX, y: e.offsetY };
|
||||
var imgPos = img.position();
|
||||
var realPos = { x: pos.x, y: pos.y - 30 };
|
||||
var poslist = img.data("poslist");
|
||||
var imgPos = img.position();
|
||||
|
||||
if (realPos.x <= 0 || realPos.y <= 0 || poslist.length >= 20)
|
||||
return;
|
||||
|
||||
//var strlist = img.data("strlist");
|
||||
|
||||
//查找是否已经点击过了
|
||||
@ -53,11 +60,11 @@
|
||||
// return;
|
||||
//}
|
||||
|
||||
poslist.push(pos);
|
||||
poslist.push(realPos);
|
||||
|
||||
//add marker
|
||||
var marker = $("<span class='vc-touchclick-marker' style='top:" + (pos.y + imgPos.top - 16) + "px; left:" + (pos.x + imgPos.left - 16) + "px;'></span>");
|
||||
marker.data("pos", pos);
|
||||
marker.data("pos", realPos);
|
||||
parent.append(marker);
|
||||
|
||||
//set input
|
||||
|
Loading…
Reference in New Issue
Block a user