更新功能
This commit is contained in:
parent
2df7fe1658
commit
9126f44765
@ -3,6 +3,10 @@ import request from "@/utils/requesta.js";
|
|||||||
export function getCityCloundShop(data) {
|
export function getCityCloundShop(data) {
|
||||||
return request.get("city/get_cloud_shop", data);
|
return request.get("city/get_cloud_shop", data);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function getCategoryListLevel(data) {
|
||||||
|
return request.get("category/list_level", data);
|
||||||
|
}
|
||||||
export function cloudWarehouse(data) {
|
export function cloudWarehouse(data) {
|
||||||
return request.get("store/product/cloudWarehouse", data);
|
return request.get("store/product/cloudWarehouse", data);
|
||||||
}
|
}
|
||||||
|
175
components/shortPopup.vue
Normal file
175
components/shortPopup.vue
Normal file
@ -0,0 +1,175 @@
|
|||||||
|
<template>
|
||||||
|
<view>
|
||||||
|
<uni-popup ref="popupRef" type="bottom">
|
||||||
|
<view class="pop">
|
||||||
|
<view class="image">
|
||||||
|
<image src="../static/images/f2.png"></image>
|
||||||
|
<view class="border"></view>
|
||||||
|
</view>
|
||||||
|
<view class="white_card">
|
||||||
|
<view class="flex">
|
||||||
|
<view class="price">¥<text class="pro">10</text>.00</view>
|
||||||
|
<view>订货价</view>
|
||||||
|
</view>
|
||||||
|
<view class="short_name">商品名称</view>
|
||||||
|
<view class="shop_name">店铺名称</view>
|
||||||
|
<u-line></u-line>
|
||||||
|
<view class="m_title">规格选中</view>
|
||||||
|
<view class="flex">
|
||||||
|
<view class="attr">规格1</view>
|
||||||
|
<view class="attr">规格2</view>
|
||||||
|
</view>
|
||||||
|
<view class="m_title num">
|
||||||
|
<view>购买数量</view>
|
||||||
|
<view>1</view>
|
||||||
|
</view>
|
||||||
|
<view>
|
||||||
|
商品库存 200
|
||||||
|
</view>
|
||||||
|
<view class="button">
|
||||||
|
<view class="b_icon">
|
||||||
|
<image src="@/static/images/icon/car.png"></image>
|
||||||
|
<view>采购车</view>
|
||||||
|
</view>
|
||||||
|
<view class="btn">加入采购清单</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</uni-popup>
|
||||||
|
</view>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: "shortPopup",
|
||||||
|
props: ['datas'],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
show: false
|
||||||
|
};
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
open() {
|
||||||
|
this.$refs.popupRef.open();
|
||||||
|
},
|
||||||
|
close() {
|
||||||
|
this.$refs.popupRef.close();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.pop {
|
||||||
|
background-color: #fff;
|
||||||
|
border-radius: 31.54rpx 31.54rpx 0rpx 0rpx;
|
||||||
|
overflow: hidden;
|
||||||
|
position: relative;
|
||||||
|
|
||||||
|
.image{
|
||||||
|
height: 750rpx;
|
||||||
|
width: 750rpx;
|
||||||
|
position: relative;
|
||||||
|
image{
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
.border{
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
left: 0;
|
||||||
|
background-color: #fff;
|
||||||
|
height: 40rpx;
|
||||||
|
width: 100%;
|
||||||
|
border-radius: 40rpx 40rpx 0 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.white_card{
|
||||||
|
border-radius: 31.54rpx 31.54rpx 0rpx 0rpx;
|
||||||
|
background-color: #fff;
|
||||||
|
margin: 0 28rpx;
|
||||||
|
padding-bottom: 30rpx;
|
||||||
|
color: #737373;
|
||||||
|
font-size: 26.29rpx;
|
||||||
|
|
||||||
|
.price{
|
||||||
|
font-size: 35rpx;
|
||||||
|
font-family: SF Pro Display-Semibold, SF Pro Display;
|
||||||
|
font-weight: 600;
|
||||||
|
color: #F84221;
|
||||||
|
.pro{
|
||||||
|
font-size: 49.07rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.short_name{
|
||||||
|
font-size: 33rpx;
|
||||||
|
font-family: PingFang SC-Semibold, PingFang SC;
|
||||||
|
font-weight: 600;
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
.shop_name{
|
||||||
|
display: inline-block;
|
||||||
|
background: #FEF5F3;
|
||||||
|
padding: 0 16rpx;
|
||||||
|
border-radius: 26rpx 26rpx 26rpx 26rpx;
|
||||||
|
margin-top: 30rpx;
|
||||||
|
margin-bottom: 20rpx;
|
||||||
|
}
|
||||||
|
.m_title{
|
||||||
|
font-size: 30rpx;
|
||||||
|
font-family: PingFang SC-Medium, PingFang SC;
|
||||||
|
font-weight: 500;
|
||||||
|
color: #333333;
|
||||||
|
margin-top: 31rpx;
|
||||||
|
margin-bottom: 21rpx;
|
||||||
|
}
|
||||||
|
.attr{
|
||||||
|
background: #FEF5F3;
|
||||||
|
opacity: 1;
|
||||||
|
border: 1rpx solid #F84221;
|
||||||
|
padding: 15rpx 30rpx;
|
||||||
|
margin-right: 20rpx;
|
||||||
|
height: 63rpx;
|
||||||
|
border-radius: 63rpx;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
.num{
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
}
|
||||||
|
.button{
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-around;
|
||||||
|
margin-top: 20rpx;
|
||||||
|
.b_icon{
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 19rpx;
|
||||||
|
font-weight: 400;
|
||||||
|
color: #333333;
|
||||||
|
image{
|
||||||
|
width: 50.82rpx;
|
||||||
|
height: 50.82rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.btn{
|
||||||
|
width: 575rpx;
|
||||||
|
height: 84rpx;
|
||||||
|
background: linear-gradient(270deg, #FF6D20 0%, #F84221 100%);
|
||||||
|
border-radius: 42rpx 42rpx 42rpx 42rpx;
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 30rpx;
|
||||||
|
font-family: PingFang SC-Medium, PingFang SC;
|
||||||
|
font-weight: 500;
|
||||||
|
color: #FFFFFF;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
@ -838,8 +838,7 @@
|
|||||||
order: this.type,
|
order: this.type,
|
||||||
keyword: this.keyword,
|
keyword: this.keyword,
|
||||||
page: this.page_num,
|
page: this.page_num,
|
||||||
location: this.location
|
location: this.location,
|
||||||
|
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
this.goodsList = res.data.list
|
this.goodsList = res.data.list
|
||||||
this.showLoading = false
|
this.showLoading = false
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -17,7 +17,7 @@
|
|||||||
供销综合云市场
|
供销综合云市场
|
||||||
</view>
|
</view>
|
||||||
<view class=""
|
<view class=""
|
||||||
@click="navGoto(`/pages/nongKe/cloud_entrepot/indexb?street=${street_id}&townName=${street}&location=${latitude},${longitude}`)"
|
@click="navGoto(`/pages/nongKe/cloud_entrepot/indexb?street_id=${street_id}&townName=${street}&location=${latitude},${longitude}`)"
|
||||||
style="font-size: 31.54rpx;font-weight: 700;transform: skewX(-10deg);margin-left: 20rpx;">
|
style="font-size: 31.54rpx;font-weight: 700;transform: skewX(-10deg);margin-left: 20rpx;">
|
||||||
供销综合云商品
|
供销综合云商品
|
||||||
</view>
|
</view>
|
||||||
@ -87,11 +87,11 @@
|
|||||||
|
|
||||||
<view class="menu_cls">
|
<view class="menu_cls">
|
||||||
<u-scroll-list indicatorActiveColor='#FF6D20' :indicator="true">
|
<u-scroll-list indicatorActiveColor='#FF6D20' :indicator="true">
|
||||||
<view class="menu_li" @click="changeMerchant(item.merchant_category_id)" v-for="item,index in menuList"
|
<view class="menu_li" :class="{'menu_li_on': item.merchant_category_id==merchant_category_id}" @click="changeMerchant(item.merchant_category_id)" v-for="item,index in menuList"
|
||||||
:key="index">
|
:key="index">
|
||||||
<u--image :showLoading="true" :src="item.background" width="87.62rpx" height="87.62rpx" shape="circle"
|
<u--image class="image" :showLoading="true" :src="item.background" width="87.62rpx" height="87.62rpx" shape="circle"
|
||||||
></u--image>
|
></u--image>
|
||||||
<view style="display: block;font-size: 26.29rpx;margin-top: 10rpx;">{{item.category_name}}</view>
|
<view class="li_text" style="display: block;font-size: 26.29rpx;margin-top: 10rpx;">{{item.category_name}}</view>
|
||||||
</view>
|
</view>
|
||||||
</u-scroll-list>
|
</u-scroll-list>
|
||||||
</view>
|
</view>
|
||||||
@ -121,7 +121,7 @@
|
|||||||
<text v-if="item.type_id==17"
|
<text v-if="item.type_id==17"
|
||||||
style="font-weight: normal;font-size: 19.28rpx;color: red;padding:0 10rpx; border-radius: 10rpx; border: 1px solid red;">{{item.type_name}}</text>
|
style="font-weight: normal;font-size: 19.28rpx;color: red;padding:0 10rpx; border-radius: 10rpx; border: 1px solid red;">{{item.type_name}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="li">
|
<view class="li" style="align-items: center;">
|
||||||
<view class="score">
|
<view class="score">
|
||||||
<view class="star">
|
<view class="star">
|
||||||
<view
|
<view
|
||||||
@ -129,10 +129,9 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<text style="margin-left: 20rpx;color: #FF6D20; ">{{item.service_score}}</text>
|
<text style="margin-left: 20rpx;color: #FF6D20;font-size: 22.78rpx; ">{{item.service_score}}</text>
|
||||||
<text>月销{{item.sales}}</text>
|
<text style="font-size: 24.53rpx;">月销{{item.sales}}</text>
|
||||||
<text v-if="item.distance" style="font-size: 24rpx;color: #aaa;">{{item.distance}}</text>
|
<text v-if="item.distance" style="font-size: 21.03rpx;color: #aaa;">{{item.distance}}</text>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
<view class="li" style="align-items: center;">
|
<view class="li" style="align-items: center;">
|
||||||
<u--image :showLoading="true" src="/static/images/GXSC/DH.png" width="33.85rpx"
|
<u--image :showLoading="true" src="/static/images/GXSC/DH.png" width="33.85rpx"
|
||||||
@ -307,6 +306,7 @@
|
|||||||
},
|
},
|
||||||
storeKey: 0,
|
storeKey: 0,
|
||||||
storeScroll: true,
|
storeScroll: true,
|
||||||
|
merchant_category_id: '', // 当前选中类型的id
|
||||||
mer_id: '',
|
mer_id: '',
|
||||||
sortId: '',
|
sortId: '',
|
||||||
price_on: '',
|
price_on: '',
|
||||||
@ -342,15 +342,16 @@
|
|||||||
this.storeParam.type_id = options.type_id && options.type_id.split(',').toString() || ''
|
this.storeParam.type_id = options.type_id && options.type_id.split(',').toString() || ''
|
||||||
this.storeParam.category_id = options.cate_id && options.cate_id.split(',').toString() || ''
|
this.storeParam.category_id = options.cate_id && options.cate_id.split(',').toString() || ''
|
||||||
this.storeList = [];
|
this.storeList = [];
|
||||||
|
supMenuApi().then(res => {
|
||||||
|
this.menuList = res.data;
|
||||||
|
this.merchant_category_id = this.menuList[0].merchant_category_id;
|
||||||
|
this.storeParam.category_id = this.merchant_category_id;
|
||||||
if (this.mer_location == 1) {
|
if (this.mer_location == 1) {
|
||||||
this.selfLocation()
|
this.selfLocation()
|
||||||
}
|
}
|
||||||
this.storeMerchantList();
|
// this.storeMerchantList();
|
||||||
this.getClassfication();
|
this.getClassfication();
|
||||||
this.getStoreType();
|
this.getStoreType();
|
||||||
supMenuApi().then(res => {
|
|
||||||
this.menuList = res.data
|
|
||||||
})
|
|
||||||
this.Area()
|
this.Area()
|
||||||
let that = this
|
let that = this
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
@ -361,10 +362,11 @@
|
|||||||
// console.log(this.cartTagInfo, 6666)
|
// console.log(this.cartTagInfo, 6666)
|
||||||
// that.cartTagInfo = rect
|
// that.cartTagInfo = rect
|
||||||
that.headTop = rect.top
|
that.headTop = rect.top
|
||||||
console.log(that.headTop)
|
// console.log(that.headTop)
|
||||||
})
|
})
|
||||||
.exec();
|
.exec();
|
||||||
}, 100)
|
}, 100)
|
||||||
|
})
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
downMenus: function() {
|
downMenus: function() {
|
||||||
@ -387,7 +389,6 @@
|
|||||||
methods: {
|
methods: {
|
||||||
selectLocation() {
|
selectLocation() {
|
||||||
this.isSelectPlace ? this.showPicker = true : ''
|
this.isSelectPlace ? this.showPicker = true : ''
|
||||||
|
|
||||||
},
|
},
|
||||||
confirm(e) {
|
confirm(e) {
|
||||||
this.showPicker = false
|
this.showPicker = false
|
||||||
@ -627,7 +628,10 @@
|
|||||||
},
|
},
|
||||||
selfLocation() {
|
selfLocation() {
|
||||||
let self = this
|
let self = this
|
||||||
if (uni.getStorageSync('RejectTarget')) return;
|
if (uni.getStorageSync('RejectTarget')) {
|
||||||
|
this.storeMerchantList();
|
||||||
|
return;
|
||||||
|
}
|
||||||
if(this.$store?.state?.storage?.location?.lat){
|
if(this.$store?.state?.storage?.location?.lat){
|
||||||
this.latitude = this.$store?.state?.storage?.location?.lat;
|
this.latitude = this.$store?.state?.storage?.location?.lat;
|
||||||
this.longitude = this.$store?.state?.storage?.location?.long;
|
this.longitude = this.$store?.state?.storage?.location?.long;
|
||||||
@ -640,12 +644,14 @@
|
|||||||
this.location_address = res.data.address;
|
this.location_address = res.data.address;
|
||||||
this.recommend_address = res.data.address.length > 4 ? res.data.address
|
this.recommend_address = res.data.address.length > 4 ? res.data.address
|
||||||
.slice(0, 4) + '...' :
|
.slice(0, 4) + '...' :
|
||||||
res.data.address
|
res.data.address;
|
||||||
|
this.storeMerchantList();
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: err,
|
title: err,
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
})
|
})
|
||||||
|
this.storeMerchantList();
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
else uni.getLocation({
|
else uni.getLocation({
|
||||||
@ -671,11 +677,13 @@
|
|||||||
this.recommend_address = res.data.address.length > 4 ? res.data.address
|
this.recommend_address = res.data.address.length > 4 ? res.data.address
|
||||||
.slice(0, 4) + '...' :
|
.slice(0, 4) + '...' :
|
||||||
res.data.address
|
res.data.address
|
||||||
|
this.storeMerchantList();
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: err,
|
title: err,
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
})
|
})
|
||||||
|
this.storeMerchantList();
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
fail: (res) => {
|
fail: (res) => {
|
||||||
@ -684,6 +692,7 @@
|
|||||||
icon: 'none',
|
icon: 'none',
|
||||||
duration: 1000
|
duration: 1000
|
||||||
});
|
});
|
||||||
|
this.storeMerchantList();
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
@ -728,7 +737,7 @@
|
|||||||
page: this.storeParam.page,
|
page: this.storeParam.page,
|
||||||
limit: 10,
|
limit: 10,
|
||||||
order: this.storeParam.order,
|
order: this.storeParam.order,
|
||||||
category_id: this.storeParam.category_id,
|
// category_id: this.storeParam.category_id,
|
||||||
type_id: this.storeParam.type_id,
|
type_id: this.storeParam.type_id,
|
||||||
credit_buy: this.credit_buy,
|
credit_buy: this.credit_buy,
|
||||||
}
|
}
|
||||||
@ -830,7 +839,10 @@
|
|||||||
},
|
},
|
||||||
// 点击商户分类
|
// 点击商户分类
|
||||||
changeMerchant(id){
|
changeMerchant(id){
|
||||||
console.log(id);
|
this.merchant_category_id = id;
|
||||||
|
this.storeParam.category_id = this.merchant_category_id;
|
||||||
|
this.storeParam.page = 1;
|
||||||
|
this.storeMerchantList()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
//刷新
|
//刷新
|
||||||
@ -930,20 +942,44 @@
|
|||||||
// height: 199.77rpx;
|
// height: 199.77rpx;
|
||||||
border-radius: 21.03rpx 21.03rpx 21.03rpx 21.03rpx;
|
border-radius: 21.03rpx 21.03rpx 21.03rpx 21.03rpx;
|
||||||
padding: 20rpx 20rpx 0 20rpx;
|
padding: 20rpx 20rpx 0 20rpx;
|
||||||
|
font-size: 26.29rpx;
|
||||||
|
height: 220rpx;
|
||||||
|
|
||||||
.menu_li {
|
.menu_li {
|
||||||
margin-right: 30rpx;
|
margin-right: 20rpx;
|
||||||
// background-color: red;
|
// background-color: red;
|
||||||
// width: 50vw;
|
// width: 50vw;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
min-width: 15vw;
|
min-width: 16vw;
|
||||||
height: 140rpx;
|
height: auto;
|
||||||
// width: 120rpx;
|
// width: 120rpx;
|
||||||
// display: inline-block;
|
// display: inline-block;
|
||||||
|
.image{
|
||||||
|
border: 5rpx solid #fff;
|
||||||
|
}
|
||||||
|
.li_text{
|
||||||
|
width: 100%;
|
||||||
|
white-space: nowrap;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
text-align: center;
|
||||||
|
padding: 4rpx 10rpx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.menu_li_on{
|
||||||
|
.image{
|
||||||
|
border: 5rpx solid #ff6d20;
|
||||||
|
border-radius: 50%;
|
||||||
|
}
|
||||||
|
.li_text{
|
||||||
|
background-color: #ff6d20;
|
||||||
|
border-radius: 2em;
|
||||||
|
color: #fff;
|
||||||
|
padding: 4rpx 10rpx;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -976,6 +1012,7 @@
|
|||||||
padding: 20rpx;
|
padding: 20rpx;
|
||||||
// border-radius: 20rpx;
|
// border-radius: 20rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
border-radius: 21rpx 21rpx 21rpx 21rpx;
|
||||||
// align-items: center;
|
// align-items: center;
|
||||||
|
|
||||||
.left {
|
.left {
|
||||||
@ -988,16 +1025,18 @@
|
|||||||
|
|
||||||
.right {
|
.right {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
|
color: #737373;
|
||||||
.head {
|
.head {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
// color: red;
|
// color: red;
|
||||||
|
color: #333;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.li {
|
.li {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
display: flex;
|
display: flex;
|
||||||
font-size: 26.29rpx;
|
font-size: 28.04rpx;
|
||||||
margin-bottom: 10rpx;
|
margin-bottom: 10rpx;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|
||||||
|
BIN
static/images/icon/car.png
Normal file
BIN
static/images/icon/car.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.5 KiB |
BIN
static/images/icon/plus.png
Normal file
BIN
static/images/icon/plus.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.2 KiB |
Loading…
x
Reference in New Issue
Block a user