tianyi 2 weeks ago
parent
commit
27f9a69498
  1. 22
      package1/buyFood/buyFood.vue
  2. 10
      package1/group/groupBuyDetail.vue
  3. 127
      package1/group/groupBuySingle.vue
  4. 4
      package1/group/shopEvaluate.vue
  5. 2
      package1/myCenter/partTimeJobRegister.vue

22
package1/buyFood/buyFood.vue

@ -35,9 +35,6 @@
</view>
<view class="ziqu-address">
<img src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/e13c675ffd4547d0b271900902ffea66.png" alt="" />
<view class="ziqu-text">
{{shopItem.shopName || '未知商家'}}
</view>
<view class="ziqu-text">
地址{{shopItem.shopAddress || ''}}
</view>
@ -87,7 +84,7 @@
</view>
<view v-if="isPaotui" style='background: #fff;border-bottom: 1px solid #eee;'>
<view
style="height: 90rpx;line-height: 40rpx;padding: 0 40rpx;font-size: 28rpx;font-weight: 700;padding-top: 20rpx;">
style="height: 140rpx;line-height: 40rpx;padding: 0 40rpx;font-size: 28rpx;font-weight: 700;padding-top: 20rpx;">
<view class="">
配送员
</view>
@ -238,9 +235,9 @@
<view style="flex: 1;color: #777;font-weight: 700;">
备注
</view>
<view style="color: #000;font-weight:700;">
<view style="color: #000;font-weight:700;flex: 1;">
<input type="digit" v-model="remark"
style="width: 140rpx; border-bottom: 1px solid #ccc; text-align: center; font-size: 28rpx; font-weight: normal; height: 50rpx; min-height: 50rpx;"
style="border-bottom: 1px solid #ccc; text-align: center; font-size: 28rpx; font-weight: normal; height: 50rpx; min-height: 50rpx;"
/>
</view>
</view>
@ -1138,7 +1135,10 @@
border-radius: 100rpx;
margin: 20rpx auto;
}
.ziqu-text{
align-items: center;
display: flex;
}
.btn {
width: 95%;
height: 100rpx;
@ -1174,19 +1174,19 @@
.ziqu-address {
display: flex;
height: 100rpx;
height: 110rpx;
background: #fff;
width: 90%;
border-radius: 20rpx;
font-size: 26rpx;
margin: 60rpx auto 0;
margin: 60rpx auto 20rpx;
font-weight: bold;
line-height: 100rpx;
line-height: 40rpx;
img {
width: 40rpx;
height: 40rpx;
margin: 30rpx 20rpx 0 30rpx;
margin: 36rpx 20rpx 0 30rpx;
}
}

10
package1/group/groupBuyDetail.vue

@ -20,11 +20,11 @@
</view>
<view style="line-height: 60rpx;height: 60rpx;color: #777;">
<uni-icons type="location" size="13"></uni-icons>
<text>{{shopItem.shopAddress}}</text>
<text style="padding-left: 10rpx;">{{shopItem.shopAddress}}</text>
</view>
<view style="line-height: 60rpx;height: 60rpx;color: #777;">
<uni-icons type="loop" size="13"></uni-icons>
<text>周一到周日 {{shopItem.shopTakeaway.businessHourBegin}}-{{shopItem.shopTakeaway.businessHourEnd}}</text>
<text style="padding-left: 10rpx;">周一到周日 {{shopItem.shopTakeaway.businessHourBegin}}-{{shopItem.shopTakeaway.businessHourEnd}}</text>
</view>
</view>
<view class="right">
@ -139,7 +139,7 @@
.back-btn{
position: absolute;
bottom: 0;
left: 0;
left: 20rpx;
}
.title-name{
padding-top: 110rpx;
@ -156,10 +156,10 @@
padding: 20rpx;
}
.left{
width: 60%;
width: 80%;
}
.right{
width: 40%;
width: 20%;
height: 160rpx;
}
.img-popup-content {

127
package1/group/groupBuySingle.vue

@ -91,10 +91,10 @@
</swiper>
</view>
<!-- 分类栏移到goods-list外层position:sticky才能生效 -->
<view class="container" :class="{'container-sticky': isContainerSticky}" :style="{'margin-top': isContainerSticky ? '0' : '10px', 'top': isContainerSticky ? navBarHeight + 'px' : 'auto'}" style="display: flex;height: 72%;">
<scroll-view scroll-y id="menuList" style="border-right: 1px solid #eee;font-weight: 700;font-size: 14px;height: 100%;width: 160rpx;">
<view class="container" style="display: flex;height: 72%;">
<scroll-view scroll-y id="menuList" style="border-right: 1px solid #eee;font-weight: 700;font-size: 28rpx;height: 100%;width: 160rpx;">
<view class="menu1" @tap="checkTab(index)" v-for="(item,index) in menuList" :key="index"
:style="{'border-radius':item.checked?'10px':'','color':item.checked?'rgba(0, 35, 28, 1)':'#777','background':item.checked?'#fff':'','border-right':item.checked?'5px solid #48D1CC;':''}">
:style="{'border-top-right-radius':item.checked?'20rpx':'','border-bottom-right-radius':item.checked?'20rpx':'','color':item.checked?'rgba(0, 35, 28, 1)':'#777','background':item.checked?'#fff':''}">
<view style="width: 160rpx;">{{item.categoryName}}</view>
</view>
</scroll-view>
@ -143,7 +143,6 @@
</view>
</view>
<uni-load-more :status="loadStatus" @change="onChange" />
<view style="height: 80px;width: 100%;"></view>
</scroll-view>
</view>
@ -178,7 +177,7 @@
<scroll-view scroll-y style="max-height: 400rpx;">
<view class="goods-top" style="padding: 20rpx 0;" v-for="(cartItem, index) in cartItems"
:key="index">
<view class="goods-img" style="width: 120rpx;height: 120rpx;">
<view class="goods-img" style="width: 168rpx;height: 168rpx;">
<img :src="cartItem.item.productPicture" alt=""
style="border-radius: 20rpx;width:100%;height:100%;">
</view>
@ -188,8 +187,9 @@
</view>
<view class="goods-content-center">
<view class="goods-deal1" v-if="cartItem.specs">
<text style="color: #999; font-size: 20rpx;">已选规格:
{{getSpecDisplayString(cartItem.specs)}}</text>
<text style="color: #999; font-size: 20rpx;">
已选规格:{{getSpecDisplayString(cartItem.specs)}}
</text>
</view>
</view>
<view class="goods-content-bottom" style="margin-top: 10rpx;">
@ -287,9 +287,22 @@
</view>
<view class="spec11" v-if="moreBuyList.length > 0 && isPintuan" style="display: flex;">
搭配小食
<view style="flex: 1;text-align: right;">
<uni-number-box v-model="vModelValue" :min="0" @change="changeValue" />
<view style="flex: 1;">
搭配小食
</view>
<view style="padding-top: 10rpx;">
<view class="goods-num">
<view class="num-plus" style="background: #999;color: #fff;"
@tap="changeValue('minus')">
-
</view>
<view class="num">
{{vModelValue}}
</view>
<view class="num-plus" @tap="changeValue('plus')">
+
</view>
</view>
</view>
</view>
@ -298,11 +311,14 @@
v-for="(spec, sIndex) in moreBuyList" :key="sIndex"
@tap="selectMoreBuy(spec,sIndex)">
<view class="team11">
{{spec.attributeListPrice | sliceMsg}} {{spec.quantity ? spec.quantity : ''}}
{{spec.attributeListPrice | sliceMsg}}
</view>
<view class="team11">
{{spec.productName}}
</view>
<view class="jiaobiao" v-if="spec.isChecked && spec.quantity>0">
{{spec.quantity ? spec.quantity : ''}}
</view>
</view>
</view>
@ -400,7 +416,7 @@
<!-- 支付弹出层 -->
<uni-popup ref="payPopup" background-color="#fff">
<view class="pay-popup" style="height: 960px;background: #fff;border-radius: 40rpx 40rpx 0 0;padding-top: 40rpx;">
<view class="pay-popup" style="height: 1920rpx;background: #fff;border-radius: 40rpx 40rpx 0 0;padding-top: 40rpx;">
<view class="content">
<view class="box1">
<view style="height: 70rpx;line-height: 70rpx;text-align: center;">
@ -478,7 +494,14 @@
loadStatus: 'more',
type: '',
shopId: '',
shopItem: {},
shopItem: {
shopIcon:'',
shopName:'',
shopScore:'',
shopTypeTitle:'',
saleCount:'',
remark:'',
},
productId: '',
productItem: [],
tuanzhangOrder:{},
@ -501,8 +524,6 @@
lastScrollTop: 0,
// onPageScroll
isSwitching: false,
//
isContainerSticky: false,
containerOriginalTop: 0,
scrollIntoViewId: '',
goodsListScrollTop: 0,
@ -527,9 +548,10 @@
onlineWorkerDuration:500,
menuList: [{
categoryName: '猜你喜欢',
id: '',
id: '1',
checked: true
}]
}],
shopRecommend:[]
}
},
components: {
@ -597,6 +619,11 @@
} catch(e) {
this.shopItem = JSON.parse(option.item);
}
this.shopRecommend = this.shopItem.products
for(let i=0;i<this.shopRecommend.length;i++){
this.shopRecommend[i].categoryId = '1'
this.shopRecommend[i].isChecked = false
}
} else {
try {
this.productItem = JSON.parse(decodeURIComponent(option.item));
@ -629,9 +656,7 @@
this.lastScrollTop = e.scrollTop;
// container
const stickyThreshold = this.containerOriginalTop - this.navBarHeight;
if (e.scrollTop >= stickyThreshold && !this.isContainerSticky) {
this.isContainerSticky = true;
}
},
methods: {
// touchmovegoods-list
@ -642,18 +667,13 @@
onGoodsListScroll(e) {
if (this.isAutoScrolling) return;
const scrollTop = e.detail.scrollTop;
//
if (scrollTop <= 0 && this.isContainerSticky) {
this.isContainerSticky = false;
return;
}
//
this.detectCurrentCategory();
},
onGoodsListScrollToTop() {
if (this.isAutoScrolling) return;
//
this.isContainerSticky = false;
},
//
detectCurrentCategory() {
@ -712,6 +732,7 @@
that.loadStatus = 'nomore';
if (res.code == 200) {
that.productItem = res.result.records;
that.productItem = [...that.shopRecommend, ...that.productItem];
for(let i = 0;i<that.productItem.length;i++){
if(that.productItem[i].isMoreBuy == 1){
//
@ -767,10 +788,7 @@
this.goodsListScrollTop = 0;
});
} else {
//
if (!this.isContainerSticky) {
this.isContainerSticky = true;
}
// scroll-into-view
const targetId = 'category-' + selectedCategory.id;
// id
@ -814,7 +832,7 @@
}
}
} catch (e) {
console.error("Failed to parse specifications", e);
console.log(e);
}
}
this.isPintuan = true;
@ -915,7 +933,7 @@
}
}
} catch (e) {
console.error("Failed to parse specifications", e);
console.log(e);
}
}
@ -1026,8 +1044,6 @@
groupId: this.groupId,
isFaceToFace: this.groupId ? this.isFaceToFaceGroup : (isFaceToFace || false)
};
// Directly navigate to checkout
console.log("111",this.currentItem)
uni.navigateTo({
url: '/package1/buyFood/buyFood?item=' + encodeURIComponent(JSON.stringify(goData)) +
'&shopItem=' + encodeURIComponent(JSON.stringify(this.shopItem)) + '&packageFee=' +
@ -1234,11 +1250,16 @@
}
return name;
},
changeValue(value) {
changeValue(type) {
if(type == 'plus'){
this.vModelValue += 1
}else{
this.vModelValue = this.vModelValue > 0 ?this.vModelValue -= 1:0
}
let moreBuyPrice = 0
for(let i = 0;i<this.moreBuyList.length;i++){
if(this.moreBuyList[i].id == this.checkMoreBuyIndex){
this.moreBuyList[i].quantity = value
this.moreBuyList[i].quantity = this.vModelValue
}
if(this.moreBuyList[i].quantity > 0){
moreBuyPrice += Number((Number(this.moreBuyList[i].quantity) * Number(this.sliceMsg2(this.moreBuyList[i].attributeListPrice))).toFixed(2))
@ -1247,7 +1268,7 @@
this.selectedGroupRule.groupPriceAndMore = Number(this.selectedGroupRule.groupPrice) + moreBuyPrice
for(let i = 0;i<this.moreBuyData.length;i++){
if(this.moreBuyData[i].id == this.checkMoreBuyIndex){
this.moreBuyData[i].quantity = value
this.moreBuyData[i].quantity = this.vModelValue
}
}
this.$forceUpdate()
@ -1336,6 +1357,7 @@
height: 100%;
font-size: 24rpx;
position: relative;
overflow: hidden;
}
/* 顶部背景图随页面滚动(不固定) */
@ -1568,7 +1590,7 @@
left: 0;
width: 100%;
z-index: 50;
height: calc(100vh - 80px);
height: calc(100vh - 160rpx);
background: #F5F8F5;
padding: 0 2.5%;
box-sizing: border-box;
@ -1719,7 +1741,8 @@
.car-content {
position: relative;
height: 1200rpx;
height: auto;
max-height: 1200rpx;
width: 100%;
border-top-left-radius: 20rpx;
border-top-right-radius: 20rpx;
@ -1837,9 +1860,10 @@
border-radius: 20rpx;
font-size: 26rpx;
text-align: center;
line-height: 60rpx;
line-height: 40rpx;
float: left;
margin-right: 40rpx;
font-weight: 700;
}
.team-check {
@ -1849,9 +1873,10 @@
border-radius: 20rpx;
font-size: 26rpx;
text-align: center;
line-height: 60rpx;
line-height: 40rpx;
float: left;
margin-right: 40rpx;
position: relative;
}
.zaixian-swiper{
flex: 1;
@ -1867,8 +1892,8 @@
}
.team11 {
height: 26rpx;
margin-top: 20rpx;
height: 35rpx;
margin-top: 18rpx;
}
.goods-team {
@ -1882,7 +1907,19 @@
padding: 30rpx 0 30rpx 30rpx;
flex: 1;
}
.jiaobiao{
position: absolute;
top: -16rpx;
right: -12rpx;
width: 40rpx;
height: 40rpx;
border-radius: 40rpx;
background: red;
color: #fff;
text-align: center;
line-height: 40rpx;
font-size: 20rpx;
}
.list-right-img {
height: 80rpx;
display: flex;

4
package1/group/shopEvaluate.vue

@ -26,7 +26,7 @@
<view class="menu1" @tap="checkTab(index)" v-for="(item,index) in menuList" :key="index"
:style="{'font-size':item.checked?'40rpx':'30rpx','color':item.checked?'rgba(0, 35, 28, 1)':'#777','width':index == 0?'160rpx':'180rpx'}">
<view :style="{'width':index == 0?'160rpx':'180rpx'}" style="text-align: left;">
{{item.name}}({{item.num}})
{{item.name}} {{item.num}}
</view>
<img v-if="item.checked" class="checked-img"
src="https://jewel-shop.oss-cn-beijing.aliyuncs.com/4bb5fc7725cb4a7a84d1d3a15f05b39c.png"
@ -110,7 +110,7 @@
},
menuList: [{
name: '全部',
num: 0,
num: "",
checked: true
}, {
name: '有图/视频',

2
package1/myCenter/partTimeJobRegister.vue

@ -21,7 +21,7 @@
<view class="box1">
<view class="reg-name">
* 学生证上传 <text style="font-size: 28rpx;font-weight: 400;color: #777;">身份信息仅用于认证身份平台会严格保密</text>
* 学生证上传 <text style="font-weight: 400;color: #777;">身份信息仅用于认证身份平台会严格保密</text>
</view>
<view class="reg-value">
<img @tap="pictureAdd('mentou')"

Loading…
Cancel
Save