aadb19d6 by 任超

style:注销

1 parent 3d4146d0
......@@ -110,7 +110,7 @@ div.top-logo .top_logo_search {
float: left;
width: 350px;
position: relative;
margin-left: 385px;
margin-left: 338px;
}
div.top-logo .top_logo_search input {
border-radius: 50px;
......@@ -163,7 +163,9 @@ div.top-logo .top_logo_search i {
height: 13px;
line-height: 12px;
}
#cancellation {
cursor: pointer;
}
div.navigation {
text-align: center;
height: 59px;
......
......@@ -180,3 +180,6 @@
text-align: center;
margin:30px 0;
}
.business {
cursor: pointer;
}
\ No newline at end of file
......
......@@ -40,6 +40,9 @@ document.writeln(" </li>");
document.writeln(" <li>");
document.writeln(" <p class='PersonLogin'>登录</p>");
document.writeln(" </li>");
document.writeln(" <li>");
document.writeln(" <p id='cancellation'>注销</p>");
document.writeln(" </li>");
document.writeln(" </ul>");
document.writeln(" </div>");
document.writeln(" </div>");
......
var localhostPaht = curWwwPath.substring(0, pos);
function login() {
layui.use('layer', function () {
layer.open({
......@@ -40,6 +41,24 @@ $(document).on('click', '#loginButton', function () {
clicklogin(userLoginRequest)
layer.closeAll()
});
// cancellation
$(document).on('click', '#cancellation', function () {
delCookie();
window.open('' + localhostPaht + '/index.html', '_self')
});
function delCookie () {
var keys = document.cookie.match(/[^ =;]+(?==)/g)
if (keys) {
for (var i = keys.length; i--;) {
document.cookie = keys[i] + '=0;path=/;expires=' + new Date(0).toUTCString() // 清除当前域名下的,例如:m.ratingdog.cn
document.cookie = keys[i] + '=0;path=/;domain=' + document.domain + ';expires=' + new Date(0).toUTCString() // 清除当前域名下的,例如 .m.ratingdog.cn
document.cookie = keys[i] + '=0;path=/;domain=ratingdog.cn;expires=' + new Date(0).toUTCString() // 清除一级域名下的或指定的,例如 .ratingdog.cn
}
}
}
$(function () {
$('.PersonLogin').html(getCookie('myCookie').username)
if (getCookie('myCookie').username) {
......
......@@ -7,9 +7,13 @@ layui.use('element', function () {
});
});
$(function () {
_initData()
$('#zjhm').text(getCookie().zjhm)
$('#username').text(getCookie().username )
_initData();
$('#zjhm').text(getCookie().zjhm);
$('#username').text(getCookie().username);
$(document).on("click", ".business", function (e) {
window.open("./businessGuideDeatil.html?id=" + $(this).attr('ywid') + "")
})
})
// 获取列表信息
function _initData(currentPage=1) {
......@@ -53,7 +57,7 @@ function _initData(currentPage=1) {
li += '<ul class="item_info">'
li += '<li><span>预约人:</span><p>'+records[i].name+'</p></li>'
li += '<li><span>办事大厅:</span><p>'+records[i].organizationName+'</p></li>'
li += '<li><span>办理业务类型:</span><p>'+records[i].businessName+'</p><a href="">办事指南</a></li>'
li += '<li><span>办理业务类型:</span><p>'+records[i].businessName+'</p><a class="business" ywid="'+records[i].ywid+'">办事指南</a></li>'
li += '<li><span>预约日期:</span><p>'+records[i].reserveTime+'</p></li>'
li += '<li><span>预约流水号:</span><p>'+records[i].reservationNumber+'</p></li>'
li += '</ul>'
......@@ -93,6 +97,7 @@ function paged(pageCount, curr) {
});
})
}
var dataList = {
"userid":getCookie().userid
};
\ No newline at end of file
......