@ -0,0 +1,354 @@ |
||||
<!DOCTYPE html> |
||||
<html lang="en"> |
||||
|
||||
<head> |
||||
<meta charset="UTF-8"> |
||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=0"> |
||||
<title>Payment History</title> |
||||
|
||||
<!-- Google font file. If you want you can change. --> |
||||
<link href="https://fonts.googleapis.com/css?family=Nunito:300,400,600,700,900" rel="stylesheet"> |
||||
|
||||
<!-- Fontawesome font file css --> |
||||
<link rel="stylesheet" type="text/css" href="css/font-awesome.min.css"> |
||||
|
||||
<!-- Animate css file for css3 animations. for more : https://daneden.github.io/animate.css --> |
||||
<!-- Only use animate action. If you dont use animation, you don't have to add.--> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/css/animate.css"> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/css/cryptocoins.css"> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/plugins/c3-chart/c3.css"> |
||||
|
||||
<!-- Template global css file. Requared all pages --> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/css/global.style.css"> |
||||
|
||||
<!-- Swiper slider css file --> |
||||
<link rel="stylesheet" href="https://cdn.yimian.xyz/smart-settlement/css/swiper.min.css"> |
||||
|
||||
<!--turbo slider plugin css file --> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/css/bootstrap.min.css"> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/plugins/turbo-slider/turbo.css"> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/shaky/shaky.css"> |
||||
<script>var block_aplayer = true;</script> |
||||
<script type="text/javascript" src="https://cdn.yimian.xyz/ushio-js/ushio-head.min.js"></script> |
||||
|
||||
</head> |
||||
|
||||
<body> |
||||
|
||||
<div class="wrapper "> |
||||
<div class="nav-menu"> |
||||
<nav class="menu"> |
||||
<!-- Menu navigation start --> |
||||
<div class="nav-container"> |
||||
<ul class="main-menu"> |
||||
<li class=""> |
||||
<a href="index.html"><img src="https://cdn.yimian.xyz/smart-settlement/img/content/icons/1.png" alt=""><strong class="special">Dashboard</strong> </a> |
||||
</li> |
||||
<li class="active"> |
||||
<a href="buy-sell.html"><img src="https://cdn.yimian.xyz/smart-settlement/img/content/icons/6.png" alt=""><strong class="special">History Payment</strong> </a> |
||||
</li> |
||||
<li class=""> |
||||
<a onclick="javascript:logout();" href="#" data-loader="show"><img src="https://cdn.yimian.xyz/smart-settlement/img/content/icons/7.png" alt=""><strong>Log out</strong></a> |
||||
</li> |
||||
</ul> |
||||
</div> |
||||
<!-- Menu navigation end --> |
||||
</nav> |
||||
</div> |
||||
<div class="wrapper-inline"> |
||||
<!-- Header area start --> |
||||
<header class="no-background"> <!-- extra class no-background --> |
||||
|
||||
<a class="go-back-link" href="javascript:history.back();"><i class="fa fa-arrow-left"></i></a> |
||||
<div class="search-button" data-search="open"> |
||||
<img id="no-icon" src="img/content/notification-no.png" class="not-icon1" alt=""> |
||||
<img id="no-icon2" src="img/content/notification2-no.png" class="not-icon2" alt=""> |
||||
</div> |
||||
|
||||
<div class="navi-menu-button"> |
||||
<em></em> |
||||
<em></em> |
||||
<em></em> |
||||
</div> |
||||
|
||||
</header> |
||||
<!-- Header area end --> |
||||
|
||||
<!--NOTIFICATION BOX CONTENT START--> |
||||
<div class="search-form"> |
||||
<span class="close-search-form" data-search="close"><i class="fa fa-times"></i> </span> |
||||
<form> |
||||
<div class="search-input"> |
||||
<br/> |
||||
</div> |
||||
</form> |
||||
<ul class="notification-list list-unstyled" id="no-content"> |
||||
</ul> |
||||
</div> |
||||
<!--NOTIFICATION BOX CONTENT END--> |
||||
|
||||
|
||||
<!-- Page content start --> |
||||
<main class="margin mt-0"> |
||||
|
||||
<div class="dash-balance"> |
||||
<div class="dash-content relative"> |
||||
<h3 class="w-text">ERP for CP Home</h3> |
||||
<div class="notification"> |
||||
<h3 class="w-text" id="usr">xxx</h3> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
|
||||
<section class="container"> |
||||
<h4 class="title-main">Recent Transactions</h4> |
||||
<ul class="transaction-list list-unstyled" id="account-events"> |
||||
</ul> |
||||
</section> |
||||
|
||||
<footer> |
||||
<div class="container"> |
||||
<ul> |
||||
<li><a id="ushio-blog" href="https://www.eee.dog"><i class="fa fa-home"></i></a></li> |
||||
<li><a href="https://github.com/iotcat"><i class="fa fa-github"></i></a></li> |
||||
<li><a href="mailto:i@yimian.xyz"><i class="fa fa-envelope"></i></a></li> |
||||
<li><a href="https://www.eee.dog/feed"><i class="fa fa-rss"></i></a></li> |
||||
</ul> |
||||
<p>© 2018-<script type="text/javascript">document.write(new Date().getFullYear());</script> Made with <span class="shaky"><i style="color:red;" class="fa fa-heart"></i></span> by <a id="ushio-tome" href="https://iotcat.me">iotcat</a></p> |
||||
</div> |
||||
</footer> |
||||
</main> |
||||
<!-- Page content end --> |
||||
</div> |
||||
</div> |
||||
|
||||
<!--Page loader DOM Elements. Requared all pages--> |
||||
<div class="sweet-loader"> |
||||
<div class="box"> |
||||
<div class="circle1"></div> |
||||
<div class="circle2"></div> |
||||
<div class="circle3"></div> |
||||
</div> |
||||
</div> |
||||
|
||||
<script type="text/javascript" src="https://cdn.yimian.xyz/ushio-js/ushio-footer.min.js"></script> |
||||
|
||||
<!-- JQuery library file. requared all pages --> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/js/jquery-3.2.1.min.js"></script> |
||||
|
||||
<!-- Swiper JS --> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/js/swiper.min.js"></script> |
||||
|
||||
<!-- Template global script file. requared all pages --> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/js/global.script.js"></script> |
||||
|
||||
<script type="text/javascript"> |
||||
|
||||
var usr = null; |
||||
var usr_arr = ['liu', 'yang', 'li', 'jia', 'zheng']; |
||||
|
||||
if(cookie.get('usr') == null){ |
||||
usr=prompt("please input your surname",""); |
||||
cookie.set("usr", usr); |
||||
}else{ |
||||
usr = cookie.get("usr"); |
||||
} |
||||
|
||||
$('#usr').html(usr); |
||||
|
||||
$.post('https://settlement.yimian.xyz/api/getDetail.php', function(res){ |
||||
res = JSON.parse(res); |
||||
var s = ''; |
||||
res.data.forEach(function(i, index){ |
||||
if(index < res.data.length - 1){ |
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<img class="img-xs" src="https://cdn.yimian.xyz/smart-settlement/img/content/coin3.png" alt="coin image"> |
||||
<div class="ml-10"> |
||||
<h4 class="coin-name">payment`; |
||||
s += ' - ' + i.usr; |
||||
s += `</h4> |
||||
<small class="text-muted">`; |
||||
s += i.datetime; |
||||
s += `</small> |
||||
</div> |
||||
</div> |
||||
<div> |
||||
`; |
||||
s += `<small class="d-block mb-0 txt-red">£-`+Number(i.val).toFixed(2) + `</small>`; |
||||
|
||||
s += ` |
||||
<small class="text-muted d-block"><a href='`+i.img+`'>see invoice</a></small> |
||||
</div> |
||||
</div> |
||||
</li> |
||||
`; |
||||
} |
||||
|
||||
$('#account-events').html(s); |
||||
}); |
||||
}); |
||||
|
||||
|
||||
|
||||
/* notification func */ |
||||
|
||||
function timeago(dateTimeStamp){ //dateTimeStamp是一个时间毫秒,注意时间戳是秒的形式,在这个毫秒的基础上除以1000,就是十位数的时间戳。13位数的都是时间毫秒。 |
||||
var minute = 1000 * 60; //把分,时,天,周,半个月,一个月用毫秒表示 |
||||
var hour = minute * 60; |
||||
var day = hour * 24; |
||||
var week = day * 7; |
||||
var halfamonth = day * 15; |
||||
var month = day * 30; |
||||
var now = new Date().getTime(); //获取当前时间毫秒 |
||||
var diffValue = now - dateTimeStamp;//时间差 |
||||
|
||||
if(diffValue < 0){ |
||||
return; |
||||
} |
||||
var minC = diffValue/minute; //计算时间差的分,时,天,周,月 |
||||
var hourC = diffValue/hour; |
||||
var dayC = diffValue/day; |
||||
var weekC = diffValue/week; |
||||
var monthC = diffValue/month; |
||||
if(monthC >= 1 && monthC <= 3){ |
||||
result = " " + parseInt(monthC) + "month ago" |
||||
}else if(weekC >= 1 && weekC <= 3){ |
||||
result = " " + parseInt(weekC) + "week ago" |
||||
}else if(dayC >= 1 && dayC <= 6){ |
||||
result = " " + parseInt(dayC) + "day ago" |
||||
}else if(hourC >= 1 && hourC <= 23){ |
||||
result = " " + parseInt(hourC) + "hours ago" |
||||
}else if(minC >= 1 && minC <= 59){ |
||||
result =" " + parseInt(minC) + "minutes ago" |
||||
}else if(diffValue >= 0 && diffValue <= minute){ |
||||
result = "just now" |
||||
}else { |
||||
var datetime = new Date(); |
||||
datetime.setTime(dateTimeStamp); |
||||
var Nyear = datetime.getFullYear(); |
||||
var Nmonth = datetime.getMonth() + 1 < 10 ? "0" + (datetime.getMonth() + 1) : datetime.getMonth() + 1; |
||||
var Ndate = datetime.getDate() < 10 ? "0" + datetime.getDate() : datetime.getDate(); |
||||
var Nhour = datetime.getHours() < 10 ? "0" + datetime.getHours() : datetime.getHours(); |
||||
var Nminute = datetime.getMinutes() < 10 ? "0" + datetime.getMinutes() : datetime.getMinutes(); |
||||
var Nsecond = datetime.getSeconds() < 10 ? "0" + datetime.getSeconds() : datetime.getSeconds(); |
||||
result = Nyear + "-" + Nmonth + "-" + Ndate |
||||
} |
||||
return result; |
||||
} |
||||
|
||||
function confirm(id){ |
||||
$.post('https://settlement.yimian.xyz/api/?type=confirm&id='+id, function(res){ |
||||
notice(); |
||||
}); |
||||
} |
||||
|
||||
|
||||
function notice(){ |
||||
|
||||
|
||||
$.post('https://settlement.yimian.xyz/api/getCurrent.php', {'usr': usr}, function(res){ |
||||
res = JSON.parse(res); |
||||
var s = ''; |
||||
|
||||
if(!res.data.length){ |
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<div class=""> |
||||
<h5 class="coin-name">You have NO notifications!!</h5> |
||||
</div> |
||||
</div> |
||||
<div> |
||||
<a href=""></a> |
||||
</div> |
||||
</div> |
||||
</li>`; |
||||
$('#no-content').html(s); |
||||
$("#no-icon").attr("src", 'https://cdn.yimian.xyz/smart-settlement/img/content/notification-no.png'); |
||||
$("#no-icon2").attr("src", 'https://cdn.yimian.xyz/smart-settlement/img/content/notification2-no.png'); |
||||
return; |
||||
} |
||||
|
||||
|
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<div class=""> |
||||
<h5 class="coin-name">Your last `; |
||||
|
||||
s += res.data.length; |
||||
s += ` notifications</h5> |
||||
</div> |
||||
</div> |
||||
<div> |
||||
<a href=""></a> |
||||
</div> |
||||
</div> |
||||
</li>`; |
||||
|
||||
res.data.forEach(function(item){ |
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<div class="notice-icon `; |
||||
if(item.usr_to == usr) s += `available`; |
||||
if(item.usr_from == usr) s += `away`; |
||||
|
||||
s += `"> |
||||
<i class="fa fa-`; |
||||
if(item.usr_to == usr) s += `check`; |
||||
if(item.usr_from == usr) s += `clock-o`; |
||||
s += `"></i> |
||||
</div> |
||||
<div class="ml-10"> |
||||
<h4 class="coin-name">`; |
||||
|
||||
if(item.usr_to == usr) s += `You will Get £50 from `+ item.usr_from + ` <button style="color: green;" onClick="javascript:confirm(`+item.id+`);">Confirm to Recived</button>`; |
||||
if(item.usr_from == usr) s += `Please Give £50 to `+ item.usr_to; |
||||
|
||||
s += `</h4> |
||||
<small class="text-muted">`; |
||||
s += timeago(new Date(item.datetime.replace(/-/g, '/')).getTime()); |
||||
s += `</small> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</li>`; |
||||
}); |
||||
|
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<a href="" class="text-muted">The end of all notifications</a> |
||||
</div> |
||||
</div> |
||||
</li>`; |
||||
|
||||
$('#no-content').html(s); |
||||
$("#no-icon").attr("src", 'https://cdn.yimian.xyz/smart-settlement/img/content/notification-yes.png'); |
||||
$("#no-icon2").attr("src", 'https://cdn.yimian.xyz/smart-settlement/img/content/notification2-yes.png'); |
||||
}); |
||||
}; |
||||
|
||||
notice(); |
||||
|
||||
/* log out */ |
||||
function logout(){ |
||||
cookie.del('usr'); |
||||
cookie.del('val'); |
||||
location.reload(); |
||||
} |
||||
|
||||
</script> |
||||
|
||||
|
||||
</body> |
||||
|
||||
</html> |
After Width: | Height: | Size: 26 KiB |
After Width: | Height: | Size: 29 KiB |
After Width: | Height: | Size: 43 KiB |
After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 567 B |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 884 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1019 B |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 892 B |
After Width: | Height: | Size: 393 B |
After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 1019 B |
After Width: | Height: | Size: 16 KiB |
After Width: | Height: | Size: 9.4 KiB |
After Width: | Height: | Size: 24 KiB |
After Width: | Height: | Size: 24 KiB |
After Width: | Height: | Size: 20 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 9.5 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 66 KiB |
After Width: | Height: | Size: 8.4 KiB |
After Width: | Height: | Size: 9.8 KiB |
After Width: | Height: | Size: 8.6 KiB |
After Width: | Height: | Size: 9.8 KiB |
After Width: | Height: | Size: 13 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 10 KiB |
After Width: | Height: | Size: 7.5 KiB |
After Width: | Height: | Size: 19 KiB |
After Width: | Height: | Size: 55 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 417 B |
After Width: | Height: | Size: 567 B |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 884 B |
After Width: | Height: | Size: 1.3 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.2 KiB |
After Width: | Height: | Size: 1.6 KiB |
After Width: | Height: | Size: 892 B |
After Width: | Height: | Size: 393 B |
After Width: | Height: | Size: 1.5 KiB |
After Width: | Height: | Size: 1019 B |
After Width: | Height: | Size: 4.2 KiB |
After Width: | Height: | Size: 4.5 KiB |
After Width: | Height: | Size: 3.8 KiB |
After Width: | Height: | Size: 4.1 KiB |
After Width: | Height: | Size: 46 KiB |
After Width: | Height: | Size: 48 KiB |
After Width: | Height: | Size: 46 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 5.3 KiB |
After Width: | Height: | Size: 17 KiB |
After Width: | Height: | Size: 15 KiB |
After Width: | Height: | Size: 21 KiB |
After Width: | Height: | Size: 23 KiB |
After Width: | Height: | Size: 16 KiB |
After Width: | Height: | Size: 38 KiB |
After Width: | Height: | Size: 43 KiB |
After Width: | Height: | Size: 34 KiB |
After Width: | Height: | Size: 6.0 KiB |
After Width: | Height: | Size: 5.6 KiB |
After Width: | Height: | Size: 5.7 KiB |
After Width: | Height: | Size: 73 KiB |
After Width: | Height: | Size: 104 KiB |
After Width: | Height: | Size: 1.4 KiB |
@ -0,0 +1,582 @@ |
||||
<!DOCTYPE html> |
||||
<html lang="en"> |
||||
|
||||
<head> |
||||
<meta charset="UTF-8"> |
||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=0"> |
||||
<title>ERP for CP Home</title> |
||||
|
||||
<!-- Google font file. If you want you can change. --> |
||||
<link href="https://fonts.googleapis.com/css?family=Nunito:300,400,600,700,900" rel="stylesheet"> |
||||
|
||||
<!-- Fontawesome font file css --> |
||||
<link rel="stylesheet" type="text/css" href="css/font-awesome.min.css"> |
||||
|
||||
<!-- Animate css file for css3 animations. for more : https://daneden.github.io/animate.css --> |
||||
<!-- Only use animate action. If you dont use animation, you don't have to add.--> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/css/animate.css"> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/css/cryptocoins.css"> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/plugins/c3-chart/c3.css"> |
||||
|
||||
<!-- Template global css file. Requared all pages --> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/css/global.style.css"> |
||||
|
||||
<!-- Swiper slider css file --> |
||||
<link rel="stylesheet" href="https://cdn.yimian.xyz/smart-settlement/css/swiper.min.css"> |
||||
|
||||
<!--turbo slider plugin css file --> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/css/bootstrap.min.css"> |
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/smart-settlement/plugins/turbo-slider/turbo.css"> |
||||
|
||||
<link rel="stylesheet" type="text/css" href="https://cdn.yimian.xyz/shaky/shaky.css"> |
||||
<script>var block_aplayer = true;</script> |
||||
<script type="text/javascript" src="https://cdn.yimian.xyz/ushio-js/ushio-head.min.js"></script> |
||||
|
||||
</head> |
||||
|
||||
<body> |
||||
|
||||
<div class="wrapper "> |
||||
<div class="nav-menu"> |
||||
<nav class="menu"> |
||||
|
||||
<!-- Menu navigation start --> |
||||
<div class="nav-container"> |
||||
<ul class="main-menu"> |
||||
<li class="active"> |
||||
<a href="index.html"><img src="https://cdn.yimian.xyz/smart-settlement/img/content/icons/1.png" alt=""><strong class="special">Dashboard</strong> </a> |
||||
</li> |
||||
<li class=""> |
||||
<a href="buy-sell.html"><img src="https://cdn.yimian.xyz/smart-settlement/img/content/icons/6.png" alt=""><strong class="special">History Payment</strong> </a> |
||||
</li> |
||||
<li class=""> |
||||
<a onclick="javascript:logout();" href="#" data-loader="show"><img src="https://cdn.yimian.xyz/smart-settlement/img/content/icons/7.png" alt=""><strong>Log out</strong></a> |
||||
</li> |
||||
</ul> |
||||
</div> |
||||
<!-- Menu navigation end --> |
||||
</nav> |
||||
</div> |
||||
<div class="wrapper-inline"> |
||||
<!-- Header area start --> |
||||
<header class="no-background"> <!-- extra class no-background --> |
||||
|
||||
<div class="search-button" data-search="open"> |
||||
<img id="no-icon" src="https://cdn.yimian.xyz/smart-settlement/img/content/notification-no.png" class="not-icon1" alt=""> |
||||
<img id="no-icon2" src="https://cdn.yimian.xyz/smart-settlement/img/content/notification2-no.png" class="not-icon2" alt=""> |
||||
</div> |
||||
|
||||
<div class="navi-menu-button"> |
||||
<em></em> |
||||
<em></em> |
||||
<em></em> |
||||
</div> |
||||
|
||||
</header> |
||||
<!-- Header area end --> |
||||
|
||||
<!--NOTIFICATION BOX CONTENT START--> |
||||
<div class="search-form"> |
||||
<span class="close-search-form" data-search="close"><i class="fa fa-times"></i> </span> |
||||
<form> |
||||
<div class="search-input"> |
||||
<br/> |
||||
</div> |
||||
</form> |
||||
<ul class="notification-list list-unstyled" id="no-content"> |
||||
</ul> |
||||
</div> |
||||
<!--NOTIFICATION BOX CONTENT END--> |
||||
|
||||
<!-- Page content start --> |
||||
<main class="margin mt-0"> |
||||
|
||||
<div class="dash-balance"> |
||||
<div class="dash-content relative"> |
||||
<h3 class="w-text">ERP for CP Home</h3> |
||||
<div class="notification"> |
||||
<h3 class="w-text" id="usr">xxx</h3> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
|
||||
<section class="bal-section container"> |
||||
<div class="balance-card mb-15"> |
||||
<div class="d-flex align-items-center"> |
||||
<div class="d-flex flex-grow"> |
||||
<div class="mr-auto"> |
||||
<h1 class="b-val"> £<span id="week-avg"></span> </h1> |
||||
<p class="g-text mb-10">Weekly Payment</p> |
||||
<div class="badge badge-pill" id="week-avg-rate"> 43.55% <i style="color:red;" class="fa fa-arrow-down ml-10"></i></div> |
||||
</div> |
||||
<div class="ml-auto align-self-end"> |
||||
<div id="sparkline1"></div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
<div class="resources-card-wrapper"> |
||||
<div class="resources-card mr-10"> |
||||
<div class="d-flex flex-column flex-md-row"> |
||||
<i class="fa fa-shield text-primary"></i> |
||||
<div class="d-flex flex-column ml-md-2"> |
||||
<p class="text-muted mb-10 font-weight-medium">Total Payment</p> |
||||
<div class="progress"> |
||||
<div class="progress-bar bg-primary" id="total-bar" role="progressbar" style="width: 97%"></div> |
||||
</div> |
||||
<h4 class="mt-10 mb-0">£<span id="total"></span> </h4> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
<div class="resources-card ml-10"> |
||||
<div class="d-flex flex-column flex-md-row"> |
||||
<i class="fa fa fa-shopping-cart txt-green"></i> |
||||
<div class="d-flex flex-column ml-md-2"> |
||||
<p class="text-muted mb-10 font-weight-medium">Your Payment</p> |
||||
<div class="progress"> |
||||
<div class="progress-bar bg-success" id="total-usr-bar" role="progressbar" style="width: 67%"></div> |
||||
</div> |
||||
<h4 class="mt-10 mb-0">£<span id="total-usr"></span> </h4> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</section> |
||||
<br/> |
||||
<section> |
||||
<div class="content"> |
||||
<div class="wallet-address"> |
||||
<h4 class="w-text mt-0">Report New Payment</h4> |
||||
<div class="form-row-group with-icons"> |
||||
<div class="form-row no-padding"> |
||||
<i>£</i> |
||||
<input type="text" id="aaa" class="form-element"> |
||||
</div> |
||||
</div> |
||||
<h4><a id="submit-a" href="#">Submit</a></h4> |
||||
<p class="g-text mb-0">Be Careful when Input..</p> |
||||
</div> |
||||
</div> |
||||
</section> |
||||
|
||||
<section class="container"> |
||||
<div class="content"> |
||||
<h4 class="title-main">Daily Payment Trend</h4> |
||||
<div class="c-panel pl-0"> |
||||
|
||||
<div class="row align-items-center"> |
||||
<div class="col-12"> |
||||
<div class="advertising-wrapper"> |
||||
<div id="barAreaGraph" ></div> |
||||
</div> |
||||
</div> |
||||
|
||||
</div> |
||||
</div> |
||||
</div> |
||||
</section> |
||||
<section class="container"> |
||||
<div class="content"> |
||||
<h4 class="title-main">Bill Split</h4> |
||||
<div class="c-panel"> |
||||
|
||||
<div class="row align-items-center"> |
||||
<div class="col-12 col-sm-6"> |
||||
<div class="advertising-wrapper"> |
||||
<div id="advertising" class="chart-height-sm"></div> |
||||
<h3 class="info-label"><span>Variance</span> <span id="a-balance"></span></h3> |
||||
</div> |
||||
</div> |
||||
<div class="col-12 col-sm-6"> |
||||
<div class="split-list"> |
||||
<ul class="adv-stats"> |
||||
<li> |
||||
<i class="fa fa-circle-o"></i> |
||||
mingran <span id="a-mingran">22%</span> |
||||
</li> |
||||
<li> |
||||
<i class="fa fa-circle-o "></i> |
||||
boyao <span id="a-boyao">11%</span> |
||||
</li> |
||||
<li> |
||||
<i class="fa fa-circle-o"></i> |
||||
yimian <span id="a-yimian">40%</span> |
||||
</li> |
||||
<li> |
||||
<i class="fa fa-circle-o"></i> |
||||
xiaotian <span id="a-xiaotian">17%</span> |
||||
</li> |
||||
<li> |
||||
<i class="fa fa-circle-o"></i> |
||||
hao <span id="a-hao">10%</span> |
||||
</li> |
||||
</ul> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</section> |
||||
|
||||
<section class="container"> |
||||
<h4 class="title-main">Recent Transactions</h4> |
||||
<ul class="transaction-list list-unstyled" id="account-events"> |
||||
</ul> |
||||
</section> |
||||
|
||||
<footer> |
||||
<div class="container"> |
||||
<ul> |
||||
<li><a id="ushio-blog" href="https://www.eee.dog"><i class="fa fa-home"></i></a></li> |
||||
<li><a href="https://github.com/iotcat"><i class="fa fa-github"></i></a></li> |
||||
<li><a href="mailto:i@yimian.xyz"><i class="fa fa-envelope"></i></a></li> |
||||
<li><a href="https://www.eee.dog/feed"><i class="fa fa-rss"></i></a></li> |
||||
</ul> |
||||
<p>© 2018-<script type="text/javascript">document.write(new Date().getFullYear());</script> Made with <span class="shaky"><i style="color:red;" class="fa fa-heart"></i></span> by <a id="ushio-tome" href="https://iotcat.me">iotcat</a></p> |
||||
</div> |
||||
</footer> |
||||
</main> |
||||
<!-- Page content end --> |
||||
</div> |
||||
</div> |
||||
|
||||
<!--Page loader DOM Elements. Requared all pages--> |
||||
<div class="sweet-loader"> |
||||
<div class="box"> |
||||
<div class="circle1"></div> |
||||
<div class="circle2"></div> |
||||
<div class="circle3"></div> |
||||
</div> |
||||
</div> |
||||
<script type="text/javascript" src="https://cdn.yimian.xyz/ushio-js/ushio-footer.min.js"></script> |
||||
|
||||
<!-- JQuery library file. requared all pages --> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/js/jquery-3.2.1.min.js"></script> |
||||
|
||||
<!-- Swiper JS --> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/js/swiper.min.js"></script> |
||||
|
||||
<!-- Initialize Swiper --> |
||||
|
||||
<!-- Flot Charts --> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/c3-chart/c3.min.js"></script> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/c3-chart/d3.min.js"></script> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/c3-chart/c3.custom.js"></script> |
||||
<!-- Flot Charts --> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/flot/jquery.flot.min.js"></script> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/flot/jquery.flot.time.min.js"></script> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/flot/jquery.flot.pie.min.js"></script> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/flot/jquery.flot.tooltip.min.js"></script> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/flot/jquery.flot.resize.min.js"></script> |
||||
<!-- Sparkline--> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/plugins/jquery-sparkline/jquery.sparkline.js"></script> |
||||
|
||||
<!-- Template global script file. requared all pages --> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/js/app-charts.js"></script> |
||||
<script src="https://cdn.yimian.xyz/smart-settlement/js/global.script.js"></script> |
||||
|
||||
<script type="text/javascript"> |
||||
var usr = null; |
||||
var usr_arr = ['liu', 'yang', 'li', 'jia', 'zheng']; |
||||
|
||||
if(cookie.get('usr') == null){ |
||||
usr=prompt("please input your surname",""); |
||||
cookie.set("usr", usr); |
||||
}else{ |
||||
usr = cookie.get("usr"); |
||||
} |
||||
|
||||
$('#usr').html('Hi~ '+usr); |
||||
$("#aaa").bind("input propertychange",function(event){ |
||||
console.log($("#aaa").val()); |
||||
$("#aaa").val(clearNoNum($("#aaa").val())) |
||||
}); |
||||
$("#submit-a").click(function(){ |
||||
if(!$('#aaa').val()) { |
||||
alert('illegal input'); |
||||
return; |
||||
} |
||||
cookie.set('val', $('#aaa').val()); |
||||
window.location.href='https://settlement.yimian.xyz/imgbed/'; |
||||
}); |
||||
|
||||
$.post('https://settlement.yimian.xyz/api/', function(res){ |
||||
res = JSON.parse(res); |
||||
$('#total').html(Number(res.data.total)); |
||||
$('#total-usr').html(Number(res.data[usr])); |
||||
$('#total-usr-bar').css('width', (res.data[usr] / res.data.avg)*100+'%'); |
||||
}); |
||||
|
||||
$.post('https://settlement.yimian.xyz/api/getWeekData.php', function(res){ |
||||
res = JSON.parse(res); |
||||
|
||||
$('#week-avg').html(Number(res.data[0]['week_val']).toFixed(2)); |
||||
$('#total-bar').css('width', (res.data[0]['val'] / res.data[0]['week_val'])*100+'%'); |
||||
if(res.data[0]['week_val'] > res.data[1]['week_val']) $('#week-avg-rate').html(((res.data[0]['week_val'] - res.data[1]['week_val'])/res.data[1]['week_val']).toFixed(2)+'% <i style="color:red;" class="fa fa-arrow-up ml-10"></i>'); |
||||
if(res.data[0]['week_val'] <= res.data[1]['week_val']) $('#week-avg-rate').html(((res.data[0]['week_val'] - res.data[1]['week_val'])/res.data[1]['week_val']).toFixed(2)+'% <i style="color:green;" class="fa fa-arrow-down ml-10"></i>'); |
||||
}); |
||||
|
||||
|
||||
/* trans items */ |
||||
|
||||
function whoPayment(res, index){ |
||||
var who = null; |
||||
usr_arr.forEach(function(item){ |
||||
if(res.data[index][item] > res.data[index+1][item]) who = item; |
||||
}); |
||||
|
||||
return who; |
||||
} |
||||
|
||||
|
||||
function whoCurrentTo(res, index){ |
||||
var who = null; |
||||
usr_arr.forEach(function(item){ |
||||
if(res.data[index][item+'_'] < res.data[index+1][item+'_']) who = item; |
||||
}); |
||||
|
||||
return who; |
||||
} |
||||
|
||||
function whoCurrentFrom(res, index){ |
||||
var who = null; |
||||
usr_arr.forEach(function(item){ |
||||
if(res.data[index][item+'_'] > res.data[index+1][item+'_']) who = item; |
||||
}); |
||||
|
||||
return who; |
||||
} |
||||
|
||||
function whoConfirmTo(res, index){ |
||||
var who = null; |
||||
usr_arr.forEach(function(item){ |
||||
if(res.data[index][item] > res.data[index+1][item]) who = item; |
||||
}); |
||||
|
||||
return who; |
||||
} |
||||
|
||||
function whoConfirmFrom(res, index){ |
||||
var who = null; |
||||
usr_arr.forEach(function(item){ |
||||
if(res.data[index][item] < res.data[index+1][item]) who = item; |
||||
}); |
||||
|
||||
return who; |
||||
} |
||||
|
||||
|
||||
$.post('https://settlement.yimian.xyz/api/getAccountEvents.php', function(res){ |
||||
res = JSON.parse(res); |
||||
var s = ''; |
||||
res.data.forEach(function(i, index){ |
||||
if(index < res.data.length - 1){ |
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<img class="img-xs" src="https://cdn.yimian.xyz/smart-settlement/img/content/coin`; |
||||
if(i.type == "payment") s += 3; |
||||
if(i.type == "current") s += 4; |
||||
if(i.type == "confirm") s += 5; |
||||
s += `.png" alt="coin image"> |
||||
<div class="ml-10"> |
||||
<h4 class="coin-name">`; |
||||
s += i.type; |
||||
if(i.type == "payment") s += ' - ' + whoPayment(res, index); |
||||
if(i.type == "current") s += ' - ' + whoCurrentFrom(res, index) + ' -> ' + whoCurrentTo(res, index); |
||||
if(i.type == "confirm") s += ' - ' + whoConfirmFrom(res, index) + ' 👍 ' + whoConfirmTo(res, index); |
||||
s += `</h4> |
||||
<small class="text-muted">`; |
||||
s += i.datetime; |
||||
s += `</small> |
||||
</div> |
||||
</div> |
||||
<div> |
||||
`; |
||||
if(i.total > res.data[index+1].total) s += `<small class="d-block mb-0 txt-red">£`+(res.data[index+1].total - i.total).toFixed(2) + `</small>`; |
||||
|
||||
s += ` |
||||
<small class="text-muted d-block">£`; |
||||
s += Number(i.total); |
||||
|
||||
s += `</small> |
||||
</div> |
||||
</div> |
||||
</li> |
||||
`; |
||||
} |
||||
|
||||
$('#account-events').html(s); |
||||
}); |
||||
}); |
||||
|
||||
/* notification func */ |
||||
|
||||
function timeago(dateTimeStamp){ //dateTimeStamp是一个时间毫秒,注意时间戳是秒的形式,在这个毫秒的基础上除以1000,就是十位数的时间戳。13位数的都是时间毫秒。 |
||||
var minute = 1000 * 60; //把分,时,天,周,半个月,一个月用毫秒表示 |
||||
var hour = minute * 60; |
||||
var day = hour * 24; |
||||
var week = day * 7; |
||||
var halfamonth = day * 15; |
||||
var month = day * 30; |
||||
var now = new Date().getTime(); //获取当前时间毫秒 |
||||
var diffValue = now - dateTimeStamp;//时间差 |
||||
|
||||
if(diffValue < 0){ |
||||
return; |
||||
} |
||||
var minC = diffValue/minute; //计算时间差的分,时,天,周,月 |
||||
var hourC = diffValue/hour; |
||||
var dayC = diffValue/day; |
||||
var weekC = diffValue/week; |
||||
var monthC = diffValue/month; |
||||
if(monthC >= 1 && monthC <= 3){ |
||||
result = " " + parseInt(monthC) + "month ago" |
||||
}else if(weekC >= 1 && weekC <= 3){ |
||||
result = " " + parseInt(weekC) + "week ago" |
||||
}else if(dayC >= 1 && dayC <= 6){ |
||||
result = " " + parseInt(dayC) + "day ago" |
||||
}else if(hourC >= 1 && hourC <= 23){ |
||||
result = " " + parseInt(hourC) + "hours ago" |
||||
}else if(minC >= 1 && minC <= 59){ |
||||
result =" " + parseInt(minC) + "minutes ago" |
||||
}else if(diffValue >= 0 && diffValue <= minute){ |
||||
result = "just now" |
||||
}else { |
||||
var datetime = new Date(); |
||||
datetime.setTime(dateTimeStamp); |
||||
var Nyear = datetime.getFullYear(); |
||||
var Nmonth = datetime.getMonth() + 1 < 10 ? "0" + (datetime.getMonth() + 1) : datetime.getMonth() + 1; |
||||
var Ndate = datetime.getDate() < 10 ? "0" + datetime.getDate() : datetime.getDate(); |
||||
var Nhour = datetime.getHours() < 10 ? "0" + datetime.getHours() : datetime.getHours(); |
||||
var Nminute = datetime.getMinutes() < 10 ? "0" + datetime.getMinutes() : datetime.getMinutes(); |
||||
var Nsecond = datetime.getSeconds() < 10 ? "0" + datetime.getSeconds() : datetime.getSeconds(); |
||||
result = Nyear + "-" + Nmonth + "-" + Ndate |
||||
} |
||||
return result; |
||||
} |
||||
|
||||
function confirm(id){ |
||||
$.post('https://settlement.yimian.xyz/api/?type=confirm&id='+id, function(res){ |
||||
notice(); |
||||
}); |
||||
} |
||||
|
||||
|
||||
function notice(){ |
||||
|
||||
|
||||
$.post('https://settlement.yimian.xyz/api/getCurrent.php', {'usr': usr}, function(res){ |
||||
res = JSON.parse(res); |
||||
var s = ''; |
||||
|
||||
if(!res.data.length){ |
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<div class=""> |
||||
<h5 class="coin-name">You have NO notifications!!</h5> |
||||
</div> |
||||
</div> |
||||
<div> |
||||
<a href=""></a> |
||||
</div> |
||||
</div> |
||||
</li>`; |
||||
$('#no-content').html(s); |
||||
$("#no-icon").attr("src", 'https://cdn.yimian.xyz/smart-settlement/img/content/notification-no.png'); |
||||
$("#no-icon2").attr("src", 'https://cdn.yimian.xyz/smart-settlement/img/content/notification2-no.png'); |
||||
return; |
||||
} |
||||
|
||||
|
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<div class=""> |
||||
<h5 class="coin-name">Your last `; |
||||
|
||||
s += res.data.length; |
||||
s += ` notifications</h5> |
||||
</div> |
||||
</div> |
||||
<div> |
||||
<a href=""></a> |
||||
</div> |
||||
</div> |
||||
</li>`; |
||||
|
||||
res.data.forEach(function(item){ |
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<div class="notice-icon `; |
||||
if(item.usr_to == usr) s += `available`; |
||||
if(item.usr_from == usr) s += `away`; |
||||
|
||||
s += `"> |
||||
<i class="fa fa-`; |
||||
if(item.usr_to == usr) s += `check`; |
||||
if(item.usr_from == usr) s += `clock-o`; |
||||
s += `"></i> |
||||
</div> |
||||
<div class="ml-10"> |
||||
<h4 class="coin-name">`; |
||||
|
||||
if(item.usr_to == usr) s += `You will Get £50 from `+ item.usr_from + ` <button style="color: green;" onClick="javascript:confirm(`+item.id+`);">Confirm to Recived</button>`; |
||||
if(item.usr_from == usr) s += `Please Give £50 to `+ item.usr_to; |
||||
|
||||
s += `</h4> |
||||
<small class="text-muted">`; |
||||
s += timeago(new Date(item.datetime.replace(/-/g, '/')).getTime()); |
||||
s += `</small> |
||||
</div> |
||||
</div> |
||||
</div> |
||||
</li>`; |
||||
}); |
||||
|
||||
s += ` |
||||
<li> |
||||
<div class="d-flex align-items-center justify-content-between"> |
||||
<div class="d-flex align-items-center"> |
||||
<a href="" class="text-muted">The end of all notifications</a> |
||||
</div> |
||||
</div> |
||||
</li>`; |
||||
|
||||
$('#no-content').html(s); |
||||
$("#no-icon").attr("src", 'https://cdn.yimian.xyz/smart-settlement/img/content/notification-yes.png'); |
||||
$("#no-icon2").attr("src", 'https://cdn.yimian.xyz/smart-settlement/img/content/notification2-yes.png'); |
||||
}); |
||||
}; |
||||
|
||||
notice(); |
||||
|
||||
/* log out */ |
||||
function logout(){ |
||||
cookie.del('usr'); |
||||
cookie.del('val'); |
||||
location.reload(); |
||||
} |
||||
|
||||
</script> |
||||
|
||||
|
||||
<script language="JavaScript" type="text/javascript"> |
||||
function clearNoNum(value){ |
||||
value = value.replace(/[^\d.]/g,""); //清除“数字”和“.”以外的字符 |
||||
value = value.replace(/^\./g,""); //验证第一个字符是数字而不是. |
||||
value = value.replace(/\.{2,}/g,"."); //只保留第一个. 清除多余的. |
||||
value = value.replace(".","$#$").replace(/\./g,"").replace("$#$","."); |
||||
return value; |
||||
} |
||||
</script> |
||||
|
||||
</body> |
||||
|
||||
</html> |
@ -0,0 +1,190 @@ |
||||
var $danger = "#D66061"; |
||||
var $yellow = "#ffee00"; |
||||
|
||||
|
||||
// Sparkline Graphs
|
||||
$(function () { |
||||
$('#projects').sparkline([620,250,400,380,280,320,220,385,450], { |
||||
type: 'line', |
||||
lineWidth: 3, |
||||
fillColor: false, |
||||
lineColor: '#058DC7', |
||||
spotColor: '#e13f3d', |
||||
minSpotColor: '#50B432', |
||||
maxSpotColor: '#f7b53c', |
||||
highlightSpotColor: '#', |
||||
height: 60, |
||||
width: 120, |
||||
spotRadius: 6, |
||||
}); |
||||
$('#sparkline1').sparkline([8, 6, 2, 8, 9, 4, 7, 10, 11, 12, 7], { |
||||
type: 'bar', |
||||
height: '80', |
||||
barWidth: '10', |
||||
barWidth: 2, |
||||
barSpacing: 10, |
||||
chartRangeMin: 0, |
||||
barColor: '#e6ecf5' |
||||
}); |
||||
|
||||
$("#downloads").sparkline([290,320,310,365,420,320,350,370,320], { |
||||
type: 'bar', |
||||
barWidth: 10, |
||||
height: 60, |
||||
width: 120,
|
||||
barSpacing: 5, |
||||
barColor: '#058DC7', |
||||
negBarColor: '#ffffaa' |
||||
}); |
||||
$(".watch1").sparkline([2,4,4,6,8,5,6,4,8,6,6,2 ], { |
||||
type: 'line', |
||||
width: '100%', |
||||
height: '80', |
||||
lineColor: '#13dafe', |
||||
fillColor: 'rgba(19, 218, 254, 0.3)', |
||||
maxSpotColor: '#99d683', |
||||
highlightLineColor: 'rgba(0, 0, 0, 0.2)', |
||||
highlightSpotColor: 'rgba(0,0,0,.2)' |
||||
}); |
||||
$('.watch2').sparkline([0,13,10,14,15,10,18,15,19], { |
||||
type: 'line', |
||||
width: '100%', |
||||
height: '80', |
||||
lineColor: '#6164c1', |
||||
fillColor: 'rgba(97, 100, 193, 0.3)', |
||||
highlightLineColor: 'rgba(0,0,0,.1)', |
||||
highlightSpotColor: 'rgba(0,0,0,.2)' |
||||
}); |
||||
$(".watch3").sparkline([0,2,8,6,8,5,6,4,8,6,6,2 ], { |
||||
type: 'line', |
||||
width: '100%', |
||||
height: '80', |
||||
lineColor: '#fa8282', |
||||
fillColor: 'rgba(255,211,152,.8)', |
||||
minSpotColor:'#13dafe', |
||||
maxSpotColor: '#13dafe', |
||||
highlightLineColor: 'rgba(0, 0, 0, 0.2)', |
||||
highlightSpotColor: '#13dafe' |
||||
}); |
||||
$(".watch4").sparkline([3,7,5,6,8,7,6,7,8,6,6,9 ], { |
||||
type: 'line', |
||||
width: '100%', |
||||
height: '80', |
||||
lineColor: '#13dafe', |
||||
fillColor: 'rgba(153,214,131,.7)', |
||||
minSpotColor:'#13dafe', |
||||
maxSpotColor: '#13dafe', |
||||
highlightLineColor: 'rgba(0, 0, 0, 0.2)', |
||||
highlightSpotColor: '#13dafe' |
||||
}); |
||||
$(".watch5").sparkline([2,5,6,6,9,5,7,7,8,5,6,8 ], { |
||||
type: 'line', |
||||
width: '100%', |
||||
height: '80', |
||||
lineColor: '#fc6180', |
||||
fillColor: 'rgba(252, 97, 128, 0.3)', |
||||
maxSpotColor: '#99d683', |
||||
highlightLineColor: 'rgba(0, 0, 0, 0.2)', |
||||
highlightSpotColor: 'rgba(0,0,0,.2)' |
||||
}); |
||||
|
||||
$(".profile1").sparkline([0,2,8,6,8,5,6,4,8,6,6,2 ], { |
||||
type: 'bar', |
||||
width: '100%', |
||||
height: '50', |
||||
barColor: '#fa8282', |
||||
fillColor: 'rgba(255,211,152,.8)', |
||||
minSpotColor:'#13dafe', |
||||
maxSpotColor: '#13dafe', |
||||
highlightLineColor: 'rgba(0, 0, 0, 0.2)', |
||||
highlightSpotColor: '#13dafe' |
||||
}); |
||||
$(".profile2").sparkline([3,7,5,6,8,7,6,7,8,6,6,9 ], { |
||||
type: 'bar', |
||||
width: '100%', |
||||
height: '50', |
||||
barColor: '#13dafe', |
||||
fillColor: 'rgba(153,214,131,.7)', |
||||
minSpotColor:'#13dafe', |
||||
maxSpotColor: '#13dafe', |
||||
highlightLineColor: 'rgba(0, 0, 0, 0.2)', |
||||
highlightSpotColor: '#13dafe' |
||||
}); |
||||
$(".profile3").sparkline([2,5,6,6,9,5,7,7,8,5,6,8 ], { |
||||
type: 'bar', |
||||
width: '100%', |
||||
height: '50', |
||||
barColor: '#72a1ec' |
||||
}); |
||||
|
||||
$("#total-applications").sparkline([212,257,284,315,365,383,358,371,329,295,321,392,316,423,477,495,419], { |
||||
type: 'line', |
||||
lineWidth: 3, |
||||
fillColor: false, |
||||
lineColor: '#058DC7', |
||||
spotColor: '#e13f3d', |
||||
minSpotColor: '#50B432', |
||||
maxSpotColor: '#f7b53c', |
||||
highlightSpotColor: '#', |
||||
height: 40, |
||||
width: 180, |
||||
spotRadius: 5, |
||||
}); |
||||
}); |
||||
|
||||
|
||||
// Flot Donut Chart
|
||||
$(function () { |
||||
|
||||
$.post('https://settlement.yimian.xyz/api/', function(res){ |
||||
res = JSON.parse(res); |
||||
//console.log(res);
|
||||
$('#a-yimian').html((res.data.liu / res.data.total * 100).toFixed(1) +'%'); |
||||
$('#a-boyao').html((res.data.yang / res.data.total * 100).toFixed(1) +'%'); |
||||
$('#a-xiaotian').html((res.data.li / res.data.total * 100).toFixed(1) +'%'); |
||||
$('#a-mingran').html((res.data.jia / res.data.total * 100).toFixed(1) +'%'); |
||||
$('#a-hao').html((res.data.zheng / res.data.total * 100).toFixed(1) +'%'); |
||||
$('#a-balance').html(((Math.pow(res.data.liu - res.data.avg, 2) + Math.pow(res.data.yang - res.data.avg, 2) + Math.pow(res.data.li - res.data.avg, 2) + Math.pow(res.data.jia - res.data.avg, 2) + Math.pow(res.data.zheng - res.data.avg, 2)) / 5).toFixed(1)); |
||||
|
||||
var data, chartOptions; |
||||
data = [ |
||||
{ label: "", data: Math.floor (res.data.liu) },
|
||||
{ label: "", data: Math.floor (res.data.yang) }, |
||||
{ label: "", data: Math.floor (res.data.li) },
|
||||
{ label: "", data: Math.floor (res.data.jia) },
|
||||
{ label: "", data: Math.floor (res.data.zheng) },
|
||||
]; |
||||
chartOptions = {
|
||||
series: { |
||||
pie: { |
||||
show: true,
|
||||
innerRadius: .8,
|
||||
stroke: { |
||||
width: 1, |
||||
} |
||||
} |
||||
},
|
||||
shadowSize: 0, |
||||
legend: { |
||||
position: 'sw' |
||||
}, |
||||
tooltip: true, |
||||
|
||||
tooltipOpts: { |
||||
content: '%s: %y' |
||||
}, |
||||
grid:{ |
||||
hoverable: false, |
||||
clickable: false, |
||||
borderWidth: 0, |
||||
}, |
||||
shadowSize: 0, |
||||
colors: ['#F782AA', '#0084B4', '#3FC5AC', '#FFD06B', '#CCCCCC'], |
||||
}; |
||||
var holder = $('#advertising'); |
||||
if (holder.length) { |
||||
$.plot(holder, data, chartOptions ); |
||||
}
|
||||
|
||||
}); |
||||
}); |
@ -0,0 +1,281 @@ |
||||
"use strict"; |
||||
|
||||
$(document).ready(function(){ |
||||
|
||||
$('.navi-menu-button').on('click', function(e){ |
||||
navMenuOpen(); |
||||
}); |
||||
|
||||
$('.nav-menu').on('click', function(e){ |
||||
if ($(e.target).hasClass('nav-menu')){ |
||||
navMenuClose(); |
||||
} |
||||
}); |
||||
|
||||
$('nav.menu ul.main-menu>li>a').on('click', function(e){ |
||||
var that = $(this); |
||||
if (that.parent().find('ul:first').length) |
||||
{ |
||||
e.preventDefault(); |
||||
if (!that.parent().hasClass('active')) |
||||
{ |
||||
$('nav.menu ul.main-menu ul').slideUp('fast',function(){ |
||||
$('nav.menu ul.main-menu > li').removeClass('active'); |
||||
}); |
||||
|
||||
$('nav.menu ul li a span').removeClass('fa-angle-up').addClass('fa-angle-down'); |
||||
|
||||
|
||||
that.parent().find('ul:first').slideDown('fast',function(){ |
||||
that.parent().addClass('active'); |
||||
}); |
||||
|
||||
that.find('span').removeClass('fa-angle-down').addClass('fa-angle-up'); |
||||
} |
||||
else |
||||
{ |
||||
|
||||
that.parent().find('ul:first').slideUp('fast',function(){ |
||||
$(this).parent().removeClass('active'); |
||||
}); |
||||
that.find('span').removeClass('fa-angle-up').addClass('fa-angle-down'); |
||||
} |
||||
} |
||||
else |
||||
{ |
||||
$('nav.menu ul.main-menu ul').slideUp('fast'); |
||||
$('nav.menu ul.main-menu > li').removeClass('active'); |
||||
that.parent().addClass('active'); |
||||
} |
||||
}); |
||||
|
||||
|
||||
$('.tab-item .fix-width .menu-item').css({'width': 100/$('.tab-item .fix-width .menu-item').length+'%'}); |
||||
|
||||
if ($('.wizard').length) |
||||
{ |
||||
wizardFixHeight(); |
||||
$(window).resize(); |
||||
} |
||||
|
||||
if ($('.wizard').length) { |
||||
$(".wizard").Turbo({ |
||||
items:1, |
||||
circular:false |
||||
}); |
||||
} |
||||
|
||||
if ($('.animated-text').length) |
||||
animateText(); |
||||
|
||||
}); |
||||
|
||||
|
||||
$(".wrapper-inline").on("scroll", function(e) { |
||||
if (this.scrollTop > 150) { |
||||
$('header.no-background').addClass("set-bg"); |
||||
} else { |
||||
$('header.no-background').removeClass("set-bg"); |
||||
} |
||||
|
||||
}); |
||||
|
||||
var navMenuOpen = function(){ |
||||
$('.navi-menu-button').addClass('focused'); |
||||
|
||||
$('div.nav-menu').fadeIn(50,function(e){ |
||||
$('nav.menu').addClass('opened'); |
||||
}); |
||||
} |
||||
|
||||
var navMenuClose = function(){ |
||||
$('.navi-menu-button').removeClass('focused'); |
||||
|
||||
$('nav.menu').removeClass('opened'); |
||||
$('div.nav-menu').fadeOut(200); |
||||
} |
||||
|
||||
var wizardFixHeight = function(){ |
||||
$(window).on('resize', function(e){ |
||||
$('.wizard .wizard-item').height($(window).height()-50); |
||||
}); |
||||
} |
||||
|
||||
var animateText = function(){ |
||||
$('.vertical-center').css({'margin-top':$(window).height()/2 - $('.vertical-center').height()/2}); |
||||
$('.animated-text').removeClass('zero-opacity'); |
||||
$('[data-transation]').each(function(e,i){ |
||||
var that = $(this); |
||||
that.addClass('hide'); |
||||
|
||||
var transation = that.attr('data-transation'); |
||||
if (transation == '') |
||||
transation = 'fadeInDown'; |
||||
|
||||
var startTime = parseInt(that.attr('data-start-time')); |
||||
if (isNaN(startTime)) |
||||
startTime = 0; |
||||
|
||||
setTimeout(function(){ |
||||
that.addClass('animated '+transation); |
||||
},startTime); |
||||
}) |
||||
} |
||||
|
||||
|
||||
/*sweet checkbox scripts*/ |
||||
$('.sweet-check :checkbox:checked').each(function(e,i){ |
||||
$(this).parent().addClass('checked'); |
||||
}); |
||||
|
||||
|
||||
$(document).on('click', '.sweet-check', function(){ |
||||
if ($(this).hasClass('checked')) |
||||
{ |
||||
$(this).removeClass('checked'); |
||||
$(this).find('input').prop('checked', false); |
||||
} |
||||
else |
||||
{ |
||||
$(this).addClass('checked'); |
||||
$(this).find('input').prop('checked', true); |
||||
} |
||||
|
||||
//console.log($(this).find('input').prop('checked'));
|
||||
}); |
||||
|
||||
$(document).on('click','[data-loader]', function(){ |
||||
$('.sweet-loader').show().addClass('show'); |
||||
}); |
||||
|
||||
|
||||
/*expandable list scrips****/ |
||||
$(document).on('click', '.expandable-item .expandable-header', function(){ |
||||
if ($(this).parent().hasClass('accordion')) |
||||
{ |
||||
if ($(this).parent().hasClass('active')) |
||||
{ |
||||
$(this).parent().removeClass('active'); |
||||
$(this).parent().find('.expandable-content').attr('style',''); |
||||
} |
||||
else |
||||
{ |
||||
var accordionGroup = $(this).parent().attr('data-group'); |
||||
$('[data-group="'+accordionGroup+'"]').removeClass('active'); |
||||
$('[data-group="'+accordionGroup+'"]').find('.expandable-content').attr('style',''); |
||||
$(this).parent().find('.expandable-content').css({'max-height':$(this).parent().find('.expandable-content')[0].scrollHeight}); |
||||
$(this).parent().addClass('active'); |
||||
} |
||||
} |
||||
else |
||||
{ |
||||
if ($(this).parent().hasClass('active')) |
||||
$(this).parent().find('.expandable-content').attr('style',''); |
||||
else |
||||
$(this).parent().find('.expandable-content').css({'max-height':$(this).parent().find('.expandable-content')[0].scrollHeight}); |
||||
|
||||
$(this).parent().toggleClass('active'); |
||||
} |
||||
}); |
||||
|
||||
|
||||
|
||||
$(document).on('click', '.tab-item .menu-item', function(e){ |
||||
e.preventDefault(); |
||||
var tabContentId = $(this).attr('data-content'); |
||||
|
||||
$(this).parents('.tab-item').find('.menu-item').removeClass('active'); |
||||
$(this).addClass('active'); |
||||
|
||||
$(this).parents('.tab-item').find('.content-item').removeClass('active'); |
||||
$('#'+tabContentId).addClass('active'); |
||||
}); |
||||
|
||||
|
||||
/*post item scripts **************/ |
||||
$(document).on('click', '.post-item .post-share > i', function(e){ |
||||
e.preventDefault(); |
||||
$(this).parent().find('.social-links').fadeToggle('fast'); |
||||
}); |
||||
|
||||
|
||||
/*popup actions ******************/ |
||||
$(document).on('click', '[data-dismiss="true"]', function(){ |
||||
$(this).parents('.popup-overlay').fadeOut('fast'); |
||||
}); |
||||
|
||||
$(document).on('click', '[data-popup]', function(){ |
||||
var modalId = $(this).attr('data-popup'); |
||||
$('#'+modalId).fadeIn('fast'); |
||||
}); |
||||
|
||||
$(document).on('click', '.popup-overlay', function(e){ |
||||
if ($(e.target).hasClass('popup-overlay')) |
||||
{ |
||||
$(this).fadeOut('fast'); |
||||
} |
||||
}); |
||||
|
||||
|
||||
|
||||
/*search popup actions ************/ |
||||
|
||||
var openSearchPopup = function(){ |
||||
$('.search-form').fadeIn('fast'); |
||||
$('.search-form input').focus(); |
||||
} |
||||
|
||||
var closeSearchPopup = function(){ |
||||
$('.search-form').fadeOut('fast'); |
||||
} |
||||
|
||||
$(document).on('click', '[data-search="open"]', function(){ |
||||
openSearchPopup(); |
||||
}); |
||||
|
||||
$(document).on('click', '[data-search="close"]', function(){ |
||||
closeSearchPopup(); |
||||
}); |
||||
|
||||
|
||||
// ------------------------------------------------------- //
|
||||
// Swiper Slider
|
||||
// ------------------------------------------------------ //
|
||||
if($('.swiper-container').length || $('.swiper-recievers').length){ |
||||
var swiper = new Swiper('.swiper-container', { |
||||
slidesPerView: 2, |
||||
breakpoints: { |
||||
400: { |
||||
slidesPerView: 1 |
||||
} |
||||
}, |
||||
pagination: { |
||||
el: '.swiper-pagination', |
||||
}, |
||||
}); |
||||
|
||||
var swiper = new Swiper('.swiper-recievers', { |
||||
slidesPerView: 4, |
||||
breakpoints: { |
||||
400: { |
||||
slidesPerView:3 |
||||
} |
||||
} |
||||
}); |
||||
} |
||||
|
||||
// ------------------------------------------------------- //
|
||||
// Map
|
||||
// ------------------------------------------------------ //
|
||||
|
||||
function initMap() { |
||||
var coords = {lat: 40.7127837, lng: -74.00594130000002}; |
||||
var map = new google.maps.Map(document.getElementById('map'), { |
||||
zoom: 17, |
||||
center: coords |
||||
}); |
||||
var marker = new google.maps.Marker({ |
||||
position: coords, |
||||
map: map |
||||
}); |
||||
} |
@ -0,0 +1,191 @@ |
||||
.c3 svg { |
||||
font-size: 12px; |
||||
-webkit-tap-highlight-color: transparent |
||||
} |
||||
|
||||
.c3 line, |
||||
.c3 path { |
||||
fill: none; |
||||
stroke: #ccc |
||||
} |
||||
|
||||
.c3-legend-item-tile { |
||||
stroke-width: 5 |
||||
} |
||||
|
||||
.c3 text { |
||||
-webkit-user-select: none; |
||||
-moz-user-select: none; |
||||
user-select: none; |
||||
fill: #666 |
||||
} |
||||
|
||||
.c3-bars path, |
||||
.c3-event-rect, |
||||
.c3-legend-item-tile, |
||||
.c3-xgrid-focus, |
||||
.c3-ygrid { |
||||
shape-rendering: crispEdges |
||||
} |
||||
|
||||
.c3-chart-arc path { |
||||
stroke: #FFF |
||||
} |
||||
|
||||
.c3-chart-arc text { |
||||
fill: #fff; |
||||
font-size: 13px |
||||
} |
||||
|
||||
.c3-grid line { |
||||
stroke: #ccc |
||||
} |
||||
|
||||
.c3-grid text { |
||||
fill: #535D6F |
||||
} |
||||
|
||||
.c3-xgrid, |
||||
.c3-ygrid { |
||||
stroke-dasharray: 3 3 |
||||
} |
||||
|
||||
.c3-text.c3-empty { |
||||
fill: grey; |
||||
font-size: 2em |
||||
} |
||||
|
||||
.c3-line { |
||||
stroke-width: 2px |
||||
} |
||||
|
||||
.c3-circle._expanded_ { |
||||
stroke-width: 1px; |
||||
stroke: #fff |
||||
} |
||||
|
||||
.c3-selected-circle { |
||||
fill: #fff; |
||||
stroke-width: 4px |
||||
} |
||||
|
||||
.c3-bar { |
||||
stroke-width: 0 |
||||
} |
||||
|
||||
.c3-bar._expanded_ { |
||||
fill-opacity: .75 |
||||
} |
||||
|
||||
.c3-target.c3-focused { |
||||
opacity: 1 |
||||
} |
||||
|
||||
.c3-target.c3-focused path.c3-line, |
||||
.c3-target.c3-focused path.c3-step { |
||||
stroke-width: 2px |
||||
} |
||||
|
||||
.c3-target.c3-defocused { |
||||
opacity: .3 |
||||
} |
||||
|
||||
.c3-region { |
||||
fill: #4682b4; |
||||
fill-opacity: .1 |
||||
} |
||||
|
||||
.c3-brush .extent { |
||||
fill-opacity: .1 |
||||
} |
||||
|
||||
.c3-legend-item { |
||||
font-size: 12px |
||||
} |
||||
|
||||
.c3-legend-item-hidden { |
||||
opacity: .15 |
||||
} |
||||
|
||||
.c3-legend-background { |
||||
opacity: .75; |
||||
fill: #fff; |
||||
stroke: #d3d3d3; |
||||
stroke-width: 1 |
||||
} |
||||
|
||||
.c3-title { |
||||
font-size: 14px |
||||
} |
||||
|
||||
.c3-tooltip-container { |
||||
z-index: 10 |
||||
} |
||||
|
||||
.c3-tooltip { |
||||
padding: 10px; |
||||
border-collapse: collapse; |
||||
border-spacing: 0; |
||||
background-color: #222; |
||||
fill: #BBB; |
||||
color: #BBB; |
||||
font-size: 12px; |
||||
display: block; |
||||
min-width: 90px |
||||
} |
||||
|
||||
.c3-tooltip td { |
||||
font-size: 13px; |
||||
padding: 3px; |
||||
background-color: #1E2229 |
||||
} |
||||
|
||||
.c3-tooltip td>span { |
||||
display: inline-block; |
||||
width: 10px; |
||||
height: 10px; |
||||
margin-right: 6px |
||||
} |
||||
|
||||
.c3-tooltip td.value { |
||||
text-align: right |
||||
} |
||||
|
||||
.c3-area { |
||||
stroke-width: 0; |
||||
opacity: .2 |
||||
} |
||||
|
||||
.c3-chart-arcs-title { |
||||
dominant-baseline: middle; |
||||
font-size: 1.3em |
||||
} |
||||
|
||||
.c3-chart-arcs .c3-chart-arcs-background { |
||||
fill: #e0e0e0; |
||||
stroke: none |
||||
} |
||||
|
||||
.c3-chart-arcs .c3-chart-arcs-gauge-unit { |
||||
fill: #ccc; |
||||
font-size: 16px |
||||
} |
||||
|
||||
.c3-chart-arc .c3-gauge-value, |
||||
.c3-chart-arcs .c3-chart-arcs-gauge-max, |
||||
.c3-chart-arcs .c3-chart-arcs-gauge-min { |
||||
fill: #ccc |
||||
} |
||||
|
||||
.panel-blue .c3-grid line { |
||||
stroke: #11436d |
||||
} |
||||
|
||||
.panel-blue .c3 line, |
||||
.panel-blue .c3 path { |
||||
stroke: #4a8fca |
||||
} |
||||
|
||||
.panel-blue .c3 text { |
||||
fill: #abd8ff |
||||
} |
@ -0,0 +1,291 @@ |
||||
|
||||
$.post('https://settlement.yimian.xyz/api/getWeekData.php', function(res){ |
||||
res = JSON.parse(res); |
||||
|
||||
var daily_avg = ['data1']; |
||||
var daily_avg_week = ['data2']; |
||||
|
||||
res.data.reverse(); |
||||
res.data.forEach(function(i){ |
||||
daily_avg.push(i.val); |
||||
daily_avg_week.push(i.week_val); |
||||
}); |
||||
|
||||
|
||||
var chart1=c3.generate( { |
||||
bindto:"#lineGraph", data: { |
||||
columns:[["data1", 14, 28, 31, 49, 57, 59, 52, 48, 55, 58, 62, 60, 62, 58, 55, 61, 70, 80, 77, 78, 82, 98, 99, 121, 136, 115, 112, 120, 103, 117, 121, 126], ["data2", 3, 16, 19, 24, 27, 32, 38, 36, 32, 36, 40, 48, 41, 44, 46, 53, 58, 62, 65, 61, 64, 62, 59, 63, 87, 92, 72, 81, 75, 80, 97, 97]], names: { |
||||
data1: "onGoing", data2: "Completed" |
||||
} |
||||
, colors: { |
||||
data1: "#f0b518", data2: "#3a86c8" |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart2=c3.generate( { |
||||
bindto:"#splineGraph", data: { |
||||
columns:[["data1", 24, 28, 31, 49, 57, 59, 52, 48, 55, 58, 62, 60, 62, 58, 55, 61, 70, 80, 77, 78, 82, 98, 99, 105, 102, 95, 92, 100, 103, 117, 121, 126], ["data2", 15, 16, 19, 24, 27, 32, 38, 36, 32, 36, 40, 48, 41, 44, 46, 53, 58, 62, 65, 61, 64, 62, 59, 63, 67, 69, 72, 71, 75, 80, 65, 71]], types: { |
||||
data1: "spline", data2: "area-spline" |
||||
} |
||||
, names: { |
||||
data1: "Likes", data2: "Clicks" |
||||
} |
||||
, colors: { |
||||
data1: "#3a86c8", data2: "#c282e0" |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart3=c3.generate( { |
||||
bindto:"#areaSplineGraph", data: { |
||||
columns:[["data1", 24, 49, 52, 48, 62, 60, 62, 70, 80, 82, 95, 92, 100, 103, 117, 121, 136], ["data2", 15, 27, 39, 32, 40, 48, 46, 57, 64, 62, 59, 71, 75, 80, 65, 71, 102]], types: { |
||||
data1: "area-spline", data2: "area-spline" |
||||
} |
||||
, names: { |
||||
data1: "Male", data2: "Female" |
||||
} |
||||
, colors: { |
||||
data1: "#F782AA", data2: "#3a86c8" |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart4=c3.generate( { |
||||
bindto:"#stepGraph", data: { |
||||
columns:[["data1", 52, 59, 78, 102, 95, 92, 100, 48, 55, 58, 62, 60, 24, 28, 31, 49, 57, 103, 117, 121, 126], ["data2", 27, 32, 38, 36, 32, 36, 40, 15, 16, 82, 81, 85, 90, 95, 71, 19, 24, 44, 59, 73, 77, 89]], types: { |
||||
data1: "step", data2: "area-step" |
||||
} |
||||
, names: { |
||||
data1: "Twitter", data2: "LinkedIn" |
||||
} |
||||
, colors: { |
||||
data1: "#3a86c8", data2: "#f0b518" |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart5=c3.generate( { |
||||
bindto:"#barAreaGraph", data: { |
||||
columns:[daily_avg, daily_avg_week], types: { |
||||
data1: "bar", data2: "area" |
||||
} |
||||
, names: { |
||||
data1: "Payment", data2: "Ghost Payment" |
||||
} |
||||
, colors: { |
||||
data1: "#E9BB27", data2: "#3a86c8" |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart6=c3.generate( { |
||||
bindto:"#barGraph", data: { |
||||
columns:[["data1", 15, 58, 62, 87, 32, 58, 55, 21, 20, 30, 98, 10, 22, 98, 99, 105, 82, 57, 121, 78], ["data2", 21, 26, 30, 38, 11, 24, 36, 53, 58, 62, 65, 61, 64, 32, 45, 71, 38, 23, 65, 11]], type:"bar", names: { |
||||
data1: "Referrals", data2: "Signups" |
||||
} |
||||
, colors: { |
||||
data1: "#fee074", data2: "#66c0dc" |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart7=c3.generate( { |
||||
bindto:"#stackedBarGraph", data: { |
||||
x: 'x', |
||||
columns:[ |
||||
['x', '2010-01-01', '2011-01-01', '2012-01-01', '2013-01-01', '2014-01-01'], |
||||
|
||||
], type:"bar", names: { |
||||
data1: "Weekly Payment" |
||||
} |
||||
, colors: { |
||||
data1: "#1d73bd" |
||||
} |
||||
, groups:[["data1"]] |
||||
} |
||||
, grid: { |
||||
x: { |
||||
show: !0 |
||||
} |
||||
, y: { |
||||
show: !0 |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart8=c3.generate( { |
||||
bindto:"#scatterPlot", data: { |
||||
xs: { |
||||
Male: "male_x", Female: "female_x" |
||||
} |
||||
, columns:[["male_x", 3.5, 3, 3.2, 3.1, 3.6, 3.9, 3.4, 3.4, 2.9, 3.1, 3.7, 3.4, 3, 3, 4, 4.4, 3.9, 3.5, 3.8, 3.8, 3.4, 3.7, 3.6, 3.3, 3.4, 3, 3.4, 3.5, 3.4, 3.2, 3.1, 3.4, 4.1, 4.2, 3.1, 3.2, 3.5, 3.6, 3, 3.4, 3.5, 2.3, 3.2, 3.5, 3.8, 3, 3.8, 3.2, 3.7, 3.3], ["female_x", 3.2, 3.2, 3.1, 2.3, 2.8, 2.8, 3.3, 2.4, 2.9, 2.7, 2, 3, 2.2, 2.9, 2.9, 3.1, 3, 2.7, 2.2, 2.5, 3.2, 2.8, 2.5, 2.8, 2.9, 3, 2.8, 3, 2.9, 2.6, 2.4, 2.4, 2.7, 2.7, 3, 3.4, 3.1, 2.3, 3, 2.5, 2.6, 3, 2.6, 2.3, 2.7, 3, 2.9, 2.9, 2.5, 2.8], ["Male", .2, .2, .2, .2, .2, .4, .3, .2, .2, .1, .2, .2, .1, .1, .2, .4, .4, .3, .3, .3, .2, .4, .2, .5, .2, .2, .4, .2, .2, .2, .2, .4, .1, .2, .2, .2, .2, .1, .2, .2, .3, .3, .2, .6, .4, .3, .2, .2, .2, .2], ["Female", 1.4, 1.5, 1.5, 1.3, 1.5, 1.3, 1.6, 1, 1.3, 1.4, 1, 1.5, 1, 1.4, 1.3, 1.4, 1.5, 1, 1.5, 1.1, 1.8, 1.3, 1.5, 1.2, 1.3, 1.4, 1.4, 1.7, 1.5, 1, 1.1, 1, 1.2, 1.6, 1.5, 1.6, 1.5, 1.3, 1.3, 1.3, 1.2, 1.4, 1.2, 1, 1.3, 1.2, 1.3, 1.3, 1.1, 1.3]], type:"scatter", colors: { |
||||
Male: "#3a86c8", Female: "#dd5826" |
||||
} |
||||
} |
||||
, axis: { |
||||
x: { |
||||
label:"Male Visitors", tick: { |
||||
fit: !1 |
||||
} |
||||
} |
||||
, y: { |
||||
label: "Female Visitors" |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart9=c3.generate( { |
||||
bindto:"#pieChart", data: { |
||||
columns:[["Likes", 36], ["Shares", 62]], type:"pie", colors: { |
||||
Likes: "#91c46b", Shares: "#3a86c8" |
||||
} |
||||
, onclick:function(a, b) { |
||||
console.log("onclick", a, b) |
||||
} |
||||
, onmouseover:function(a, b) { |
||||
console.log("onmouseover", a, b) |
||||
} |
||||
, onmouseout:function(a, b) { |
||||
console.log("onmouseout", a, b) |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart10=c3.generate( { |
||||
bindto:"#donutChart", data: { |
||||
columns:[["Likes", 32], ["Shares", 87], ["Clicks", 51]], type:"donut", colors: { |
||||
Likes: "#c282e0", Shares: "#c38fbb", Clicks: "#F782AA" |
||||
} |
||||
, onclick:function(a, b) { |
||||
console.log("onclick", a, b) |
||||
} |
||||
, onmouseover:function(a, b) { |
||||
console.log("onmouseover", a, b) |
||||
} |
||||
, onmouseout:function(a, b) { |
||||
console.log("onmouseout", a, b) |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart11=c3.generate( { |
||||
bindto:".accountValue", padding: { |
||||
top: 10, left: 40 |
||||
} |
||||
, data: { |
||||
columns:[["data1", 18, 22, 90, 33, 19, 21, 28, 21, 19, 43, 23, 34, 55, 43, 33, 77, 33, 87, 46, 39, 51, 32, 66, 99, 32, 54, 33, 24, 54, 22, 37, 76, 67, 89, 34, 12, 77, 99, 59, 66, 28, 77, 39, 60, 66, 99, 32, 54, 33, 24, 54, 22, 37, 76, 67, 89, 34, 12, 77, 99, 59, 66, 28, 77, 39, 60]], types: { |
||||
data1: "area" |
||||
} |
||||
, names: { |
||||
data1: "Account Val" |
||||
} |
||||
, colors: { |
||||
data1: "#c38fbb" |
||||
} |
||||
} |
||||
, axis: { |
||||
y: { |
||||
tick: { |
||||
count: 3 |
||||
} |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart12=c3.generate( { |
||||
bindto:"#domestic", data: { |
||||
columns:[["Domestic", 70], ["International", 120]], type:"pie", colors: { |
||||
Domestic: "#E24B46", International: "#1d73bd" |
||||
} |
||||
} |
||||
, legend: { |
||||
show: !1 |
||||
} |
||||
, tooltip: { |
||||
show: !1 |
||||
} |
||||
, pie: { |
||||
label: { |
||||
show: !1 |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart13=c3.generate( { |
||||
bindto:"#domain", data: { |
||||
columns:[["Com", 100], ["Org", 20], ["Net", 15], ["Biz", 10], ["Others", 5]], type:"pie", colors: { |
||||
Com: "#fa9255", Org: "#fee074", Net: "#47BCC7", Biz: "#F782AA", Others: "#aed048" |
||||
} |
||||
} |
||||
, legend: { |
||||
show: !1 |
||||
} |
||||
, tooltip: { |
||||
show: !1 |
||||
} |
||||
, pie: { |
||||
label: { |
||||
show: !1 |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart14=c3.generate( { |
||||
bindto:"#imgFonts", data: { |
||||
columns:[["Images", 170], ["Fonts", 50], ["Text", 30]], type:"pie", colors: { |
||||
Images: "#5c6bc2", Fonts: "#C790E1", Text: "#F782AA" |
||||
} |
||||
} |
||||
, legend: { |
||||
show: !1 |
||||
} |
||||
, tooltip: { |
||||
show: !1 |
||||
} |
||||
, pie: { |
||||
label: { |
||||
show: !1 |
||||
} |
||||
} |
||||
} |
||||
|
||||
), |
||||
chart5=c3.generate( { |
||||
bindto:"#globalLocal", data: { |
||||
columns:[["data2", 15, 19, 27, 32, 38, 36, 32, 36, 40, 48, 46, 53, 58, 62, 65, 99]], types: { |
||||
data2: "area-spline" |
||||
} |
||||
, names: { |
||||
data2: "Active Users" |
||||
} |
||||
, colors: { |
||||
data2: "#52bf8a" |
||||
} |
||||
} |
||||
, axis: { |
||||
x: { |
||||
show: !1 |
||||
} |
||||
, y: { |
||||
show: !1 |
||||
} |
||||
} |
||||
} |
||||
|
||||
); |
||||
|
||||
}); |
@ -0,0 +1,7 @@ |
||||
/* Javascript plotting library for jQuery, version 0.8.3. |
||||
|
||||
Copyright (c) 2007-2014 IOLA and Ole Laursen. |
||||
Licensed under the MIT license. |
||||
|
||||
*/ |
||||
(function($,e,t){"$:nomunge";var i=[],n=$.resize=$.extend($.resize,{}),a,r=false,s="setTimeout",u="resize",m=u+"-special-event",o="pendingDelay",l="activeDelay",f="throttleWindow";n[o]=200;n[l]=20;n[f]=true;$.event.special[u]={setup:function(){if(!n[f]&&this[s]){return false}var e=$(this);i.push(this);e.data(m,{w:e.width(),h:e.height()});if(i.length===1){a=t;h()}},teardown:function(){if(!n[f]&&this[s]){return false}var e=$(this);for(var t=i.length-1;t>=0;t--){if(i[t]==this){i.splice(t,1);break}}e.removeData(m);if(!i.length){if(r){cancelAnimationFrame(a)}else{clearTimeout(a)}a=null}},add:function(e){if(!n[f]&&this[s]){return false}var i;function a(e,n,a){var r=$(this),s=r.data(m)||{};s.w=n!==t?n:r.width();s.h=a!==t?a:r.height();i.apply(this,arguments)}if($.isFunction(e)){i=e;return a}else{i=e.handler;e.handler=a}}};function h(t){if(r===true){r=t||1}for(var s=i.length-1;s>=0;s--){var l=$(i[s]);if(l[0]==e||l.is(":visible")){var f=l.width(),c=l.height(),d=l.data(m);if(d&&(f!==d.w||c!==d.h)){l.trigger(u,[d.w=f,d.h=c]);r=t||true}}else{d=l.data(m);d.w=0;d.h=0}}if(a!==null){if(r&&(t==null||t-r<1e3)){a=e.requestAnimationFrame(h)}else{a=setTimeout(h,n[o]);r=false}}}if(!e.requestAnimationFrame){e.requestAnimationFrame=function(){return e.webkitRequestAnimationFrame||e.mozRequestAnimationFrame||e.oRequestAnimationFrame||e.msRequestAnimationFrame||function(t,i){return e.setTimeout(function(){t((new Date).getTime())},n[l])}}()}if(!e.cancelAnimationFrame){e.cancelAnimationFrame=function(){return e.webkitCancelRequestAnimationFrame||e.mozCancelRequestAnimationFrame||e.oCancelRequestAnimationFrame||e.msCancelRequestAnimationFrame||clearTimeout}()}})(jQuery,this);(function($){var options={};function init(plot){function onResize(){var placeholder=plot.getPlaceholder();if(placeholder.width()==0||placeholder.height()==0)return;plot.resize();plot.setupGrid();plot.draw()}function bindEvents(plot,eventHolder){plot.getPlaceholder().resize(onResize)}function shutdown(plot,eventHolder){plot.getPlaceholder().unbind("resize",onResize)}plot.hooks.bindEvents.push(bindEvents);plot.hooks.shutdown.push(shutdown)}$.plot.plugins.push({init:init,options:options,name:"resize",version:"1.0"})})(jQuery); |
@ -0,0 +1,14 @@ |
||||
/* |
||||
* jquery.flot.tooltip |
||||
* |
||||
* desc: create tooltip with values of hovered point on the graph,
|
||||
support many series, time mode, stacking and pie charts |
||||
you can set custom tip content (also with use of HTML tags) and precision of values |
||||
* version: 0.4.4 |
||||
* author: Krzysztof Urbas @krzysu [myviews.pl] with help of @ismyrnow |
||||
* website: https://github.com/krzysu/flot.tooltip
|
||||
*
|
||||
* released under MIT License, 2012 |
||||
*/ |
||||
|
||||
(function(a){var b={tooltip:false,tooltipOpts:{content:"%s | X: %x | Y: %y.2",dateFormat:"%y-%0m-%0d",shifts:{x:-10,y:-60},defaultTheme:true}};var c=function(b){var c={x:0,y:0};var d=b.getOptions();var e=function(a){c.x=a.x;c.y=a.y};var f=function(a){var b={x:0,y:0};b.x=a.pageX;b.y=a.pageY;e(b)};var g=function(b){var c=new Date(b);return a.plot.formatDate(c,d.tooltipOpts.dateFormat)};b.hooks.bindEvents.push(function(b,e){var i=d.tooltipOpts;var j=b.getPlaceholder();var k;if(d.tooltip===false)return;if(a("#flotTip").length>0){k=a("#flotTip")}else{k=a("<div />").attr("id","flotTip");k.appendTo("body").hide().css({position:"absolute"});if(i.defaultTheme){k.css({background:"#000000","z-index":"100",padding:"0.6em 0.6em","border-radius":"0.2em","font-size":"0.8em",border:"1px solid #000000", color: "#fff"})}}a(j).bind("plothover",function(a,b,e){if(e){var f;if(d.xaxis.mode==="time"||d.xaxes[0].mode==="time"){f=h(i.content,e,g)}else{f=h(i.content,e)}k.html(f).css({left:c.x+i.shifts.x,top:c.y+i.shifts.y}).show()}else{k.hide().html("")}});e.mousemove(f)});var h=function(a,b,c){var d=/%p\.{0,1}(\d{0,})/;var e=/%s/;var f=/%x\.{0,1}(\d{0,})/;var g=/%y\.{0,1}(\d{0,})/;if(typeof b.series.percent!=="undefined"){a=i(d,a,b.series.percent)}if(typeof b.series.label!=="undefined"){a=a.replace(e,b.series.label)}if(typeof c==="function"){a=a.replace(f,c(b.series.data[b.dataIndex][0]))}else if(typeof b.series.data[b.dataIndex][0]==="number"){a=i(f,a,b.series.data[b.dataIndex][0])}if(typeof b.series.data[b.dataIndex][1]==="number"){a=i(g,a,b.series.data[b.dataIndex][1])}return a};var i=function(a,b,c){var d;if(b.match(a)!=="null"){if(RegExp.$1!==""){d=RegExp.$1;c=c.toFixed(d)}b=b.replace(a,c)}return b}};a.plot.plugins.push({init:c,options:b,name:"tooltip",version:"0.4.4"})})(jQuery) |
@ -0,0 +1,119 @@ |
||||
/** |
||||
* Turboslider - An open source jquery slider |
||||
* |
||||
* @author Baianat |
||||
* @copyright 2015 Baianat |
||||
* @link http://www.baianat.com |
||||
* @license MIT permissive license http://www.baianat.com |
||||
* @version 1.0.0 |
||||
* @package TurboSlider |
||||
* |
||||
*/ |
||||
|
||||
|
||||
/* Main Wrapper for turbo slider */ |
||||
|
||||
.TurboWrapper { |
||||
position: relative; |
||||
} |
||||
|
||||
/* Main item for turbo slider better to leave this settings unmodified */ |
||||
|
||||
.item { |
||||
-moz-user-select : none ; |
||||
user-select: none; |
||||
opacity: 1 ; |
||||
} |
||||
|
||||
|
||||
/* Turbo navigation container */ |
||||
|
||||
.slider-navigation |
||||
{ |
||||
text-align: center; |
||||
} |
||||
|
||||
|
||||
/* Turbo default dot container class */ |
||||
|
||||
.dotsClass |
||||
{ |
||||
margin-top: 5px ; |
||||
} |
||||
|
||||
/* Turbo default dot item class */ |
||||
|
||||
|
||||
.dotClass |
||||
{ |
||||
border-radius: 50%; |
||||
background: #525252; |
||||
width: 8px; |
||||
height: 8px; |
||||
margin:5px; |
||||
display:inline-block; |
||||
transition: 0.3s all; |
||||
} |
||||
|
||||
/* Turbo active dot item class */ |
||||
|
||||
.dotClass.active |
||||
{ |
||||
background: rgba(0,0,0,.3); |
||||
} |
||||
|
||||
/* Turbo vertical dots class */ |
||||
|
||||
.vertical-dots { |
||||
position: absolute; |
||||
right: 0; |
||||
top: 50%; |
||||
transform: rotate(90deg); |
||||
margin: 0; |
||||
} |
||||
|
||||
|
||||
/* Turbo video wrapper class */ |
||||
|
||||
.turbo-video-wrapper { |
||||
position: relative; |
||||
height: 100%; |
||||
} |
||||
|
||||
/* Turbo video thumb class */ |
||||
|
||||
.turbo-video-thumb { |
||||
height: 100%; |
||||
background-repeat: no-repeat; |
||||
background-size: cover; |
||||
background-position: center center; |
||||
} |
||||
|
||||
/* Turbo video play class */ |
||||
|
||||
.turbo-video-play { |
||||
height: 50px; |
||||
width: 50px; |
||||
border-radius: 50%; |
||||
background: #CCC none repeat scroll 0% 0%; |
||||
position: absolute; |
||||
top: 50%; |
||||
left: 50%; |
||||
margin-left: -18px; |
||||
margin-top: -14px; |
||||
} |
||||
|
||||
/* Turbo default navigation next and prev */ |
||||
|
||||
.turbo-prev, .turbo-next { |
||||
border: 2px solid #FE623C; |
||||
border-radius: 5px; |
||||
color: #fff; |
||||
cursor: pointer; |
||||
display: inline-block; |
||||
font-size: 14px; |
||||
margin: 5px; |
||||
padding: 6px 20px; |
||||
-moz-user-select: none; |
||||
} |
||||
|