Authored by 李奇

Merge branch 'hotfix/banner' into 'master'

Hotfix/banner



See merge request !5
... ... @@ -17,7 +17,7 @@ export default {
},
"mini_app_type": "29",
"client_type": "miniapp",
"business_line": "miniapp",
"business_line": "minappLuck",
"os_version": "yohobuy:h5",
"app_version": "2.8.3",
"app_build": "1032",
... ...
... ... @@ -77,7 +77,7 @@ function request(method = 'GET') {
params.source_type = "wechat";
params.client_type = "miniapp";
if (!params.business_line) {
params.business_line = "miniapp";
params.business_line = "minappLuck";
}
params.user_source = "wechat"
... ... @@ -155,7 +155,7 @@ function request(method = 'GET') {
params.session_key = sessionkey;
params.source_type = "wechat";
params.client_type = "miniapp";
params.business_line = "miniapp";
params.business_line = "minappLuck";
params.user_source = "wechat"
if (params && !params.hasOwnProperty('udid')) {
... ...
import queryString from '../vendors/query-string';
import jumpMiniApp from '../router/jump-to-miniapp';
const GO_LIST = 'go.list';
const GO_PRODUCTPOOL = 'go.poollist';
... ... @@ -59,7 +58,20 @@ function jumpByUrl(jumpUrl,pageName){
} else if (GO_SHOP === action) {
path = "../goodsList/brandStore";
} else if (GO_DETAIL === action) {
path = "../goodsDetail/goodsDetail";
let actionType = '';
if (json.params && json.params.activity_type){
actionType = json.params.activity_type;
}
if (actionType && actionType === 'groupPurchase'){
return jumpMiniApp({
app: 'groupBuy',
page: 'detail',
data: {
activityId: json.params.activity_id,
productSkn: json.params.product_skn
}
});
}
} else if (GO_COUPON === action) {
path = "../page/subPackage/pages/couponList/couponList";
}else if (GO_NEW === action) {
... ...
... ... @@ -95,7 +95,7 @@ Page(extend({},Toast,{
GET(API_HOST +'/smart/way', param)
.then(data => {
let graphicsCodeSwitch = data.data;
let graphicsCodeUrl = API_HOST + '/passport/img-check' + '?business_line=miniapp' + '&udid=' + udid + '&fromPage=' + 'bindPhoneNumber' + '&timeStamp=' + timeStamp;
let graphicsCodeUrl = API_HOST + '/passport/img-check' + '?business_line=minappLuck' + '&udid=' + udid + '&fromPage=' + 'bindPhoneNumber' + '&timeStamp=' + timeStamp;
that.setData({
graphicsCodeSwitch,
... ... @@ -131,7 +131,7 @@ Page(extend({},Toast,{
update: function (event) {
var timeStamp = Date.parse(new Date());
let udid = app && app.globalData && app.globalData.udid ? app.globalData.udid : '';
let graphicsCodeUrl = API_HOST + '/passport/img-check' + '?business_line=miniapp' + '&udid=' + udid + '&fromPage=' + 'bindPhoneNumber' + '&timeStamp=' + timeStamp;
let graphicsCodeUrl = API_HOST + '/passport/img-check' + '?business_line=minappLuck' + '&udid=' + udid + '&fromPage=' + 'bindPhoneNumber' + '&timeStamp=' + timeStamp;
this.setData({
graphicsCodeUrl,
})
... ...
... ... @@ -5,8 +5,8 @@
</view>
<view class="desc-content">
<view class="banner" bindtap="_jumpBanner" wx:if="{{bannerSrc != null && bannerSrc !== ''}}">
<image class="banner-img" src="{{bannerSrc}}"></image>
<view class="banner" bindtap="jumpUrl" wx:if="{{bannerSrc != null && bannerSrc !== ''}}">
<image class="banner-img" src="{{bannerSrc}}" mode="widthFix"></image>
</view>
<block wx:for="{{list}}">
<block wx:if="{{item.floor_type === 1}}">
... ...
... ... @@ -37,11 +37,10 @@
.banner {
font-size: 0;
width: 100%;
height: 234rpx;
}
.banner-img {
width: 100%;
height: 234rpx;
}
\ No newline at end of file
... ...
... ... @@ -447,7 +447,7 @@ Page(Object.assign({
if (this.data.bannerUrl == null) {
return;
}
jumpByUrl(that.data.bannerUrl);
jumpByUrl(this.data.bannerUrl);
},
_getDetailBanner() {
let commonService = this.commonService;
... ... @@ -455,7 +455,7 @@ Page(Object.assign({
.then(data => {
// console.log(data)
this.setData({
bannerSrc: formatImageUrl(data.src, 340 * app.globalData.systemInfo.pixelRatio, 340 * app.globalData.systemInfo.pixelRatio, 2),
bannerSrc: formatImageUrl(data.src, 750, 140, 2),
bannerUrl: data.url
})
})
... ...
... ... @@ -249,7 +249,7 @@ Page(Object.assign({
.then(data => {
// console.log(data)
this.setData({
bannerSrc: formatImageUrl(data.src, app.globalData.systemInfo.screenWidth, 70, 2),
bannerSrc: formatImageUrl(data.src, 750, 234, 2),
bannerUrl: data.url
})
})
... ...
... ... @@ -73,17 +73,6 @@
<image class="bottom-banner-img" src="{{bannerSrc}}"></image>
</view>
</block>
<!-- <view class="bottom-bar">
<block wx:if="{{isLogin}}">
<view bindtap="goMyList">我的抽奖码</view>
</block>
<block wx:else>
<button class="bottom-btn" plain="true" hover-class="none" open-type="{{!hasUnionID ? 'getUserInfo':'getPhoneNumber'}}" bindgetphonenumber="getPhoneNumber" bindgetuserinfo='getUserInfo'>我的抽奖码</button>
</block>
</view> -->
<import src="../../../../vendors/zanui/toast/index.wxml"/>
<template is="zan-toast" data="{{zanToast}}"/>
... ... @@ -96,4 +85,3 @@ url="{{dialogUrl}}"
></dialog>
<import src="../../vendors/zanui/actionsheet/index.wxml" />
<template is="zan-actionsheet" data="{{...actionsheet}}" />
<!-- <quickNavigation id="quickNavigation" isShowIndicator="{{false}}" isShowShopCart="{{false}}" marginBottom="{{190}}"></quickNavigation> -->
\ No newline at end of file
... ...
@import '../../vendors/zanui/actionsheet/index.wxss';
page {
font-size: 0;
}
.product {
display: block;
width: 100%;
... ... @@ -24,14 +28,12 @@
}
.bottom-banner {
/* position: fixed; */
/* padding-bottom: 88rpx; */
height: 234rpx;
width: 100%;
width: 750rpx;
}
.bottom-banner-img {
width: 100%;
width: 750rpx;
height: 234rpx;
}
... ...
import wx from '../utils/wx';
import {stringify} from '../vendors/query-string';
const appData = {
yohobuyLimitChannel: {
appId: 'wxed31f9e8705fb8d1',
page: {
limitProductList: 'pages/index/index'
}
},
groupBuy: { // 拼团
appId: 'wx207f18be42db9028',
page: {
home: '/pages/group/home',
detail: '/pages/group/detail',
}
}
};
export default function(params) {
let navigateToMiniParams = {
appId: appData[params.app].appId,
path: params.path || `${appData[params.app].page[params.page]}?${stringify(params.data)}`
};
return wx.navigateToMiniProgram(navigateToMiniParams);
}
... ...