|
|
@@ -4,13 +4,13 @@
|
|
|
<div @click="toggleOpen" class="menu color">
|
|
|
<div class="logo">
|
|
|
<img :src="require('@/assets/images/icon/logo.png')" alt="" />
|
|
|
- <p>{{$t('common.title') }}</p>
|
|
|
+ <p>{{ $t('common.title') }}</p>
|
|
|
</div>
|
|
|
<div class="vline"></div>
|
|
|
<ul :class="player.lang" @touchmove.stop>
|
|
|
<li v-if="tours.length > 0">
|
|
|
<ui-icon type="preview" @click.stop="playTour"></ui-icon>
|
|
|
- <div>{{$t('common.tour')}}</div>
|
|
|
+ <div>{{ $t('common.tour') }}</div>
|
|
|
</li>
|
|
|
<li @click.stop="onClickMenu(item)" v-for="(item, i) in menulist" :key="i">
|
|
|
<ui-icon :type="item.icon"></ui-icon>
|
|
|
@@ -18,32 +18,26 @@
|
|
|
</li>
|
|
|
|
|
|
<li v-if="showdaogou">
|
|
|
- <ui-icon
|
|
|
- type="guided_shopping"
|
|
|
- @click.stop="
|
|
|
- onClickMenu({
|
|
|
- icon: 'guided_shopping',
|
|
|
- id: 'guided_shopping',
|
|
|
- name: $t('common.mode'),
|
|
|
- })
|
|
|
- "
|
|
|
- ></ui-icon>
|
|
|
+ <ui-icon type="guided_shopping" @click.stop="
|
|
|
+ onClickMenu({
|
|
|
+ icon: 'guided_shopping',
|
|
|
+ id: 'guided_shopping',
|
|
|
+ name: $t('common.mode'),
|
|
|
+ })
|
|
|
+ "></ui-icon>
|
|
|
<div>{{ $t('common.mode') }}</div>
|
|
|
</li>
|
|
|
|
|
|
- <!-- <li>
|
|
|
- <ui-icon
|
|
|
- type="shopping"
|
|
|
- @click.stop="
|
|
|
- onClickMenu({
|
|
|
- icon: 'shopping',
|
|
|
- id: 'shopping',
|
|
|
- name: $t('common.shopping'),
|
|
|
- })
|
|
|
- "
|
|
|
- ></ui-icon>
|
|
|
+ <li v-if="metadata?.cdfProductSource?.mchType == 0">
|
|
|
+ <ui-icon type="shopping" @click.stop="
|
|
|
+ onClickMenu({
|
|
|
+ icon: 'shopping',
|
|
|
+ id: 'shopping',
|
|
|
+ name: $t('common.shopping'),
|
|
|
+ })
|
|
|
+ "></ui-icon>
|
|
|
<div>{{ $t('common.shopping') }}</div>
|
|
|
- </li> -->
|
|
|
+ </li>
|
|
|
</ul>
|
|
|
</div>
|
|
|
|
|
|
@@ -58,13 +52,9 @@
|
|
|
</div>
|
|
|
<div class="swiper-container" id="sw-navigation">
|
|
|
<ul class="swiper-wrapper">
|
|
|
- <li
|
|
|
- class="swiper-slide"
|
|
|
+ <li class="swiper-slide"
|
|
|
:class="{ liactive: item.sceneUrl === currentM && item.inPosition.indexOf(currentPose) > -1 }"
|
|
|
- @click.stop="onClickShop(item)"
|
|
|
- v-for="(item, i) in brandlist"
|
|
|
- :key="i"
|
|
|
- >
|
|
|
+ @click.stop="onClickShop(item)" v-for="(item, i) in brandlist" :key="i">
|
|
|
<div v-if="item.shopLogo" class="img" :style="{ 'background-image': `url(${item.shopLogo})` }"></div>
|
|
|
<div class="name" v-if="item.shopName">
|
|
|
<span :class="{ active: item.shopName.length > 6 }">
|
|
|
@@ -79,19 +69,16 @@
|
|
|
<div class="category">
|
|
|
<div class="swiper-container" id="sw-category">
|
|
|
<ul class="swiper-wrapper">
|
|
|
- <li
|
|
|
- class="swiper-slide"
|
|
|
- :class="{ categoryactive: '' == currentCategory.id }"
|
|
|
- @click.stop="
|
|
|
- onClickCategory({
|
|
|
- id: '',
|
|
|
- categoryName: $t('common.all'),
|
|
|
- })
|
|
|
- "
|
|
|
- >
|
|
|
+ <li class="swiper-slide" :class="{ categoryactive: '' == currentCategory.id }" @click.stop="
|
|
|
+ onClickCategory({
|
|
|
+ id: '',
|
|
|
+ categoryName: $t('common.all'),
|
|
|
+ })
|
|
|
+ ">
|
|
|
<div>{{ $t('common.all') }}</div>
|
|
|
</li>
|
|
|
- <li @click.stop="onClickCategory(item)" :class="{ categoryactive: item.id == currentCategory.id }" class="swiper-slide" v-for="(item, i) in categorylist" :key="i">
|
|
|
+ <li @click.stop="onClickCategory(item)" :class="{ categoryactive: item.id == currentCategory.id }"
|
|
|
+ class="swiper-slide" v-for="(item, i) in categorylist" :key="i">
|
|
|
<div>{{ item.categoryName }}</div>
|
|
|
</li>
|
|
|
</ul>
|
|
|
@@ -160,6 +147,7 @@ const currentM = computed(() => browser.getURLParam('m'));
|
|
|
const currentPose = computed(() => browser.getURLParam('pose'));
|
|
|
const showdaogou = computed(() => store.getters['rtc/showdaogou']);
|
|
|
|
|
|
+
|
|
|
const isPlay = computed(() => {
|
|
|
let status = store.getters['tour/isPlay'];
|
|
|
let map = document.querySelector('.kankan-app div[xui_min_map]');
|
|
|
@@ -193,19 +181,23 @@ const player = computed(() => store.getters['player']);
|
|
|
const tours = computed(() => store.getters['tour/tours']);
|
|
|
|
|
|
const menulist = computed(() => {
|
|
|
+ console.log('result:',);
|
|
|
let fff = [
|
|
|
{
|
|
|
icon: 'help',
|
|
|
id: 'help',
|
|
|
name: t('common.help'),
|
|
|
- },
|
|
|
- // {
|
|
|
- // icon: 'customer_service',
|
|
|
- // id: 'kefu',
|
|
|
- // name: t('common.kefu'),
|
|
|
- // },
|
|
|
+ }
|
|
|
];
|
|
|
|
|
|
+ if (metadata.value?.cdfProductSource?.mchType == 0) {
|
|
|
+ fff.push({
|
|
|
+ icon: 'customer_service',
|
|
|
+ id: 'kefu',
|
|
|
+ name: t('common.kefu')
|
|
|
+ },)
|
|
|
+ }
|
|
|
+
|
|
|
if (!browser.isMobile()) {
|
|
|
fff.shift();
|
|
|
}
|
|
|
@@ -230,7 +222,7 @@ const brandScroll = () => {
|
|
|
grid: {
|
|
|
rows: 2,
|
|
|
},
|
|
|
- observer:true,
|
|
|
+ observer: true,
|
|
|
on: {
|
|
|
touchMove(swiper, e) {
|
|
|
e.stopPropagation();
|
|
|
@@ -238,7 +230,7 @@ const brandScroll = () => {
|
|
|
},
|
|
|
observerUpdate(swiper, e) {
|
|
|
swiper.slideTo(0)
|
|
|
- },
|
|
|
+ },
|
|
|
},
|
|
|
});
|
|
|
|
|
|
@@ -259,11 +251,29 @@ const brandScroll = () => {
|
|
|
|
|
|
const onClickMenu = (item) => {
|
|
|
if (item.id == 'kefu') {
|
|
|
+ let envtype = 1
|
|
|
+ if (browser.detectWeixin()) {
|
|
|
+ wx.miniProgram.getEnv((res) => {
|
|
|
+ if (res.miniprogram) {
|
|
|
+ //在小程序里
|
|
|
+ envtype = 2
|
|
|
+ } else {
|
|
|
+ envtype = 1
|
|
|
+ }
|
|
|
+ })
|
|
|
+ } else if (browser.isMobile()) {
|
|
|
+ envtype = 1
|
|
|
+ } else if (browser.getURLParam("isMiniApp") === "1") {
|
|
|
+ envtype = 3
|
|
|
+ } else {
|
|
|
+ envtype = 4
|
|
|
+ }
|
|
|
+
|
|
|
let mglink =
|
|
|
- 'https://webpage.qidian.qq.com/2/chat/h5/index.html?linkType=1&env=ol&kfuin=3009110132&fid=3655&key=9b4334768c39150ead3f23e11e5dc2e4&cate=7&source=0&isLBS=0&isCustomEntry=0&type=10&ftype=1&_type=wpa&qidian=true&_pid=kvrmvu.74cg11.l43qvbcu&translateSwitch=0&isSsc=0&roleValue=4&roleData=922223821';
|
|
|
+ `https://${metadata.value?.cdfProductSource?.cdfHost}/shop/${metadata.value?.cdfProductSource?.cdfMchId}/qidian?terminalType=${envtype}`;
|
|
|
window.open(mglink, '_blank');
|
|
|
} else if (item.id == 'shopping') {
|
|
|
- browser.openLink('/subPackage/pages/shoppingcart/shoppingcart', 'https://m.cdfmembers.com/shop/600667208/shoppingcart', '/subPackage/pages/shoppingcart/shoppingcart');
|
|
|
+ browser.openLink('/subPackage/pages/shoppingcart/shoppingcart', `https://${metadata.value?.cdfProductSource?.cdfHost}/shop/${metadata.value?.cdfProductSource?.cdfMchId}/shoppingcart`, '/subPackage/pages/shoppingcart/shoppingcart');
|
|
|
} else if (item.id == 'help') {
|
|
|
store.commit('showUserGuide', true);
|
|
|
} else if (item.id == 'guided_shopping') {
|
|
|
@@ -350,44 +360,52 @@ onMounted(() => {
|
|
|
height: 48px;
|
|
|
padding: 0 12px;
|
|
|
text-align: center;
|
|
|
+
|
|
|
.logo {
|
|
|
- width: 120px;
|
|
|
+ width: 100px;
|
|
|
transform: translateY(-24%);
|
|
|
- min-width: 120px;
|
|
|
+ min-width: 100px;
|
|
|
flex-shrink: 0;
|
|
|
- > img {
|
|
|
+
|
|
|
+ >img {
|
|
|
width: 100%;
|
|
|
border-radius: 4px;
|
|
|
}
|
|
|
- > p {
|
|
|
+
|
|
|
+ >p {
|
|
|
margin: 2px 0;
|
|
|
font-size: 10px;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
.vline {
|
|
|
width: 1px;
|
|
|
height: 14px;
|
|
|
background: #fff;
|
|
|
}
|
|
|
- > ul {
|
|
|
+
|
|
|
+ >ul {
|
|
|
display: flex;
|
|
|
align-items: center;
|
|
|
font-size: 0;
|
|
|
justify-content: flex-end;
|
|
|
overflow-x: auto;
|
|
|
- > li {
|
|
|
+
|
|
|
+ >li {
|
|
|
margin-left: 0.4rem;
|
|
|
+
|
|
|
&:first-of-type {
|
|
|
margin-left: 0;
|
|
|
}
|
|
|
- > div {
|
|
|
+
|
|
|
+ >div {
|
|
|
margin-top: 4px;
|
|
|
font-size: 10px;
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- .en{
|
|
|
+ .en {
|
|
|
// justify-content: flex-start;
|
|
|
// width: calc(100% - 160px);
|
|
|
}
|
|
|
@@ -400,6 +418,7 @@ onMounted(() => {
|
|
|
margin-top: 8px;
|
|
|
margin-bottom: 30px;
|
|
|
background: rgba(0, 0, 0, 0.2);
|
|
|
+
|
|
|
.navigation {
|
|
|
padding: 8px 0;
|
|
|
|
|
|
@@ -409,7 +428,8 @@ onMounted(() => {
|
|
|
display: flex;
|
|
|
justify-content: space-between;
|
|
|
align-items: center;
|
|
|
- > div {
|
|
|
+
|
|
|
+ >div {
|
|
|
width: 96px;
|
|
|
height: 24px;
|
|
|
background: rgba(0, 0, 0, 0.5);
|
|
|
@@ -419,11 +439,13 @@ onMounted(() => {
|
|
|
justify-content: center;
|
|
|
align-items: center;
|
|
|
}
|
|
|
+
|
|
|
img {
|
|
|
width: 12px;
|
|
|
margin-right: 6px;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
.swiper-container {
|
|
|
width: 100%;
|
|
|
height: 130px;
|
|
|
@@ -446,9 +468,11 @@ onMounted(() => {
|
|
|
opacity: 0.4;
|
|
|
pointer-events: none;
|
|
|
}
|
|
|
- > ul {
|
|
|
+
|
|
|
+ >ul {
|
|
|
margin: 0 !important;
|
|
|
- > li {
|
|
|
+
|
|
|
+ >li {
|
|
|
width: 60px;
|
|
|
height: 60px;
|
|
|
border-radius: 4px;
|
|
|
@@ -457,15 +481,18 @@ onMounted(() => {
|
|
|
overflow: hidden;
|
|
|
border: 1px transparent solid;
|
|
|
box-sizing: border-box;
|
|
|
+
|
|
|
&.liactive {
|
|
|
color: var(--editor-main-color);
|
|
|
border: 1px var(--editor-main-color) solid;
|
|
|
}
|
|
|
+
|
|
|
.img {
|
|
|
width: 100%;
|
|
|
height: 100%;
|
|
|
background-size: contain;
|
|
|
}
|
|
|
+
|
|
|
.name {
|
|
|
width: 100%;
|
|
|
position: absolute;
|
|
|
@@ -480,10 +507,12 @@ onMounted(() => {
|
|
|
padding: 2px 4px;
|
|
|
box-sizing: border-box;
|
|
|
word-break: break-all;
|
|
|
- > span {
|
|
|
+
|
|
|
+ >span {
|
|
|
display: inline-block;
|
|
|
white-space: nowrap;
|
|
|
}
|
|
|
+
|
|
|
.active {
|
|
|
animation: 5s wordsLoop linear infinite normal;
|
|
|
}
|
|
|
@@ -492,6 +521,7 @@ onMounted(() => {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
.category {
|
|
|
padding: 8px 14px;
|
|
|
border-top: 1px solid rgba(255, 255, 255, 0.2);
|
|
|
@@ -499,16 +529,19 @@ onMounted(() => {
|
|
|
.swiper-container {
|
|
|
width: 100%;
|
|
|
overflow: hidden;
|
|
|
- > ul {
|
|
|
- > li {
|
|
|
+
|
|
|
+ >ul {
|
|
|
+ >li {
|
|
|
width: auto;
|
|
|
color: rgba(255, 255, 255, 0.5);
|
|
|
- > div {
|
|
|
+
|
|
|
+ >div {
|
|
|
width: 100%;
|
|
|
font-size: 14px;
|
|
|
padding: 2px 4px;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
.categoryactive {
|
|
|
color: #fff;
|
|
|
}
|
|
|
@@ -529,6 +562,7 @@ onMounted(() => {
|
|
|
background: rgba(0, 0, 0, 0.8);
|
|
|
border-radius: 10px 10px 0px 0px;
|
|
|
padding: 12px 15px;
|
|
|
+
|
|
|
.l-title {
|
|
|
font-size: 16px;
|
|
|
font-weight: bold;
|
|
|
@@ -554,27 +588,31 @@ onMounted(() => {
|
|
|
align-items: center;
|
|
|
padding: 0 8px;
|
|
|
margin-top: 20px;
|
|
|
- > img {
|
|
|
+
|
|
|
+ >img {
|
|
|
width: 16px;
|
|
|
opacity: 0.8;
|
|
|
}
|
|
|
- > input {
|
|
|
+
|
|
|
+ >input {
|
|
|
text-align: left;
|
|
|
font-size: 16px;
|
|
|
width: 100%;
|
|
|
color: #fff;
|
|
|
margin-left: 10px;
|
|
|
}
|
|
|
+
|
|
|
.close {
|
|
|
color: #7d7e80;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
- > ul {
|
|
|
+ >ul {
|
|
|
width: 100%;
|
|
|
height: calc(100% - 80px);
|
|
|
overflow-y: auto;
|
|
|
- > li {
|
|
|
+
|
|
|
+ >li {
|
|
|
width: 100%;
|
|
|
height: 60px;
|
|
|
position: relative;
|
|
|
@@ -585,6 +623,7 @@ onMounted(() => {
|
|
|
justify-content: center;
|
|
|
align-items: center;
|
|
|
margin: 18px 0;
|
|
|
+
|
|
|
.img {
|
|
|
width: 60px;
|
|
|
height: 60px;
|
|
|
@@ -593,6 +632,7 @@ onMounted(() => {
|
|
|
border-radius: 4px;
|
|
|
margin-right: 10px;
|
|
|
}
|
|
|
+
|
|
|
.name {
|
|
|
width: 100%;
|
|
|
font-size: 12px;
|
|
|
@@ -604,11 +644,13 @@ onMounted(() => {
|
|
|
padding: 2px 4px;
|
|
|
box-sizing: border-box;
|
|
|
word-break: break-all;
|
|
|
- > span {
|
|
|
+
|
|
|
+ >span {
|
|
|
display: inline-block;
|
|
|
white-space: nowrap;
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
.right {
|
|
|
font-size: 14px;
|
|
|
}
|