|
@@ -6,7 +6,7 @@
|
|
|
<view class="tab-bar">
|
|
|
<view class="tab_item" v-for="(tab, index) in tabList" :key="index"
|
|
|
:class="{'active':tabActive==index}" @click="checkIndex(index)">
|
|
|
- <text class="text">{{tab.title}}{{index===0 && tabList[0].leng>0?"("+tabList[0].leng+")":""}}</text>
|
|
|
+ <text class="text">{{tab.title}}{{tabActive===0 && index==0 && orderList.length>0?"("+orderList.length+")":""}}</text>
|
|
|
</view>
|
|
|
</view>
|
|
|
<view class="search-bar">
|
|
@@ -216,7 +216,7 @@ const emitSelect = (v)=>{
|
|
|
// 查在ids中查找v,如果存在就删除,如果不存在就添加
|
|
|
const index = ids.value.findIndex(x=>x==v)
|
|
|
if (index>-1){
|
|
|
- ids.splice(index, 1)
|
|
|
+ ids.value.splice(index, 1)
|
|
|
} else {
|
|
|
ids.value.push(v)
|
|
|
}
|
|
@@ -290,25 +290,21 @@ const handleRefresh = async()=>{
|
|
|
}
|
|
|
console.log('handleRefresh >params>>666',params)
|
|
|
const {data:res} = await releaseOrder(params)
|
|
|
+
|
|
|
if (res.code === 200) {
|
|
|
- const paramss = {
|
|
|
- token: uni.getStorageSync('token'),
|
|
|
- data:JSON.stringify({
|
|
|
- currentUserId: parseInt(uni.getStorageSync('userId')),
|
|
|
- page: page.value,
|
|
|
- pageSize: pageSize.value,
|
|
|
- status: tabList.value[tabActive.value].status
|
|
|
+ if(ids.value.length>0){
|
|
|
+ console.log('ids.value',ids.value)
|
|
|
+ ids.value.forEach(x=>{
|
|
|
+ console.log('orderList',orderList.value)
|
|
|
+ const index = orderList.value.findIndex(y=>y.id == x)
|
|
|
+ console.log('orderList index',index)
|
|
|
+ if(index>-1){
|
|
|
+ console.log('orderList',orderList.value)
|
|
|
+ orderList.value.splice(index,1)
|
|
|
+ console.log('orderList',orderList.value)
|
|
|
+ }
|
|
|
})
|
|
|
}
|
|
|
-
|
|
|
- const {data:res} = await receiveOrderList(paramss)
|
|
|
- if (res.code === 200) {
|
|
|
- total.value = res.total
|
|
|
- orderList.value = res.rows
|
|
|
- if(tabActive.value ==0){
|
|
|
- tabList.value[0].leng = orderList.value.length
|
|
|
- }
|
|
|
- }
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -647,6 +643,10 @@ const loadPreList = async()=>{
|
|
|
}
|
|
|
.search{
|
|
|
width: 187.5rpx;
|
|
|
+ height: 40rpx;
|
|
|
+ :deep(.easyinput__content-input){
|
|
|
+ height: 40rpx!important;
|
|
|
+ }
|
|
|
:deep(.uni-easyinput__placeholder-class){
|
|
|
font-size: 15rpx;
|
|
|
}
|