<!DOCTYPE html>
|
<html>
|
<head>
|
<meta charset="utf-8">
|
<title>推送预览</title>
|
<meta name="viewport" content="width=device-width, viewport-fit=cover,initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
|
<link rel="stylesheet" type="text/css" href="./css/base.css" />
|
<link rel="stylesheet" type="text/css" href="./css/orderpush.css" />
|
<script>
|
window.onresize = function() {
|
document.documentElement.style.fontSize = document.documentElement.clientWidth / 7.5 + 'px';
|
};
|
window.onresize();
|
</script>
|
<script src="https://apps.bdimg.com/libs/jquery/2.1.4/jquery.min.js"></script>
|
<script src="http://img.flqapp.com/resource/js/app2019112217.js"></script>
|
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
|
</head>
|
<body>
|
<div id="root">
|
<div class="previewType">预览推送类型</div>
|
|
<div class="div_applycategory_conent_bg">
|
<div class="div_vip_1" @click="selectvip(1)">
|
团队订单
|
<img src="img/icon_select.png" class="img_select_1">
|
</div>
|
<!-- <div class="div_vip_2" @click="selectvip(2)">
|
分享订单
|
<img src="img/icon_select.png" class="img_select_2">
|
</div> -->
|
</div>
|
|
<div class="pushCount">推送数量</div>
|
<div class="div_input_content_bg">
|
<input id="inpunt_id" class="input" type="number" placeholder="最多支持50条,例如:30条" @focus="focus()" @blur="blur()">
|
</div>
|
|
<!-- 重要提示 -->
|
<!-- <div class="div_tips">
|
<div class="div_tips_title">重要提示</div>
|
<div class="div_tips_content">
|
1.本页数据仅供数据预览使用,不可用作其他用途;<br>
|
2.本页仅对超级会员开放预览使用,且仅支持在板栗快省App中打开;<br>
|
3.系统将会记录上一次填写的预览数据;<br>
|
<span style="color: #E5005C;">4.提交预览后,系统会让相关页面保留预览数据10分钟,10分钟后恢复到非预览数据。</span>
|
</div>
|
<div style="height: 0.41rem;"></div>
|
</div> -->
|
|
<!-- 提交申请 -->
|
<div class="div_commit">
|
<div class="commitInfo" @click="commitInfo">{{buttonName}}</div>
|
</div>
|
</div>
|
</body>
|
|
<script>
|
var host = "http://api.flqapp.com";
|
var host1 = "http://apph5.banliapp.com";
|
$(function() {
|
var app = new Vue({
|
el: '#root',
|
data: {
|
type: '1',
|
img_select_vip: 1,
|
buttonName: '提交申请'
|
},
|
watch: {},
|
methods: {
|
focus: function() {
|
this.scrollTop = document.scrollingElement.scrollTop;
|
|
},
|
|
blur: function() {
|
document.scrollingElement.scrollTo(0, this.scrollTop);
|
},
|
|
selectvip: function(type) {
|
if (app.img_select_vip == type) return;
|
|
$('.div_vip_' + app.img_select_vip).css({
|
'color': '#000000',
|
'background-color': '#ffffff'
|
});
|
$('.img_select_' + app.img_select_vip).css('opacity', '0');
|
|
$('.div_vip_' + type).css({
|
'color': '#E5005B',
|
'background-color': '#FFD1E4'
|
});
|
$('.img_select_' + type).css('opacity', '1');
|
|
if (type == 1) {
|
app.type = '1';
|
|
} else if (type == 2) {
|
app.type = '2';
|
}
|
|
app.img_select_vip = type;
|
},
|
|
commitInfo: function() {
|
|
var num = $('#inpunt_id').val();
|
|
if (num.length == 0 || num == null) {
|
yesApp.toast('请将信息填写完整')
|
return;
|
}
|
|
if (isNaN(num)) {
|
yesApp.toast('请输入正确的格式')
|
return;
|
}
|
|
yesApp.showLoading();
|
var uid = yesApp.getUid();
|
var params = {
|
uid: uid,
|
type: app.type,
|
num: num
|
};
|
params = yesApp.getRequestBaseParams(params);
|
|
$.ajax({
|
type: "GET",
|
data: JSON.parse(params),
|
url: host + "/fanli/api/v2/preview/saveOrderInfo",
|
dataType: "jsonp",
|
async: false,
|
success: function(result) {
|
yesApp.hideLoading();
|
if (result.code == 0) {
|
yesApp.toast(result.data);
|
|
} else {
|
yesApp.toast(result.msg);
|
}
|
},
|
error: function(XMLHttpRequest, textStatus, errorThrown) {
|
yesApp.hideLoading();
|
if (textStatus === 'timeout') {
|
alert('請求超時');
|
setTimeout(function() {
|
alert('重新请求');
|
}, 2000);
|
}
|
}
|
});
|
}
|
}
|
});
|
});
|
</script>
|
</html>
|