Commit 34a784c2 by Sweet Zhang

自动喜报

parent 37037e4d
This source diff could not be displayed because it is too large. You can view the blob instead.
ul, li {
list-style: none;
padding: 0;
margin: 0;
}
html, body {
width: 100%;
height: 100%;
font-size: 14px;
overflow: hidden;
}
.container {
position: relative;
padding: 0;
max-width: 640px;
min-width: 320px;
margin: 0 auto;
height: 100%;
background-color: #000;
}
.content {
position: absolute;
left: 0;
top: 52%;
color: #f4e1af;
font-size: 28px;
width: 100%;
display: flex;
flex-direction: column;
align-items: center;
padding: 0 30px;
word-break: break-all;
}
.relativeContent{
position: relative;
background: url(https://yindun-images.oss-cn-shanghai-finance-1-pub.aliyuncs.com/pic/lifeoffline.png) no-repeat left top;
width: 100%;
height: 100%;
background-size: cover;
}
@media (max-width: 320px) {
.content {
font-size: 20px;
}
}
\ No newline at end of file
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate">
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Expires" content="0">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no">
<title>银盾保险在线</title>
<link rel="stylesheet" href="./css/bootstrap.min.css">
<link rel="stylesheet" href="./css/style.css">
<link rel="shortcut icon" href="https://www.ydinsurance.cn/wp-content/uploads/2018/04/favicon.gif"/>
<script>
var _hmt = _hmt || [];
(function () {
var hm = document.createElement("script");
hm.src = "https://hm.baidu.com/hm.js?36b1eb7eec3b5dac9f97d887092b5b27";
var s = document.getElementsByTagName("script")[0];
s.parentNode.insertBefore(hm, s);
})();
</script>
</head>
<body>
<div class="container">
<div class="relativeContent">
<!--<img src="https://yindun-images.oss-cn-shanghai-finance-1-pub.aliyuncs.com/pic/onlinebackground.png" alt="喜报"-->
<!--id="goodNewsImg" class="img-responsive">-->
<div class="content">
<div id="insurerName"></div>
<div id="productName" style="margin: 3% 0;text-align: center"></div>
<div id="paymentPeriod" style="font-size:22px;"></div>
<div id="fyp" style="position: relative;font-size:40px;color:#edff00;font-weight: bold;border-radius: 30px"></div>
<div id="belongToCompany" style="margin: 3% 0;font-size: 22px;"></div>
<div style="font-weight: bold">
<span id="subordinateName" style="margin-right:10px;"></span>
<span id="name"></span>
</div>
</div>
</div>
</div>
<script src="https://res2.wx.qq.com/open/js/jweixin-1.4.0.js "></script>
<script src="./js/jquery.min.js"></script>
<script src="./js/base.js"></script>
</body>
</html>
\ No newline at end of file
$(function () {
var api = 'https://mdev.zuihuibi.cn';
function getToken() {
$.ajax({
type: "POST",
url: api + '/api/authorize/obtainToken',
contentType: "application/json",
data: JSON.stringify({
ticket: 'job'
}),
async: false,
success: function (res) {
token = res.data.token
}
})
return token;
}
var token = getToken();
getXBDetailInfo();
function getXBDetailInfo() {
$.ajax({
url: api + '/api/getXBDetailInfo',
type: 'POST',
contentType: "application/json",
data: JSON.stringify({
orderId: getQueryString('orderId')
}),
headers: {
"X-Authorization": token
},
success: function (res) {
if (res['success']) {
$('.relativeContent').css({'background':'url(' + res['data']['xbUrl'] + ') no-repeat left top','background-size':'cover'});
$('.content #productName').html(res['data']['orderInfo']['productName']);
if (res['data']['orderInfo']['productName'].indexOf(res['data']['orderInfo']['insurerName']) < 0) {
$('.content #insurerName').html(res['data']['orderInfo']['insurerName']);
}
if (res['data']['orderInfo']['paymentPeriod'] && parseInt(res['data']['orderInfo']['paymentPeriod'], 0) > 0) {
$('.content #paymentPeriod').html(`${res['data']['orderInfo']['paymentPeriod']}期`);
}
$('.content #fyp').html(`FYP ${numFormat(res['data']['orderInfo']['premium'])}`);
$('.content #belongToCompany').html(res['data']['practitionerInfo']['insurerBranchName']);
$('.content #subordinateName').html(res['data']['practitionerInfo']['subordinateName']);
$('.content #name').html(res['data']['practitionerInfo']['name']);
}
}
})
}
// 金额千分号
function numFormat(num) {
var c = (num.toString().indexOf('.') !== -1) ? num.toLocaleString() : num.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,');
return c;
}
// 获取URL的参数
/**
* url中的参数
* @param name
* @returns {any}
*/
function getQueryString(name) {
const reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)');
const r = decodeURIComponent(window.location.search).substr(1).match(reg);
if (r != null) {
return r[2];
}
return null;
}
});
\ No newline at end of file
...@@ -144,7 +144,6 @@ html, body { ...@@ -144,7 +144,6 @@ html, body {
justify-content: center; justify-content: center;
align-items: center; align-items: center;
} }
@media (max-width: 320px) { @media (max-width: 320px) {
.formInfo > ul > li { .formInfo > ul > li {
height: 40px; height: 40px;
...@@ -161,3 +160,19 @@ html, body { ...@@ -161,3 +160,19 @@ html, body {
font-size: 20px; font-size: 20px;
} }
} }
@media (max-width: 360px) {
.formInfo > ul > li {
height: 40px;
line-height: 40px;
}
.formInfo input {
height: 24px;
}
.immediateMeasurement {
height: 40px;
line-height: 40px;
font-size: 20px;
}
}
\ No newline at end of file

90 KB | W: | H:

40.4 KB | W: | H:

yd-children-overall/images/mengge.jpg
yd-children-overall/images/mengge.jpg
yd-children-overall/images/mengge.jpg
yd-children-overall/images/mengge.jpg
  • 2-up
  • Swipe
  • Onion skin
...@@ -21,6 +21,13 @@ ...@@ -21,6 +21,13 @@
s.parentNode.insertBefore(hm, s); s.parentNode.insertBefore(hm, s);
})(); })();
</script> </script>
<script>
(function(r,d,s,l){var meteor=r.meteor=r.meteor||[];meteor.methods=["track","off","on"];meteor.factory=function(method){return function(){
var args=Array.prototype.slice.call(arguments);args.unshift(method);meteor.push(args);return meteor}};for(var i=0;i<meteor.methods.length;i++){
var key=meteor.methods[i];meteor[key]=meteor.factory(key)}meteor.load=function(){var js,fjs=d.getElementsByTagName(s)[0];js=d.createElement(s);
js.src="https://analytics.snssdk.com/meteor.js/v1/"+l+"/sdk";fjs.parentNode.insertBefore(js,fjs)};meteor.load();if(meteor.invoked){return}
meteor.invoked=true;meteor.track("pageview")})(window,document,"script","97540494543");
</script>
</head> </head>
<body> <body>
<div class="container"> <div class="container">
...@@ -62,7 +69,7 @@ ...@@ -62,7 +69,7 @@
<li> <li>
<div>手机号码</div> <div>手机号码</div>
<div> <div>
<input type="tel" placeholder="用于接收保费预测结果" id="phone"> <input type="tel" placeholder="用于接收保费预测结果" id="phone" maxlength="11">
</div> </div>
</li> </li>
<li> <li>
......
...@@ -173,7 +173,11 @@ $(function () { ...@@ -173,7 +173,11 @@ $(function () {
"X-Authorization": token "X-Authorization": token
}, },
data: JSON.stringify({ data: JSON.stringify({
mobileNo: $("#phone").val() mobileNo: $("#phone").val(),
campaignInfo: {
campaignCode: '202003mamibaby',
campaignTaskCode: null
}
}), }),
success: function (res) { success: function (res) {
param.customerId = res.data.customerId; param.customerId = res.data.customerId;
...@@ -282,7 +286,11 @@ $(function () { ...@@ -282,7 +286,11 @@ $(function () {
type: 'POST', type: 'POST',
contentType: "application/json", contentType: "application/json",
data: JSON.stringify({ data: JSON.stringify({
mobileNo: $("#phone").val() mobileNo: $("#phone").val(),
campaignInfo: {
campaignCode: '202003mamibaby',
campaignTaskCode: null
}
}), }),
headers: { headers: {
"X-Authorization": token "X-Authorization": token
...@@ -308,12 +316,16 @@ $(function () { ...@@ -308,12 +316,16 @@ $(function () {
name: param.name, name: param.name,
babyGender: param.babyGender, babyGender: param.babyGender,
babyBirth: $("#babyBirth").val(), babyBirth: $("#babyBirth").val(),
sourceChannel: '20203月妈咪宝贝线上推广', channelLaunchAD: {
mktCampaign: null, hmsr: getQueryString('hmsr'),
mktTask: null, hmpl: getQueryString('hmpl'),
sourcePlanName: null, hmkw: getQueryString('hmkw'),
sourcePublishdate: null, hmci: getQueryString('hmci')
sourceArticle: null },
campaignInfo: {
campaignCode: '202003mamibaby',
campaignTaskCode: null
}
} }
$.ajax({ $.ajax({
url: api + '/api/activity/momBabyPromotion', url: api + '/api/activity/momBabyPromotion',
...@@ -325,6 +337,7 @@ $(function () { ...@@ -325,6 +337,7 @@ $(function () {
}, },
success: function (res) { success: function (res) {
if (res['success']) { if (res['success']) {
meteor.track('form', {convert_id: 1661923364086796 });
$('.dialog').show(); $('.dialog').show();
} else { } else {
layer.open({ layer.open({
...@@ -391,4 +404,18 @@ $(function () { ...@@ -391,4 +404,18 @@ $(function () {
}) })
} }
// 获取URL的参数
/**
* url中的参数
* @param name
* @returns {any}
*/
function getQueryString(name) {
const reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)');
const r = decodeURIComponent(window.location.search).substr(1).match(reg);
if (r != null) {
return r[2];
}
return null;
}
}); });
\ No newline at end of file
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