Commit 3a8a3a32 authored by zhengke's avatar zhengke

修改

parents 3862321f bdd2af9b
......@@ -4,7 +4,7 @@
:style="{
'background-color': goodsInfo.backgroundColor,
'background-image': goodsInfo.backgroundPicUrl,
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : ''
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : '',
}"
>
<view
......@@ -14,55 +14,85 @@
:key="gli"
:style="{
border: goodsInfo.goodsStyle == 2 ? '1px solid rgb(226, 226, 226)' : '',
background: goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2 ? '#FFF' : ''
background:
goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2 ? '#FFF' : '',
}"
>
<view class="list-box" >
<view class="list-box">
<view class="img-box">
<image style="width: 100%; height: 100%; border-radius: 50%;" mode="aspectFill" :src="item.picUrl" />
<image
style="width: 100%; height: 100%; border-radius: 50%"
mode="aspectFill"
:src="item.picUrl"
/>
</view>
<view class="textone" style="font-size: 14px;font-weight: bold;margin: 5px 0;">{{item.name}}</view>
<view style="display: flex;align-items: center;margin-top: 5px;margin-bottom: 14px;">
<image style="width: 23px; height: 15px;margin-right: 5px;" mode="aspectFill" :src="item.foreignersUrl" />
<text >{{item.nationality}}</text>
<view
class="textone"
style="font-size: 14px; font-weight: bold; margin: 5px 0"
>{{ item.name }}</view
>
<view
style="
display: flex;
align-items: center;
margin-top: 5px;
margin-bottom: 14px;
"
>
<image
style="width: 23px; height: 15px; margin-right: 5px"
mode="aspectFill"
:src="item.foreignersUrl"
/>
<text>{{ item.nationality }}</text>
</view>
<view class="textone">
<text v-for="(x, y) in item.lableNameList" :key="y" v-if="item.lableNameList!=null && item.lableNameList.length>0">
{{x}}{{item.lableNameList.length==y+1?'':'、'}}
<text
v-for="(x, y) in item.lableNameList"
:key="y"
v-if="item.lableNameList != null && item.lableNameList.length > 0"
>
{{ x }}{{ item.lableNameList.length == y + 1 ? "" : "、" }}
</text>
<text v-if="item.lableNameList==null || item.lableNameList.length==0">
<text
v-if="item.lableNameList == null || item.lableNameList.length == 0"
>
教育
</text>
</view>
</view>
</view>
<good-sku v-if="showSku" :option-type="2" borderRadius="20" v-model="showSku" :good="sku"></good-sku>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth="gbAuth"></auth>
<good-sku
v-if="showSku"
:option-type="2"
borderRadius="20"
v-model="showSku"
:good="sku"
></good-sku>
<auth
v-if="showAuth"
@changeuserinfo="reloadUserinfo"
@gbAuth="gbAuth"
></auth>
</view>
</template>
<script>
import goodSku from '../goods/goodsku';
import auth from '@/components/auth/index.vue';
import goodSku from "../goods/goodsku";
import auth from "@/components/auth/index.vue";
export default {
components: {
goodSku,
auth
auth,
},
props: ['goodList', 'goodsInfo'],
props: ["goodList", "goodsInfo"],
data() {
return {
mainColor: '',
mainColor: "",
activeKey: 0,
showSku: false,
sku: {},
showAuth: false,
u: {}
u: {},
};
},
created() {
......@@ -70,14 +100,13 @@ export default {
},
methods: {
openGood(item) {
uni.navigateTo({ url: '/pages/school/teacherDetails?ID=' + item.id });
uni.navigateTo({ url: "/pages/school/teacherDetails?ID=" + item.id });
},
},
}
};
</script>
<style>
<style scoped>
.her-scoller {
overflow-x: auto !important;
padding: 12px;
......@@ -96,25 +125,29 @@ export default {
border: 1rpx solid transparent;
border-radius: 10rpx;
padding: 10px;
display:inline-block;
display: inline-block;
box-shadow: 0 5px 10upx rgba(0, 0, 0, 0.1);
background: #FFF;
background: #fff;
/* float: left; */
}
.her-scoller .good-five .img-box {
width: 40px;
height: 40px;
border-radius: 50%;
}
.list-box{
.list-box {
display: flex;
flex-direction: column;
align-items: center;
font-size: 12px;color: #333F53;
font-size: 12px;
color: #333f53;
}
.textone{
width: 100%;white-space: nowrap;text-overflow: ellipsis;overflow: hidden;text-align: center;
.textone {
width: 100%;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
text-align: center;
}
</style>
<template>
<div
style="padding: 12px; padding-bottom: 0;"
style="padding: 12px; padding-bottom: 0"
:style="{
'background-color': goodsInfo.backgroundColor,
'background-image': goodsInfo.backgroundPicUrl,
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : ''
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : '',
}"
>
<u-row gutter="24">
......@@ -13,11 +13,21 @@
class="good-three"
@click="openGood(item)"
:style="{
border: goodsInfo.goodsStyle == 2 ? '1px solid rgb(226, 226, 226)' : '',
background: goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2 ? '#FFF' : ''
border:
goodsInfo.goodsStyle == 2 ? '1px solid rgb(226, 226, 226)' : '',
background:
goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2
? '#FFF'
: '',
}"
>
<div class="tips" v-if="goodsInfo.showGoodsTag"><image :src="goodsInfo.goodsTagPicUrl" mode="widthFix" style="width:100%" /></div>
<div class="tips" v-if="goodsInfo.showGoodsTag">
<image
:src="goodsInfo.goodsTagPicUrl"
mode="widthFix"
style="width: 100%"
/>
</div>
<div class="img-box">
<div class="img-show">
<image
......@@ -32,27 +42,63 @@
</div>
</div>
<div class="good-info">
<div class="good-name" v-if="goodsInfo.showGoodsName">{{ item.name }}</div>
<div class="good-name" v-if="goodsInfo.showGoodsName">
{{ item.name }}
</div>
<div class="good-price-info">
<view class="price" :style="{ color: mainColor }">
<span>{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : '' }}</span>
<span style='text-decoration: line-through;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span>
<span>{{
goodsInfo.showGoodsPrice ? getPrice(item.price) : ""
}}</span>
<span
style="
text-decoration: line-through;
font-size: 10px;
color: gray;
font-family: aa;
"
>原价:{{
goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ""
}}</span
>
</view>
<view class="buy" v-if="goodsInfo.showBuyBtn" @click.stop="showSkuHandler(item)">
<u-icon name="cart-o" size="40" :color="mainColor" v-if="goodsInfo.buyBtn == 'cart'" />
<u-icon name="add-o" size="40" :color="mainColor" v-else-if="goodsInfo.buyBtn == 'add'" />
<view
class="buy"
v-if="goodsInfo.showBuyBtn"
@click.stop="showSkuHandler(item)"
>
<u-icon
name="cart-o"
size="40"
:color="mainColor"
v-if="goodsInfo.buyBtn == 'cart'"
/>
<u-icon
name="add-o"
size="40"
:color="mainColor"
v-else-if="goodsInfo.buyBtn == 'add'"
/>
<u-button
type="primary"
size="mini"
:ripple="true"
:color="goodsInfo.buttonColor"
:custom-style="
`backgroundColor:${goodsInfo.buttonColor},color:${
goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4 ? goodsInfo.buttonColor : '#FFF'
}`
:custom-style="`backgroundColor:${
goodsInfo.buttonColor
},color:${
goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4
? goodsInfo.buttonColor
: '#FFF'
}`"
:plain="
goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4
"
:shape="
goodsInfo.buyBtnStyle == 3 || goodsInfo.buyBtnStyle == 4
? 'circle'
: 'square'
"
:plain="goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4"
:shape="goodsInfo.buyBtnStyle == 3 || goodsInfo.buyBtnStyle == 4 ? 'circle' : 'square'"
v-else
>
{{ goodsInfo.buyBtnText }}
......@@ -63,28 +109,38 @@
</div>
</u-col>
</u-row>
<good-sku v-if="showSku" borderRadius="20" v-model="showSku" :good="sku" :option-type="2"></good-sku>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth="gbAuth"></auth>
<good-sku
v-if="showSku"
borderRadius="20"
v-model="showSku"
:good="sku"
:option-type="2"
></good-sku>
<auth
v-if="showAuth"
@changeuserinfo="reloadUserinfo"
@gbAuth="gbAuth"
></auth>
</div>
</template>
<script>
import goodSku from '../goods/goodsku';
import auth from '@/components/auth/index.vue';
import goodSku from "../goods/goodsku";
import auth from "@/components/auth/index.vue";
export default {
components: {
goodSku,
auth
auth,
},
props: ['goodList', 'goodsInfo'],
props: ["goodList", "goodsInfo"],
data() {
return {
mainColor: '',
mainColor: "",
activeKey: 0,
showSku: false,
sku: {},
showAuth: false,
u: {}
u: {},
};
},
created() {
......@@ -94,38 +150,42 @@ export default {
openGood(item) {
//线路
if (item.goodType == 4) {
var url="/pages/jiuzhai/jz_LineDetail?tcid=" + item.id + '&configId=' + item.subid;
console.log("url3",url)
var url =
"/pages/jiuzhai/jz_LineDetail?tcid=" +
item.id +
"&configId=" +
item.subid;
console.log("url3", url);
uni.navigateTo({
url: url
url: url,
});
}
//酒店
else if (item.goodType == 1) {
uni.navigateTo({
url: "/pages/hotel/detail?id=" + item.id
url: "/pages/hotel/detail?id=" + item.id,
});
}
//餐食
else if (item.goodType == 2) {
uni.navigateTo({
url: '/pages/restaurant/detail?id=' + item.id
url: "/pages/restaurant/detail?id=" + item.id,
});
}
//景点
else if (item.goodType == 3) {
uni.navigateTo({
url: '/pages/ticketCoupons/detail?id=' + item.id
url: "/pages/ticketCoupons/detail?id=" + item.id,
});
}
},
showSkuHandler(g) {
this.sku = g;
this.u = uni.getStorageSync('mall_UserInfo');
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: '未登录',
avatarUrl: ''
nickName: "未登录",
avatarUrl: "",
};
this.showAuth = true;
} else {
......@@ -133,18 +193,18 @@ export default {
}
},
reloadUserinfo() {
this.u = uni.getStorageSync('mall_UserInfo');
this.u = uni.getStorageSync("mall_UserInfo");
// this.showAuth = false;
},
//关闭登录窗口
gbAuth() {
this.showAuth = false;
}
}
},
},
};
</script>
<style>
<style scoped>
.good-three {
position: relative;
margin-bottom: 12px;
......
<template>
<view
style="padding: 12px; padding-bottom: 0;width:100%;min-height:450rpx;"
style="padding: 12px; padding-bottom: 0; width: 100%; min-height: 450rpx"
:style="{
'background-color': goodsInfo.backgroundColor,
'background-image': goodsInfo.backgroundPicUrl,
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : ''
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : '',
}"
>
<view
......@@ -14,28 +14,63 @@
@click="openGood(item)"
:style="{
border: goodsInfo.goodsStyle == 2 ? '1px solid rgb(226, 226, 226)' : '',
background: goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2 ? '#FFF' : ''
background:
goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2 ? '#FFF' : '',
}"
>
<view class="tips" v-if="goodsInfo.showGoodsTag"><image :src="goodsInfo.goodsTagPicUrl" mode="widthFix" style="width: 100%;" /></view>
<view class="img-box"><image style="width: 100%; height: 100%;" :mode="goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'" :src="item.picUrl" /></view>
<view class="tips" v-if="goodsInfo.showGoodsTag"
><image
:src="goodsInfo.goodsTagPicUrl"
mode="widthFix"
style="width: 100%"
/></view>
<view class="img-box"
><image
style="width: 100%; height: 100%"
:mode="goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'"
:src="item.picUrl"
/></view>
<view class="good-info">
<view class="good-name" v-if="goodsInfo.showGoodsName">{{ item.name }}</view>
<view class="good-name" v-if="goodsInfo.showGoodsName">{{
item.name
}}</view>
<view class="good-price-info">
<view class="price" :style="{ color: mainColor }">{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : '' }}</view>
<view class="buy" v-if="goodsInfo.showBuyBtn" @click.stop="showSkuHandler(item)">
<u-icon name="cart-o" size="40" :color="mainColor" v-if="goodsInfo.buyBtn == 'cart'" />
<u-icon name="add-o" size="40" :color="mainColor" v-else-if="goodsInfo.buyBtn == 'add'" />
<view class="price" :style="{ color: mainColor }">{{
goodsInfo.showGoodsPrice ? getPrice(item.price) : ""
}}</view>
<view
class="buy"
v-if="goodsInfo.showBuyBtn"
@click.stop="showSkuHandler(item)"
>
<u-icon
name="cart-o"
size="40"
:color="mainColor"
v-if="goodsInfo.buyBtn == 'cart'"
/>
<u-icon
name="add-o"
size="40"
:color="mainColor"
v-else-if="goodsInfo.buyBtn == 'add'"
/>
<u-button
type="primary"
size="mini"
:ripple="true"
:color="goodsInfo.buttonColor"
:custom-style="
`backgroundColor:${goodsInfo.buttonColor},color:${goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4 ? goodsInfo.buttonColor : '#FFF'}`
"
:custom-style="`backgroundColor:${goodsInfo.buttonColor},color:${
goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4
? goodsInfo.buttonColor
: '#FFF'
}`"
:plain="goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4"
:shape="goodsInfo.buyBtnStyle == 3 || goodsInfo.buyBtnStyle == 4 ? 'circle' : 'square'"
:shape="
goodsInfo.buyBtnStyle == 3 || goodsInfo.buyBtnStyle == 4
? 'circle'
: 'square'
"
v-else
>
{{ goodsInfo.buyBtnText }}
......@@ -44,28 +79,38 @@
</view>
</view>
</view>
<good-sku v-if="showSku" :option-type="2" borderRadius="20" v-model="showSku" :good="sku"></good-sku>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth="gbAuth"></auth>
<good-sku
v-if="showSku"
:option-type="2"
borderRadius="20"
v-model="showSku"
:good="sku"
></good-sku>
<auth
v-if="showAuth"
@changeuserinfo="reloadUserinfo"
@gbAuth="gbAuth"
></auth>
</view>
</template>
<script>
import goodSku from '../goods/goodsku';
import auth from '@/components/auth/index.vue';
import goodSku from "../goods/goodsku";
import auth from "@/components/auth/index.vue";
export default {
components: {
goodSku,
auth
auth,
},
props: ['goodList', 'goodsInfo'],
props: ["goodList", "goodsInfo"],
data() {
return {
mainColor: '',
mainColor: "",
activeKey: 0,
showSku: false,
sku: {},
showAuth: false,
u: {}
u: {},
};
},
created() {
......@@ -75,38 +120,42 @@ export default {
openGood(item) {
//线路
if (item.goodType == 4) {
var url="/pages/jiuzhai/jz_LineDetail?tcid=" + item.id + '&configId=' + item.subid;
console.log("url4",url)
var url =
"/pages/jiuzhai/jz_LineDetail?tcid=" +
item.id +
"&configId=" +
item.subid;
console.log("url4", url);
uni.navigateTo({
url: url
url: url,
});
}
//酒店
else if (item.goodType == 1) {
uni.navigateTo({
url: "/pages/hotel/detail?id=" + item.id
url: "/pages/hotel/detail?id=" + item.id,
});
}
//餐食
else if (item.goodType == 2) {
uni.navigateTo({
url: '/pages/restaurant/detail?id=' + item.id
url: "/pages/restaurant/detail?id=" + item.id,
});
}
//景点
else if (item.goodType == 3) {
uni.navigateTo({
url: '/pages/ticketCoupons/detail?id=' + item.id
url: "/pages/ticketCoupons/detail?id=" + item.id,
});
}
},
showSkuHandler(g) {
this.sku = g;
this.u = uni.getStorageSync('mall_UserInfo');
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: '未登录',
avatarUrl: ''
nickName: "未登录",
avatarUrl: "",
};
this.showAuth = true;
} else {
......@@ -114,13 +163,13 @@ export default {
}
},
reloadUserinfo() {
this.u = uni.getStorageSync('mall_UserInfo');
this.u = uni.getStorageSync("mall_UserInfo");
// this.showAuth = false;
},
//关闭登录窗口
gbAuth() {
this.showAuth = false;
}
},
//格式化价格添加.00
// getPrice(value){
// var html,_val;
......@@ -134,11 +183,11 @@ export default {
// _val = value.split('.');
// return html = '¥'+_val[0]+'.'+_val[1];
// }
}
},
};
</script>
<style>
<style scoped>
.good-four {
position: relative;
margin-bottom: 14px;
......
<template>
<view style="padding: 12px; padding-bottom: 0;width:100%;" :style="{
<view
style="padding: 12px; padding-bottom: 0; width: 100%"
:style="{
'background-color': goodsInfo.backgroundColor,
'background-image': goodsInfo.backgroundPicUrl,
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : ''
}">
<view class="good-four" v-for="(item, gli) in goodList" :key="gli" @click="openGood(item)" :style="{
'border-color': goodsInfo.goodsStyle == 2 ? 'rgb(226, 226, 226)' : '',
}"
>
<view
class="good-four"
v-for="(item, gli) in goodList"
:key="gli"
@click="openGood(item)"
:style="{
border: goodsInfo.goodsStyle == 2 ? '1px solid rgb(226, 226, 226)' : '',
background: goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2 ? '#FFF' : ''
}">
background:
goodsInfo.goodsStyle == 1 || goodsInfo.goodsStyle == 2 ? '#FFF' : '',
}"
>
<view class="tips" v-if="goodsInfo.showGoodsTag">
<image :src="goodsInfo.goodsTagPicUrl" mode="widthFix" style="width: 100%;" />
<image
:src="goodsInfo.goodsTagPicUrl"
mode="widthFix"
style="width: 100%"
/>
</view>
<view class="img-box">
<image style="width: 100%; height: 100%;" :mode="goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'" :src="item.picUrl" />
<image
style="width: 100%; height: 100%"
:mode="goodsInfo.fill == 1 ? 'aspectFill' : 'aspectFit'"
:src="item.picUrl"
/>
</view>
<view class="good-info">
<view class="good-name" v-if="goodsInfo.showGoodsName">{{ item.name }}</view>
<view class="good-sub-name" v-if="item.subname">{{item.subname}}</view>
<view class="good-name" v-if="goodsInfo.showGoodsName">{{
item.name
}}</view>
<view class="good-sub-name" v-if="item.subname">{{
item.subname
}}</view>
<view class="good-price-info">
<view class="price" :style="{ color: mainColor }">{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : '' }}
<view class="price" :style="{ color: mainColor }"
>{{ goodsInfo.showGoodsPrice ? getPrice(item.price) : "" }}
<!-- <span style='text-decoration: line-through;margin-left: 10px;font-size: 10px;color: gray;font-family: aa;'>原价:{{goodsInfo.showGoodsPrice ? getPrice(item.OriginalPrice) : ''}}</span> -->
</view>
<view class="buy" v-if="goodsInfo.showBuyBtn" @click.stop="showSkuHandler(item)">
<u-icon name="cart-o" size="40" :color="mainColor" v-if="goodsInfo.buyBtn == 'cart'" />
<u-icon name="add-o" size="40" :color="mainColor" v-else-if="goodsInfo.buyBtn == 'add'" />
<u-button type="primary" size="mini" :ripple="true" :color="goodsInfo.buttonColor" :custom-style="
`backgroundColor:${goodsInfo.buttonColor},color:${goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4 ? goodsInfo.buttonColor : '#FFF'}`
<view
class="buy"
v-if="goodsInfo.showBuyBtn"
@click.stop="showSkuHandler(item)"
>
<u-icon
name="cart-o"
size="40"
:color="mainColor"
v-if="goodsInfo.buyBtn == 'cart'"
/>
<u-icon
name="add-o"
size="40"
:color="mainColor"
v-else-if="goodsInfo.buyBtn == 'add'"
/>
<u-button
type="primary"
size="mini"
:ripple="true"
:color="goodsInfo.buttonColor"
:custom-style="`backgroundColor:${goodsInfo.buttonColor},color:${
goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4
? goodsInfo.buttonColor
: '#FFF'
}`"
:plain="goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4"
:shape="
goodsInfo.buyBtnStyle == 3 || goodsInfo.buyBtnStyle == 4
? 'circle'
: 'square'
"
:plain="goodsInfo.buyBtnStyle == 2 || goodsInfo.buyBtnStyle == 4" :shape="goodsInfo.buyBtnStyle == 3 || goodsInfo.buyBtnStyle == 4 ? 'circle' : 'square'"
v-else>
v-else
>
{{ goodsInfo.buyBtnText }}
</u-button>
</view>
</view>
</view>
</view>
<good-sku v-if="showSku" borderRadius="20" v-model="showSku" :good="sku" :option-type="2"></good-sku>
<auth v-if="showAuth" @changeuserinfo="reloadUserinfo" @gbAuth="gbAuth"></auth>
<good-sku
v-if="showSku"
borderRadius="20"
v-model="showSku"
:good="sku"
:option-type="2"
></good-sku>
<auth
v-if="showAuth"
@changeuserinfo="reloadUserinfo"
@gbAuth="gbAuth"
></auth>
</view>
</template>
<script>
import goodSku from '../goods/goodsku';
import auth from '@/components/auth/index.vue';
export default {
import goodSku from "../goods/goodsku";
import auth from "@/components/auth/index.vue";
export default {
components: {
goodSku,
auth
auth,
},
props: ['goodList', 'goodsInfo'],
props: ["goodList", "goodsInfo"],
data() {
return {
mainColor: '',
mainColor: "",
activeKey: 0,
showSku: false,
sku: {},
showAuth: false,
u: {}
u: {},
};
},
created() {
......@@ -66,38 +126,42 @@
openGood(item) {
//线路
if (item.goodType == 4) {
var url="/pages/jiuzhai/jz_LineDetail?tcid=" + item.id + '&configId=' + item.subid;
console.log("url6",url)
var url =
"/pages/jiuzhai/jz_LineDetail?tcid=" +
item.id +
"&configId=" +
item.subid;
console.log("url6", url);
uni.navigateTo({
url: url
url: url,
});
}
//酒店
else if (item.goodType == 1) {
uni.navigateTo({
url: "/pages/hotel/detail?id=" + item.id
url: "/pages/hotel/detail?id=" + item.id,
});
}
//餐食
else if (item.goodType == 2) {
uni.navigateTo({
url: '/pages/restaurant/detail?id=' + item.id
url: "/pages/restaurant/detail?id=" + item.id,
});
}
//景点
else if (item.goodType == 3) {
uni.navigateTo({
url: '/pages/ticketCoupons/detail?id=' + item.id
url: "/pages/ticketCoupons/detail?id=" + item.id,
});
}
},
showSkuHandler(g) {
this.sku = g;
this.u = uni.getStorageSync('mall_UserInfo');
this.u = uni.getStorageSync("mall_UserInfo");
if (!this.u) {
this.u = {
nickName: '未登录',
avatarUrl: ''
nickName: "未登录",
avatarUrl: "",
};
this.showAuth = true;
} else {
......@@ -105,19 +169,19 @@
}
},
reloadUserinfo() {
this.u = uni.getStorageSync('mall_UserInfo');
this.u = uni.getStorageSync("mall_UserInfo");
// this.showAuth = false;
},
//关闭登录窗口
gbAuth() {
this.showAuth = false;
}
}
};
},
},
};
</script>
<style>
.good-four {
<style scoped>
.good-four {
position: relative;
margin-bottom: 14px;
display: flex;
......@@ -127,23 +191,23 @@
box-sizing: border-box;
padding: 0 1px 1px 0;
overflow: hidden;
}
}
.good-four .tips {
.good-four .tips {
width: 64rpx;
height: 64rpx;
position: absolute;
top: 0;
left: 0;
z-index: 4;
}
}
.good-four .img-box {
.good-four .img-box {
width: 100px;
height: 100px;
}
}
.good-four .good-info {
.good-four .good-info {
padding: 12px;
flex: 1;
width: 1rpx;
......@@ -152,9 +216,9 @@
display: flex;
flex-direction: column;
/* width:20%; */
}
}
.good-four .good-info .good-name {
.good-four .good-info .good-name {
font-size: 13px;
height: 34px;
overflow: hidden;
......@@ -162,32 +226,32 @@
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
}
}
.good-four .good-info .good-price-info {
.good-four .good-info .good-price-info {
display: flex;
justify-items: center;
align-items: flex-end;
height: 22px;
flex: 1;
padding-bottom: 10rpx;
}
}
.good-four .good-info .good-price-info .price {
.good-four .good-info .good-price-info .price {
color: #ff4544;
flex: 1;
font-size: 14px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
}
}
.good-four .good-info .good-price-info .buy {
.good-four .good-info .good-price-info .buy {
width: 24px;
text-align: right;
}
}
..good-four .good-info .good-sub-name {
..good-four .good-info .good-sub-name {
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
......@@ -198,5 +262,5 @@
font-size: 22rpx;
color: #999999;
/* height: 37px; */
}
}
</style>
This diff is collapsed.
......@@ -42,21 +42,20 @@
</view>
</view>
</view>
<!-- #ifdef MP-WEIXIN -->
<view
@click="goback"
:style="[titleStyle, { opacity: '100% !important' }]"
style="position: fixed; top: 0; left: 0; padding-left: 6rpx"
>
<!-- #ifdef MP-WEIXIN -->
<u-icon
name="arrow-left"
size="44"
color="#FFF"
style="margin-top: 22rpx"
></u-icon>
<!-- #endif -->
</view>
<!-- #endif -->
</view>
<view class="top-title" :style="[titleStyle]">
<view @click="goback">
......@@ -892,12 +891,11 @@
<view class="jz_OrderDiv">
<view style="color: #ff3166; font-weight: bold">
<text style="font-size: 22rpx">¥</text>
<text style="font-size: 40rpx">{{
$utils.getretailer() == true
<text style="font-size: 40rpx"
>{{ $utils.getretailer() == true
<!-- b2b -->
? currentPrice.b2CPrice
: currentPrice.b2CPrice
}}</text>
? currentPrice.b2CPrice : currentPrice.b2CPrice }}</text
>
<text style="font-size: 22rpx">/起</text>
</view>
<view style="display: flex; align-items: center">
......@@ -984,53 +982,73 @@ export default {
that.titleStyle = {
height: "45px",
paddingTop: `${res.statusBarHeight}px`,
opacity: "0",
opacity: 0,
};
},
});
this.mainColor = this.$uiConfig.mainColor;
},
methods: {
downloadFile(){
let msg={
"configId":"7274","cityId":"0","tcid":"11409","orderId":"0","FileName":"2021-10-11飞猪平台九寨沟3天2晚3日游","isShowBase":1,"isShowFlight":1,"isShowFeature":1,"isShowFee":1,"isShowShop":1,"isShowTip":1,"isShowB2B":1,"isShowTrip":1,"isShowTitle":0,"isShowGuest":0,"isShowMan":1,"isShowTCNUM":1,"isShowTripImage":1,"isShowVisa":1,"isShowVideoImg":1,"isPc":2,"templateId":3,"UId":615
}
this.apipostDownload(
"GetWebHtmlTwo_V2",
msg,
(res) => {
console.log(res)
let url="https://reborn.oytour.com"+res.data
downloadFile() {
let msg = {
configId: "7274",
cityId: "0",
tcid: "11409",
orderId: "0",
FileName: "2021-10-11飞猪平台九寨沟3天2晚3日游",
isShowBase: 1,
isShowFlight: 1,
isShowFeature: 1,
isShowFee: 1,
isShowShop: 1,
isShowTip: 1,
isShowB2B: 1,
isShowTrip: 1,
isShowTitle: 0,
isShowGuest: 0,
isShowMan: 1,
isShowTCNUM: 1,
isShowTripImage: 1,
isShowVisa: 1,
isShowVideoImg: 1,
isPc: 2,
templateId: 3,
UId: 615,
};
this.apipostDownload("GetWebHtmlTwo_V2", msg, (res) => {
console.log(res);
let url = "https://reborn.oytour.com" + res.data;
uni.downloadFile({
url: url,
success: (res) => {
if (res.statusCode === 200) {
console.log('下载成功');
}
console.log("下载成功");
}
},
});
});
})
} ,
downloadFile2(){
let url="https://reborn.oytour.com/Upload/Temporary/C7274_T11409_CTY0_OD0_MMDD637695432017412893_1_1.pdf"
},
downloadFile2() {
let url =
"https://reborn.oytour.com/Upload/Temporary/C7274_T11409_CTY0_OD0_MMDD637695432017412893_1_1.pdf";
uni.downloadFile({
url: url,
success: (res) => {
console.log('suc',res);
console.log("suc", res);
if (res.statusCode === 200) {
console.log('下载成功');
const tempFilePath = res.tempFilePath//返回的文件临时地址,用于后面打开本地预览所用
console.log("下载成功");
const tempFilePath = res.tempFilePath; //返回的文件临时地址,用于后面打开本地预览所用
wx.openDocument({
filePath: tempFilePath,
showMenu: true,
fileType: "pdf",
success: function (res) {}
})
success: function (res) {},
});
}
},
fail(err){
console.log('err',err);
}
fail(err) {
console.log("err", err);
},
});
},
openOrderPreview() {
......
......@@ -864,13 +864,43 @@ export default {
},
(res) => {
this.orderInfo = JSON.parse(res.data);
// this.PayAli(OrderId);
if (res.data) {
this.PayAli(res.data);
} else {
uni.showToast({
title: "获取交易号失败",
duration: 2000,
});
}
console.log(873, res);
}
);
},
PayAli(OrderId) {
PayAli(tradeNO) {
let that = this;
my.tradePay({
tradeNO: tradeNO,
success: function (res) {
console.log("success", res);
uni.showToast({
title: "支付成功",
});
setTimeout(() => {
uni.redirectTo({
url: "/pages/jiuzhai/paysuccess?PreferPrice=" + price,
});
}, 100);
},
fail: function (err) {
console.log("fail:", err);
uni.showToast({
title: "支付失败",
icon: "none",
});
},
});
return;
uni.requestPayment({
provider: "wxpay",
timeStamp: this.orderInfo.timeStamp,
......
......@@ -16,21 +16,20 @@
name="picUrl"
v-if="active == 1"
></u-swiper>
<!-- #ifdef MP-WEIXIN -->
<view
@click="goback"
:style="[titleStyle, { opacity: '100% !important' }]"
style="position: fixed; top: 0; left: 0; padding-left: 6rpx"
>
<!-- #ifdef MP-WEIXIN -->
<u-icon
name="arrow-left"
size="44"
color="#FFF"
style="margin-top: 22rpx"
></u-icon>
<!-- #endif -->
</view>
<!-- #endif -->
</view>
<view class="restaurant-title" :style="[titleStyle]">
<view @click="goback">
......@@ -284,20 +283,7 @@ import calendar from "./components/uni-calendar/uni-calendar.vue";
export default {
data() {
return {
imgsList: [
// {
// picUrl: "https://viitto-1301420277.cos.ap-chengdu.myqcloud.com/Test/Upload/Goods/1622459632000_216.png"
// },
// {
// picUrl: "https://ak-d.tripcdn.com/images/t1/hotel/533000/532930/3fcc6398b3c44c08bb1b57aef579793e_R_1080_808_R5_D.jpg"
// },
// {
// picUrl: "https://ak-d.tripcdn.com/images/20010r000000hmqk32EF2_R_1080_808_R5_D.jpg"
// },
// {
// picUrl: "https://ak-d.tripcdn.com/images/200v0f0000007d6wgBCD6_R_1080_808_R5_D.jpg"
// }
],
imgsList: [],
ID: 0,
details: {},
typeList: [
......
......@@ -17,6 +17,7 @@
"
:style="{ opacity: 100 - boxOption + '%' }"
>
<!-- #ifdef MP-WEIXIN -->
<view
@click="goback"
:style="[titleStyle, { opacity: '100% !important' }]"
......@@ -28,15 +29,14 @@
padding-left: 6rpx;
"
>
<!-- #ifdef MP-WEIXIN -->
<u-icon
name="arrow-left"
size="44"
color="#ffffff"
style="margin-top: 22rpx"
></u-icon>
<!-- #endif -->
</view>
<!-- #endif -->
<image
class="banner-img"
:src="details.AllPicList[0].TagPicList[0].Path"
......@@ -232,7 +232,7 @@
:class="{ 'last-item': index == TicketList.length - 1 }"
v-if="TicketList.length > 0"
>
<view class="ticket-key">
<view class="ticket-key" v-if="item.Key">
{{ item.Key }}
</view>
<view class="ticket-list">
......@@ -553,7 +553,7 @@ export default {
that.titleStyle = {
height: "45px",
paddingTop: `${res.statusBarHeight}px`,
opacity: "0",
opacity: 0,
};
},
});
......@@ -1197,6 +1197,10 @@ export default {
position: relative;
.TicketName {
max-width: 450rpx;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
font-size: 28rpx;
font-family: PingFang SC;
font-weight: bold;
......
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