商户入驻以及 供应界面修改
This commit is contained in:
commit
caa3e35b3e
15
api/requesta.js
Normal file
15
api/requesta.js
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
import request from "@/utils/requesta.js";
|
||||||
|
|
||||||
|
export function getCityCloundShop(data) {
|
||||||
|
return request.get("city/get_cloud_shop", data);
|
||||||
|
}
|
||||||
|
export function cloudWarehouse(data) {
|
||||||
|
return request.get("store/product/cloudWarehouse", data);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 供销市场标签
|
||||||
|
* @returns {*}
|
||||||
|
*/
|
||||||
|
export function supMenuApi(data) {
|
||||||
|
return request.get('intention/v2/cate', data);
|
||||||
|
}
|
@ -27,19 +27,24 @@
|
|||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class='mask' catchtouchmove="true" :hidden='popup.show==false' @tap="closePopup"></view>
|
<view class='mask' style="height: 100vh;" catchtouchmove="true" :hidden='popup.show==false' @tap="closePopup">
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { goShopDetail } from '@/libs/order.js'
|
import {
|
||||||
import { mapGetters } from "vuex";
|
goShopDetail
|
||||||
|
} from '@/libs/order.js'
|
||||||
|
import {
|
||||||
|
mapGetters
|
||||||
|
} from "vuex";
|
||||||
export default {
|
export default {
|
||||||
computed:{
|
computed: {
|
||||||
...mapGetters(['viewColor']),
|
...mapGetters(['viewColor']),
|
||||||
},
|
},
|
||||||
props:{
|
props: {
|
||||||
list: {
|
list: {
|
||||||
type: Array,
|
type: Array,
|
||||||
default: []
|
default: []
|
||||||
@ -63,11 +68,12 @@
|
|||||||
// 点击关闭按钮
|
// 点击关闭按钮
|
||||||
closePopup() {
|
closePopup() {
|
||||||
this.$set(this.popup, 'show', false);
|
this.$set(this.popup, 'show', false);
|
||||||
|
this.$emit("closes")
|
||||||
},
|
},
|
||||||
showPopup() {
|
showPopup() {
|
||||||
this.$set(this.popup, 'show', true);
|
this.$set(this.popup, 'show', true);
|
||||||
},
|
},
|
||||||
goDetail(item){
|
goDetail(item) {
|
||||||
if (item.product_type === 1) {
|
if (item.product_type === 1) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/activity/goods_seckill_details/index?id=${item.product_id}&time=${item.stop_time}&spid=${this.uid}`
|
url: `/pages/activity/goods_seckill_details/index?id=${item.product_id}&time=${item.stop_time}&spid=${this.uid}`
|
||||||
@ -80,11 +86,11 @@
|
|||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/goods_details/index?id=${item.product_id}&spid=${this.uid}`
|
url: `/pages/goods_details/index?id=${item.product_id}&spid=${this.uid}`
|
||||||
})
|
})
|
||||||
}else if (item.product_type === 4) {
|
} else if (item.product_type === 4) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/activity/combination_details/index?id=${item.activity_id}&spid=${this.uid}`
|
url: `/pages/activity/combination_details/index?id=${item.activity_id}&spid=${this.uid}`
|
||||||
})
|
})
|
||||||
}else if (item.product_type === 40) {
|
} else if (item.product_type === 40) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/activity/combination_status/index?id=${item.activity_id}&spid=${this.uid}`
|
url: `/pages/activity/combination_status/index?id=${item.activity_id}&spid=${this.uid}`
|
||||||
})
|
})
|
||||||
@ -94,115 +100,135 @@
|
|||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.container{
|
.container {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
left: 0;
|
left: 0;
|
||||||
background-color: #ffffff;
|
background-color: #ffffff;
|
||||||
z-index: 77;
|
z-index: 77;
|
||||||
border-radius: 16rpx 16rpx 0 0;
|
border-radius: 16rpx 16rpx 0 0;
|
||||||
transform: translate3d(0, 100%, 0);
|
transform: translate3d(0, 100%, 0);
|
||||||
transition: all .3s cubic-bezier(.25, .5, .5, .9);
|
transition: all .3s cubic-bezier(.25, .5, .5, .9);
|
||||||
max-height: 1000rpx;
|
max-height: 1000rpx;
|
||||||
&.on {
|
|
||||||
transform: translate3d(0, 0, 0);
|
&.on {
|
||||||
}
|
transform: translate3d(0, 0, 0);
|
||||||
.header{
|
|
||||||
position: relative;
|
|
||||||
padding: 40rpx 30rpx;
|
|
||||||
.title{
|
|
||||||
color: #282828;
|
|
||||||
font-size: 30rpx;
|
|
||||||
}
|
}
|
||||||
.iconfont{
|
|
||||||
color: #8A8A8A;
|
.header {
|
||||||
font-size: 28rpx;
|
position: relative;
|
||||||
position: absolute;
|
padding: 40rpx 30rpx;
|
||||||
top: 0;
|
|
||||||
right: 0;
|
.title {
|
||||||
}
|
color: #282828;
|
||||||
.icon-guanbi5 {
|
font-size: 30rpx;
|
||||||
right: 20rpx;
|
}
|
||||||
color: #8a8a8a;
|
|
||||||
font-size: 30rpx;
|
.iconfont {
|
||||||
line-height: 30rpx;
|
color: #8A8A8A;
|
||||||
top: 20rpx;
|
font-size: 28rpx;
|
||||||
background-color: transparent;
|
position: absolute;
|
||||||
font-weight: normal;
|
top: 0;
|
||||||
}
|
right: 0;
|
||||||
}
|
}
|
||||||
scroll-view{
|
|
||||||
max-height: 800rpx;
|
.icon-guanbi5 {
|
||||||
}
|
right: 20rpx;
|
||||||
.main_count{
|
color: #8a8a8a;
|
||||||
padding: 0 30rpx 30rpx;
|
font-size: 30rpx;
|
||||||
max-height: 800rpx;
|
line-height: 30rpx;
|
||||||
overflow-y: scroll;
|
top: 20rpx;
|
||||||
/* #ifndef MP */
|
background-color: transparent;
|
||||||
&.mb90{
|
font-weight: normal;
|
||||||
margin-bottom: 90rpx;
|
|
||||||
}
|
|
||||||
/* #endif */
|
|
||||||
.list{
|
|
||||||
margin-bottom: 40rpx;
|
|
||||||
height: auto;
|
|
||||||
flex-direction: row;
|
|
||||||
&:last-child{
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.pro_list{
|
|
||||||
display: flex;
|
scroll-view {
|
||||||
flex-direction: row;
|
max-height: 800rpx;
|
||||||
.picture,.image,uni-image{
|
}
|
||||||
width: 200rpx;
|
|
||||||
height: 200rpx;
|
.main_count {
|
||||||
border-radius: 16rpx;
|
padding: 0 30rpx 30rpx;
|
||||||
|
max-height: 800rpx;
|
||||||
|
overflow-y: scroll;
|
||||||
|
|
||||||
|
/* #ifndef MP */
|
||||||
|
&.mb90 {
|
||||||
|
margin-bottom: 90rpx;
|
||||||
}
|
}
|
||||||
.info{
|
|
||||||
margin-left: 30rpx;
|
/* #endif */
|
||||||
position: relative;
|
.list {
|
||||||
.bottom{
|
margin-bottom: 40rpx;
|
||||||
display: flex;
|
height: auto;
|
||||||
justify-content: space-between;
|
flex-direction: row;
|
||||||
align-items: center;
|
|
||||||
width: 460rpx;
|
&:last-child {
|
||||||
position: absolute;
|
margin-bottom: 0;
|
||||||
left: 0;
|
|
||||||
bottom: 10rpx;
|
|
||||||
flex-direction: row;
|
|
||||||
}
|
}
|
||||||
.name{
|
}
|
||||||
color: #282828;
|
|
||||||
font-size: 30rpx;
|
.pro_list {
|
||||||
line-height: 45rpx;
|
display: flex;
|
||||||
display: -webkit-box;
|
flex-direction: row;
|
||||||
width: 460rpx;
|
|
||||||
|
.picture,
|
||||||
|
.image,
|
||||||
|
uni-image {
|
||||||
|
width: 200rpx;
|
||||||
|
height: 200rpx;
|
||||||
|
border-radius: 16rpx;
|
||||||
}
|
}
|
||||||
.price{
|
|
||||||
color: var(--view-priceColor);
|
.info {
|
||||||
font-size: 26rpx;
|
margin-left: 30rpx;
|
||||||
font-weight: bold;
|
position: relative;
|
||||||
flex-direction: row;
|
|
||||||
align-items: flex-end;
|
.bottom {
|
||||||
text{
|
display: flex;
|
||||||
font-size: 34rpx;
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
width: 460rpx;
|
||||||
|
position: absolute;
|
||||||
|
left: 0;
|
||||||
|
bottom: 10rpx;
|
||||||
|
flex-direction: row;
|
||||||
|
}
|
||||||
|
|
||||||
|
.name {
|
||||||
|
color: #282828;
|
||||||
|
font-size: 30rpx;
|
||||||
|
line-height: 45rpx;
|
||||||
|
display: -webkit-box;
|
||||||
|
width: 460rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.price {
|
||||||
|
color: var(--view-priceColor);
|
||||||
|
font-size: 26rpx;
|
||||||
|
font-weight: bold;
|
||||||
|
flex-direction: row;
|
||||||
|
align-items: flex-end;
|
||||||
|
|
||||||
|
text {
|
||||||
|
font-size: 34rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.buy-btn {
|
||||||
|
color: #fff;
|
||||||
|
background: var(--view-theme);
|
||||||
|
border-radius: 28.04rpx 28.04rpx 28.04rpx 28.04rpx;
|
||||||
|
width: 154.21rpx;
|
||||||
|
height: 57.83rpx;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
font-size: 22rpx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.buy-btn{
|
|
||||||
color: #fff;
|
|
||||||
background: var(--view-theme);
|
|
||||||
border-radius: 26rpx;
|
|
||||||
width: 140rpx;
|
|
||||||
height: 48rpx;
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: center;
|
|
||||||
font-size: 22rpx;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
</style>
|
</style>
|
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class='product-bg'>
|
<view class='product-bg'>
|
||||||
<swiper :indicator-dots="indicatorDots" indicator-active-color="#e93323" :circular="circular"
|
<swiper :indicator-dots="indicatorDots" indicator-active-color="#e93323" :circular="circular"
|
||||||
:interval="interval" :duration="duration">
|
:interval="interval" :duration="duration">
|
||||||
|
|
||||||
<block v-for="(item,index) in imgUrls" :key='index'>
|
<block v-for="(item,index) in imgUrls" :key='index'>
|
||||||
<swiper-item>
|
<swiper-item>
|
||||||
@ -56,8 +56,7 @@
|
|||||||
videoContext: ''
|
videoContext: ''
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {},
|
||||||
},
|
|
||||||
watch: {
|
watch: {
|
||||||
|
|
||||||
},
|
},
|
||||||
@ -83,7 +82,7 @@
|
|||||||
// #ifdef APP-PLUS
|
// #ifdef APP-PLUS
|
||||||
this.isPlay = false
|
this.isPlay = false
|
||||||
this.videoContext = uni.createVideoContext('myVideo', this);
|
this.videoContext = uni.createVideoContext('myVideo', this);
|
||||||
this.$nextTick(()=>{
|
this.$nextTick(() => {
|
||||||
this.videoContext.play();
|
this.videoContext.play();
|
||||||
})
|
})
|
||||||
// #endif
|
// #endif
|
||||||
@ -102,13 +101,15 @@
|
|||||||
height: 710rpx;
|
height: 710rpx;
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.product-bg swiper {
|
.product-bg swiper {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
|
||||||
.product-bg .slide-image {
|
.product-bg .slide-image {
|
||||||
width: 100%;
|
width: 100vw;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
border-radius: 16rpx;
|
border-radius: 16rpx;
|
||||||
}
|
}
|
||||||
|
@ -142,10 +142,12 @@
|
|||||||
this.$emit('change', e)
|
this.$emit('change', e)
|
||||||
this.street = e.value[1].name
|
this.street = e.value[1].name
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$bus.$emit('value-updated',e.value[1].name + ',' +e.value[1].code);
|
this.$bus.$emit('value-updated', e.value[1].name + ',' + e.value[1].code);
|
||||||
|
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
changeHandler(e) {
|
changeHandler(e) {
|
||||||
const {
|
const {
|
||||||
|
353
components/zbpSwiperb.vue
Normal file
353
components/zbpSwiperb.vue
Normal file
@ -0,0 +1,353 @@
|
|||||||
|
<template>
|
||||||
|
<view class="zbp-head-wrapper">
|
||||||
|
<view class="color-lump"></view>
|
||||||
|
<view class="bg-img">
|
||||||
|
<img :src="bgColor" alt="">
|
||||||
|
</view>
|
||||||
|
|
||||||
|
<view class="site-box flex_a_c_j_sb" style="padding-top: var(--status-bar-height)">
|
||||||
|
|
||||||
|
<view class="place_wrapper flex_a_c" @click="selectLocation">
|
||||||
|
<view class="iconfont icon-weizhi"></view>
|
||||||
|
<view class="town_name">{{street}}</view>
|
||||||
|
</view>
|
||||||
|
<view class="" style="display: flex;">
|
||||||
|
<navigator url="/pages/chat/customer_list/index?type=0" hover-class="none">
|
||||||
|
<view class="iconfont icon-xiaoxi" style="color:#fff;margin-right: 20rpx;"></view>
|
||||||
|
</navigator>
|
||||||
|
<navigator url="/pages/columnGoods/goods_search/index" hover-class="none">
|
||||||
|
<view class="iconfont icon-sousuo" style="font-size: 39rpx;color: white;"></view>
|
||||||
|
</navigator>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
||||||
|
<!-- 搜索栏 -->
|
||||||
|
<!-- <navigator url="/pages/columnGoods/goods_search/index" hover-class="none" class="search_content flex_a_c_j_sb">
|
||||||
|
<view class="flex_a_c">
|
||||||
|
<view class="iconfont icon-sousuo" style="font-size: 39rpx;"></view>
|
||||||
|
<input type="text" v-model="keyword" placeholder="搜索产品或店铺" placeholder-style="font-size: 30rpx;"
|
||||||
|
disabled>
|
||||||
|
</view>
|
||||||
|
<button class="search_btn">搜索</button>
|
||||||
|
</navigator> -->
|
||||||
|
<!-- 轮播图 -->
|
||||||
|
<view class="supply_chains-head">
|
||||||
|
<swiper class="swiper " @change="swiperChange" :indicator-dots="swiper.indicatorDots"
|
||||||
|
:autoplay="swiper.autoplay" :interval="swiper.interval" :duration="swiper.duration"
|
||||||
|
indicator-active-color="#fff">
|
||||||
|
<block v-for="(item,index) in swiper['url']" :key="index">
|
||||||
|
<swiper-item class="swi_item" @click="swiperClick(item)">
|
||||||
|
<!-- <u--image :showLoading="true" :src="item.img" width="750rpx" height="259rpx" mode="aspectFit">
|
||||||
|
</u--image> -->
|
||||||
|
<u--image :showLoading="true" :src="item.img" width="750rpx" height="600rpx">
|
||||||
|
</u--image>
|
||||||
|
</swiper-item>
|
||||||
|
</block>
|
||||||
|
</swiper>
|
||||||
|
</view>
|
||||||
|
<u-picker :defaultIndex="defaInd" :show="showPicker" ref="uPicker" :columns="columnData" @confirm="confirm"
|
||||||
|
@cancel="showPicker = false" @change="changeHandler" keyName="name"></u-picker>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {
|
||||||
|
getArea,
|
||||||
|
getStreet
|
||||||
|
} from '@/api/article.js';
|
||||||
|
import {
|
||||||
|
getIndexData,
|
||||||
|
getDiy
|
||||||
|
} from '@/api/api.js'
|
||||||
|
import {
|
||||||
|
getGeocoder
|
||||||
|
} from '@/api/store.js';
|
||||||
|
import {
|
||||||
|
mapGetters
|
||||||
|
} from 'vuex'
|
||||||
|
import {
|
||||||
|
Toast
|
||||||
|
} from '../libs/uniApi';
|
||||||
|
import Cache from '@/utils/cache';
|
||||||
|
export default {
|
||||||
|
props: {
|
||||||
|
isSelectPlace: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false
|
||||||
|
},
|
||||||
|
location_Arr: {
|
||||||
|
type: Object,
|
||||||
|
default: () => ({})
|
||||||
|
},
|
||||||
|
town: {
|
||||||
|
type: String,
|
||||||
|
default: false
|
||||||
|
},
|
||||||
|
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
defaInd: [0, 0],
|
||||||
|
street: '',
|
||||||
|
|
||||||
|
showPicker: false,
|
||||||
|
styleConfig: [],
|
||||||
|
columnData: [],
|
||||||
|
homeCombData: [],
|
||||||
|
keyword: '',
|
||||||
|
bgColor: '',
|
||||||
|
swiper: {
|
||||||
|
url: [{
|
||||||
|
img: ''
|
||||||
|
}],
|
||||||
|
indicatorDots: true, // 显示面板指示点
|
||||||
|
vertical: false, // 滑动方向是否为纵向
|
||||||
|
autoplay: true, // 是否自动切换
|
||||||
|
interval: 2000, // 自动切换时间间隔
|
||||||
|
duration: 400 // 滑动动画时长
|
||||||
|
},
|
||||||
|
|
||||||
|
}
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
street(nval, val) {
|
||||||
|
this.street = nval
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
created() {
|
||||||
|
|
||||||
|
this.getBanner()
|
||||||
|
this.Area()
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
mounted() {
|
||||||
|
this.$bus.$on('value-updated', (newValue) => {
|
||||||
|
// 更新组件的值
|
||||||
|
this.street = newValue.split(',')[0]
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
methods: {
|
||||||
|
swiperClick(item) {
|
||||||
|
const url = item.info[1].value
|
||||||
|
uni.navigateTo({
|
||||||
|
url: url
|
||||||
|
})
|
||||||
|
},
|
||||||
|
selectLocation() {
|
||||||
|
this.isSelectPlace ? this.showPicker = true : ''
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
confirm(e) {
|
||||||
|
|
||||||
|
this.showPicker = false
|
||||||
|
this.$emit('selectPlce', e)
|
||||||
|
this.$emit('change', e)
|
||||||
|
this.street = e.value[1].name
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$bus.$emit('value-updated', e.value[1].name + ',' + e.value[1].code);
|
||||||
|
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
},
|
||||||
|
changeHandler(e) {
|
||||||
|
const {
|
||||||
|
columnIndex,
|
||||||
|
value,
|
||||||
|
values,
|
||||||
|
index,
|
||||||
|
picker = this.$refs.uPicker
|
||||||
|
} = e;
|
||||||
|
if (columnIndex === 0) {
|
||||||
|
getStreet({
|
||||||
|
area_code: value[0]['code']
|
||||||
|
}).then(res => {
|
||||||
|
picker.setColumnValues(1, res.data);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
Area() {
|
||||||
|
getArea({
|
||||||
|
city_code: 510500
|
||||||
|
}).then(res => {
|
||||||
|
this.$refs.uPicker.setColumnValues(0, res.data);
|
||||||
|
this.Street(res.data[0]['code']);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
Street(code) {
|
||||||
|
getStreet({
|
||||||
|
area_code: code
|
||||||
|
}).then(res => {
|
||||||
|
this.$refs.uPicker.setColumnValues(1, res.data);
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
swiperChange(e) {
|
||||||
|
let {
|
||||||
|
current,
|
||||||
|
source
|
||||||
|
} = e.detail;
|
||||||
|
if (source === 'autoplay' || source === 'touch') {
|
||||||
|
this.bgColor = this.swiper.url[e.detail.current]['img']
|
||||||
|
this.$emit('kkchange', this.bgColor)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
// 对象转数组
|
||||||
|
objToArr(data) {
|
||||||
|
let obj = Object.keys(data).sort();
|
||||||
|
let m = obj.map(key => data[key]);
|
||||||
|
return m;
|
||||||
|
},
|
||||||
|
async getBanner(id) {
|
||||||
|
let that = this;
|
||||||
|
const {
|
||||||
|
data
|
||||||
|
} = await getDiy({
|
||||||
|
id: 0
|
||||||
|
})
|
||||||
|
that.styleConfig = that.objToArr(data.value);
|
||||||
|
/* 循环数组得到数据*/
|
||||||
|
that.styleConfig.forEach((item, index, arr) => {
|
||||||
|
if (item.name == 'headerSerch' || item.name == 'homeComb') {
|
||||||
|
if (item.name == 'homeComb') {
|
||||||
|
that.swiper.url = item.swiperConfig.list
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
this.bgColor = this.swiper.url[0].img
|
||||||
|
},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.zbp-head-wrapper {
|
||||||
|
position: relative;
|
||||||
|
// padding-top: 78.95rpx;
|
||||||
|
overflow: hidden;
|
||||||
|
// background-color: green;
|
||||||
|
height: 600rpx;
|
||||||
|
|
||||||
|
// .color-lump {
|
||||||
|
// z-index: 1;
|
||||||
|
// position: absolute;
|
||||||
|
// bottom: -86px;
|
||||||
|
// left: 50%;
|
||||||
|
// transform: translate(-50%, 0);
|
||||||
|
// width: 102%;
|
||||||
|
// height: 133px;
|
||||||
|
// border-radius: 30px 30px 0 0;
|
||||||
|
// background-color: #fff;
|
||||||
|
// }
|
||||||
|
|
||||||
|
.bg-img {
|
||||||
|
position: absolute;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
top: 0;
|
||||||
|
/* #ifdef MP || APP-PLUS */
|
||||||
|
z-index: -1;
|
||||||
|
/* #endif */
|
||||||
|
/* #ifdef H5 */
|
||||||
|
z-index: 0;
|
||||||
|
/* #endif */
|
||||||
|
z-index: 0;
|
||||||
|
filter: blur(0);
|
||||||
|
overflow: hidden;
|
||||||
|
|
||||||
|
img {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
filter: blur(30rpx);
|
||||||
|
transform: scale(1.5);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.site-box {
|
||||||
|
margin: 0 auto;
|
||||||
|
width: 750rpx;
|
||||||
|
height: 66.67rpx;
|
||||||
|
margin-top: 30rpx;
|
||||||
|
// margin-bottom: 26.32rpx;
|
||||||
|
position: absolute;
|
||||||
|
z-index: 9999;
|
||||||
|
padding-right: 20rpx;
|
||||||
|
|
||||||
|
|
||||||
|
// 位置
|
||||||
|
.place_wrapper {
|
||||||
|
margin-left: 20rpx;
|
||||||
|
color: #fff;
|
||||||
|
margin-right: 24.56rpx;
|
||||||
|
font-size: 30rpx;
|
||||||
|
|
||||||
|
.town_name {
|
||||||
|
margin-left: 21rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.iconfont {
|
||||||
|
font-size: 35.09rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.my-main {
|
||||||
|
transition: background-color .5s ease;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search_content {
|
||||||
|
margin: 0 auto;
|
||||||
|
width: 724rpx;
|
||||||
|
height: 74rpx;
|
||||||
|
padding: 2px 2px 2px 21.05rpx;
|
||||||
|
border-radius: 175rpx;
|
||||||
|
background: #fff;
|
||||||
|
margin-bottom: 21rpx;
|
||||||
|
position: relative;
|
||||||
|
box-sizing: border-box;
|
||||||
|
|
||||||
|
.icon-sousuo {
|
||||||
|
font-size: 26.32rpx;
|
||||||
|
font-weight: bold;
|
||||||
|
color: #c8c7c6;
|
||||||
|
margin-right: 17.54rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.search_btn {
|
||||||
|
color: #fff;
|
||||||
|
width: 105.26rpx;
|
||||||
|
height: 52.63rpx;
|
||||||
|
line-height: 52.63rpx;
|
||||||
|
background: #f84221;
|
||||||
|
border-radius: 100px;
|
||||||
|
font-size: 28.07rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.supply_chains-head {
|
||||||
|
// margin-bottom: 17.54rpx;
|
||||||
|
position: relative;
|
||||||
|
z-index: 2;
|
||||||
|
|
||||||
|
.swiper {
|
||||||
|
width: 750rpx;
|
||||||
|
height: 600rpx;
|
||||||
|
margin: 0 auto;
|
||||||
|
// border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||||
|
overflow: hidden;
|
||||||
|
|
||||||
|
.swi_item {
|
||||||
|
width: 750rpx;
|
||||||
|
height: 600rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
@ -177,7 +177,6 @@
|
|||||||
height="400.09rpx"></u--image>
|
height="400.09rpx"></u--image>
|
||||||
<view class="" style="text-align: center;">
|
<view class="" style="text-align: center;">
|
||||||
暂无商品
|
暂无商品
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -244,17 +243,19 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="empty" style="" v-else>
|
<view class="empty" style="" v-else>
|
||||||
<view style="height: var(--status-bar-height);"></view>
|
<view style="height: var(--status-bar-height);"></view>
|
||||||
|
<view style="padding: 10rpx;">
|
||||||
|
<u--image :showLoading="true" src="/static/images/LHYC/PFH.png" width="50.82rpx" height="50.82rpx"
|
||||||
|
@click='goBack'></u--image>
|
||||||
|
</view>
|
||||||
<view class="info">
|
<view class="info">
|
||||||
|
|
||||||
<u--image :showLoading="true" src="/static/images/noCart.png" width="400.09rpx"
|
<u--image :showLoading="true" src="/static/images/noCart.png" width="400.09rpx"
|
||||||
height="400.09rpx"></u--image>
|
height="400.09rpx"></u--image>
|
||||||
<view class="" style="text-align: center;">
|
<view class="" style="text-align: center;">
|
||||||
暂无商家
|
当前区域暂无云仓
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="" :style="`height:${appInfo.bottom}px;background-color:white`">
|
<view class="" :style="`height:${appInfo.bottom}px;background-color:white`">
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -266,7 +267,7 @@
|
|||||||
import {
|
import {
|
||||||
cloudWarehouse,
|
cloudWarehouse,
|
||||||
getCityCloundShop
|
getCityCloundShop
|
||||||
} from '@/api/api.js'
|
} from '@/api/requesta.js'
|
||||||
import {
|
import {
|
||||||
Toast
|
Toast
|
||||||
} from '@/libs/uniApi';
|
} from '@/libs/uniApi';
|
||||||
@ -335,7 +336,7 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(e) {
|
onLoad(e) {
|
||||||
this.cartFn()
|
// this.cartFn()
|
||||||
this.appInfo = this.$appInfo.safeAreaInsets
|
this.appInfo = this.$appInfo.safeAreaInsets
|
||||||
this.winHeight = this.$appInfo.windowHeight
|
this.winHeight = this.$appInfo.windowHeight
|
||||||
this.street_code = e.street
|
this.street_code = e.street
|
||||||
@ -344,7 +345,7 @@
|
|||||||
// console.log(this.appInfo, "手机信息")
|
// console.log(this.appInfo, "手机信息")
|
||||||
},
|
},
|
||||||
onShow() {
|
onShow() {
|
||||||
this.cartFn()
|
// this.cartFn()
|
||||||
},
|
},
|
||||||
// 分页
|
// 分页
|
||||||
onReachBottom() {
|
onReachBottom() {
|
||||||
@ -364,6 +365,12 @@
|
|||||||
if (res.data.list[0].product_id == this.goodsList[0].product_id) {
|
if (res.data.list[0].product_id == this.goodsList[0].product_id) {
|
||||||
this.status = "nomore"
|
this.status = "nomore"
|
||||||
this.flag = false
|
this.flag = false
|
||||||
|
} else {
|
||||||
|
if (res.data.list.length == 0) {
|
||||||
|
this.status = "nomore"
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.goodsList = this.goodsList.concat(res.data.list)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
// this.getList().then(res => {
|
// this.getList().then(res => {
|
||||||
|
@ -37,7 +37,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<view style="background-color: red;height: 10px">
|
<view style="background-color: red;height: 10px">
|
||||||
asdasd
|
|
||||||
</view>
|
</view>
|
||||||
<view class="hot_serch">
|
<view class="hot_serch">
|
||||||
<text>热搜:</text> <text @click="hotSerchFn('小张副食')">小张副食</text> <text
|
<text>热搜:</text> <text @click="hotSerchFn('小张副食')">小张副食</text> <text
|
||||||
@ -283,8 +283,10 @@
|
|||||||
import {
|
import {
|
||||||
storeMerchantList,
|
storeMerchantList,
|
||||||
getGeocoder,
|
getGeocoder,
|
||||||
supMenuApi
|
|
||||||
} from '@/api/store.js';
|
} from '@/api/store.js';
|
||||||
|
import {
|
||||||
|
supMenuApi
|
||||||
|
} from '@/api/requesta.js';
|
||||||
import recommend from './component/recommend';
|
import recommend from './component/recommend';
|
||||||
import rightSlider from './component/rightSlider';
|
import rightSlider from './component/rightSlider';
|
||||||
import {
|
import {
|
||||||
|
@ -274,9 +274,12 @@
|
|||||||
import {
|
import {
|
||||||
storeMerchantList,
|
storeMerchantList,
|
||||||
getGeocoder,
|
getGeocoder,
|
||||||
supMenuApi,
|
|
||||||
supAgoodsApi
|
supAgoodsApi
|
||||||
} from '@/api/store.js';
|
} from '@/api/store.js';
|
||||||
|
import {
|
||||||
|
supMenuApi,
|
||||||
|
} from '@/api/requesta.js';
|
||||||
import recommend from './component/recommend';
|
import recommend from './component/recommend';
|
||||||
import rightSlider from './component/rightSlider';
|
import rightSlider from './component/rightSlider';
|
||||||
import {
|
import {
|
||||||
|
@ -3,8 +3,8 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
<view v-if="followDetail != null && followDetail" class="main" @click.stop="showManage = false"
|
<view v-if="followDetail != null && followDetail" class="main" :class="{off_scoll:flag}"
|
||||||
style="padding-top: var(--status-bar-height);;">
|
@click.stop="showManage = false" style="padding-top: var(--status-bar-height);;">
|
||||||
<view v-if="followDetail.status != 1" class="approval_status">
|
<view v-if="followDetail.status != 1" class="approval_status">
|
||||||
<view class="status_count" :class="followDetail.status == 0 ? 'status1' : 'status0'">
|
<view class="status_count" :class="followDetail.status == 0 ? 'status1' : 'status0'">
|
||||||
<view class="status_title">
|
<view class="status_title">
|
||||||
@ -202,7 +202,8 @@
|
|||||||
<text>暂无评论,快去抢沙发吧~</text>
|
<text>暂无评论,快去抢沙发吧~</text>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view v-if="followDetail.status == 1 && followDetail.relevance.length<=0" class="release_bar acea-row">
|
<view v-if="followDetail.status == 1 && followDetail.relevance.length<=0"
|
||||||
|
class="release_bar acea-row">
|
||||||
<view class="input_count" :class="{input_reply:content}">
|
<view class="input_count" :class="{input_reply:content}">
|
||||||
<form @submit="submitComment">
|
<form @submit="submitComment">
|
||||||
<input type="text" :placeholder="placeholder"
|
<input type="text" :placeholder="placeholder"
|
||||||
@ -220,21 +221,22 @@
|
|||||||
:class="followDetail.relevance_id ? 'icon-shoucang1' : 'icon-dianzan'"></text>
|
:class="followDetail.relevance_id ? 'icon-shoucang1' : 'icon-dianzan'"></text>
|
||||||
<text>{{followDetail.count_start}}</text>
|
<text>{{followDetail.count_start}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="item acea-row" @click="FToggle">
|
<view class="item acea-row" @click="FToggle">
|
||||||
<text class="iconfont icon-pinglun"></text>
|
<text class="iconfont icon-pinglun"></text>
|
||||||
<text>{{replyData.all}}</text>
|
<text>{{replyData.all}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view v-if="followDetail.status == 1&& followDetail.relevance.length>0" class="release_bar acea-row">
|
<view v-if="followDetail.status == 1&& followDetail.relevance.length>0"
|
||||||
|
class="release_bar acea-row">
|
||||||
|
|
||||||
<view class="shopp" @click="openMore(followDetail)" style="margin-top: 10rpx">
|
<view class="shopp" @click="openMore(followDetail)" style="margin-top: 10rpx">
|
||||||
<view class="shopp-img">
|
<view class="shopp-img">
|
||||||
<image src="@/static/images/shopp.png" mode=""></image>
|
<image src="@/static/images/shopp.png" mode=""></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="shopp-txt">
|
<view class="shopp-txt">
|
||||||
商品 (2)
|
商品 ({{followDetail.relevance.length}})
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -265,8 +267,8 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- 他提到的宝贝弹窗 -->
|
<!-- 他提到的宝贝弹窗 -->
|
||||||
<mentioned ref="mentioned" v-if="followDetail" @close="close" :list="followDetail.relevance"
|
<mentioned ref="mentioned" v-if="followDetail" @close="close" @closes="flag=false"
|
||||||
:uid="followDetail.uid"></mentioned>
|
:list="followDetail.relevance" :uid="followDetail.uid"></mentioned>
|
||||||
<authorize @onLoadFun="onLoadFun" :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse"></authorize>
|
<authorize @onLoadFun="onLoadFun" :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse"></authorize>
|
||||||
<!-- 绑定手机号 -->
|
<!-- 绑定手机号 -->
|
||||||
<uni-popup ref="bindmobile" type="bottom">
|
<uni-popup ref="bindmobile" type="bottom">
|
||||||
@ -275,10 +277,15 @@
|
|||||||
|
|
||||||
<uni-popup ref="bindmobile1" type="bottom">
|
<uni-popup ref="bindmobile1" type="bottom">
|
||||||
<view class="" style="background-color: #fff;height: 154rpx ;">
|
<view class="" style="background-color: #fff;height: 154rpx ;">
|
||||||
<view class="input_count1" :class="{input_reply:content}" >
|
<view class="input_count1" :class="{input_reply:content}">
|
||||||
<form @submit="submitComment">
|
<form @submit="submitComment">
|
||||||
<input type="text" class="count1" :placeholder="placeholder" placeholder-style="color: #999999; font-size: 26rpx;"
|
<view class="" style="display: flex;padding: 0 20rpx;box-sizing: border-box;">
|
||||||
v-model="content" :focus="focus" @confirm.stop="submitComment()" cursorSpacing={20}>
|
<input type="text" class="count1" :placeholder="placeholder"
|
||||||
|
placeholder-style="color: #999999; font-size: 26rpx;" v-model="content" :focus="focus"
|
||||||
|
@confirm.stop="submitComment()" cursorSpacing={20}>
|
||||||
|
<button class="send1" @click.stop="submitComment">发送</button>
|
||||||
|
</view>
|
||||||
|
|
||||||
</form>
|
</form>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -336,6 +343,7 @@
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
flag: false,
|
||||||
open_grass: openPlantGrass,
|
open_grass: openPlantGrass,
|
||||||
followDetail: null,
|
followDetail: null,
|
||||||
commList: [], //评论列表
|
commList: [], //评论列表
|
||||||
@ -712,10 +720,12 @@
|
|||||||
/*查看提到的宝贝*/
|
/*查看提到的宝贝*/
|
||||||
openMore(item) {
|
openMore(item) {
|
||||||
this.$refs.mentioned.showPopup()
|
this.$refs.mentioned.showPopup()
|
||||||
|
this.flag = true
|
||||||
},
|
},
|
||||||
close() {
|
close() {
|
||||||
this.$refs.mentioned.closePopup()
|
this.$refs.mentioned.closePopup()
|
||||||
this.$refs.bindmobile.close()
|
this.$refs.bindmobile.close()
|
||||||
|
this.flag = false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onReachBottom() {
|
onReachBottom() {
|
||||||
@ -1280,23 +1290,25 @@
|
|||||||
font-size: 32rpx;
|
font-size: 32rpx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.input_count1{
|
|
||||||
|
|
||||||
height: 70rpx;
|
.input_count1 {
|
||||||
padding-top: 15rpx;
|
|
||||||
|
|
||||||
|
|
||||||
/deep/.count1{
|
|
||||||
padding-left: 20rpx;
|
|
||||||
width: 617rpx;
|
|
||||||
height: 70rpx;
|
height: 70rpx;
|
||||||
background: #F4F4F4;
|
padding-top: 15rpx;
|
||||||
margin: 0 auto;
|
|
||||||
|
|
||||||
|
/deep/.count1 {
|
||||||
|
padding-left: 20rpx;
|
||||||
|
width: 617rpx;
|
||||||
|
height: 70rpx;
|
||||||
|
background: #F4F4F4;
|
||||||
|
margin: 0 auto;
|
||||||
|
|
||||||
|
border-radius: 35px 35px 35px 35px;
|
||||||
|
}
|
||||||
|
|
||||||
border-radius: 35px 35px 35px 35px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
|
||||||
.release_bar {
|
.release_bar {
|
||||||
align-items: center;
|
align-items: center;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
@ -1403,4 +1415,24 @@
|
|||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.send1 {
|
||||||
|
font-size: 26rpx;
|
||||||
|
color: #ffffff;
|
||||||
|
// padding: 12rpx 45rpx;
|
||||||
|
background-image: linear-gradient(126deg, var(--view-bntColor21) 0%, var(--view-bntColor22) 100%);
|
||||||
|
border-radius: 30rpx;
|
||||||
|
text-align: center;
|
||||||
|
width: 150rpx;
|
||||||
|
line-height: 70rpx;
|
||||||
|
margin-left: 20rpx;
|
||||||
|
|
||||||
|
// height: ;
|
||||||
|
}
|
||||||
|
|
||||||
|
// 禁止滚动
|
||||||
|
.off_scoll {
|
||||||
|
height: 100vh;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
76
utils/requesta.js
Normal file
76
utils/requesta.js
Normal file
@ -0,0 +1,76 @@
|
|||||||
|
// +----------------------------------------------------------------------
|
||||||
|
// | CRMEB [ CRMEB赋能开发者,助力企业发展 ]
|
||||||
|
// +----------------------------------------------------------------------
|
||||||
|
// | Copyright (c) 2016~2021 https://www.crmeb.com All rights reserved.
|
||||||
|
// +----------------------------------------------------------------------
|
||||||
|
// | Licensed CRMEB并不是自由软件,未经许可不能去掉CRMEB相关版权
|
||||||
|
// +----------------------------------------------------------------------
|
||||||
|
// | Author: CRMEB Team <admin@crmeb.com>
|
||||||
|
// +----------------------------------------------------------------------
|
||||||
|
import {
|
||||||
|
HTTP_REQUEST_URL,
|
||||||
|
HEADER,
|
||||||
|
TOKENNAME
|
||||||
|
} from '@/config/app';
|
||||||
|
import {
|
||||||
|
checkLogin
|
||||||
|
} from '../libs/login';
|
||||||
|
import store from '../store';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 发送请求
|
||||||
|
*/
|
||||||
|
function baseRequest(url, method, data, {
|
||||||
|
noAuth = false,
|
||||||
|
noVerify = false
|
||||||
|
}) {
|
||||||
|
let Url = HTTP_REQUEST_URL,
|
||||||
|
header = HEADER;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if (store.state.app.token) header[TOKENNAME] = 'Bearer ' + store.state.app.token;
|
||||||
|
|
||||||
|
return new Promise((reslove, reject) => {
|
||||||
|
uni.request({
|
||||||
|
url: Url + '/api/' + url,
|
||||||
|
method: method || 'GET',
|
||||||
|
header: header,
|
||||||
|
data: data || {},
|
||||||
|
success: (res) => {
|
||||||
|
// #ifdef APP-PLUS
|
||||||
|
// console.log('app', Url + '/api/' + url, res.data);
|
||||||
|
// #endif
|
||||||
|
if (noVerify)
|
||||||
|
reslove(res.data, res);
|
||||||
|
else if (res.data.status == 200)
|
||||||
|
reslove(res.data, res);
|
||||||
|
else if ([410000, 410001, 410002, 40000].indexOf(res.data.status) !== -1) {
|
||||||
|
|
||||||
|
reject(res.data);
|
||||||
|
} else if (res.data.status == 501) {
|
||||||
|
uni.reLaunch({
|
||||||
|
url: '/pages/error/index'
|
||||||
|
})
|
||||||
|
reject(res.data);
|
||||||
|
} else
|
||||||
|
reject(res.data.message || '系统错误');
|
||||||
|
},
|
||||||
|
fail: (message) => {
|
||||||
|
reject('请求失败');
|
||||||
|
}
|
||||||
|
})
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
const request = {};
|
||||||
|
|
||||||
|
['options', 'get', 'post', 'put', 'head', 'delete', 'trace', 'connect'].forEach((method) => {
|
||||||
|
request[method] = (api, data, opt) => baseRequest(api, method, data, opt || {})
|
||||||
|
});
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
export default request;
|
Loading…
x
Reference in New Issue
Block a user