Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
增加功能:
1.租赁账号在用户信息中显示
2.充值功能
3.扣费功能
4.安全系统(在涉及用户信息安全的界面添加了登录状态识别)
5.优化服务器
  • Loading branch information
Json-WJK authored Oct 29, 2018
1 parent f90f7bc commit 21c5bc3
Show file tree
Hide file tree
Showing 10 changed files with 636 additions and 18 deletions.
292 changes: 292 additions & 0 deletions public/css/topup.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,292 @@
section{
width:1100px;
margin:0 auto;
display:flex;
justify-content:space-around;
}
/*左侧列表-总体布局*/
.l-list{
background:#fff;
width:155px;
font-size:14px;
margin-right:5px;
}
.l-heng{
background:#eee;
height:1px;
width:80%;
margin:0 auto;
}
.l-list>a{
display:block;
height:42px;
line-height:42px;
font-weight:bold;
box-sizing:border-box;
padding-left:35px;
}
.l-list>a:nth-child(1){
color:rgb(247, 71, 62);
}
.l-list>ul>li{
height:32px;
line-height:32px;
box-sizing:border-box;
padding-left:25px;
}
/*左侧列表背景图*/
.l-imgs{
background:url(../zuhao/menuPerson.png) no-repeat;
}
.l-a1{
background-position:-143px 0;
}
.l-a2{
background-position:10px -42px;
}
.l-a3{
background-position:10px -84px;
}
.l-a4{
background-position:10px -126px;
}
.l-a5{
background-position:10px -168px;
}
.l-a6{
background-position:10px -210px;
}
.l-a7{
background-position:10px -252px;
}
.l-a8{
background-position:10px -294px;
}
.l-a9{
background-position:10px -336px;
}

/*右侧个人资料*/
.r-data{
width:930px;
background:#fff;
height:158px;
display:flex;
justify-content: space-around;
color:#555;
font-size:14px;
position: relative;
box-sizing:border-box;
padding:30px 20px;
}
/*头像*/
.r-data>div:nth-child(1){
height:97px;
width:96px;
border-radius:50%;
overflow:hidden;
}
/*账号名称及安全*/
.r-data>div:nth-child(2){
font-size:13px;
}
.r-data>div:nth-child(2)>p{
margin-bottom:12px;
}
.r-data>div:nth-child(2)>p:nth-child(1){
font-weight:bold;
}
/*安全等级条*/
.r-bar{
display:inline-block;
width:50px;
height:8px;
background:#eee;
margin-right:5px;
position: relative;
}
.r-bar>b{
display:inline-block;
width:40px;
height:8px;
background:#04DB04;
position: absolute;
}
/*信誉下侧四张图片*/
.r-dataImgsBg{
display: inline-block;
width:21px;
height:21px;
background:url(../zuhao/psonHZ_13.png) no-repeat;
}
.r-dataImgs1{
background-position:0 0;
}
.r-dataImgs2{
background-position:0 -30px;
}
.r-dataImgs3{
background-position:0 -60px;
}
.r-dataImgs4{
background-position:0 -90px;
}
/*第三部分*/
.r-data>div:nth-child(3){
width:575px;
}
/*个人信息上半部分*/
.balance{
display:flex;
width:605px;
height:50px;
flex-wrap: nowrap;
text-align:center;
margin-left:30px;
}
.r-dataShu{
border-left:1px solid #eee;
}
.balance>div{
margin:0 15px;
}
.balance>div>span{
color:#f96658;
}
.balance>div:last-child{
width:70px;
height:28px;
line-height:28px;
border-radius:20px;
box-sizing:border-box;
padding-left:15px;
background:#f96658 url(../zuhao/psonHZ_57.png) no-repeat 8px 5px;
}
.balance>div:last-child>a{
display: inline-block;
width:100%;
height:28px;
line-height:28px;
border-radius:20px;
color:#fff;
font-size:13px;
}
.balance>img:nth-child(1){
position:absolute;
right:0;
top:0;
}
/*个人信息下半部分*/
.r-status>span{
display: inline-block;
width:185px;
height:42px;
line-height:42px;
text-align:center;
background:#f6f6f6;
}
.r-status>span>u{
color:#f96658;
}

/*账户当前余额*/
.r-t{
color:#555;
margin-top:15px;
font-size:13px;
}
.r-t>.r-t-balance{
height:60px;
width:100%;
background:#fff;
padding-top:20px;
}
.r-t>.r-t-balance>p{
height:40px;
width:95%;
background:#f5f5f5;
margin:0 auto;
box-sizing:border-box;
padding-left:20px;
}
.r-t>.r-t-balance>p>span{
display:inline-block;
height:40px;
line-height:40px;
margin-right:50px;
}

/*选择充值方式*/
.zfb,.wx{
display:inline-block;
width:124px;
height:41px;
background:#fff;
text-align:center;
line-height:41px;
font-weight:bold;
margin:15px 5px -1px 10px;
cursor: pointer;
border:1px solid #ddd;
border-bottom:1px solid #df3234;
}
.hover{
border:1px solid #df3234;
border-bottom:1px solid #fff;
}
/*充值*/
.r-t-topupa{
width:930px;
height:280px;
background:#FFF;
box-sizing:border-box;
border:1px solid #df3234;
}
.r-t-topupa>img{
display: block;
margin:20px 0 20px 40px;
}
.r-t-topupa>div:nth-child(2){
width:745px;
height:55px;
background:#f5f5f5;
margin:0 auto;
line-height:55px;
}
.r-t-topupa input{
width:100px;
height:16px;
border:1px solid #ddd;
}
.r-t-topupa>div:nth-child(3){
width:745px;
border-top:1px solid #ccc;
margin:30px auto;
}
.r-t-topupa>div:nth-child(4){
width:745px;
margin:20px auto;
height:60px;
}
.r-t-topupa>div:nth-child(4)>span:nth-child(1){
float: left;
background:#eb3f41;
width:120px;
height:40px;
text-align:center;
line-height:40px;
color:#fff;
border-radius:10px;
}
.r-t-topupa>div:nth-child(4)>span:nth-child(2){
float: left;
height:40px;
line-height:40px;
margin:10px 0 0 30px;
}
.r-t-topupa>div:nth-child(4)>span:nth-child(2)>b{
color:#eb3f41;
}
#rtopup{
cursor: pointer;
}
23 changes: 21 additions & 2 deletions public/css/user.css
Original file line number Diff line number Diff line change
Expand Up @@ -158,12 +158,19 @@ section{
height:28px;
line-height:28px;
border-radius:20px;
color:#fff;
font-size:13px;
box-sizing:border-box;
padding-left:15px;
background:#f96658 url(../zuhao/psonHZ_57.png) no-repeat 8px 5px;
}
.balance>div:last-child>a{
display: inline-block;
width:100%;
height:28px;
line-height:28px;
border-radius:20px;
color:#fff;
font-size:13px;
}
.balance>img:nth-child(1){
position:absolute;
right:0;
Expand Down Expand Up @@ -308,6 +315,15 @@ section{
text-align:center;
line-height:28px;
}
.zh-list>span:last-child>a{
display:inline-block;
width:90px;
height:28px;
color:#0ea0e0;
border-radius:15px;
text-align:center;
line-height:28px;
}
.zh-list>div:nth-child(2),
.zh-list>div:nth-child(3)
{
Expand All @@ -319,3 +335,6 @@ section{
.zh-list>span:nth-child(5){
margin:45px 0 0 10px;
}
#rtopup{
cursor: pointer;
}
12 changes: 10 additions & 2 deletions public/js/account-detail.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,14 @@ $(function(){
)
}
/*请求账号租金详情 */
var myDate = new Date();
var m=myDate.getMinutes();
var h=myDate.getHours();
var date=h+":"+m
$.ajax({
url:"http://localhost:1997/detail/details",
type:"get",
data:{game_id},
data:{game_id,date},
dataType:"json",
success:function(res){
var html="";
Expand Down Expand Up @@ -72,15 +76,18 @@ $(function(){
success:function(res){
/*立即租号 */
$("input[type=button]").click(function(){
var url1=location.pathname.slice(1);
var url2=location.search.slice(1)
if(res.ok==0) location.href="verify.html"+"?"+url1+"?"+url2;
if(res.ok==1) location.href=`order.html?game_id=${game_id}`;
else{location.href="verify.html"+location.search};
})
}
})

}
})
//推荐账号列表

$.ajax({
url:"http://localhost:1997/search/recommendlist",
type:"get",
Expand Down Expand Up @@ -114,6 +121,7 @@ $(function(){
element.innerHTML=html;
})

/*左侧图片 */
$.ajax({
url:"http://localhost:1997/detail/gamegallery",
type:"get",
Expand Down
Loading

0 comments on commit 21c5bc3

Please sign in to comment.