Authored by 王水玲

Merge branch 'release/4.9.2' of git.yoho.cn:fe/yohobuywap-node into release/4.9.2

... ... @@ -134,6 +134,11 @@ const _getChannelResource = (params) => {
cache: true
}).then(result => {
if (result && result.code === 200) {
for (let item of result.data.list) {
item.template_name === 'single_image' &&
item.data.length === 1 &&
(item.singleOne = true);
}
return resourcesProcess(result.data.list);
} else {
logger.error('index resouce is not 200');
... ...
... ... @@ -42,15 +42,7 @@ module.exports = {
retries: 0
},
interfaceShunt: {
useInterfaceShunt: false,
tencentServers: {
api: ['123.206.1.98', '123.206.2.80'],
service: ['123.206.1.98', '123.206.2.80']
},
awsServers: {
api: 'app-java-168863769.cn-north-1.elb.amazonaws.com.cn',
service: 'service-yoho-579825100.cn-north-1.elb.amazonaws.com.cn'
}
open: false
},
loggers: {
infoFile: {
... ... @@ -103,15 +95,8 @@ if (isProduction) {
useOneapm: true,
useCache: true,
interfaceShunt: {
useInterfaceShunt: false,
tencentServers: {
api: ['123.206.1.98', '123.206.2.80'],
service: ['123.206.1.98', '123.206.2.80']
},
awsServers: {
api: 'app-java-168863769.cn-north-1.elb.amazonaws.com.cn',
service: 'service-yoho-579825100.cn-north-1.elb.amazonaws.com.cn'
}
open: true,
url: 'http://123.206.2.55/strategy'
}
});
} else if (isTest) {
... ...
{{#data}}
<div class="banner-center">
<a href="{{url}}">
<img class="lazy" data-original="{{image src 640 200}}" alt="">
</a>
</div>
{{/data}}
\ No newline at end of file
<div class="banner-center banner-center-swiper">
{{#if singleOne}}
{{#data}}
<div class="banner-list">
<a href="{{url}}">
<img src="{{image src 640 200}}" alt="">
</a>
</div>
{{/data}}
{{else}}
<ul class="banner-list swiper-wrapper clearfix">
{{#data}}
<li class="swiper-slide">
<a href="{{url}}">
<img src="{{image src 640 200}}" alt="">
</a>
</li>
{{/data}}
</ul>
{{/if}}
</div>
\ No newline at end of file
... ...
... ... @@ -56,7 +56,7 @@
"uuid": "^2.0.2",
"winston": "^2.2.0",
"winston-daily-rotate-file": "^1.2.0",
"yoho-node-lib": "0.0.43"
"yoho-node-lib": "0.0.46"
},
"devDependencies": {
"autoprefixer": "^6.3.7",
... ...
... ... @@ -284,9 +284,12 @@ function get_websocket_server(type) {
var arr = data.data[0].split(':');
var ip = arr[0];
var port = arr[1];
var protocol = 'ws'
// var protocol = location.protocol === 'https:' ? 'wss' :'ws'
if (is_live) {
ip = 'ws://' + ip;
ip = protocol + '://' + ip;
link_to_websocket_server(ip, port);
}
}
... ...
... ... @@ -108,6 +108,17 @@ if ($('.banner-swiper').find('li').size() > 1) {
});
}
// single_image的轮播
if ($('.banner-center-swiper').find('li').size() > 1) {
new Swiper('.banner-center-swiper', {
loop: true,
autoplay: 3000,
autoplayDisableOnInteraction: false,
paginationClickable: true,
slideElement: 'li',
});
}
// 热门品牌滑动
new Swiper('.brands-swiper', {
grabCursor: true,
... ...
@import "live/index";
@import "student";
.receive-coupon-page {
* {
margin: 0;
... ... @@ -294,5 +296,3 @@
}
@import "student";
@import "live/index";
... ...
... ... @@ -33,28 +33,36 @@ $border: #e0e0e0;
position: absolute;
top: 30px;
left: 30px;
height: 35px;
padding: 0 10px;
border: 2px solid $white;
border-radius: 20px;
height: 70px;
padding: 0 20px;
border: 4px solid $white;
border-radius: 40px;
color: $white;
font-size: 22px;
font-size: 44px;
text-align: center;
line-height: 1.5;
line-height: 70px;
-webkit-transform: scale(0.5);
transform: scale(0.5);
-webkit-transform-origin: 0 0;
transform-origin: 0 0;
}
.living {
position: absolute;
top: 30px;
left: 30px;
height: 35px;
width: 70px;
height: 70px;
width: 140px;
background: $red;
border-radius: 15px;
border-radius: 40px;
color: $white;
font-size: 22px;
font-size: 44px;
text-align: center;
line-height: 1.5;
line-height: 70px;
-webkit-transform: scale(0.5);
transform: scale(0.5);
-webkit-transform-origin: 0 0;
transform-origin: 0 0;
}
&_tag {
... ... @@ -196,14 +204,18 @@ $border: #e0e0e0;
position: absolute;
top: 30px;
left: 30px;
height: 35px;
width: 70px;
height: 70px;
width: 140px;
background: $red;
border-radius: 20px;
border-radius: 40px;
color: $white;
font-size: 22px;
font-size: 44px;
text-align: center;
line-height: 1.5;
line-height: 70px;
-webkit-transform: scale(0.5);
transform: scale(0.5);
-webkit-transform-origin: 0 0;
transform-origin: 0 0;
}
.main-intro {
... ... @@ -294,14 +306,18 @@ $border: #e0e0e0;
position: absolute;
top: 20px;
left: 220px;
height: 35px;
width: 70px;
border: 2px solid $black;
border-radius: 20px;
font-size: 22px;
line-height: 1.5;
height: 70px;
width: 140px;
border: 4px solid $black;
border-radius: 40px;
font-size: 44px;
line-height: 70px;
text-align: center;
color: $black;
-webkit-transform: scale(0.5);
transform: scale(0.5);
-webkit-transform-origin: 0 0;
transform-origin: 0 0;
}
.pre-time {
... ...
... ... @@ -2,9 +2,45 @@
margin: 30px 0 0;
height: 200px;
overflow: hidden;
img {
display: block;
width: 100%;
height: 100%;
}
}
.banner-center-swiper {
background: #fff;
width: 100%;
height: 200px;
border-top: 1px solid #e0e0e0;
overflow: hidden;
.banner-list {
position: relative;
height: 200px;
li {
float: left;
width: 100%;
height: 200px;
a {
position: relative;
display: block;
width: 100%;
height: 100%;
line-height: 200px;
font-size: 0;
}
img {
display: inline-block;
max-width: 100%;
max-height: 100%;
vertical-align: middle;
}
}
}
}
... ...