From e6a02c8b09a796e436a501e9b87d19e25c34c9d1 Mon Sep 17 00:00:00 2001
From: zjj <3272660260@qq.com>
Date: 星期日, 07 四月 2024 15:53:37 +0800
Subject: [PATCH] #
---
pages/business/saleManage/saleManage.vue | 34 +++++++++++++++++++++++++++++-----
1 files changed, 29 insertions(+), 5 deletions(-)
diff --git a/pages/business/saleManage/saleManage.vue b/pages/business/saleManage/saleManage.vue
index e90d2aa..d821256 100644
--- a/pages/business/saleManage/saleManage.vue
+++ b/pages/business/saleManage/saleManage.vue
@@ -17,7 +17,7 @@
</uni-nav-bar>
<!-- 鎼滅储妗� -->
<view class="search-bg">
- <uni-search-bar placeholder="瀹㈡埛浠e彿/鍚嶇О" bgColor="#f4f4f4" @confirm="search" />
+ <u-search placeholder="杈撳叆" v-model="keyword" :clearabled="true" @custom="search()" @search="search()"></u-search>
</view>
<view>
<!-- 瀹㈡埛鍒楄〃 -->
@@ -76,7 +76,7 @@
</view>
<!-- <uni-load-more :status="status" :icon-size="16" :content-text="contentText" /> -->
<u-empty v-if="true" icon="../../../static/image/emptyList.png" v-show="csmtrList.length <= 0" />
-
+ <view style="height: 10rpx;"></view>
<view class="fxbtn">
<uni-icons type="plusempty" color="#fff" @click="add()" ></uni-icons>
</view>
@@ -88,6 +88,7 @@
export default {
data() {
return {
+ keyword: '',
user: {
username: '',
id: 0,
@@ -147,10 +148,19 @@
getCsmtr1(e) {
let that = this
that.csmtrList = []
+ uni.showLoading({})
+ let param = {curr:1,limit:4,dept_id: 0,user_id: 67}
+ if (this.user.type == 'user_id') {
+ param = {curr:1,limit:4,user_id: that.user.id}
+ } else if(this.user.type == 'dept_id') {
+ param = {curr:1,limit:4,dept_id: that.user.id}
+ } else {
+ param = {curr:1,limit:4}
+ }
uni.request({
url: that.baseUrl + '/order/page/auth',
header: {'token' : uni.getStorageSync('token'),},
- data: {curr:1,limit:4},
+ data: param,
method:'GET',
success(result) {
if (result.statusCode === 404) {
@@ -158,7 +168,6 @@
return
}
var res = result.data
- console.log(res);
if (res.code === 200) {
let list = res.data.records
that.csmtrList = that.reload ? list : that.csmtrList.concat(list);
@@ -184,14 +193,26 @@
});
}, 1000);
},
+ complete() {
+ uni.hideLoading()
+ }
})
},
getCsmtr() {
let that = this
+ uni.showLoading({})
+ let param = {curr:that.curr,limit:4,dept_id: 0,user_id: 67}
+ if (this.user.type == 'user_id') {
+ param = {curr:that.curr,limit:4,user_id: that.user.id}
+ } else if(this.user.type == 'dept_id') {
+ param = {curr:that.curr,limit:4,dept_id: that.user.id}
+ } else {
+ param = {curr:that.curr,limit:4}
+ }
uni.request({
url: that.baseUrl + '/order/page/auth',
header: {'token' : uni.getStorageSync('token'),},
- data: {curr:that.curr,limit:4},
+ data: param,
method:'GET',
success(result) {
if (result.statusCode === 404) {
@@ -225,6 +246,9 @@
});
}, 1000);
},
+ complete() {
+ uni.hideLoading()
+ }
})
},
getDetails(id) {
--
Gitblit v1.9.1