Commit 6279386f authored by 华国豪's avatar 华国豪 🙄

回馈页面部分代码

parent f6c2a962
......@@ -112,4 +112,19 @@ input[type=button], input[type=submit], input[type=file], button { cursor: point
}
}
@font-face {
font-family: "PingFangR";
src: url("../fonts/Semibold.eot"); /* IE9 */
src: url("../fonts/Semibold.eot?#iefix") format("embedded-opentype"), /* IE6-IE8 */
url("../fonts/Semibold.woff") format("woff"), /* chrome, firefox */
url("../fonts/Semibold.ttf") format("truetype"); /* chrome, firefox, opera, Safari, Android, iOS 4.2+ */
font-style: normal;
font-weight: normal;
}
@font-face {
font-family: "lingxin";
src: url("../fonts/lingxin.ttf") format("truetype"); /* chrome, firefox, opera, Safari, Android, iOS 4.2+ */
font-style: normal;
font-weight: normal;
}
\ No newline at end of file
.wrap{width:100%;height:100%;overflow:hidden}
.wrap2{width:100%;height:1000%;transition:.3s linear}
.page{
width:100%;
height:10%;
background:url('../images/huikui/bg-img.png');
font-size:.12rem;
background-repeat: no-repeat;
background-size: 100% 100%;
padding: 12.34% 0 0 0;
box-sizing: border-box;
background-color: #fff8f5;
}
.page .tit,.page .content,.page .tit2{
padding-left: 12.4%;
}
.fan{position: fixed;width: 100%;text-align: center;z-index: 2;}
.fan-up{
top: .2rem;
font-size: .16rem;
}
.fan-down{
bottom: .2rem;
font-size: .16rem;
}
.page .tit img{
width: 47%;
}
.red{
color: #C04843;
}
.page .content{
margin-top: 5%;
line-height: 2em;
font-size: 1.4em;
font-family: 'PingFangR';
color: #475165;
}
.page1 .content>div{
margin-top: .2rem;
}
.page1 .rili-tit{
text-align: center;
color: white;
font-weight:bold;
-webkit-text-stroke:1px #A52924;
text-stroke:1px #A52924;
font-size: .15rem;
}
.page1 .rili-box {
height: 2.5rem;
width: 92%;
background:url('../images/huikui/page1_rili.png');
background-repeat: no-repeat;
background-size: 100% 100%;
margin: .3rem auto;
}
.page1 .rili-box>div{
padding: .6rem .4rem .4rem .4rem;
transform: rotate(6deg);
-ms-transform: rotate(6deg);
-moz-transform: rotate(6deg);
-webkit-transform: rotate(6deg);
-o-transform: rotate(6deg);
}
.page1 .rili>div{
width: 14.2%;
height: .2rem;
float: left;
font-family: 'lingxin';
font-size: .14rem;
}
.page1 .rili>div span{
text-align: center;
color: #FFFFFF;
font-weight:bold;
-webkit-text-stroke:1px #A52924;
text-stroke:1px #A52924;
}
.page1 .rili .today{
border: solid 2px #fff;
border-radius: 50%;
min-width: .21rem;
min-height: .21rem;
display: inline-block;
}
.page .font-c04-s3{
color: #C04843;
font-size: .3rem;
}
.margint-20{
margin-top: .2rem;
}
.page2 .bottom-box{
width: 100%;
margin-top: .4rem;
position: absolute;
text-align: center;
}
.page2 .bottom-box img.page2_ren{
width: 98%;
position: relative;
z-index: 2;
}
.page2 .bottom-box img.page2_tanzi{
width: 80%;
position: relative;
bottom: 1.1rem;
right: -.8rem;
}
.page2 .bottom-box p{
position: absolute;
z-index: 3;
width: 100%;
padding-top: .75rem;
font-size: .12rem;
padding-left: .05rem;
font-family: 'PingFangR';
color: #475165;
}
.page3 .page3_shiz{
width: 80%;
padding-left: 5%;
padding-top: .8rem;
}
.page3 .page3_shiz img{
width: 100%;
}
.page4{
padding-left: .1rem;
}
.page4 .page4_shiz img{
width: 93%;
}
.page5{
font-family: 'PingFangR';
color: #475165;
}
.page5 .content{
margin-top: 0;
}
.page5 #fenshu{
font-size: 1rem;
color: #E27E6E;
font-weight: bold;
}
.page5 .danmu{
height: 1.5rem;
position: relative;
overflow: hidden;
width: 100%;
}
.page5 .danmu div{
font-size: .14rem;
background:rgba(255,255,255,0.6);
border:2px solid rgba(226, 126, 110, 1);
border-radius:12px;
height: .2rem;
line-height: .2rem;
overflow: hidden;
color:#E27E6E;
padding: .01rem .04rem;
width: auto;
position:absolute;
left:0;
top:0;
}
.page5 .page5_img{
width: 80%;
padding-left: .2rem;
}
.page5 .page5_img img{
width: 100%;
}
.page6 .line_box div{
width: 88%;
height: 1.8rem;
margin: .3rem auto 0 auto;
}
.page6 .xianlu,.page6 .nianling{
background:url('../images/huikui/page6_xianl.png');
background-repeat: no-repeat;
background-size: 100% 100%;
}
.page6 .nianling{
background:url('../images/huikui/page6_nian.png');
background-repeat: no-repeat;
background-size: 100% 100%;
}
\ No newline at end of file
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, target-densitydpi=device-dpi" />
<meta name="screen-orientation" content="portrait">
</meta>
<meta name="x5-orientation" content="portrait">
</meta>
<title>意见调查详情</title>
<style>
body, h1, h2, h3, h4, h5, h6, hr, p, blockquote, dl, dt, dd, ul, ol, li, pre, form, fieldset, legend, button, input, textarea, th, td { margin:0; padding:0; }
h1, h2, h3, h4, h5, h6{ font-size:100%; }
address, cite, dfn, em, var { font-style:normal; }
code, kbd, pre, samp { font-family:couriernew, courier, monospace; }
small{ font-size:12px; }
ul, ol { list-style:none; }
a { text-decoration:none; }
a:hover { text-decoration:underline; }
sup { vertical-align:text-top; }
sub{ vertical-align:text-bottom; }
legend { color:#000; }
fieldset, img { border:0; }
button, input, select, textarea { font-size:100%; }
table { border-collapse:collapse; border-spacing:0; }
*{
color: #5b5653;
}
.main{
padding: 1.5rem;
}
.tit{
font-size: 2rem;
text-align: center;
margin-bottom: .5rem;
}
.sub_tit{
font-size: 1.4rem;
margin-bottom: .4rem;
}
.indet_2{
text-indent: 2.4rem;
}
.tit_det{
text-indent: 2.4rem;
font-size: 1rem;
}
table{
margin-top: .5rem;
}
tr td{
padding: .5rem;
border: 1px solid #5b5653;
font-size: 1rem;
}
#LeaderName{
width: 2rem;
}
.qianming{
margin-top: .5rem;
display: flex;
justify-content: space-between;
}
.qianming label{
margin-right: .2rem;
}
</style>
</head>
<body>
<div class="main">
<p class="tit">印象旅游服务意见表</p>
<p class="sub_tit">亲爱的旅客:</p>
<div class="tit_det">
<p>感谢与您同行,让我们的旅行更加圆满!</p>
<p>我们十分珍视倾听您的声音。它将是我们改善服务的重要基础。</p>
<p>最后,需要您花一点点时间填写此表。诚挚地感谢您!</p>
</div>
<table id="table">
<tr>
<td>线路:</td>
<td id="LineName"></td>
<td>出发时间:</td>
<td id="StartDateStr"></td>
<td>领队:</td>
<td id="LeaderName"></td>
</tr>
<tr>
<td>您的报名公司:</td>
<td id="BranchName"></td>
<td>报名接待员:</td>
<td id="ContactName"></td>
<td>专业度及服务评价:</td>
<td></td>
</tr>
<tr>
<td>旅客意见</td>
<td>非常满意</td>
<td>满意</td>
<td>基本合格</td>
<td>不满意</td>
<td>评价</td>
</tr>
</table>
<div class="qianming">
<label>旅客签名:<span id="name"></span></label>
<label>手机:<span id="phone"></span></label>
<label>日期:<span id="day"></span></label>
</div>
</div>
<script type="text/javascript" src="../js/jquery-1.10.2.js"></script>
<script type="text/javascript" src="../js/md5.js"></script>
<script type="text/javascript" src="../js/layer/layer.js"></script>
<script type="text/javascript" src="../js/mian.js"></script>
<script type="text/javascript" src="../js/autosize.js"></script>
<script>
var str = location.href; //取得整个地址栏
var param = str.substr(str.indexOf("?")+1);
let html = '';
param = param.split('&')
let ID = param[0].split('=')[1],
name = decodeURI(param[1].split('=')[1]),
phone = param[2].split('=')[1];
console.log(ID,name,phone)
$.ajax({
type: "POST",
url: `${getApiUrl().urlPost}`,
contentType: "application/json",
data: getAjaxData('survey_post_GetGuestSurveyDetails', {SurveyID: ID}),
async: false,
success: function (res) {
if (res.resultCode === 1) {
let data = res.data;
$("#LineName").text(data.obj.LineName)
$("#StartDateStr").text(data.obj.StartDateStr)
$("#LeaderName").text(data.obj.LeaderName ? data.obj.LeaderName : '')
$("#BranchName").text(data.obj.ContactName.split('(')[0])
$("#ContactName").text(data.obj.ContactName.split('(')[1].split(')')[0])
$("#name").text(name)
$("#phone").text(phone)
$("#day").text(data.surverList[0].CreateDate.split('T')[0].replace(/-/g,'.'))
let SurveyType1 = [],
SurveyType2 = []
for (let i = 0; i < data.surverList.length; i++) {
if (data.surverList[i].SurveyType === 1) {
SurveyType1.push(data.surverList[i])
} else {
SurveyType2.push(data.surverList[i])
}
}
for (let i = 0; i < SurveyType1.length; i++) {
html += `<tr>
<td>${SurveyType1[i].Title}</td>
<td>${SurveyType1[i].ScoreNum === 5 ? '√' : '' }</td>
<td>${SurveyType1[i].ScoreNum === 4 ? '√' : '' }</td>
<td>${SurveyType1[i].ScoreNum === 3 ? '√' : '' }</td>
<td>${SurveyType1[i].ScoreNum === 2 || SurveyType1[i].ScoreNum === 1 ? '√' : '' }</td>
<td>无</td>
</tr>`
}
html += `<tr>
<td colspan="6">
<p>您参加的自费项目有:</p>
<p></p>
</td>
</tr>`
for (let i = 0; i < SurveyType2.length; i++) {
if (SurveyType2[i].Title.indexOf('自费') !== -1) {
html += `<tr>
<td colspan="6">
<p>您参加的自费项目有:</p>
<p class="indet_2">${SurveyType2[i].TextContent}</p>
</td>
</tr>`
}
if (SurveyType2[i].Title.indexOf('建议') !== -1) {
html += `<tr>
<td colspan="6">
<p>您给印象旅游的评价及建议:</p>
<p class="indet_2">${SurveyType2[i].TextContent}</p>
</td>
</tr>`
}
if (SurveyType2[i].Title.indexOf('想去') !== -1) {
html += `<tr>
<td colspan="6">
<p>您下次出游最想去哪里?</p>
<p class="indet_2">${SurveyType2[i].TextContent}</p>
</td>
</tr>`
}
if (SurveyType2[i].Title.indexOf('优先考虑') !== -1) {
html += `<tr>
<td colspan="6">
<p>下次出游是否优先考虑印象产品?</p>
<p class="indet_2">${SurveyType2[i].TextContent}</p>
</td>
</tr>`
}
}
html += `<tr>
<td>
<p>备注</p>
</td>
<td colspan="5">
本表是旅游团队服务的衡量标准。请妥善填写!谢谢合作!
</td>
</tr>`
$("#table").append(html)
}
},
error: function (res) {
}
});
</script>
</body>
</html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, target-densitydpi=device-dpi" />
<meta name="screen-orientation" content="portrait">
</meta>
<meta name="x5-orientation" content="portrait">
</meta>
<title>意见调查详情</title>
<style>
body, h1, h2, h3, h4, h5, h6, hr, p, blockquote, dl, dt, dd, ul, ol, li, pre, form, fieldset, legend, button, input, textarea, th, td { margin:0; padding:0; }
h1, h2, h3, h4, h5, h6{ font-size:100%; }
address, cite, dfn, em, var { font-style:normal; }
code, kbd, pre, samp { font-family:couriernew, courier, monospace; }
small{ font-size:12px; }
ul, ol { list-style:none; }
a { text-decoration:none; }
a:hover { text-decoration:underline; }
sup { vertical-align:text-top; }
sub{ vertical-align:text-bottom; }
legend { color:#000; }
fieldset, img { border:0; }
button, input, select, textarea { font-size:100%; }
table { border-collapse:collapse; border-spacing:0; }
*{
color: #5b5653;
}
.main{
padding: 1.5rem;
}
.tit{
font-size: 2rem;
text-align: center;
margin-bottom: .5rem;
}
.sub_tit{
font-size: 1.4rem;
margin-bottom: .4rem;
}
.indet_2{
text-indent: 2.4rem;
}
.tit_det{
text-indent: 2.4rem;
font-size: 1rem;
}
table{
margin-top: 2.5rem;
width: 100%;
}
tr td{
padding: .5rem;
border: 1px solid #5b5653;
font-size: 1rem;
}
#LeaderName{
/* width: 2rem; */
}
.qianming{
margin-top: 2.5rem;
display: flex;
justify-content: space-between;
}
.qianming label{
margin-right: .2rem;
}
.main{
width: 720px;
margin: 0 auto;
margin-top: -50px;
}
#table td,.qianming span{
color: #111;
}
#table td._name,.qianming label{
color: #5d5d5d;
}
.top-img img{
width: 100%;
}
</style>
</head>
<body>
<div>
<button>提交</button>
</div>
<script type="text/javascript" src="../js/jquery-1.10.2.js"></script>
<script type="text/javascript" src="../js/md5.js"></script>
<script type="text/javascript" src="../js/layer/layer.js"></script>
<script type="text/javascript" src="../js/mian.js"></script>
<script>
$.ajax({
type: "POST",
url: `${getApiUrl().urlPost}`,
contentType: "application/json",
data: getAjaxData('survey_post_GetGuestSurveyDetails', {}),
async: false,
success: function (res) {
if (res.resultCode === 1) {
}
},
error: function (res) {
}
});
</script>
</body>
</html>
......@@ -7,43 +7,217 @@
<meta content="yes" name="mobile-web-app-capable">
<meta content="yes" name="apple-mobile-web-app-capable" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<title>整页滑屏示例</title>
<title>回馈</title>
<link rel="stylesheet" href="../css/animate.css">
<style type="text/css">
*{padding:0;margin:0}
body,html{height:100%;background-color:#000}
.wrap{width:100%;height:100%;overflow:hidden}
.wrap2{width:100%;height:1000%;transition:.3s linear}
.page{width:100%;height:10%;background-color:#fdfdfd;font-size:12px;line-height:400px;text-align:center;font-weight:700}
.fan{position: fixed;width: 100%;text-align: center;z-index: 2;}
.fan-up{top: 1rem;}
.fan-down{bottom: 1rem;}
</style>
<link rel="stylesheet" href="../css/cssReset.css">
<script type="text/javascript" src="../js/autosize2.js"></script>
<link rel="stylesheet" href="../css/huikui.css">
</head>
<body>
<div class="wrap" id="wrap">
<div class="fan fan-up animated fadeInDownBig" id="fan-up">上翻</div>
<div class="wrap2" id="wrap2">
<div class="page">我是第一屏内容</div>
<div class="page" style="background-color:#ccc;">我是第二屏内容</div>
<div class="page">我是第三屏内容</div>
<div class="page" style="background-color:#ccc;">我是第四屏内容</div>
<div class="page">我是第五屏内容</div>
<div class="page" style="background-color:#ccc;">我是第六屏内容</div>
<div class="page page1" id="page1">
<div class="tit animated fadeInLeft">
<img src="../images/huikui/page1_tit.png" alt="">
</div>
<div class="content">
<p><span class="red" id="year"></span><span class="red" id="month"></span><span class="red" id="day"></span></p>
<p>成为印象同行</p>
<div>
<p><span id="CreateBy"></span>销售经理录入</p>
<p>您的资料</p>
<p>正式成为印象会员同行</p>
</div>
</div>
<div class="rili-box">
<div>
<p class="rili-tit" id="rili-tit"></p>
<div class="rili clearfix" id="rili">
</div>
</div>
</div>
</div>
<div class="page page2" id="page2">
<div class="tit">
<img src="../images/huikui/page2_tit.png" alt="">
</div>
<div class="content">
<p><span class="red year"></span>年里</p>
<p>销售经理上门拜访您<span class="num font-c04-s3"></span></p>
<div class="margint-20">
我们十分的愿意
</br>
倾听您的声音
</div>
</div>
<div class="bottom-box">
<p class="baifangjihua">
拜访
</br>
计划
</p>
<img class="page2_ren" src="../images/huikui/page2_ren.png" alt="">
<img class="page2_tanzi" src="../images/huikui/page2_tanzi.png" alt="">
</div>
</div>
<div class="page page3" id="page3">
<div class="tit">
<img src="../images/huikui/page3_tit.png" alt="">
</div>
<div class="content dingdany">
<p><span class="red" id="year"></span><span class="red" id="month"></span><span class="red" id="day"></span><span class="red" id="time"></span></p>
<p>我们收到了您的第<span class="num3 font-c04-s3">1</span></p>
<div class="margint-20">
<p>怀着无比激动与感恩的心</p>
</div>
</div>
<div class="content dingdann">
<p>我们暂未收到您的订单</p>
<div class="margint-20">
<p>我们待着与您的合作</p>
</div>
</div>
<div class="page3_shiz" >
<img src="../images/huikui/page3_shiz.png" alt="">
</div>
</div>
<div class="page page4" id="page4">
<div class="tit">
<img src="../images/huikui/page4_tit.png" alt="">
</div>
<div class="content dingdany">
<p><span class="red year4"></span></p>
<p class="margint-20">您累计交客<span class="num3 font-c04-s3" id="renshu"></span></p>
<p class="margint-20">交易额累计<span class="num3 font-c04-s3" id="jiaoyie"></span></p>
<p class="margint-20">感恩您对印象之旅的大力支持与信任</p>
</div>
<div class="page4_shiz" >
<img src="../images/huikui/page4_shiz.png" alt="">
</div>
</div>
<div class="page page5" id="page5">
<div class="tit2">
<span id="fenshu"></span>
</div>
<div class="content">
<p>这是您的客人对我们的总体评价</p>
</div>
<div class="danmu" id="danmu">
</div>
<div class="page5_img">
<img src="../images/huikui/page5_img.png" alt="">
</div>
</div>
<div class="page page6" id="page6">
<div class="tit">
<img src="../images/huikui/page6_tit.png" alt="">
</div>
<div class="content">
<p><span class="red year6"></span>年,您的客户来自哪里</p>
</div>
<div class="line_box">
<div class="xianlu margint-20">
</div>
<div class="nianling margint-20">
</div>
</div>
</div>
<div class="page page7" id="page7">我是第六屏内容</div>
<div class="page page8" id="page8">我是第六屏内容</div>
<div class="page page9" id="page9">我是第六屏内容</div>
</div>
<div class="fan fan-down animated fadeInUpBig" id="fan-down">下翻</div>
</div>
<script type="text/javascript" src="../js/jquery-1.10.2.js"></script>
<script type="text/javascript" src="../js/jquery.animateNumber.js"></script>
<script type="text/javascript" src="../js/md5.js"></script>
<script type="text/javascript" src="../js/mian.js"></script>
<script type="text/javascript" src="../js/layer/layer.js"></script>
<script type="text/javascript">
//重要!禁止移动端滑动的默认事件
// document.body.addEventListener('touchmove', function(event) {
// event = event ? event : window.event;
// if(event.preventDefault) {
// event.preventDefault()
// } else {
// event.returnValue = false
// }
// }, false)
var str = location.href,
param = str.substr(str.indexOf("?")+1),
dataObj = {},
FirstOrderCreateStr = [],
TextContentList = [],
danmuIndex = 0;
param = param.split('&');
let customerId = param[0].split('=')[1];
getData();
function getData(){
let msg = {
customerId: customerId
}
$.ajax({
type: "POST",
url: `${getApiUrl().urlPost}`,
contentType: "application/json",
data: getAjaxData("app_get_GetPersonalBills", msg),
async: false,
success: function(res) {
if (res.resultCode === 1) {
var CreateTime = res.data.CreateTime.split('-'),
year = CreateTime[0],
month = CreateTime[1],
day = CreateTime[2];
//最后一个参数为0,意为获取2018年10月一共多少天
var monthAllDay = new Date(year, month,0);
creatRili(day, monthAllDay.getDate());
dataObj = res.data;
$("#year").text(year);
$("#month").text(month);
$('#day').animateNumber({ number: day });
$("#CreateBy").text(res.data.CreateBy.split('(')[0])
$("#rili-tit").text( year + '年' + month + '月')
if (dataObj.FirstOrderCreateStr === '') {
$(".dingdany").hide()
$(".dingdann").show()
} else {
FirstOrderCreateStr = res.data.FirstOrderCreateStr.replace(' ', '-').replace(':', '-').split('-');
$(".dingdany").show()
$(".dingdann").hide()
}
// 弹幕
var danmu=document.getElementById('danmu');
var winH=danmu.clientHeight;
if(dataObj.evaluateList.TextContentList.length) {
TextContentList = dataObj.evaluateList.TextContentList
createDM()
}
} else {
layer.msg(res.message)
}
}
})
};
function creatRili(day, maxDay) {
$(".rili-box>div").hide()
let htmlStr = ''
for(let i = 1; i <= maxDay; i++) {
if (i == day) {
htmlStr += '<div class="animated"><span class="today">'+ i +'</span></div>'
} else {
htmlStr += '<div class="animated"><span>'+ i +'</span></div>'
}
}
$("#rili").html(htmlStr)
riliAnimated()
}
function riliAnimated(){
$("#rili div").each(function (index, ele) {
setTimeout(function (){
$(".rili-box>div").show()
$(ele).addClass('fadeIn')
}, 500)
})
}
$("#fan-up").hide()
var pages = function(obj) {
var box = document.getElementById(obj.wrap);
......@@ -77,7 +251,6 @@
};
//touchEnd
var touchend = function(event) {
console.log(moveY)
//位移小于+-50的不翻页
if(moveY < -50) n++;
if(moveY > 50) n--;
......@@ -86,6 +259,22 @@
if(n > len - 1) n = len - 1;
//重定位
box2.style.transform = 'translateY(' + (-n * 10) + '%)'; //根据百分比位置移动页面
// 翻页 加载页面动画
$("#page" + (n+1) + ">div.tit").addClass('animated fadeInLeft')
$("#page" + (n+1) + " .year").text(dataObj.Year)
$("#page" + (n+1) + " .num").animateNumber({ number: dataObj.VisiteCount });
$("#page" + (n+1) + " .baifangjihua").addClass('animated fadeIn')
if (FirstOrderCreateStr.length) {
$("#page" + (n+1) + " #year").text(FirstOrderCreateStr[0])
$("#page" + (n+1) + " #month").text(FirstOrderCreateStr[1])
$("#page" + (n+1) + " #day").text(FirstOrderCreateStr[2])
$("#page" + (n+1) + " #time").text(FirstOrderCreateStr[3] + ':' + FirstOrderCreateStr[4])
}
$("#page" + (n+1) + " #renshu").animateNumber({ number: dataObj.TotalGuest });
$("#page" + (n+1) + " #jiaoyie").animateNumber({ number: dataObj.TotalPrice });
$("#page" + (n+1) + " .year" + (n+1)).text(dataObj.Year)
$("#page" + (n+1) + " .year" + (n+1)).text(dataObj.Year)
$("#page" + (n+1) + " #fenshu").animateNumber({ number: dataObj.evaluateList.ScoreNum })
if (n == 0) {
$("#fan-up").hide()
} else {
......@@ -125,9 +314,48 @@
pages({
wrap: 'wrap', //.wrap的id
wrap2: 'wrap2', //.wrap2的id
len: 6, //一共有几页
len: 9, //一共有几页
n: 0 //页面一打开默认在第几页?第一页就是0,第二页就是1
});
// insert();
var timer2=setInterval(function(){
createDM();
},2000);
function createDM(){
var randomS=Math.floor(Math.random()*TextContentList.length);
var newli=document.createElement('div');
newli.innerHTML= TextContentList[randomS].TextContent;
newli.className='newli';
var newliL=danmu.clientWidth;
newli.style.left=newliL +'px';
if (danmuIndex == 0) {
newliT = '.1rem'
danmuIndex = 1
} else if (danmuIndex == 1){
newliT = '.6rem'
danmuIndex = 2
} else if (danmuIndex == 2){
newliT = '1.1rem'
danmuIndex = 0
}
newli.style.top= newliT;
danmu.appendChild(newli);
move(newli);
}
function move(obj){
var timer1=setInterval(function(){
// var danmu=document.getElementById('danmu');
var newliW=obj.clientWidth;
var run=obj.offsetLeft;
run--;
if (run<=-newliW) {
danmu.removeChild(obj);
clearInterval(timer1);
}
obj.style.left=run +'px';
}, 20)
}
</script>
</body>
......
/** @preserve jQuery animateNumber plugin v0.0.14
* (c) 2013, Alexandr Borisov.
* https://github.com/aishek/jquery-animateNumber
*/
// ['...'] notation using to avoid names minification by Google Closure Compiler
(function($) {
var reverse = function(value) {
return value.split('').reverse().join('');
};
var defaults = {
numberStep: function(now, tween) {
var floored_number = Math.floor(now),
target = $(tween.elem);
target.text(floored_number);
}
};
var handle = function( tween ) {
var elem = tween.elem;
if ( elem.nodeType && elem.parentNode ) {
var handler = elem._animateNumberSetter;
if (!handler) {
handler = defaults.numberStep;
}
handler(tween.now, tween);
}
};
if (!$.Tween || !$.Tween.propHooks) {
$.fx.step.number = handle;
} else {
$.Tween.propHooks.number = {
set: handle
};
}
var extract_number_parts = function(separated_number, group_length) {
var numbers = separated_number.split('').reverse(),
number_parts = [],
current_number_part,
current_index,
q;
for(var i = 0, l = Math.ceil(separated_number.length / group_length); i < l; i++) {
current_number_part = '';
for(q = 0; q < group_length; q++) {
current_index = i * group_length + q;
if (current_index === separated_number.length) {
break;
}
current_number_part = current_number_part + numbers[current_index];
}
number_parts.push(current_number_part);
}
return number_parts;
};
var remove_precending_zeros = function(number_parts) {
var last_index = number_parts.length - 1,
last = reverse(number_parts[last_index]);
number_parts[last_index] = reverse(parseInt(last, 10).toString());
return number_parts;
};
$.animateNumber = {
numberStepFactories: {
/**
* Creates numberStep handler, which appends string to floored animated number on each step.
*
* @example
* // will animate to 100 with "1 %", "2 %", "3 %", ...
* $('#someid').animateNumber({
* number: 100,
* numberStep: $.animateNumber.numberStepFactories.append(' %')
* });
*
* @params {String} suffix string to append to animated number
* @returns {Function} numberStep-compatible function for use in animateNumber's parameters
*/
append: function(suffix) {
return function(now, tween) {
var floored_number = Math.floor(now),
target = $(tween.elem);
target.prop('number', now).text(floored_number + suffix);
};
},
/**
* Creates numberStep handler, which format floored numbers by separating them to groups.
*
* @example
* // will animate with 1 ... 217,980 ... 95,217,980 ... 7,095,217,980
* $('#world-population').animateNumber({
* number: 7095217980,
* numberStep: $.animateNumber.numberStepFactories.separator(',')
* });
* @example
* // will animate with 1% ... 217,980% ... 95,217,980% ... 7,095,217,980%
* $('#salesIncrease').animateNumber({
* number: 7095217980,
* numberStep: $.animateNumber.numberStepFactories.separator(',', 3, '%')
* });
*
* @params {String} [separator=' '] string to separate number groups
* @params {String} [group_length=3] number group length
* @params {String} [suffix=''] suffix to append to number
* @returns {Function} numberStep-compatible function for use in animateNumber's parameters
*/
separator: function(separator, group_length, suffix) {
separator = separator || ' ';
group_length = group_length || 3;
suffix = suffix || '';
return function(now, tween) {
var negative = now < 0,
floored_number = Math.floor((negative ? -1 : 1) * now),
separated_number = floored_number.toString(),
target = $(tween.elem);
if (separated_number.length > group_length) {
var number_parts = extract_number_parts(separated_number, group_length);
separated_number = remove_precending_zeros(number_parts).join(separator);
separated_number = reverse(separated_number);
}
target.prop('number', now).text((negative ? '-' : '') + separated_number + suffix);
};
}
}
};
$.fn.animateNumber = function() {
var options = arguments[0],
settings = $.extend({}, defaults, options),
target = $(this),
args = [settings];
for(var i = 1, l = arguments.length; i < l; i++) {
args.push(arguments[i]);
}
// needs of custom step function usage
if (options.numberStep) {
// assigns custom step functions
var items = this.each(function(){
this._animateNumberSetter = options.numberStep;
});
// cleanup of custom step functions after animation
var generic_complete = settings.complete;
settings.complete = function() {
items.each(function(){
delete this._animateNumberSetter;
});
if ( generic_complete ) {
generic_complete.apply(this, arguments);
}
};
}
return target.animate.apply(target, args);
};
}(jQuery));
......@@ -3,7 +3,7 @@ let locationName = window.location.hostname;
function getApiUrl() {
let url = {
urlPost: "https://reborn.oytour.com/api/common/post",
//urlPost: locationName.indexOf('oytour') !== -1 ? "http://reborn.oytour.com/api/common/post" : "http://192.168.2.214:8082/api/common/post",
// urlPost: locationName.indexOf('oytour') !== -1 ? "http://reborn.oytour.com/api/common/post" : "http://192.168.2.65:8025/api/common/post",
//urlJava: locationName.indexOf('oytour') !== -1 ? "https://efficient.oytour.com/" : "http://192.168.2.215:9000/"
urlJava: "https://efficient.oytour.com/"
}
......
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 to comment