Browse Source

上传

master
前端-胡立永 8 months ago
parent
commit
2240290507
4 changed files with 58 additions and 20 deletions
  1. +7
    -1
      components/userShop/userShopCommission.vue
  2. +6
    -5
      pages/index/center.vue
  3. +23
    -8
      pages/index/index.vue
  4. +22
    -6
      pages_order/components/product/submit.vue

+ 7
- 1
components/userShop/userShopCommission.vue View File

@ -6,7 +6,7 @@
总佣金
</view>
<view class="num">
7890.34
{{ userInfo.wallet.shopBalance }}
</view>
</view>
@ -26,6 +26,9 @@
</template>
<script>
import {
mapState,
} from 'vuex'
export default {
name: "userShopCommission",
props : {
@ -33,6 +36,9 @@
default : false,
},
},
computed: {
...mapState(['userInfo']),
},
data() {
return {
list : [


+ 6
- 5
pages/index/center.vue View File

@ -34,12 +34,12 @@
我的用户
</view>
<view class="list">
<view class="item" v-for="(item, index) in 20" :key="index">
<view class="item" v-for="(item, index) in userList" :key="index">
<view class="name">
客户王生
客户{{ item.name }}
</view>
<view class="num">
剩余水洗布198
剩余水洗布{{ item.num }}
</view>
</view>
</view>
@ -165,7 +165,7 @@
},
//
onReachBottom() {
if(this.queryParams.pageSize < this.productList.total){
if(this.queryParams.pageSize < this.total){
this.queryParams.pageSize += 10
//
if(this.userShop){
@ -190,7 +190,8 @@
this.$api('getMyUserPage', this.queryParams, res => {
uni.stopPullDownRefresh()
if(res.code == 200){
this.userList = res.result
this.userList = res.result.records
this.total = res.result.total
console.log("===getUserPage==");
}
})


+ 23
- 8
pages/index/index.vue View File

@ -41,14 +41,14 @@
v-if="userShop">
<view class="list">
<view class="item"
v-for="(item, index) in userList"
v-for="(item, index) in statisticsKey"
:key="index">
<view class="">
<view class="">
我的客户
{{ item.title }}
</view>
<view class="num">
{{ 30 }}
{{ statistics[item.key] || 0 }}
</view>
</view>
<view class="">
@ -141,10 +141,25 @@
records : [],
total : 0,
},
userList:{
records : [],
total : 0,
}
statistics : {},
statisticsKey : [
{
key : 'user',
title : '我的客户',
},
{
key : 'wash',
title : '水洗订单',
},
{
key : 'refund',
title : '退货订单',
},
{
key : 'worn',
title : '破损换货',
},
]
}
},
onShow() {
@ -215,7 +230,7 @@
this.$api('laundryStoreHomeData', this.queryParams, res => {
uni.stopPullDownRefresh()
if(res.code == 200){
this.userList = res.result
this.statistics = res.result
console.log("===getUserPage==");
}
})


+ 22
- 6
pages_order/components/product/submit.vue View File

@ -2,12 +2,15 @@
<view class="submit">
<view class=""
@click="$emit('share')">
<uv-icon
size="40rpx"
name="share-square"></uv-icon>
<view class="">
分享
</view>
<button open-type="share"
class="share">
<uv-icon
size="40rpx"
name="share-square"></uv-icon>
<view class="">
分享
</view>
</button>
</view>
<view class=""
@click="$utils.navigateTo('/index/cart')">
@ -73,5 +76,18 @@
align-items: center;
flex-direction: column;
}
.share{
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
font-size: 24rpx;
margin: 0;
padding: 0;
background-color: #fff;
&::after{
border: none;
}
}
}
</style>

Loading…
Cancel
Save