Explorar o código

feat:询价、核价、仓库模块mock接口

zhangxin hai 2 meses
pai
achega
f5e98bfde0

+ 41 - 6
components/custom-tab-select/index.vue

@@ -39,7 +39,11 @@ export default {
39 39
       type: String,
40 40
       default: "single",
41 41
       validator: (value) => ["single", "multiple"].includes(value)
42
-    }
42
+    },
43
+    echoInfo: {
44
+      type: [String, Number, Array],
45
+      default: ""
46
+    },
43 47
   },
44 48
   computed: {
45 49
     isMultiple() {
@@ -47,18 +51,49 @@ export default {
47 51
     }
48 52
   },
49 53
   data() {
54
+    // 优先使用 echoInfo,如果 echoInfo 不为空则使用它,否则使用 defaultActive
55
+    const initialValue = this.echoInfo || this.defaultActive;
50 56
     return {
51
-      activeValue: this.defaultActive,
52
-      activeValues: Array.isArray(this.defaultActive) ? this.defaultActive : []
57
+      activeValue: this.isMultiple ? '' : initialValue,
58
+      activeValues: this.isMultiple ? (Array.isArray(initialValue) ? initialValue : []) : []
53 59
     };
54 60
   },
55 61
   watch: {
56 62
     defaultActive: {
57 63
       handler(val) {
58
-        if (this.isMultiple) {
59
-          this.activeValues = Array.isArray(val) ? val : [];
64
+        // 只有当 echoInfo 为空时,才使用 defaultActive
65
+        if (!this.echoInfo) {
66
+          if (this.isMultiple) {
67
+            this.activeValues = Array.isArray(val) ? val : [];
68
+          } else {
69
+            this.activeValue = val;
70
+          }
71
+        }
72
+      },
73
+      immediate: true
74
+    },
75
+    echoInfo: {
76
+      handler(val) {
77
+        if (val !== undefined && val !== null) {
78
+          if (this.isMultiple) {
79
+            this.activeValues = Array.isArray(val) ? val : [];
80
+          } else {
81
+            this.activeValue = val;
82
+          }
83
+        }
84
+      },
85
+      immediate: true
86
+    },
87
+    mode: {
88
+      handler(newMode) {
89
+        // 当 mode 变化时,重新初始化选中值
90
+        const initialValue = this.echoInfo || this.defaultActive;
91
+        if (newMode === 'multiple') {
92
+          this.activeValues = Array.isArray(initialValue) ? initialValue : [];
93
+          this.activeValue = '';
60 94
         } else {
61
-          this.activeValue = val;
95
+          this.activeValue = initialValue;
96
+          this.activeValues = [];
62 97
         }
63 98
       },
64 99
       immediate: true

+ 8 - 0
components/form-select-to-page/index.scss

@@ -6,4 +6,12 @@
6 6
     font-size: 28rpx;
7 7
     font-weight: 600;
8 8
     gap: 14rpx;
9
+    &.bottom{
10
+        padding-bottom: 10rpx;
11
+        border-bottom: 2rpx solid #dadbde;
12
+    }
13
+    .none{
14
+        padding-bottom: 0rpx;
15
+        border-bottom: none;
16
+    }
9 17
 }

+ 12 - 2
components/form-select-to-page/index.vue

@@ -1,7 +1,9 @@
1 1
 <template>
2
-    <view class="form_select_to_page" @click="handleClickToPage">
2
+    <view :class="['form_select_to_page', borderType]" @click="handleClickToPage">
3 3
         <view>{{ val }}</view>
4
-        <!-- <u-icon size="13" name="close-circle" @click="clear" v-if="val"></u-icon> -->
4
+        <view @click.stop="clear" v-if="val && isDelete">
5
+            <u-icon size="13" name="close-circle"></u-icon>
6
+        </view>
5 7
         <u-icon size="20" name="arrow-right"></u-icon>
6 8
     </view>
7 9
 </template>
@@ -17,6 +19,14 @@ export default {
17 19
         url: {
18 20
             type: String,
19 21
             default: '',
22
+        },
23
+        isDelete: {
24
+            type: Boolean,
25
+            default: false,
26
+        },
27
+        borderType: {   
28
+            type: String,
29
+            default: 'none',//none,bottom
20 30
         }
21 31
     },
22 32
     emits: ['handleClear'],

+ 6 - 0
components/imgs-row-scroll/index.scss

@@ -1,4 +1,7 @@
1 1
 .imgs-row-scroll {
2
+	::v-deep .uni-scroll-view {
3
+		height: 100% !important;
4
+	}
2 5
 	.img-list {
3 6
 		display: flex;
4 7
 		align-items: center;
@@ -30,6 +33,9 @@
30 33
 		align-items: center;
31 34
 		justify-content: center;
32 35
 		z-index: 10;
36
+		::v-deep .u-icon{
37
+			background-color: transparent !important;
38
+		}
33 39
 	}
34 40
 	// 使用indicator隐藏滚动条会报错,暂时使用样式隐藏
35 41
 	::v-deep .u-scroll-list__indicator{

+ 26 - 26
components/inquiry-verification-list/index.vue

@@ -1,35 +1,35 @@
1 1
 <template>
2 2
     <view class="inquiry_wrap">
3
-        <u-navbar class="nav-bar" :title="type == '1' ? '询价中心' : '核价中心'" :autoBack="true" :placeholder="true" v-hideNav></u-navbar>
4
-        <scroll-view class="list" scroll-y @scrolltolower="getList" enable-back-to-top>
5
-            <transition-group name="order-move" tag="div">
6
-                <view class="list_item" v-for="(item, index) in list" :key="index" @click="handleClick(item)">
7
-                    <view class="list_item_top">
8
-                        <view class="top_left">
9
-                            <text class="name">{{ item.dictLabel }}</text>
10
-                            <text class="desc">{{ type == '1' ? '意向' : item.model }}</text>
11
-                        </view>
12
-                        <view class="top_right">
13
-                            <text :class="['status', type == '1' ? 'inquiry' : 'verification']">{{
14
-                                formtterStatus(item.status) }}</text>
15
-                        </view>
3
+        <u-navbar class="nav-bar" :title="type == '1' ? '询价中心' : '核价中心'" :autoBack="true" :placeholder="true"
4
+            v-hideNav></u-navbar>
5
+        <scroll-view class="list_wrap" scroll-y @scrolltolower="loadMore" enable-back-to-top>
6
+            <view class="list_item" v-for="(item, index) in list" :key="index" @click="handleClick(item)">
7
+                <view class="list_item_top">
8
+                    <view class="top_left">
9
+                        <text class="name">{{ item.dictLabel }}</text>
10
+                        <text class="desc">{{ type == '1' ? '意向' : item.model }}</text>
16 11
                     </view>
17
-                    <view class="imgs">
18
-                        <imgs-row-scroll :images="item.imgsUrl" :previewEnabled="true" :showIndicator="false"
19
-                            :imageWidth="140" :imageHeight="140"></imgs-row-scroll>
12
+                    <view class="top_right">
13
+                        <text :class="['status', type == '1' ? 'inquiry' : 'verification']">{{
14
+                            formtterStatus(item.status) }}</text>
20 15
                     </view>
21
-                    <view class="list_item_bottom">
22
-                        <view class="bottom">
23
-                            <u-icon name="bookmark" size="16" color="#9ca3af"></u-icon>
24
-                            <text class="code">编码:{{ item.code }}</text>
25
-                        </view>
26
-                        <view class="bottom">
27
-                            <u-icon name="clock" size="16" color="#9ca3af"></u-icon>
28
-                            <text class="time">{{ item.date }}</text>
29
-                        </view>
16
+                </view>
17
+                <view class="imgs">
18
+                    <imgs-row-scroll :images="item.imgsUrl" :previewEnabled="true" :showIndicator="false"
19
+                        :imageWidth="140" :imageHeight="140"></imgs-row-scroll>
20
+                </view>
21
+                <view class="list_item_bottom">
22
+                    <view class="bottom">
23
+                        <u-icon name="bookmark" size="16" color="#9ca3af"></u-icon>
24
+                        <text class="code">编码:{{ item.code }}</text>
25
+                    </view>
26
+                    <view class="bottom">
27
+                        <u-icon name="clock" size="16" color="#9ca3af"></u-icon>
28
+                        <text class="time">{{ item.date }}</text>
30 29
                     </view>
31 30
                 </view>
32
-            </transition-group>
31
+            </view>
32
+            <show-emtry v-if="list.length === 0"></show-emtry>
33 33
         </scroll-view>
34 34
 
35 35
         <add-inquiry-dialog ref="addInquiryDialog" editOrAdd="edit" :editInfo="editInfo" @success="handleInquirySuccess"

+ 16 - 117
components/inquiry-verification-list/mixins/inquiryVerificationList.js

@@ -7,103 +7,11 @@ export default {
7 7
     },
8 8
     data() {
9 9
         return {
10
-            list: [
11
-        {
12
-          clueId:'',//线索公海id
13
-          id:'',//询价id
14
-          dictValue:'2',//品牌id
15
-          dictLabel:'Rolex',//品牌名称
16
-          model:'Submariner Date 126610LN',//型号
17
-          code:'123',//编码
18
-          price:'12345',//询价价格
19
-          desc:'意向',
20
-          date:'2026-2-1 10:00:00',//询价日期
21
-          status:'1',//询价列表:1-待询价 2-询价完成;   核价列表:1-待核价 2-核价完成
22
-          imgsUrl:['https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg','https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg']//询价图片数组
23
-        },
24
-        {
25
-          clueId:'',//线索公海id
26
-          id:'',//询价id
27
-          dictValue:'2',//品牌id
28
-          dictLabel:'Rolex',//品牌名称
29
-          model:'Submariner Date 126610LN',//型号
30
-          code:'123',//编码
31
-          price:'12345',//询价价格
32
-          desc:'意向',
33
-          date:'2026-2-1 10:00:00',//询价日期
34
-          status:'1',//询价列表:1-待询价 2-询价完成;   核价列表:1-待核价 2-核价完成
35
-          imgsUrl:['https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg','https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg']//询价图片数组
36
-        },
37
-        {
38
-          clueId:'',//线索公海id
39
-          id:'',//询价id
40
-          dictValue:'2',//品牌id
41
-          dictLabel:'Rolex',//品牌名称
42
-          model:'Submariner Date 126610LN',//型号
43
-          code:'123',//编码
44
-          price:'12345',//询价价格
45
-          desc:'意向',
46
-          date:'2026-2-1 10:00:00',//询价日期
47
-          status:'1',//询价列表:1-待询价 2-询价完成;   核价列表:1-待核价 2-核价完成
48
-          imgsUrl:['https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg','https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg']//询价图片数组
49
-        },
50
-        {
51
-          clueId:'',//线索公海id
52
-          id:'',//询价id
53
-          dictValue:'2',//品牌id
54
-          dictLabel:'Rolex',//品牌名称
55
-          model:'Submariner Date 126610LN',//型号
56
-          code:'123',//编码
57
-          price:'12345',//询价价格
58
-          desc:'意向',
59
-          date:'2026-2-1 10:00:00',//询价日期
60
-          status:'1',//询价列表:1-待询价 2-询价完成;   核价列表:1-待核价 2-核价完成
61
-          imgsUrl:['https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg','https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg']//询价图片数组
62
-        },
63
-        {
64
-          clueId:'',//线索公海id
65
-          id:'',//询价id
66
-          dictValue:'2',//品牌id
67
-          dictLabel:'Rolex',//品牌名称
68
-          model:'Submariner Date 126610LN',//型号
69
-          code:'123',//编码
70
-          price:'12345',//询价价格
71
-          desc:'意向',
72
-          date:'2026-2-1 10:00:00',//询价日期
73
-          status:'1',//询价列表:1-待询价 2-询价完成;   核价列表:1-待核价 2-核价完成
74
-          imgsUrl:['https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg','https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg']//询价图片数组
75
-        },
76
-        {
77
-          clueId:'',//线索公海id
78
-          id:'',//询价id
79
-          dictValue:'2',//品牌id
80
-          dictLabel:'Rolex',//品牌名称
81
-          model:'Submariner Date 126610LN',//型号
82
-          code:'123',//编码
83
-          price:'12345',//询价价格
84
-          desc:'意向',
85
-          date:'2026-2-1 10:00:00',//询价日期
86
-          status:'1',//询价列表:1-待询价 2-询价完成;   核价列表:1-待核价 2-核价完成
87
-          imgsUrl:['https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg','https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg']//询价图片数组
88
-        },
89
-        {
90
-          clueId:'',//线索公海id
91
-          id:'',//询价id
92
-          dictValue:'2',//品牌id
93
-          dictLabel:'Rolex',//品牌名称
94
-          model:'Submariner Date 126610LN',//型号
95
-          code:'123',//编码
96
-          price:'12345',//询价价格
97
-          desc:'意向',
98
-          date:'2026-2-1 10:00:00',//询价日期
99
-          status:'1',//询价列表:1-待询价 2-询价完成;   核价列表:1-待核价 2-核价完成
100
-          imgsUrl:['https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg','https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg']//询价图片数组
101
-        },
102
-      ],
10
+            list: [],
103 11
             editInfo: {},
104 12
             queryParams: {
105 13
                 pageSize: 10,
106
-                pageNum: 0,
14
+                pageNum: 1,
107 15
             },
108 16
             total: 0,
109 17
         }
@@ -112,38 +20,28 @@ export default {
112 20
         this.getList();
113 21
     },
114 22
     methods: {
115
-        getList(){
116
-            if (this.list.length > 0 && this.list.length >= this.total) {
117
-                uni.$u.toast('暂无更多数据');
118
-                return;
119
-            }
120
-            
121
-            if (this.queryParams.pageNum === 0) {
122
-                this.queryParams.pageNum = 1;
123
-                this.list = [];
124
-            } else {
125
-                this.queryParams.pageNum++;
126
-            }
127
-            
128
-            uni.$u.api.inquiryVerificationList(this.queryParams,{
23
+        getList() {
24
+            uni.$u.api.inquiryVerificationList(this.queryParams, {
129 25
                 type: this.type,
130 26
             }).then(res => {
131
-                this.total = res.total;
132
-                
133
-                if(this.total === 0){
134
-                    uni.$u.toast('暂无数据');
135
-                    return;
136
-                }
137
-                
138 27
                 if (this.queryParams.pageNum === 1) {
139 28
                     this.list = res.rows;
140 29
                 } else {
141 30
                     this.list = this.list.concat(res.rows);
142 31
                 }
32
+                this.total = res.total;
143 33
             })
144 34
         },
145
-        formtterStatus(status){
146
-            switch(status){
35
+        loadMore(){
36
+            if (this.list.length >= this.total) {
37
+                uni.$u.toast('没有更多了');
38
+                return;
39
+            }
40
+            this.queryParams.pageNum++;
41
+            this.getList();
42
+        },
43
+        formtterStatus(status) {
44
+            switch (status) {
147 45
                 case '1':
148 46
                     return this.type == '1' ? '待询价' : '待核价';
149 47
                 case '2':
@@ -158,6 +56,7 @@ export default {
158 56
             this.$refs.addInquiryDialog.closeDialog();
159 57
         },
160 58
         handleInquiryCancel() {
59
+            this.queryParams.pageNum = 1;
161 60
             this.getList();
162 61
             this.$refs.addInquiryDialog.closeDialog();
163 62
         },

+ 74 - 75
components/inquiry-verification-list/styles/index.scss

@@ -1,98 +1,97 @@
1 1
 .inquiry_wrap {
2 2
     background-color: #f9fafb;
3
-    height: 100vh;
3
+    // height: 100vh;
4 4
     display: flex;
5 5
     flex-direction: column;
6 6
     box-sizing: border-box;
7 7
 
8
-    .list {
8
+    .list_wrap {
9 9
         flex: 1;
10
-        height: calc(100vh - 100rpx);
10
+
11 11
         ::v-deep .uni-scroll-view {
12
-            height:100%;
13
-            .list_item {
14
-                margin: 0 20rpx;
15
-                padding: 30rpx;
16
-                background-color: #fff;
17
-                border-radius: 20rpx;
18
-                margin-bottom: 20rpx;
19
-                box-shadow: 2px 2px 11px 1px #e7e7e7;
20
-
21
-                .list_item_top {
12
+            height: calc(100vh - 250rpx);
13
+        }
14
+
15
+        .list_item {
16
+            margin: 0 20rpx;
17
+            padding: 30rpx;
18
+            background-color: #fff;
19
+            border-radius: 20rpx;
20
+            margin-bottom: 20rpx;
21
+            box-shadow: 2px 2px 11px 1px #e7e7e7;
22
+
23
+            .list_item_top {
24
+                display: flex;
25
+                justify-content: space-between;
26
+                align-items: flex-start;
27
+
28
+                .top_left {
22 29
                     display: flex;
23
-                    justify-content: space-between;
24
-                    align-items: flex-start;
25
-
26
-                    .top_left {
27
-                        display: flex;
28
-                        flex-direction: column;
29
-                        justify-content: flex-start;
30
-
31
-                        .name {
32
-                            font-size: 32rpx;
33
-                            font-weight: bold;
34
-                            color: #111827;
35
-                        }
36
-
37
-                        .desc {
38
-                            font-size: 26rpx;
39
-                            color: #9ca3af;
40
-                        }
41
-                    }
30
+                    flex-direction: column;
31
+                    justify-content: flex-start;
42 32
 
43
-                    .top_right {
44
-                        display: flex;
45
-                        flex-direction: column;
46
-                        justify-content: flex-end;
47
-
48
-                        .status {
49
-                            font-size: 24rpx;
50
-                            padding: 6rpx 12rpx;
51
-                            border-radius: 12rpx;
52
-                            border: 2rpx solid #2563eb;
53
-                            font-weight: 600;
54
-                        }
55
-
56
-                        .inquiry {
57
-                            color: #2563eb;
58
-                            background-color: #eff6ff;
59
-                            border-color: #dceafe;
60
-                        }
61
-
62
-                        .verification {
63
-                            color: #ed590e;
64
-                            background-color: #fff7ed;
65
-                            border-color: #fff2e2;
66
-                        }
33
+                    .name {
34
+                        font-size: 32rpx;
35
+                        font-weight: bold;
36
+                        color: #111827;
67 37
                     }
68 38
 
39
+                    .desc {
40
+                        font-size: 26rpx;
41
+                        color: #9ca3af;
42
+                    }
69 43
                 }
70 44
 
71
-                .imgs {
72
-                    margin: 20rpx 0;
45
+                .top_right {
46
+                    display: flex;
47
+                    flex-direction: column;
48
+                    justify-content: flex-end;
49
+
50
+                    .status {
51
+                        font-size: 24rpx;
52
+                        padding: 6rpx 12rpx;
53
+                        border-radius: 12rpx;
54
+                        border: 2rpx solid #2563eb;
55
+                        font-weight: 600;
56
+                    }
57
+
58
+                    .inquiry {
59
+                        color: #2563eb;
60
+                        background-color: #eff6ff;
61
+                        border-color: #dceafe;
62
+                    }
63
+
64
+                    .verification {
65
+                        color: #ed590e;
66
+                        background-color: #fff7ed;
67
+                        border-color: #fff2e2;
68
+                    }
73 69
                 }
74 70
 
75
-                .list_item_bottom {
71
+            }
72
+
73
+            .imgs {
74
+                margin: 20rpx 0;
75
+            }
76
+
77
+            .list_item_bottom {
78
+                display: flex;
79
+                justify-content: space-between;
80
+                align-items: center;
81
+                font-size: 26rpx;
82
+                color: #9ca3af;
83
+                font-weight: 550;
84
+
85
+                .bottom {
76 86
                     display: flex;
77
-                    justify-content: space-between;
78 87
                     align-items: center;
79
-                    font-size: 26rpx;
80
-                    color: #9ca3af;
81
-                    font-weight: 550;
82
-
83
-                    .bottom {
84
-                        display: flex;
85
-                        align-items: center;
86
-                        gap: 8rpx;
87
-                    }
88
-                }
89
-                &:nth-of-type(1){
90
-                    margin-top: 20rpx;
88
+                    gap: 8rpx;
91 89
                 }
92 90
             }
93
-            // .uni-scroll-view-content{
94
-            //     height: calc(100% - 70px);
95
-            // }
91
+
92
+            &:nth-of-type(1) {
93
+                margin-top: 20rpx;
94
+            }
96 95
         }
97 96
 
98 97
     }

+ 0 - 0
components/person-picker/index.scss


+ 74 - 0
components/person-picker/index.vue

@@ -0,0 +1,74 @@
1
+<template>
2
+  <view class="">
3
+    <u-picker :show="show" :title="title" :columns="columns" keyName="label" ref="uPicker"
4
+                @confirm="recyclePersonConfirm" @change="recyclePersonChange" @cancel='close'></u-picker>
5
+  </view>
6
+</template>
7
+
8
+<script>
9
+export default {
10
+  name: 'personPicker',
11
+  data() {
12
+    return {
13
+        show: false,
14
+        columns: [],
15
+    }
16
+  },
17
+  props: {
18
+    title: {
19
+      type: String,
20
+      default: '请选择',
21
+    },
22
+  },
23
+  emits: ['selectPerson'],
24
+  methods: {
25
+    open() {
26
+        this.show = true;
27
+        this.recyclePersonClick();
28
+    },
29
+    close() {
30
+        this.columns = [];
31
+        this.show = false;
32
+    },
33
+    recyclePersonConfirm({ columnIndex, value, values }) {
34
+        this.$emit('selectPerson', value[value.length -1]);
35
+        this.close();
36
+    },
37
+    recyclePersonChange(e) {
38
+        const {
39
+              columnIndex,
40
+              value,
41
+              values,
42
+              picker = this.$refs.uPicker
43
+          } = e
44
+          // 当前项不是用户,且有子级,添加下一层
45
+          if(!value[columnIndex].isUser){
46
+            picker.setColumnValues(columnIndex+1, value[columnIndex].children);
47
+          }else{
48
+            // 当前是用户且同等级的其他项有子级,则添加下一层空数据
49
+            values[columnIndex].forEach((item, index) => {
50
+              if(!item.isUser){
51
+                picker.setColumnValues(columnIndex+1, []);
52
+              }
53
+            })
54
+          }
55
+        },
56
+    recyclePersonClick() {
57
+        uni.$u.api.getCustomerManagerAllList().then(res => {
58
+            this.columns = [res.data] || [];
59
+            
60
+            // 如果第一层只有一个选项,自动处理下一层级
61
+            if (res.data && res.data.length === 1) {
62
+                // 如果当前项不是用户且有子级,添加下一层
63
+                if (!res.data[0].isUser && res.data[0].children && res.data[0].children.length > 0) {
64
+                    this.columns.push(res.data[0].children);
65
+                }
66
+            }
67
+        })
68
+    },
69
+  }
70
+}
71
+</script>
72
+
73
+<style lang="scss" scoped>
74
+</style>

+ 295 - 7
mock/mockData.js

@@ -260,28 +260,316 @@ const mockDataList = {
260 260
       pageNum: 1,
261 261
     },
262 262
     data:{
263
-      category:'1',//品类:1-全部 2-腕表 3-箱包 4-珠宝  5-鞋靴 6-配饰 7-服饰
264
-      sort:'date',// 排序方式:date-按最近更新排序
263
+      searchString:'',//搜索编号、名称、品牌...
264
+      category:1,//品类:1-全部 2-腕表 3-箱包 4-珠宝  5-鞋靴 6-配饰 7-服饰 8-其它
265
+      sortType:4,// 排序方式:1-按最久未下载 2-按最近更新 3-按最久更新 4-按入库最新 5-按入库最久 6-按价格最高 7-按价格最低
266
+      dictLabel:'Rolex',//品牌名称
265 267
       dictValue:'2',//品牌id
266 268
       priceMin:'1000',//价格范围:最小价格
267 269
       priceMax:'10000',//价格范围:最大价格
268 270
       location:'',//位置
269
-      date:'2026-02-01',//回收时间,比如2026-02-01
270
-      recyclePerson:'',//回收人员
271
-      identifyingPerson:'',//鉴定人员
272
-      productAttribute:'',//产品属性:1-自有商品 2-寄卖商品 3-质押商品 4-其它
271
+      recycleTime:'2026-01-09',//回收时间,比如2026-02-01
272
+      recyclePerson:'张三',//回收人员
273
+      recyclePersonId:'',//回收人员id
274
+      identifyingPerson:'李四',//鉴定人员
275
+      identifyingPersonId:'',//鉴定人员id
276
+      productAttribute:['1','2'],//产品属性 多选:1-自有商品 2-寄卖商品 3-质押商品 4-其它
273 277
     },
274 278
     url: '/prod-api/crm/warehouse/wareHouseList',
275 279
     delay: 300,
276 280
     response: {
277 281
       code: 200,
278 282
       msg: 'success',
283
+      rows:[
284
+        {
285
+          id:'123456754',//商品库存id
286
+          name:'Rolex',//商品名称
287
+          model:'Submariner Date 126610LN',//型号
288
+          costPrice:'12345',//成本价格
289
+          salesPrice:'12345',//销售价格
290
+          peerPrice:'12345',//同行价格
291
+          agentPrice:'12345',//代理价格
292
+          stock:'12345',//库存数量
293
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
294
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
295
+        
296
+        },
297
+        {
298
+          id:'',//商品库存id
299
+          name:'Rolex',//商品名称
300
+          model:'Submariner Date 126610LN',//型号
301
+          costPrice:'12345',//成本价格
302
+          salesPrice:'12345',//销售价格
303
+          peerPrice:'12345',//同行价格
304
+          agentPrice:'12345',//代理价格
305
+          stock:'12345',//库存数量
306
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
307
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
308
+        
309
+        },
310
+        {
311
+          id:'',//商品库存id
312
+          name:'Rolex',//商品名称
313
+          model:'Submariner Date 126610LN',//型号
314
+          costPrice:'12345',//成本价格
315
+          salesPrice:'12345',//销售价格
316
+          peerPrice:'12345',//同行价格
317
+          agentPrice:'12345',//代理价格
318
+          stock:'12345',//库存数量
319
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
320
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
321
+        
322
+        },
323
+        {
324
+          id:'',//商品库存id
325
+          name:'Rolex',//商品名称
326
+          model:'Submariner Date 126610LN',//型号
327
+          costPrice:'12345',//成本价格
328
+          salesPrice:'12345',//销售价格
329
+          peerPrice:'12345',//同行价格
330
+          agentPrice:'12345',//代理价格
331
+          stock:'12345',//库存数量
332
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
333
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
334
+        },
335
+        {
336
+          id:'',//商品库存id
337
+          name:'Rolex',//商品名称
338
+          model:'Submariner Date 126610LN',//型号
339
+          costPrice:'12345',//成本价格
340
+          salesPrice:'12345',//销售价格
341
+          peerPrice:'12345',//同行价格
342
+          agentPrice:'12345',//代理价格
343
+          stock:'12345',//库存数量
344
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
345
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
346
+        },
347
+        {
348
+          id:'',//商品库存id
349
+          name:'Rolex',//商品名称
350
+          model:'Submariner Date 126610LN',//型号
351
+          costPrice:'12345',//成本价格
352
+          salesPrice:'12345',//销售价格
353
+          peerPrice:'12345',//同行价格
354
+          agentPrice:'12345',//代理价格
355
+          stock:'12345',//库存数量
356
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
357
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
358
+        },
359
+        {
360
+          id:'',//商品库存id
361
+          name:'Rolex',//商品名称
362
+          model:'Submariner Date 126610LN',//型号
363
+          costPrice:'12345',//成本价格
364
+          salesPrice:'12345',//销售价格
365
+          peerPrice:'12345',//同行价格
366
+          agentPrice:'12345',//代理价格
367
+          stock:'12345',//库存数量
368
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
369
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
370
+        },
371
+        {
372
+          id:'',//商品库存id
373
+          name:'Rolex',//商品名称
374
+          model:'Submariner Date 126610LN',//型号
375
+          costPrice:'12345',//成本价格
376
+          salesPrice:'12345',//销售价格
377
+          peerPrice:'12345',//同行价格
378
+          agentPrice:'12345',//代理价格
379
+          stock:'12345',//库存数量
380
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
381
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
382
+        },
383
+        {
384
+          id:'',//商品库存id
385
+          name:'Rolex',//商品名称
386
+          model:'Submariner Date 126610LN',//型号
387
+          costPrice:'12345',//成本价格
388
+          salesPrice:'12345',//销售价格
389
+          peerPrice:'12345',//同行价格
390
+          agentPrice:'12345',//代理价格
391
+          stock:'12345',//库存数量
392
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
393
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
394
+        },
395
+        {
396
+          id:'',//商品库存id
397
+          name:'Rolex',//商品名称
398
+          model:'Submariner Date 126610LN',//型号
399
+          costPrice:'12345',//成本价格
400
+          salesPrice:'12345',//销售价格
401
+          peerPrice:'12345',//同行价格
402
+          agentPrice:'12345',//代理价格
403
+          stock:'12345',//库存数量
404
+          imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
405
+          platform:[]//同步平台,此功能暂时不做,先定义一个字段
406
+        }
407
+      ],
408
+      total: 20,//总条数
279 409
     }
280
-  }
410
+  },
411
+  // 仓库模块-详情
412
+  '/warehouse/wareHouseDetail': {
413
+    method: 'get',
414
+    params: {
415
+      id: '',
416
+      userId:'12345',//用户id
417
+    },
418
+    url: '/prod-api/crm/warehouse/wareHouseDetail',
419
+    delay: 300,
420
+    response: {
421
+      code: 200,
422
+      msg: 'success',
423
+      data: {
424
+        id:'12345',//商品库存id
425
+        imgsUrl:[{
426
+          url:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
427
+        },
428
+        {
429
+          url:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
430
+        }],//商品图片
431
+        dictLabel:'Rolex',//商品名称
432
+        dictValue:'12345',//商品名称id
433
+        model:'Submariner Date 126610LN',//型号
434
+        code:'12345',//独立编码
435
+        warehouseDate:'2026-01-06',//入库日期
436
+        payType:'1',//付款方式 1:微信 2:支付宝 3:银行卡 4:现金 5:数字货币 6:挂账
437
+        note:'单包 附件齐全 成色极好',//备注
438
+        originalCost:'12345',//原始成本
439
+        additionalCost:'12345',//附加成本
440
+        agentPrice:'12345',//代理价格
441
+        suggestedPrice:'12345',//建议价格
442
+        location:'上海',//商品位置
443
+        recyclePerson:'张三',//回收人员
444
+        recyclePersonId:'12345',//回收人员id
445
+        identifyingPerson:'张三',//鉴定人员
446
+        identifyingPersonId:'12345',//鉴定人员id
447
+        logTotal:12,//操作日志总数
448
+        lockStatus:'0',//锁单状态 0:未锁单 1:已锁单 
449
+        downStatus:'1',//下架状态 0:已下架 1:已上架
450
+      }
451
+    }
452
+  },
453
+  // 仓库模块-详情-操作日志-列表
454
+  '/warehouse/wareHouseLog': {
455
+    method: 'get',
456
+    params: {
457
+      id: '',//商品库存id
458
+      userId:'12345',//用户id
459
+    },
460
+    url: '/prod-api/crm/warehouse/wareHouseLog',
461
+    delay: 300,
462
+    response: {
463
+      code: 200,
464
+      msg: 'success',
465
+      data: [
466
+        {
467
+          id:1,//操作日志id
468
+          name:'张三',//操作人
469
+          createTime:'2026-01-06 12:00:00',//操作时间
470
+          operation:'修改名称为Rolex',//操作内容
471
+        },
472
+        {
473
+          id:2,//操作日志id
474
+          name:'张三',//操作人
475
+          createTime:'2026-01-06 12:00:00',//操作时间
476
+          operation:'修改型号为Submariner Date 126610LN',//操作内容
477
+        },
478
+        {
479
+          id:3,//操作日志id
480
+          name:'张三',//操作人
481
+          createTime:'2026-01-06 12:00:00',//操作时间
482
+          operation:'修改名称为Rolex',//操作内容
483
+        },
484
+        {
485
+          id:4,//操作日志id
486
+          name:'张三',//操作人
487
+          createTime:'2026-01-06 12:00:00',//操作时间
488
+          operation:'修改型号为Submariner Date 126610LN',//操作内容
489
+        },
490
+      ]
491
+    }
492
+  },
493
+  // 仓库模块-详情-编辑
494
+  '/warehouse/wareHouseUpdate': {
495
+    method: 'post',
496
+    data:{
497
+      id:'',//商品库存id
498
+      imgsUrl:[{
499
+        url:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
500
+      },
501
+      {
502
+        url:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
503
+      }],//商品图片
504
+      dictLabel:'Rolex',//商品名称
505
+      dictValue:'12345',//商品名称id
506
+      model:'Submariner Date 126610LN',//型号
507
+      code:'12345',//独立编码
508
+      warehouseDate:'2026-01-06',//入库日期
509
+      payType:'1',//付款方式 1:微信 2:支付宝 3:银行卡 4:现金 5:数字货币 6:挂账
510
+      note:'单包 附件齐全 成色极好',//备注
511
+      originalCost:'12345',//原始成本
512
+      additionalCost:'12345',//附加成本
513
+      agentPrice:'12345',//代理价格
514
+      suggestedPrice:'12345',//建议价格
515
+      location:'上海',//商品位置
516
+      recyclePerson:'张三',//回收人员
517
+      recyclePersonId:'12345',//回收人员id
518
+      identifyingPerson:'张三',//鉴定人员
519
+      identifyingPersonId:'12345',//鉴定人员id
520
+    },
521
+    url: '/prod-api/crm/warehouse/wareHouseUpdate',
522
+    delay: 300,
523
+    response: {
524
+      code: 200,
525
+      msg: 'success'
526
+    }
527
+  },
528
+  // 仓库模块-详情-锁单/解锁
529
+  '/warehouse/wareHouseLock': {
530
+    method: 'post',
531
+    data:{
532
+      id:'',//商品库存id
533
+      lockStatus:'1',//锁单状态 0:解锁 1:锁单
534
+    },
535
+    url: '/prod-api/crm/warehouse/wareHouseLock',
536
+    delay: 300,
537
+    response: {
538
+      code: 200,
539
+      msg: 'success'
540
+    }
541
+  },
542
+  // 仓库模块-详情-上架/下架
543
+  '/warehouse/wareHouseDown': {
544
+    method: 'post',
545
+    data:{
546
+      id:'',//商品库存id
547
+      downStatus:'1',//下架状态 0:下架 1:上架
548
+    },
549
+    url: '/prod-api/crm/warehouse/wareHouseDown',
550
+    delay: 300,
551
+    response: {
552
+      code: 200,
553
+      msg: 'success'
554
+    }
555
+  },
556
+  // 仓库模块-新增
557
+  '/warehouse/wareHouseAdd': {
558
+    method: 'post',
559
+    data:{
281 560
 
561
+    },
562
+    url: '/prod-api/crm/warehouse/wareHouseAdd',
563
+    delay: 300,
564
+    response: {
565
+      code: 200,
566
+      msg: 'success'
567
+    }
568
+  }
282 569
   
283 570
 
284 571
   
572
+
285 573
   
286 574
 };
287 575
 

+ 3 - 3
pages.json

@@ -166,7 +166,7 @@
166 166
 			}
167 167
 		},
168 168
 		{
169
-			"path": "pages/wareHouse/detail",
169
+			"path": "pages/wareHouse/components/detail",
170 170
 			"style": {
171 171
 				"navigationBarTitleText": "仓库详情",
172 172
 				"enablePullDownRefresh": true,
@@ -174,7 +174,7 @@
174 174
 			}
175 175
 		},
176 176
 		{
177
-			"path": "pages/wareHouse/add",
177
+			"path": "pages/wareHouse/components/add",
178 178
 			"style": {
179 179
 				"navigationBarTitleText": "仓库新增",
180 180
 				"enablePullDownRefresh": true,
@@ -182,7 +182,7 @@
182 182
 			}
183 183
 		},
184 184
 		{
185
-			"path" : "pages/wareHouse/openOrder",
185
+			"path" : "pages/wareHouse/components/openOrder",
186 186
 			"style": {
187 187
 				"navigationBarTitleText": "销售业务开单",
188 188
 				"enablePullDownRefresh": true,

+ 0 - 1
pages/inquiry/index.vue

@@ -19,7 +19,6 @@
19 19
 
20 20
 <style>
21 21
     .page-container {
22
-        height: 100vh;
23 22
         width: 100%;
24 23
         overflow: hidden;
25 24
     }

+ 0 - 1
pages/verification/index.vue

@@ -19,7 +19,6 @@
19 19
 
20 20
 <style>
21 21
     .page-container {
22
-        height: 100vh;
23 22
         width: 100%;
24 23
         overflow: hidden;
25 24
     }

+ 80 - 13
pages/wareHouse/add.vue

@@ -16,11 +16,14 @@
16 16
 实价:6500
17 17
 型号:L2.257.5.89.7
18 18
 编码:52356065
19
-日期:2021.11.09
19
+日期:2021-11-09
20 20
 备注:全套
21
-付款方式:线上' confirmType="done" height="170" :maxlength="-1" @blur='handleRecognition'>
21
+付款方式:微信/支付宝/银行卡/现金/数字货币/挂账' confirmType="done" height="170" :maxlength="-1">
22 22
                         </u--textarea>
23
-                        <u-button text="粘贴识别" @click="handleRecognition"></u-button>
23
+                        <view class="btn_group_recognition">
24
+                            <u-button text="清除" @click="clearRecognitionContent()"></u-button>
25
+                            <u-button text="粘贴识别" type="primary" @click="handlePasteRecognition(recognitionContent)"></u-button>
26
+                        </view>
24 27
                     </u-form-item>
25 28
                     <u-form-item label="商品图片" required prop="imgs" borderBottom>
26 29
                         <u-upload :fileList="goodPicFileList" @afterRead="afterReadGoodPic" @delete="deleteGoodPic"
@@ -119,7 +122,7 @@
119 122
                         </TabSelect>
120 123
                     </u-form-item>
121 124
                     <u-form-item label="回收人员" class="u-form-item-row" borderBottom>
122
-                        <u--input v-model="formData.recyclePerson" disabled clearable border="none"></u--input>
125
+                        <u--input v-model="formData.recyclePerson" disabledColor="#fff" disabled clearable border="none"></u--input>
123 126
                     </u-form-item>
124 127
                     <u-form-item label="回收留底图" borderBottom>
125 128
                         <view class="recycle_bottom_desc">
@@ -179,7 +182,7 @@
179 182
                         </view>
180 183
                     </u-form-item>
181 184
                     <u-form-item label="付款方式" borderBottom>
182
-                        <TabSelect :tabList="paymentTabList" :colNum="4" mode="single"
185
+                        <TabSelect :tabList="paymentTabList" :echoInfo="payTypeEcho" :colNum="4" mode="single"
183 186
                             @tabChange="handlePaymentTabChange">
184 187
                         </TabSelect>
185 188
                     </u-form-item>
@@ -376,7 +379,7 @@ export default {
376 379
                     value: 6,
377 380
                 },
378 381
             ],
379
-            brandToUrl: '/pages/wareHouse/brandList',
382
+            brandToUrl: '/pages/wareHouse/components/brandList',
380 383
             // 上传
381 384
             goodPicFileList: [{ url: 'https://uviewui.com/swiper/1.jpg' }],//商品图片
382 385
             detailPicFileList: [],//细节图片
@@ -384,6 +387,7 @@ export default {
384 387
             recycleBottomFileList: [],//回收留底图
385 388
             productCardFileList: [],//商品保卡图片或独立编码照片留底
386 389
             productTagFileList: [],//商品标签图片留底
390
+            payTypeEcho:''//付款方式识别回显
387 391
         }
388 392
     },
389 393
     methods: {
@@ -443,7 +447,6 @@ export default {
443 447
             this.recycleTimeShow = false;
444 448
         },
445 449
         closeRecycleTimePicker(val) {
446
-            console.log(val);
447 450
             this.recycleTimeShow = false;
448 451
         },
449 452
         cancelRecycleTimePicker(val) {
@@ -517,27 +520,91 @@ export default {
517 520
             console.log(event);
518 521
             // this.fileList5 = [...this.fileList5, ...event.fileList];
519 522
         },
520
-        async handleRecognition() {
523
+        async handlePasteRecognition(text) {
521 524
             // 品牌:浪琴
522 525
             // 来源:【麒麟】私信-杰3-3
523 526
             // 实价:6500
524 527
             // 型号:L2.257.5.89.7
525 528
             // 编码:52356065
526
-            // 日期:2021.11.09
529
+            // 日期:2021-11-09
527 530
             // 备注:全套
528
-            // 付款方式:线上
529
-            if (!this.recognitionContent) {
531
+            // 付款方式:微信
532
+            if (!text) {
530 533
                 return;
531 534
             }
532 535
             try {
533
-                uni.$u.toast("识别成功");
536
+                if (!text) return {};
537
+                
538
+                const result = {};
539
+                // 支持中文冒号和英文冒号
540
+                const lines = text.split(/[\n\r]+/);
541
+                
542
+                lines.forEach(line => {
543
+                const lineStr = line.trim();
544
+                if (!lineStr) return;
545
+                
546
+                // 尝试中文冒号
547
+                let separatorIndex = lineStr.indexOf(':');
548
+                // 如果没有中文冒号,尝试英文冒号
549
+                if (separatorIndex === -1) {
550
+                    separatorIndex = lineStr.indexOf(':');
551
+                }
552
+                
553
+                if (separatorIndex > 0) {
554
+                    const key = lineStr.substring(0, separatorIndex).trim();
555
+                    const value = lineStr.substring(separatorIndex + 1).trim();
556
+                    result[key] = value;
557
+                }
558
+                });
559
+                console.log(result);
560
+                if(result['品牌']){
561
+                    this.formData.brand = result['品牌'];
562
+                }
563
+                if(result['来源']){
564
+                    this.formData.desc = result['来源'];
565
+                }
566
+                if(result['实价']){
567
+                    this.formData.costPrice = result['实价'];
568
+                }
569
+                if(result['型号']){
570
+                    this.formData.model = result['型号'];
571
+                }
572
+                if(result['编码']){
573
+                    this.formData.indentifyCode = result['编码'];
574
+                }
575
+                if(result['日期']){
576
+                    this.formData.recycleTime = result['日期'];
577
+                }
578
+                if(result['备注']){
579
+                    this.formData.productDesc = result['备注'];
580
+                }
581
+                if(result['付款方式']){
582
+                    console.log(result['付款方式']);
583
+                    
584
+                    this.getPaymentType(result['付款方式'])
585
+                    this.formData.paymentType = result['付款方式'];
586
+
587
+                }
588
+                // return result;
534 589
             } catch (e) {
535 590
                 uni.$u.toast("文本识别异常");
536 591
             }
537 592
         },
593
+        clearRecognitionContent(){
594
+            this.recognitionContent = '';
595
+        },
596
+        getPaymentType(val) {
597
+            let arr = []
598
+            this.paymentTabList.filter(item=>{
599
+                if(item.name == val) arr.push(item.value)
600
+            })
601
+            if(arr.length > 0){
602
+                this.payTypeEcho = arr[0]
603
+            }
604
+        }
538 605
     }
539 606
 }
540 607
 </script>
541 608
 <style lang="scss" scoped>
542
-@import './styles/add.scss';
609
+@import '../styles/add.scss';
543 610
 </style>

+ 531 - 0
pages/wareHouse/components/detail.vue

@@ -0,0 +1,531 @@
1
+<template>
2
+    <view class="detail" @click="handleClickOutside">
3
+        <u-navbar class="nav_bar" title="商品详情档案" :autoBack="true" :placeholder="true" rightIcon="more-dot-fill"
4
+            v-hideNav></u-navbar>
5
+        <u-swiper :list="imgsUrl" keyName="url" indicator indicatorMode="line" circular>
6
+            <!-- <template v-slot:item="{ item, index }">
7
+                <view style="width: 100%; height: 600rpx;">
8
+                    <image :src="item.url" mode="aspectFill" style="width: 100%; height: 100%; object-fit: cover;"></image>
9
+                </view>
10
+            </template> -->
11
+        </u-swiper>
12
+
13
+        <!-- 立即下架按钮 -->
14
+        <view class="immediate_off_shelf">
15
+            <u-button type="error" shape="circle" size="large" @click="handleOffShelf">
16
+                <u-icon :name="downStatus == '0' ? 'arrow-upward' : 'arrow-downward'" size="38rpx"
17
+                    color="#ffffff"></u-icon>
18
+                <text>{{ downStatus == '0' ? '立即上架' : '立即下架' }}</text>
19
+            </u-button>
20
+        </view>
21
+
22
+        <!-- 轮播图下方操作按钮 -->
23
+        <view class="swiper_actions">
24
+            <view class="action_item" @click="handleDownload">
25
+                <u-icon name="download" size="44rpx" color="#606266"></u-icon>
26
+                <text class="action_text">下载图文</text>
27
+            </view>
28
+            <view class="action_item">
29
+                <u-icon name="share" size="44rpx" color="#606266"></u-icon>
30
+                <text class="action_text">分享</text>
31
+            </view>
32
+            <view class="action_item" @click="handleEditImgs">
33
+                <u-icon name="camera" size="44rpx" color="#606266"></u-icon>
34
+                <text class="action_text">编辑图片</text>
35
+                <u-modal :show="showEditImgsModal" title="编辑图片" showCancelButton @confirm="confirmEditImgs" @cancel="cancelEditImgs">
36
+                    <imgs-row-scroll v-if="tempImgsUrl.length > 0" :isShowDeleteIcon="true" keyName="url"
37
+                        @deleteImgInfo="getDeleteImgInfo" imgMode="aspectFill" :totalWidth="400" :images="tempImgsUrl"
38
+                        :previewEnabled="true" :imageWidth="150" :imageHeight="150"></imgs-row-scroll>
39
+                    <u-upload @afterRead="afterRead" multiple></u-upload>
40
+                </u-modal>
41
+            </view>
42
+            <view class="action_item">
43
+                <u-icon name="cut" size="44rpx" color="#606266"></u-icon>
44
+                <text class="action_text">智能抠图</text>
45
+            </view>
46
+        </view>
47
+
48
+        <!-- 核心信息区域 -->
49
+        <view class="core_info">
50
+            <view class="section_title">核心信息</view>
51
+            <view class="info_row">
52
+                <view class="info_label">品牌</view>
53
+                <view class="info_value" @click.stop="showBrandlList()">
54
+                    <!-- <u-input v-if="editMode.dictLabel" v-model="tempValues.dictLabel" :autoFocus="true" @blur="!globalEditMode && saveEditField('dictLabel', tempValues.dictLabel, 'dictLabel')" /> -->
55
+                    <span>{{ coreInfo.dictLabel || '-' }}</span>
56
+                    <BrandList ref="brandListRef" @selectedBrand="handleSelectedBrand"></BrandList>
57
+                </view>
58
+            </view>
59
+            <view class="info_row">
60
+                <view class="info_label">型号</view>
61
+                <view class="info_value" @click.stop="toggleEditField('model', coreInfo.model)">
62
+                    <u-input v-if="editMode.model" v-model="tempValues.model" :autoFocus="true"
63
+                        @blur="!globalEditMode && saveEditField('model', tempValues.model, 'model')" />
64
+                    <span v-else>{{ coreInfo.model || '-' }}</span>
65
+                </view>
66
+            </view>
67
+            <view class="info_row">
68
+                <view class="info_label">独立编码</view>
69
+                <view class="info_value code" @click.stop="toggleEditField('code', coreInfo.code)">
70
+                    <u-input v-if="editMode.code" v-model="tempValues.code" :autoFocus="true"
71
+                        @blur="!globalEditMode && saveEditField('code', tempValues.code, 'code')" />
72
+                    <span v-else>{{ coreInfo.code || '-' }}</span>
73
+                </view>
74
+            </view>
75
+            <view class="info_row">
76
+                <view class="info_label">入库日期</view>
77
+                <view class="info_value">{{ coreInfo.warehouseDate || '-' }}</view>
78
+            </view>
79
+            <view class="info_row">
80
+                <view class="info_label">付款方式</view>
81
+                <view class="info_value">{{ coreInfo.payType || '-' }}</view>
82
+            </view>
83
+            <view class="info_row col">
84
+                <view class="info_label">备注信息</view>
85
+                <view class="info_value note" @click.stop="toggleEditField('note', coreInfo.note)">
86
+                    <textarea v-if="editMode.note" v-model="tempValues.note" :autoFocus="true" rows="3"
87
+                        @blur="!globalEditMode && saveEditField('note', tempValues.note, 'note')" />
88
+                    <span v-else>{{ coreInfo.note || '-' }}</span>
89
+                </view>
90
+            </view>
91
+        </view>
92
+
93
+        <!-- 财务与价格区域 -->
94
+        <view class="finance_price">
95
+            <view class="section_title">财务与价格</view>
96
+            <view class="price_group">
97
+                <view class="price_item">
98
+                    <view class="price_label">原始成本</view>
99
+                    <view class="price_value original"
100
+                        @click.stop="toggleEditField('originalCost', coreInfo.originalCost)">
101
+                        <u-input v-if="editMode.originalCost" v-model="tempValues.originalCost" :autoFocus="true"
102
+                            @blur="!globalEditMode && saveEditField('originalCost', tempValues.originalCost, 'originalCost')" />
103
+                        <span v-else>¥{{ coreInfo.originalCost || '-' }}</span>
104
+                    </view>
105
+                </view>
106
+                <view class="price_item">
107
+                    <view class="price_label">附加成本</view>
108
+                    <view class="price_value additional"
109
+                        @click.stop="toggleEditField('additionalCost', coreInfo.additionalCost)">
110
+                        <u-input v-if="editMode.additionalCost" v-model="tempValues.additionalCost" :autoFocus="true"
111
+                            @blur="!globalEditMode && saveEditField('additionalCost', tempValues.additionalCost, 'additionalCost')" />
112
+                        <span v-else>¥{{ coreInfo.additionalCost || '-' }}</span>
113
+                    </view>
114
+                </view>
115
+            </view>
116
+            <view class="price_group">
117
+                <view class="price_item">
118
+                    <view class="price_label">代理价格</view>
119
+                    <view class="price_value agent" @click.stop="toggleEditField('agentPrice', coreInfo.agentPrice)">
120
+                        <u-input v-if="editMode.agentPrice" v-model="tempValues.agentPrice" :autoFocus="true"
121
+                            @blur="!globalEditMode && saveEditField('agentPrice', tempValues.agentPrice, 'agentPrice')" />
122
+                        <span v-else>¥{{ coreInfo.agentPrice || '-' }}</span>
123
+                    </view>
124
+                </view>
125
+                <view class="price_item">
126
+                    <view class="price_label">建议售价</view>
127
+                    <view class="price_value suggested"
128
+                        @click.stop="toggleEditField('suggestedPrice', coreInfo.suggestedPrice)">
129
+                        <u-input v-if="editMode.suggestedPrice" v-model="tempValues.suggestedPrice" :autoFocus="true"
130
+                            @blur="!globalEditMode && saveEditField('suggestedPrice', tempValues.suggestedPrice, 'suggestedPrice')" />
131
+                        <span v-else>¥{{ coreInfo.suggestedPrice || '-' }}</span>
132
+                    </view>
133
+                </view>
134
+            </view>
135
+        </view>
136
+
137
+        <!-- 溯源与位置区域 -->
138
+        <view class="traceability_location">
139
+            <view class="section_title">溯源与位置</view>
140
+            <view class="info_row">
141
+                <view class="info_label">商品位置</view>
142
+                <view class="info_value" @click.stop="toggleEditField('location', coreInfo.location)">
143
+                    <u-input v-if="editMode.location" v-model="tempValues.location" :autoFocus="true"
144
+                        @blur="!globalEditMode && saveEditField('location', tempValues.location, 'location')" />
145
+                    <span v-else>{{ coreInfo.location || '-' }}</span>
146
+                </view>
147
+            </view>
148
+            <view class="info_row">
149
+                <view class="info_label">回收人员</view>
150
+                <view class="info_value" @click.stop="showRecyclePersonPicker">
151
+                    <!-- <u-input v-if="editMode.recyclePerson" v-model="tempValues.recyclePerson" :autoFocus="true" @blur="!globalEditMode && saveEditField('recyclePerson', tempValues.recyclePerson, 'recyclePerson')" /> -->
152
+                    <span>{{ coreInfo.recyclePerson || '-' }}</span>
153
+                    <personPicker ref="recyclePersonPickerRef" title="请选择回收人员"
154
+                        @selectPerson="handleSelectRecyclePerson">
155
+                    </personPicker>
156
+                </view>
157
+            </view>
158
+            <view class="info_row">
159
+                <view class="info_label">鉴定人员</view>
160
+                <view class="info_value" @click.stop="showIdentifyingPersonPicker">
161
+                    <!-- <u-input v-if="editMode.identifyingPerson" v-model="tempValues.identifyingPerson" :autoFocus="true" @blur="!globalEditMode && saveEditField('identifyingPerson', tempValues.identifyingPerson, 'identifyingPerson')" /> -->
162
+                    <span>{{ coreInfo.identifyingPerson || '-' }}</span>
163
+                    <personPicker ref="identifyingPersonPickerRef" title="请选择鉴定人员"
164
+                        @selectPerson="handleSelectIdentifyingPerson"></personPicker>
165
+                </view>
166
+            </view>
167
+            <view class="action_button">
168
+                <u-button type="primary" plain size="mini" @click="viewLog">查看操作日志({{ coreInfo.logTotal ||
169
+                    '-'}}条)</u-button>
170
+                <u-modal :show="logShow" title="日志" :closeOnClickOverlay="true" :showConfirmButton="false"
171
+                    @close="logShow = false">
172
+                    <view class="log_list">
173
+                        <view v-for="value in logList" :key="value.id" class="log_item">
174
+                            {{ value.createTime }}{{ value.name }}{{ value.operation }}
175
+                        </view>
176
+                    </view>
177
+                </u-modal>
178
+            </view>
179
+        </view>
180
+
181
+        <!-- 底部功能按钮栏 -->
182
+        <view class="bottom_bar">
183
+            <view class="bar_item" @click.stop="globalEditMode ? handleClickOutside() : enterGlobalEdit()">
184
+                <u-icon :name="globalEditMode ? 'checkbox-mark' : 'edit-pen'" size="46rpx"
185
+                    :color="globalEditMode ? '#10b981' : '#9ca3af'"></u-icon>
186
+                <text class="bar_text">{{ globalEditMode ? '确定' : '编辑' }}</text>
187
+            </view>
188
+            <view class="bar_item" @click.stop="lockGoods">
189
+                <u-icon :name="lockStatus === '1' ? 'lock-open' : 'lock'" size="46rpx" color="#9ca3af"></u-icon>
190
+                <text class="bar_text">{{ lockStatus === '1' ? '解锁' : '锁单' }}</text>
191
+            </view>
192
+            <view class="bar_item">
193
+                <i class="iconfont icon-crm-dayin" style="font-size:46rpx;color: #9ca3af;"></i>
194
+                <text class="bar_text">打印</text>
195
+            </view>
196
+            <view :class="['bar_item', { 'disabled': lockStatus === '1' }]" @click="handleOpenOrder">
197
+                <view class="primary">
198
+                    <u-icon name="bag" size="44rpx" color="#fff"></u-icon>
199
+                    <text class="bar_text">开单</text>
200
+                </view>
201
+            </view>
202
+        </view>
203
+    </view>
204
+</template>
205
+
206
+<script>
207
+import BrandList from '@/components/brand-list/index.vue'
208
+import personPicker from '@/components/person-picker/index.vue'
209
+import imgsRowScroll from '@/components/imgs-row-scroll/index.vue'
210
+export default {
211
+    components: {
212
+        BrandList,
213
+        personPicker,
214
+        imgsRowScroll,
215
+    },
216
+    data() {
217
+        return {
218
+            // 核心信息模拟数据
219
+            coreInfo: {},
220
+            // 编辑状态管理
221
+            editMode: {
222
+                model: false,
223
+                code: false,
224
+                note: false,
225
+                originalCost: false,
226
+                additionalCost: false,
227
+                agentPrice: false,
228
+                suggestedPrice: false,
229
+                location: false,
230
+            },
231
+            // 全局编辑模式
232
+            globalEditMode: false,
233
+            // 临时存储编辑值
234
+            tempValues: {},
235
+            goodsId: '',
236
+            logShow: false,
237
+            logList: [],
238
+            imgsUrl: [],
239
+            lockStatus: '',//锁单状态 0:未锁单 1:已锁单 
240
+            downStatus: '',//下架状态 0:已下架 1:已上架
241
+            showEditImgsModal: false,
242
+            tempImgsUrl: [],
243
+        }
244
+    },
245
+    onLoad(options) {
246
+        this.goodsId = options.id;
247
+        this.getGoodsDetail();
248
+    },
249
+    methods: {
250
+        // 锁单
251
+        lockGoods() {
252
+            uni.$u.api.wareHouseLock({
253
+                id: this.goodsId,
254
+                lockStatus: this.lockStatus === '1' ? '0' : '1',
255
+            }).then(res => {
256
+                uni.showToast({
257
+                    title: this.lockStatus === '1' ? '解锁成功' : '锁单成功',
258
+                    icon: 'success'
259
+                })
260
+                this.getGoodsDetail();
261
+            })
262
+        },
263
+        showRecyclePersonPicker() {
264
+            this.$refs.recyclePersonPickerRef.open();
265
+        },
266
+        // 处理选中回收人员
267
+        handleSelectRecyclePerson(person) {
268
+            this.coreInfo.recyclePerson = person.label;
269
+            this.coreInfo.recyclePersonId = person.id;
270
+            this.submitEdit(this.coreInfo)
271
+        },
272
+        // 显示鉴定人员选择器
273
+        showIdentifyingPersonPicker() {
274
+            this.$refs.identifyingPersonPickerRef.open();
275
+        },
276
+        // 处理选中鉴定人员
277
+        handleSelectIdentifyingPerson(person) {
278
+            this.coreInfo.identifyingPerson = person.label;
279
+            this.coreInfo.identifyingPersonId = person.id;
280
+            this.submitEdit(this.coreInfo)
281
+        },
282
+        // 显示品牌列表
283
+        showBrandlList() {
284
+            this.$refs.brandListRef.showBrandList();
285
+        },
286
+        // 处理选中品牌
287
+        handleSelectedBrand(info) {
288
+            this.coreInfo.dictLabel = info.dictLabel;
289
+            this.coreInfo.dictValue = info.dictValue;
290
+            this.submitEdit(this.coreInfo)
291
+        },
292
+        // 获取商品详情
293
+        getGoodsDetail() {
294
+            uni.$u.api.wareHouseDetail({
295
+                id: this.goodsId,
296
+                userId: this.$store.state.user.userInfo.userId,
297
+            }).then(res => {
298
+                this.coreInfo = res.data;
299
+                this.imgsUrl = res.data.imgsUrl || [];
300
+                this.lockStatus = res.data.lockStatus;
301
+                this.downStatus = res.data.downStatus;
302
+            });
303
+        },
304
+        // 打开销售业务开单页面
305
+        handleOpenOrder() {
306
+            if (this.lockStatus === '1') {
307
+                uni.showToast({
308
+                    title: '已锁单,不能开单',
309
+                    icon: 'none'
310
+                })
311
+                return
312
+            }
313
+            uni.navigateTo({
314
+                url: '/pages/wareHouse/components/openOrder?id=' + this.goodsId
315
+            });
316
+        },
317
+        viewLog() {
318
+            uni.$u.api.wareHouseLog({
319
+                id: this.goodsId,
320
+                userId: this.$store.state.user.userInfo.userId,
321
+            }).then(res => {
322
+                this.logList = res.data;
323
+                this.logShow = true;
324
+            });
325
+        },
326
+
327
+        // 立即下架按钮
328
+        handleOffShelf() {
329
+            uni.$u.api.wareHouseDown({
330
+                id: this.goodsId,
331
+                downStatus: this.downStatus === '1' ? '0' : '1',
332
+            }).then(res => {
333
+                uni.showToast({
334
+                    title: this.downStatus === '1' ? '上架成功' : '下架成功',
335
+                    icon: 'success'
336
+                })
337
+                this.getGoodsDetail();
338
+            })
339
+        },
340
+        // 切换单个字段的编辑状态
341
+        toggleEditField(field, value) {
342
+            // 如果不是全局编辑模式
343
+            if (!this.globalEditMode) {
344
+                // 重置所有编辑状态
345
+                this.resetEditMode();
346
+                // 设置当前字段为编辑状态
347
+                this.editMode[field] = true;
348
+                // 保存临时值
349
+                this.tempValues[field] = value;
350
+            }
351
+        },
352
+        // 保存单个字段的编辑值
353
+        saveEditField(field, newValue, fieldName) {
354
+            this.coreInfo[fieldName] = newValue;
355
+            this.editMode[field] = false;
356
+            delete this.tempValues[field];
357
+            console.log(`保存${field}字段值: ${newValue}`);
358
+            this.submitEdit(this.coreInfo);
359
+        },
360
+        // 进入全局编辑模式
361
+        enterGlobalEdit() {
362
+            this.globalEditMode = true;
363
+            // 设置所有可编辑字段为编辑状态
364
+            this.editMode = {
365
+                model: true,
366
+                code: true,
367
+                note: true,
368
+                originalCost: true,
369
+                additionalCost: true,
370
+                agentPrice: true,
371
+                suggestedPrice: true,
372
+                location: true,
373
+            };
374
+            // 保存所有字段的临时值
375
+            this.tempValues = { ...this.coreInfo }
376
+        },
377
+        // 重置所有编辑状态
378
+        resetEditMode() {
379
+            Object.keys(this.editMode).forEach(key => {
380
+                this.editMode[key] = false;
381
+            });
382
+        },
383
+        submitEdit(info) {
384
+            const data = {
385
+                id: this.goodsId,
386
+                imgsUrl: this.imgsUrl,
387
+                dictLabel: info.dictLabel,
388
+                dictValue: info.dictValue,
389
+                model: info.model,
390
+                code: info.code,
391
+                warehouseDate: info.warehouseDate,
392
+                payType: info.payType,
393
+                note: info.note,
394
+                originalCost: info.originalCost,
395
+                additionalCost: info.additionalCost,
396
+                agentPrice: info.agentPrice,
397
+                suggestedPrice: info.suggestedPrice,
398
+                location: info.location,
399
+                recyclePerson: info.recyclePerson,
400
+                recyclePersonId: info.recyclePersonId,
401
+                identifyingPerson: info.identifyingPerson,
402
+                identifyingPersonId: info.identifyingPersonId,
403
+            }
404
+            uni.$u.api.wareHouseUpdate(data).then(res => {
405
+                uni.showToast({
406
+                    title: '编辑成功',
407
+                    icon: 'success'
408
+                });
409
+                this.getGoodsDetail();
410
+                this.$emit('editSuccess')
411
+            })
412
+        },
413
+        // 点击页面其他地方保存所有编辑
414
+        handleClickOutside() {
415
+            if (this.globalEditMode) {
416
+                this.submitEdit(this.tempValues)
417
+                // 全局编辑模式下,点击外部区域重置所有编辑
418
+                this.globalEditMode = false;
419
+                // 退出所有编辑状态
420
+                this.resetEditMode();
421
+                // 清空临时值,恢复初始状态
422
+                this.tempValues = {};
423
+
424
+            } else {
425
+                // 保存当前正在编辑的字段
426
+                Object.keys(this.editMode).forEach(key => {
427
+                    if (this.editMode[key]) {
428
+                        this.saveEditField(key, this.tempValues[key], key);
429
+                    }
430
+                });
431
+            }
432
+
433
+        },
434
+        handleDownload() {
435
+            if (this.imgsUrl.length == 0) {
436
+                uni.showToast({
437
+                    title: '暂无图片',
438
+                    icon: 'none'
439
+                })
440
+                return;
441
+            }
442
+            uni.showModal({
443
+                title: '保存图片',
444
+                content: `是否将 ${this.imgsUrl.length} 张图片保存到本地相册?`,
445
+                confirmText: '保存',
446
+                success: (res) => {
447
+                    if (res.confirm) {
448
+                        this.saveImagesToLocal(this.imgsUrl);
449
+                    }
450
+                }
451
+            })
452
+
453
+        },
454
+        saveImagesToLocal(allUrls) {
455
+            uni.showToast({
456
+                title: '图片保存中...',
457
+                icon: 'loading'
458
+            })
459
+            allUrls.forEach((item, index) => {
460
+                uni.downloadFile({
461
+                    url: item.url,
462
+                    success: (res) => {
463
+                        if (res.statusCode === 200) {
464
+                            uni.saveImageToPhotosAlbum({
465
+                                filePath: res.tempFilePath,
466
+                                success() {
467
+                                    uni.showToast({
468
+                                        title: '保存成功'
469
+                                    })
470
+                                },
471
+                                fail: (err) => {
472
+                                    console.error('保存到相册失败:', err);
473
+                                    // 如果是权限问题,尝试请求权限
474
+                                    if (err.errMsg.includes('auth denied')) {
475
+                                        uni.showModal({
476
+                                            title: '权限不足',
477
+                                            content: '需要访问相册权限来保存图片,是否去设置?',
478
+                                            success: (modalRes) => {
479
+                                                if (modalRes.confirm) {
480
+                                                    // 打开设置页面
481
+                                                    uni.openSetting({
482
+                                                        success: (settingRes) => {
483
+                                                            console.log('设置页面结果:', settingRes);
484
+                                                        }
485
+                                                    });
486
+                                                }
487
+                                            }
488
+                                        });
489
+                                    }
490
+                                    reject(err);
491
+                                }
492
+                            })
493
+                        }
494
+                    }
495
+                })
496
+            })
497
+        },
498
+        handleEditImgs() {
499
+            this.showEditImgsModal = true;
500
+            this.tempImgsUrl = this.imgsUrl
501
+        },
502
+        getDeleteImgInfo(imgInfo) {
503
+            this.tempImgsUrl = imgInfo.newImages
504
+        },
505
+        afterRead(info) {
506
+            info.file.forEach(item=>{
507
+                uni.$u.api.uploadFile(item.url).then((res) => {
508
+                    this.tempImgsUrl.push({url:res.data.url});
509
+                    uni.$u.toast("文件上传成功");
510
+                    this.showEditImgsModal = false;
511
+                }).catch(() => {
512
+                    uni.$u.toast("上传文件失败");
513
+                })
514
+            })
515
+        },
516
+        confirmEditImgs() {
517
+            this.imgsUrl = this.tempImgsUrl
518
+            this.submitEdit(this.coreInfo)
519
+            this.showEditImgsModal = false;
520
+        },
521
+        cancelEditImgs() {
522
+            this.tempImgsUrl = []
523
+            this.showEditImgsModal = false;
524
+        }
525
+    }
526
+}
527
+</script>
528
+
529
+<style lang="scss" scoped>
530
+@import "../styles/detail.scss";
531
+</style>

+ 2 - 2
pages/wareHouse/openOrder.vue

@@ -106,7 +106,7 @@ export default {
106 106
    data() {
107 107
       return {
108 108
          openOrderForm: {
109
-            url: require('./imgs/1.jpg'),
109
+            url: require('../imgs/1.jpg'),
110 110
             title: 'ROLEX',
111 111
             desc: 'SUBMSRINER DATE 126610LN',
112 112
             totalCost: '82500',
@@ -242,5 +242,5 @@ export default {
242 242
 }
243 243
 </script>
244 244
 <style lang="scss" scoped>
245
-@import './styles/openOrder.scss';
245
+@import '../styles/openOrder.scss';
246 246
 </style>

+ 182 - 0
pages/wareHouse/components/searchFilter.vue

@@ -0,0 +1,182 @@
1
+<template>
2
+    <u-popup mode="bottom" :round="10" :show="show" @close="close" @open="open" closeable>
3
+        <u--form labelPosition="left" :model="formData" ref="uForm">
4
+            <u-form-item label="品牌" @click="showBrandList" labelWidth="70">
5
+                <FormSelectToPage :val="formData.dictLabel" :isDelete="true" borderType="bottom" @handleClear="clear('dictLabel')"></FormSelectToPage>
6
+                <BrandList ref="brandListRef" @selectedBrand="handleSelectedBrand"></BrandList>
7
+            </u-form-item>
8
+            <u-form-item label="价格范围" labelWidth="70">
9
+                <u-input v-model="formData.minPrice" placeholder="最小价格" fontSize="14" border="bottom" clearable></u-input>
10
+                &nbsp;&nbsp;——&nbsp;&nbsp;
11
+                <u-input v-model="formData.maxPrice" placeholder="最大价格" fontSize="14" border="bottom" clearable></u-input>
12
+            </u-form-item>
13
+            <u-form-item label="位置" labelWidth="70">
14
+                <u-input v-model="formData.location" fontSize="14" clearable border="bottom"></u-input>
15
+            </u-form-item>
16
+            <u-form-item label="回收时间" labelWidth="70" @click="recycleTimeShow = true">
17
+                <FormSelectToPage :val="formData.recycleTime" :isDelete="true" borderType="bottom" @handleClear="clear('recycleTime')">  </FormSelectToPage>
18
+                <u-datetime-picker  :show="recycleTimeShow" v-model="recycleTimeDefault" mode="date"  @confirm="confirmRecycleTime" @close="recycleTimeShow = false"
19
+                            @cancel="recycleTimeShow = false"></u-datetime-picker>
20
+            </u-form-item>
21
+            <u-form-item label="回收人员" labelWidth="70" @click="recyclePersonClick">
22
+                <FormSelectToPage :val="formData.recyclePerson" :isDelete="true" borderType="bottom" @handleClear="clear('recyclePerson')"></FormSelectToPage>
23
+                <personPicker ref="recyclePersonPickerRef" title="请选择回收人员" @selectPerson="handleSelectRecyclePerson"></personPicker>
24
+            </u-form-item>
25
+            <u-form-item label="鉴定人员" labelWidth="70" @click="identifyingPersonClick">
26
+                <FormSelectToPage :val="formData.identifyingPerson" :isDelete="true" borderType="bottom" @handleClear="clear('identifyingPerson')"></FormSelectToPage>
27
+                <personPicker ref="identifyingPersonPickerRef" title="请选择鉴定人员" @selectPerson="handleSelectIdentifyingPerson"></personPicker>
28
+            </u-form-item>
29
+            <u-form-item label="商品属性" labelWidth="70">
30
+                <TabSelect :tabList="productAttributeList" :colNum="3" :echoInfo="formData.productAttribute" mode="multiple" @tabChange="handleTabChangeProductAttribute"></TabSelect>
31
+            </u-form-item>
32
+        </u--form>
33
+        <view class="btns">
34
+            <u-button text="重置" @click="resetForm"></u-button>
35
+            <u-button type="primary" text="确定" @click="handleSearch"></u-button>
36
+        </view>
37
+    </u-popup>
38
+</template>
39
+
40
+<script>
41
+import FormSelectToPage from '@/components/form-select-to-page/index.vue'
42
+import BrandList from '@/components/brand-list/index.vue'
43
+import personPicker from '@/components/person-picker/index.vue'
44
+import TabSelect from '@/components/custom-tab-select/index.vue'
45
+export default {
46
+    components: {
47
+        FormSelectToPage,
48
+        BrandList,
49
+        personPicker,
50
+        TabSelect,
51
+    },
52
+    name: 'searchFilter',
53
+    emits: ['confirm'],
54
+    data() {
55
+        return {
56
+            show: false,
57
+            formData: {
58
+                dictLabel: '',
59
+                dictValue: '',
60
+                minPrice: '',
61
+                maxPrice: '',
62
+                location: '',
63
+                recycleTime: '',
64
+                recyclePerson:'',
65
+                recyclePersonId: '',
66
+                identifyingPerson:'',
67
+                identifyingPersonId: '',
68
+                productAttribute: '',
69
+            },
70
+            recycleTimeDefault: new Date().getTime(),
71
+            recycleTimeShow: false,
72
+            recyclePersonList: [],
73
+            productAttributeList: [
74
+                {
75
+                    name: '自有商品',
76
+                    value: '1',
77
+                },
78
+                {
79
+                    name: '寄卖商品',
80
+                    value: '2',
81
+                },
82
+                {
83
+                    name: '质押商品',
84
+                    value: '3',
85
+                },
86
+                {
87
+                    name: '其它',
88
+                    value: '4',
89
+                },
90
+            ],
91
+        }
92
+    },
93
+    props: {
94
+    },
95
+    emits: [],
96
+    methods: {
97
+        handleSearch() {
98
+            this.$emit('confirm', this.formData);
99
+            this.close();
100
+        },
101
+        resetForm() {
102
+            this.formData = {
103
+                dictLabel: '',
104
+                dictValue: '',
105
+                minPrice: '',
106
+                maxPrice: '',
107
+                location: '',
108
+                recycleTime: '',
109
+                recyclePerson:'',
110
+                recyclePersonId: '',
111
+                identifyingPerson:'',
112
+                identifyingPersonId: '',
113
+                productAttribute: '',
114
+            };
115
+            this.recycleTimeDefault = new Date().getTime();
116
+        },
117
+        open() {
118
+            this.show = true
119
+            
120
+        },
121
+        close() {
122
+            this.show = false
123
+        },
124
+        showBrandList() {
125
+            this.$refs.brandListRef.showBrandList();
126
+        },
127
+        handleSelectedBrand(info) {
128
+            this.formData.dictLabel = info.dictLabel;
129
+            this.formData.dictValue = info.dictValue;
130
+        },
131
+        // 处理清空事件
132
+        clear(field) {
133
+            // 品牌
134
+            if(field == 'dictLabel'){
135
+                this.formData.dictLabel = '';
136
+                this.formData.dictValue = '';
137
+                return;
138
+            }
139
+            // 回收人
140
+            if(field == 'recyclePerson'){
141
+                this.formData.recyclePerson = '';
142
+                this.formData.recyclePersonId = '';
143
+                return;
144
+            }
145
+            // 鉴定人
146
+            if(field == 'identifyingPerson'){
147
+                this.formData.identifyingPerson = '';
148
+                this.formData.identifyingPersonId = '';
149
+                return;
150
+            }
151
+            this.formData[field] = '';
152
+        },
153
+        confirmRecycleTime(val) {
154
+            this.$nextTick(()=>{
155
+                this.formData.recycleTime = this.$dayjs(val.value).format('YYYY-MM-DD');
156
+            })
157
+            this.recycleTimeShow = false;
158
+        },
159
+        recyclePersonClick() {
160
+            this.$refs.recyclePersonPickerRef.open();
161
+        },
162
+        handleSelectRecyclePerson(info) {
163
+            this.formData.recyclePerson = info.label;
164
+            this.formData.recyclePersonId = info.id;
165
+        },
166
+        identifyingPersonClick() {
167
+            this.$refs.identifyingPersonPickerRef.open();
168
+        },
169
+        handleSelectIdentifyingPerson(info) {
170
+            this.formData.identifyingPerson = info.label;
171
+            this.formData.identifyingPersonId = info.id;
172
+        },
173
+        handleTabChangeProductAttribute(e) {
174
+            this.formData.productAttribute = e;
175
+        },
176
+    }
177
+}
178
+</script>
179
+
180
+<style lang="scss" scoped>
181
+    @import "../styles/searchFilter.scss";
182
+</style>

+ 0 - 382
pages/wareHouse/detail.vue

@@ -1,382 +0,0 @@
1
-<template>
2
-    <view class="detail" @click="handleClickOutside">
3
-        <u-navbar class="nav-bar" title="商品详情档案" :autoBack="true" :placeholder="true" rightIcon="more-dot-fill" v-hideNav></u-navbar>
4
-        <u-swiper :list="imgs" keyName="url" indicator indicatorMode="line" circular>
5
-            <!-- <template v-slot:item="{ item, index }">
6
-                <view style="width: 100%; height: 600rpx;">
7
-                    <image :src="item.url" mode="aspectFill" style="width: 100%; height: 100%; object-fit: cover;"></image>
8
-                </view>
9
-            </template> -->
10
-        </u-swiper>
11
-        
12
-        <!-- 立即下架按钮 -->
13
-        <view class="immediate-off-shelf">
14
-            <u-button type="error" shape="circle" size="large" @click="handleOffShelf">
15
-                <u-icon name="download" size="38rpx" color="#ffffff"></u-icon>
16
-                <text>立即下架</text>
17
-            </u-button>
18
-        </view>
19
-        
20
-        <!-- 轮播图下方操作按钮 -->
21
-        <view class="swiper-actions">
22
-            <view class="action-item">
23
-                <u-icon name="download" size="44rpx" color="#606266"></u-icon>
24
-                <text class="action-text">下载图文</text>
25
-            </view>
26
-            <view class="action-item">
27
-                <u-icon name="share" size="44rpx" color="#606266"></u-icon>
28
-                <text class="action-text">分享</text>
29
-            </view>
30
-            <view class="action-item">
31
-                <u-icon name="camera" size="44rpx" color="#606266"></u-icon>
32
-                <text class="action-text">切换单图</text>
33
-            </view>
34
-            <view class="action-item">
35
-                <u-icon name="cut" size="44rpx" color="#606266"></u-icon>
36
-                <text class="action-text">智能抠图</text>
37
-            </view>
38
-        </view>
39
-        
40
-        <!-- 核心信息区域 -->
41
-        <view class="core-info">
42
-            <view class="section-title">核心信息</view>
43
-            <view class="info-row">
44
-                <view class="info-label">品牌</view>
45
-                <view class="info-value" @click.stop="toggleEditField('brand', coreInfo.brand)">
46
-                    <u-input v-if="editMode.brand" v-model="tempValues.brand" @blur="saveEditField('brand', tempValues.brand, 'core', 'brand')" :autoFocus="true" />
47
-                    <span v-else>{{ coreInfo.brand }}</span>
48
-                </view>
49
-            </view>
50
-            <view class="info-row">
51
-                <view class="info-label">型号</view>
52
-                <view class="info-value" @click.stop="toggleEditField('model', coreInfo.model)">
53
-                    <u-input v-if="editMode.model" v-model="tempValues.model" @blur="saveEditField('model', tempValues.model, 'core', 'model')" :autoFocus="true" />
54
-                    <span v-else>{{ coreInfo.model }}</span>
55
-                </view>
56
-            </view>
57
-            <view class="info-row">
58
-                <view class="info-label">独立编码</view>
59
-                <view class="info-value code" @click.stop="toggleEditField('code', coreInfo.code)">
60
-                    <u-input v-if="editMode.code" v-model="tempValues.code" @blur="saveEditField('code', tempValues.code, 'core', 'code')" :autoFocus="true" />
61
-                    <span v-else>{{ coreInfo.code }}</span>
62
-                </view>
63
-            </view>
64
-            <view class="info-row">
65
-                <view class="info-label">入库日期</view>
66
-                <view class="info-value">{{ coreInfo.warehouseDate }}</view>
67
-            </view>
68
-            <view class="info-row">
69
-                <view class="info-label">付款方式</view>
70
-                <view class="info-value">{{ coreInfo.paymentMethod }}</view>
71
-            </view>
72
-            <view class="info-row col">
73
-                <view class="info-label">备注信息</view>
74
-                <view class="info-value note" @click.stop="toggleEditField('note', coreInfo.note)">
75
-                    <textarea v-if="editMode.note" v-model="tempValues.note" @blur="saveEditField('note', tempValues.note, 'core', 'note')" :autoFocus="true" rows="3" />
76
-                    <span v-else>{{ coreInfo.note }}</span>
77
-                </view>
78
-            </view>
79
-        </view>
80
-        
81
-        <!-- 财务与价格区域 -->
82
-        <view class="finance-price">
83
-            <view class="section-title">财务与价格</view>
84
-            <view class="price-group">
85
-                <view class="price-item">
86
-                    <view class="price-label">原始成本</view>
87
-                    <view class="price-value original" @click.stop="toggleEditField('originalCost', financePrice.originalCost)">
88
-                        <u-input v-if="editMode.originalCost" v-model="tempValues.originalCost" @blur="saveEditField('originalCost', tempValues.originalCost, 'finance', 'originalCost')" :autoFocus="true" />
89
-                        <span v-else>¥{{ financePrice.originalCost }}</span>
90
-                    </view>
91
-                </view>
92
-                <view class="price-item">
93
-                    <view class="price-label">附加成本</view>
94
-                    <view class="price-value additional" @click.stop="toggleEditField('additionalCost', financePrice.additionalCost)">
95
-                        <u-input v-if="editMode.additionalCost" v-model="tempValues.additionalCost" @blur="saveEditField('additionalCost', tempValues.additionalCost, 'finance', 'additionalCost')" :autoFocus="true" />
96
-                        <span v-else>¥{{ financePrice.additionalCost }}</span>
97
-                    </view>
98
-                </view>
99
-            </view>
100
-            <view class="price-group">
101
-                <view class="price-item">
102
-                    <view class="price-label">代理价格</view>
103
-                    <view class="price-value agent" @click.stop="toggleEditField('agentPrice', financePrice.agentPrice)">
104
-                        <u-input v-if="editMode.agentPrice" v-model="tempValues.agentPrice" @blur="saveEditField('agentPrice', tempValues.agentPrice, 'finance', 'agentPrice')" :autoFocus="true" />
105
-                        <span v-else>¥{{ financePrice.agentPrice }}</span>
106
-                    </view>
107
-                </view>
108
-                <view class="price-item">
109
-                    <view class="price-label">建议售价</view>
110
-                    <view class="price-value suggested" @click.stop="toggleEditField('suggestedPrice', financePrice.suggestedPrice)">
111
-                        <u-input v-if="editMode.suggestedPrice" v-model="tempValues.suggestedPrice" @blur="saveEditField('suggestedPrice', tempValues.suggestedPrice, 'finance', 'suggestedPrice')" :autoFocus="true" />
112
-                        <span v-else>¥{{ financePrice.suggestedPrice }}</span>
113
-                    </view>
114
-                </view>
115
-            </view>
116
-        </view>
117
-        
118
-        <!-- 溯源与位置区域 -->
119
-        <view class="traceability-location">
120
-            <view class="section-title">溯源与位置</view>
121
-            <view class="info-row">
122
-                <view class="info-label">商品位置</view>
123
-                <view class="info-value" @click.stop="toggleEditField('location', traceability.location)">
124
-                    <u-input v-if="editMode.location" v-model="tempValues.location" @blur="saveEditField('location', tempValues.location, 'trace', 'location')" :autoFocus="true" />
125
-                    <span v-else>{{ traceability.location }}</span>
126
-                </view>
127
-            </view>
128
-            <view class="info-row">
129
-                <view class="info-label">回收人员</view>
130
-                <view class="info-value" @click.stop="toggleEditField('recoveryPerson', traceability.recoveryPerson)">
131
-                    <u-input v-if="editMode.recoveryPerson" v-model="tempValues.recoveryPerson" @blur="saveEditField('recoveryPerson', tempValues.recoveryPerson, 'trace', 'recoveryPerson')" :autoFocus="true" />
132
-                    <span v-else>{{ traceability.recoveryPerson }}</span>
133
-                </view>
134
-            </view>
135
-            <view class="info-row">
136
-                <view class="info-label">鉴定人员</view>
137
-                <view class="info-value" @click.stop="toggleEditField('authenticationPerson', traceability.authenticationPerson)">
138
-                    <u-input v-if="editMode.authenticationPerson" v-model="tempValues.authenticationPerson" @blur="saveEditField('authenticationPerson', tempValues.authenticationPerson, 'trace', 'authenticationPerson')" :autoFocus="true" />
139
-                    <span v-else>{{ traceability.authenticationPerson }}</span>
140
-                </view>
141
-            </view>
142
-            <view class="action-button">
143
-                <u-button type="primary" plain size="mini" @click="viewLog">查看操作日志(12条)</u-button>
144
-            </view>
145
-        </view>
146
-        
147
-        <!-- 底部功能按钮栏 -->
148
-        <view class="bottom-bar">
149
-            <view class="bar-item" @click.stop="enterGlobalEdit">
150
-                <u-icon name="edit-pen" size="46rpx" color="#9ca3af"></u-icon>
151
-                <text class="bar-text">编辑</text>
152
-            </view>
153
-            <view class="bar-item">
154
-                <u-icon name="lock" size="46rpx" color="#9ca3af"></u-icon>
155
-                <text class="bar-text">锁单</text>
156
-            </view>
157
-            <view class="bar-item">
158
-                <i class="iconfont icon-crm-dayin" style="font-size:46rpx;color: #9ca3af;"></i>
159
-                <text class="bar-text">打印</text>
160
-            </view>
161
-            <view class="bar-item" @click="handleOpenOrder">
162
-                <view class="primary">
163
-                    <u-icon name="bag" size="44rpx" color="#fff"></u-icon>
164
-                    <text class="bar-text">开单</text>
165
-                </view>
166
-            </view>
167
-        </view>
168
-    </view>
169
-</template>
170
-
171
-<script>
172
-    export default {
173
-        data() {
174
-            return {
175
-                imgs: [
176
-                    {
177
-                        url: 'https://img2.baidu.com/it/u=2737617573,3814711807&fm=253&fmt=auto&app=120&f=JPEG?w=800&h=800'
178
-                    },
179
-                    {
180
-                        url: 'https://img2.baidu.com/it/u=3621921167,4010012360&fm=253&fmt=auto?w=760&h=760'
181
-                    },
182
-                    {
183
-                        url: 'https://img2.baidu.com/it/u=1250952949,1454201719&fm=253&fmt=auto&app=138&f=JPEG?w=800&h=1067'
184
-                    }
185
-                ],
186
-                // 核心信息模拟数据
187
-                coreInfo: {
188
-                    brand: 'Rolex',
189
-                    model: 'Submariner Date 126610LN',
190
-                    code: 'AUTO_1002391',
191
-                    warehouseDate: '2025-12-14 10:00',
192
-                    paymentMethod: '线上转账',
193
-                    note: '单包 附件齐全 成色极好'
194
-                },
195
-                // 财务与价格模拟数据
196
-                financePrice: {
197
-                    originalCost: '82,000',
198
-                    additionalCost: '500',
199
-                    agentPrice: '85,500',
200
-                    suggestedPrice: '89,000'
201
-                },
202
-                // 溯源与位置模拟数据
203
-                traceability: {
204
-                    location: '上海A仓',
205
-                    recoveryPerson: 'IT秦',
206
-                    authenticationPerson: '中检-刘师傅'
207
-                },
208
-                // 编辑状态管理
209
-                editMode: {
210
-                    // 核心信息编辑状态
211
-                    brand: false,
212
-                    model: false,
213
-                    code: false,
214
-                    note: false,
215
-                    // 财务与价格编辑状态
216
-                    originalCost: false,
217
-                    additionalCost: false,
218
-                    agentPrice: false,
219
-                    suggestedPrice: false,
220
-                    // 溯源与位置编辑状态
221
-                    location: false,
222
-                    recoveryPerson: false,
223
-                    authenticationPerson: false
224
-                },
225
-                // 全局编辑模式
226
-                globalEditMode: false,
227
-                // 临时存储编辑值
228
-                tempValues: {}
229
-            }
230
-        },
231
-        methods: {
232
-            // 打开销售业务开单页面
233
-            handleOpenOrder() {
234
-                uni.navigateTo({
235
-                    url: '/pages/wareHouse/openOrder'
236
-                });
237
-            },
238
-            // 查看操作日志的方法
239
-            viewLog() {
240
-                // 查看操作日志的方法
241
-                console.log('查看操作日志');
242
-            },
243
-            
244
-            // 立即下架按钮处理方法
245
-            handleOffShelf() {
246
-                // 处理下架逻辑
247
-                uni.showModal({
248
-                    title: '确认下架',
249
-                    content: '确定要将此商品下架吗?',
250
-                    success: (res) => {
251
-                        if (res.confirm) {
252
-                            console.log('商品已下架');
253
-                            uni.showToast({
254
-                                title: '已下架',
255
-                                icon: 'success'
256
-                            });
257
-                        }
258
-                    }
259
-                });
260
-            },
261
-            // 切换单个字段的编辑状态
262
-            toggleEditField(field, value) {
263
-                // 如果不是全局编辑模式
264
-                if (!this.globalEditMode) {
265
-                    // 重置所有编辑状态
266
-                    this.resetEditMode();
267
-                    // 设置当前字段为编辑状态
268
-                    this.editMode[field] = true;
269
-                    // 保存临时值
270
-                    this.tempValues[field] = value;
271
-                }
272
-            },
273
-            // 保存单个字段的编辑值
274
-            saveEditField(field, newValue, type, fieldName) {
275
-                // 更新对应的数据
276
-                if (type === 'core') {
277
-                    this.coreInfo[fieldName] = newValue;
278
-                } else if (type === 'finance') {
279
-                    this.financePrice[fieldName] = newValue;
280
-                } else if (type === 'trace') {
281
-                    this.traceability[fieldName] = newValue;
282
-                }
283
-                // 退出编辑状态
284
-                this.editMode[field] = false;
285
-                // 清空临时值
286
-                delete this.tempValues[field];
287
-                // 模拟保存操作
288
-                console.log(`保存${field}字段值: ${newValue}`);
289
-            },
290
-            // 进入全局编辑模式
291
-            enterGlobalEdit() {
292
-                this.globalEditMode = true;
293
-                // 设置所有可编辑字段为编辑状态
294
-                this.editMode = {
295
-                    brand: true,
296
-                    model: true,
297
-                    code: true,
298
-                    note: true,
299
-                    originalCost: true,
300
-                    additionalCost: true,
301
-                    agentPrice: true,
302
-                    suggestedPrice: true,
303
-                    location: true,
304
-                    recoveryPerson: true,
305
-                    authenticationPerson: true
306
-                };
307
-                // 保存所有字段的临时值
308
-                this.tempValues = {
309
-                    brand: this.coreInfo.brand,
310
-                    model: this.coreInfo.model,
311
-                    code: this.coreInfo.code,
312
-                    note: this.coreInfo.note,
313
-                    originalCost: this.financePrice.originalCost,
314
-                    additionalCost: this.financePrice.additionalCost,
315
-                    agentPrice: this.financePrice.agentPrice,
316
-                    suggestedPrice: this.financePrice.suggestedPrice,
317
-                    location: this.traceability.location,
318
-                    recoveryPerson: this.traceability.recoveryPerson,
319
-                    authenticationPerson: this.traceability.authenticationPerson
320
-                };
321
-            },
322
-            // 保存全局编辑模式下的所有修改
323
-            saveGlobalEdit() {
324
-                // 保存所有临时值到原始数据
325
-                // 核心信息
326
-                if (this.tempValues.brand !== undefined) this.coreInfo.brand = this.tempValues.brand;
327
-                if (this.tempValues.model !== undefined) this.coreInfo.model = this.tempValues.model;
328
-                if (this.tempValues.code !== undefined) this.coreInfo.code = this.tempValues.code;
329
-                if (this.tempValues.note !== undefined) this.coreInfo.note = this.tempValues.note;
330
-                
331
-                // 财务与价格
332
-                if (this.tempValues.originalCost !== undefined) this.financePrice.originalCost = this.tempValues.originalCost;
333
-                if (this.tempValues.additionalCost !== undefined) this.financePrice.additionalCost = this.tempValues.additionalCost;
334
-                if (this.tempValues.agentPrice !== undefined) this.financePrice.agentPrice = this.tempValues.agentPrice;
335
-                if (this.tempValues.suggestedPrice !== undefined) this.financePrice.suggestedPrice = this.tempValues.suggestedPrice;
336
-                
337
-                // 溯源与位置
338
-                if (this.tempValues.location !== undefined) this.traceability.location = this.tempValues.location;
339
-                if (this.tempValues.recoveryPerson !== undefined) this.traceability.recoveryPerson = this.tempValues.recoveryPerson;
340
-                if (this.tempValues.authenticationPerson !== undefined) this.traceability.authenticationPerson = this.tempValues.authenticationPerson;
341
-                
342
-                this.globalEditMode = false;
343
-                // 退出所有编辑状态
344
-                this.resetEditMode();
345
-                // 清空临时值
346
-                this.tempValues = {};
347
-                // 模拟保存操作
348
-                console.log('保存所有字段值');
349
-            },
350
-            // 重置所有编辑状态
351
-            resetEditMode() {
352
-                Object.keys(this.editMode).forEach(key => {
353
-                    this.editMode[key] = false;
354
-                });
355
-            },
356
-            // 点击页面其他地方保存所有编辑
357
-            handleClickOutside() {
358
-                if (this.globalEditMode) {
359
-                    this.saveGlobalEdit();
360
-                } else {
361
-                    // 保存当前正在编辑的字段
362
-                    Object.keys(this.editMode).forEach(key => {
363
-                        if (this.editMode[key]) {
364
-                            // 根据字段名确定类型和字段名
365
-                            if (['brand', 'model', 'code', 'note'].includes(key)) {
366
-                                this.saveEditField(key, this.tempValues[key], 'core', key);
367
-                            } else if (['originalCost', 'additionalCost', 'agentPrice', 'suggestedPrice'].includes(key)) {
368
-                                this.saveEditField(key, this.tempValues[key], 'finance', key);
369
-                            } else if (['location', 'recoveryPerson', 'authenticationPerson'].includes(key)) {
370
-                                this.saveEditField(key, this.tempValues[key], 'trace', key);
371
-                            }
372
-                        }
373
-                    });
374
-                }
375
-            }
376
-        }
377
-    }
378
-</script>
379
-
380
-<style lang="scss" scoped>
381
-@import "./styles/detail.scss";
382
-</style>

+ 132 - 75
pages/wareHouse/index.vue

@@ -29,8 +29,8 @@
29 29
 			</view>
30 30
 
31 31
 			<view class="search-wrapper">
32
-				<u-search placeholder="搜索编号、名称、品牌..." bg-color="#f9fafb" border-radius="4rpx"
33
-					:show-action="false" class="search-input-wrap"></u-search>
32
+				<u-search placeholder="搜索编号、名称、品牌..." v-model="searchString" bg-color="#f9fafb" border-radius="4rpx"
33
+					:show-action="false" class="search-input-wrap" showAction @clear="handleSearch" @custom="handleSearch"></u-search>
34 34
 			</view>
35 35
 
36 36
 			<view class="category-tabs-wrap">
@@ -39,55 +39,56 @@
39 39
 			</view>
40 40
 
41 41
 			<view class="filter-bar">
42
-				<view class="sort-btn">
43
-					<text class="sort-text">{{ currentSortText }}</text>
42
+				<view class="sort-btn" @click="sortPickerShow = true">
43
+					<text class="sort-text">{{ curSortType.label }}</text>
44 44
 					<u-icon name="arrow-down" size="12" color="#666666" class="sort-icon"></u-icon>
45
+					<u-picker :show="sortPickerShow" :columns="sortColumns" keyName="label" @confirm="handleSortChange" @cancel="sortPickerShow = false"></u-picker>
45 46
 				</view>
46 47
 
47 48
 				<view class="price-layout-btn">
48
-					<view class="price-btn" type="text">
49
-						<u-icon name="eye" size="18" color="#1890ff" class="price-icon"></u-icon>
49
+					<view class="price-btn" type="text" @click="priceVisibleChange">
50
+						<u-icon :name="priceVisible ? 'eye' : 'eye-off'" size="18" color="#1890ff" class="price-icon"></u-icon>
50 51
 						<text class="price-text">价格可见</text>
51 52
 					</view>
52
-
53
-					<view class="layout-btn" type="text" size="mini">
53
+					<view class="layout-btn" type="text" size="mini" @click="openSearchFilter">
54 54
 						<u-icon name="grid" size="20" color="#666666"></u-icon>
55 55
 						<!-- 筛选列 品牌、价格范围、位置、回收时间、回收人员、鉴定人员、商品属性 -->
56 56
 					</view>
57
+					<searchFilter ref="searchFilter" @confirm="handleSearch"></searchFilter>
57 58
 				</view>
58 59
 			</view>
59 60
 
60
-			<view class="goods-list">
61
-				<view @click="handleToDetail" class="goods-item" v-for="(goods, goodsIndex) in goodsList" :key="`goods-${goodsIndex}`">
61
+			<scroll-view class="goods-list" scroll-y @scrolltolower="handleLoadMore" enable-back-to-top>
62
+				<view @click="handleToDetail(goods)" class="goods-item" v-for="(goods, goodsIndex) in goodsList" :key="`goods-${goodsIndex}`">
62 63
 					<view class="goods-img-container">
63 64
 						<image class="goods-img" :src="goods.imgUrl" mode="aspectFill" lazy-load></image>
64 65
 						<view class="stock-indicator"
65
-							v-if="goods.stock !== null && goods.stock !== undefined && goods.stock > 0"></view>
66
+							v-if="goods.stock > 0"></view>
66 67
 					</view>
67 68
 
68 69
 					<view class="goods-info">
69
-						<text class="goods-brand">{{ goods.brand || '' }}</text>
70
-						<text class="goods-name">{{ goods.name || '' }}</text>
70
+						<text class="goods-brand">{{ goods.name || '' }}</text>
71
+						<text class="goods-name">{{ goods.model || '' }}</text>
71 72
 
72 73
 						<view class="price-group">
73 74
 							<view class="price-items">
74 75
 								<view class="price-item">
75 76
 									<text class="price-type">成本价</text>
76
-									<text class="price">¥{{ goods.costPrice }}</text>
77
+									<text class="price">¥{{ priceVisible ? goods.costPrice : '****' }}</text>
77 78
 								</view>
78 79
 								<view class="price-item">
79 80
 									<text class="price-type">销售价</text>
80
-									<text class="price sales">¥{{ goods.salesPrice }}</text>
81
+									<text class="price sales">¥{{ priceVisible ? goods.salesPrice : '****' }}</text>
81 82
 								</view>
82 83
 							</view>
83 84
 							<view class="price-items">
84 85
 								<view class="price-item">
85 86
 									<text class="price-type">同行价</text>
86
-									<text class="price">¥{{ goods.peerPrice }}</text>
87
+									<text class="price">¥{{ priceVisible ? goods.peerPrice : '****' }}</text>
87 88
 								</view>
88 89
 								<view class="price-item">
89 90
 									<text class="price-type">代理价</text>
90
-									<text class="price">¥{{ goods.agentPrice }}</text>
91
+									<text class="price">¥{{ priceVisible ? goods.agentPrice : '****' }}</text>
91 92
 								</view>
92 93
 							</view>
93 94
 						</view>
@@ -99,13 +100,15 @@
99 100
 						</view>
100 101
 					</view>
101 102
 					<view class="more">
102
-						<u-icon name="more-dot-fill" size="16" color="#666666"></u-icon>
103
+						<view></view>
104
+						<!-- <u-icon name="more-dot-fill" size="16" color="#666666"></u-icon> -->
103 105
 						<text class="goods-stock"
104 106
 							v-if="goods.stock !== null && goods.stock !== undefined && goods.stock > 0">数量:{{ goods.stock
105 107
 							}}</text>
106 108
 					</view>
107 109
 				</view>
108
-			</view>
110
+				<show-emtry v-if="goodsList.length === 0"></show-emtry>
111
+			</scroll-view>
109 112
 			
110 113
 		</view>
111 114
 		<!-- 添加按钮 -->
@@ -117,9 +120,21 @@
117 120
 </template>
118 121
 
119 122
 <script>
123
+	import searchFilter from './components/searchFilter.vue'
120 124
 export default {
125
+	components: {
126
+		searchFilter,
127
+	},
121 128
 	data() {
122 129
 		return {
130
+			searchString:'',//搜索编号、名称、品牌...
131
+			searchInfo:{},
132
+			pageNum:1,
133
+			pageSize:10,
134
+			curSortType:{
135
+				id:4,
136
+				label: '按入库最新',
137
+			},
123 138
 			wareHouseCard:{
124 139
 				totalCost: '-',
125 140
 				uploadCostToday: '-',
@@ -127,83 +142,113 @@ export default {
127 142
 				totalNum: '-'
128 143
 			},
129 144
 			tabList: [
130
-				{ name: "全部" },
131
-				{ name: "腕表" },
132
-				{ name: "箱包" },
133
-				{ name: "珠宝" },
134
-				{ name: "鞋靴" },
135
-				{ name: "配饰" },
136
-				{ name: "服饰" },
137
-				{ name: "其它" }
145
+				{ name: "全部", id: 1 },
146
+				{ name: "腕表", id: 2 },
147
+				{ name: "箱包", id: 3 },
148
+				{ name: "珠宝", id: 4 },
149
+				{ name: "鞋靴", id: 5 },
150
+				{ name: "配饰", id: 6 },
151
+				{ name: "服饰", id: 7 },
152
+				{ name: "其它", id: 8 }
138 153
 			],
139
-			currentSortText: '按最近更新排序',
140 154
 			goodsList: [
155
+				// {
156
+				// 	id:'123456754',//商品库存id
157
+				// 	name:'Rolex',//商品名称
158
+				// 	model:'Submariner Date 126610LN',//型号
159
+				// 	costPrice:'12345',//成本价格
160
+				// 	salesPrice:'12345',//销售价格
161
+				// 	peerPrice:'12345',//同行价格
162
+				// 	agentPrice:'12345',//代理价格
163
+				// 	stock:'12345',//库存数量
164
+				// 	imgUrl:'https://xiaohulu-crm.oss-cn-shanghai.aliyuncs.com/crm/2026/01/06/1767677335839-1767677330379.jpg',//商品图片
165
+				// 	platform:[]//同步平台,此功能暂时不做,先定义一个字段
166
+				// }
167
+			],
168
+			sortPickerShow: false,
169
+			sortColumns: [[
141 170
 				{
142
-					imgUrl: require("./imgs/1.jpg"),
143
-					brand: "ROLEX",
144
-					name: "Submariner Date 126610LN",
145
-					costPrice: "92,500",
146
-					salesPrice: "89,000",
147
-					peerPrice: "92,500",
148
-					agentPrice: "89,000",
149
-					stock: 1
171
+					label:'按最久未下载',
172
+					id:1
150 173
 				},
151 174
 				{
152
-					imgUrl: require("./imgs/1.jpg"),
153
-					brand: "ROLEX",
154
-					name: "Submariner Date 126610LN",
155
-					costPrice: "92,500",
156
-					salesPrice: "89,000",
157
-					peerPrice: "92,500",
158
-					agentPrice: "89,000",
159
-					stock: 1
175
+					label:'按最近更新',
176
+					id:2
160 177
 				},
161 178
 				{
162
-					imgUrl: require("./imgs/1.jpg"),
163
-					brand: "ROLEX",
164
-					name: "Submariner Date 126610LN",
165
-					costPrice: "92,500",
166
-					salesPrice: "89,000",
167
-					peerPrice: "92,500",
168
-					agentPrice: "89,000",
169
-					stock: 1
179
+					label:'按最久更新',
180
+					id:3
170 181
 				},
171 182
 				{
172
-					imgUrl: require("./imgs/1.jpg"),
173
-					brand: "ROLEX",
174
-					name: "Submariner Date 126610LN",
175
-					costPrice: "92,500",
176
-					salesPrice: "89,000",
177
-					peerPrice: "92,500",
178
-					agentPrice: "89,000",
179
-					stock: 1
183
+					label:'按入库最新',
184
+					id:4
180 185
 				},
181 186
 				{
182
-					imgUrl: require("./imgs/1.jpg"),
183
-					brand: "ROLEX",
184
-					name: "Submariner Date 126610LN",
185
-					costPrice: "92,500",
186
-					salesPrice: "89,000",
187
-					peerPrice: "92,500",
188
-					agentPrice: "89,000",
189
-					stock: 1
190
-				}
191
-			]
187
+					label:'按入库最久',
188
+					id:5
189
+				},
190
+				{
191
+					label:'按价格最高',
192
+					id:6
193
+				},
194
+				{
195
+					label:'按价格最低',
196
+					id:7
197
+				},
198
+			]],
199
+			priceVisible:true,
200
+			searchPopShow:false,
201
+			total:0
192 202
 		};
193 203
 	},
194 204
 	methods: {
195
-		switchTab(index) {
196
-			console.log("当前选中标签索引:", index);
205
+		getList(){
206
+			uni.$u.api.wareHouseList({
207
+				pageNum: this.pageNum,
208
+				pageSize: this.pageSize,
209
+			},
210
+			{
211
+				searchString:this.searchString,
212
+				sortType:this.curSortType.id,
213
+				...this.searchInfo,
214
+			}).then(res => {
215
+				if(this.pageNum == 1){
216
+					this.goodsList = res.rows;
217
+				}else{
218
+					this.goodsList = this.goodsList.concat(res.rows);
219
+				}
220
+				this.total = res.total;
221
+			});
222
+		},
223
+		// 加载更多
224
+		handleLoadMore() {
225
+			console.log("加载更多");
226
+			if(this.goodsList.length >= this.total){
227
+				uni.$u.toast("没有更多了");
228
+				return;
229
+			}
230
+			this.pageNum++;
231
+			this.getList();
197 232
 		},
198
-		handleToDetail() {
233
+		handleSearch(info){
234
+			this.pageNum = 1;
235
+			this.searchInfo = info;
236
+			this.goodsList = [];
237
+			this.getList();
238
+		},
239
+		switchTab(item) {
240
+			this.searchInfo.category = item.id;
241
+			this.handleSearch();
242
+		},
243
+		handleToDetail(item) {
199 244
 			uni.navigateTo({
200
-				url: `/pages/wareHouse/detail`
245
+				url: `/pages/wareHouse/components/detail?id=${item.id}`,
201 246
 			});
202 247
 		},
203 248
 		handleAdd() {
204 249
 			console.log("点击添加按钮");
205 250
 			uni.navigateTo({
206
-				url: `/pages/wareHouse/add`
251
+				url: `/pages/wareHouse/components/add`
207 252
 			});
208 253
 		},
209 254
 		// 获取仓库卡片数据
@@ -214,9 +259,21 @@ export default {
214 259
 				}
215 260
 			});
216 261
 		},
262
+		handleSortChange(e){
263
+			this.curSortType = e.value[0];
264
+			this.sortPickerShow = false;
265
+			this.handleSearch();
266
+		},
267
+		priceVisibleChange(){
268
+			this.priceVisible = !this.priceVisible;
269
+		},
270
+		openSearchFilter(){
271
+			this.$refs.searchFilter.open();
272
+		},
217 273
 	},
218 274
 	mounted() {
219 275
 		this.getCard();
276
+		this.getList();
220 277
 	}
221 278
 };
222 279
 </script>

+ 5 - 0
pages/wareHouse/styles/add.scss

@@ -7,6 +7,11 @@
7 7
         background-color: #fff;
8 8
         padding: 0 20rpx;
9 9
         margin-bottom: 120rpx;
10
+        .btn_group_recognition{
11
+            padding-top:10rpx;
12
+            display: flex;
13
+            gap: 20rpx;
14
+        }
10 15
     }
11 16
 
12 17
 }

+ 40 - 25
pages/wareHouse/styles/detail.scss

@@ -36,7 +36,7 @@
36 36
     }
37 37
     
38 38
     // 立即下架按钮
39
-    .immediate-off-shelf {
39
+    .immediate_off_shelf {
40 40
         position: fixed;
41 41
         bottom: 130rpx;
42 42
         right: 20rpx;
@@ -78,7 +78,7 @@
78 78
     }
79 79
     
80 80
     // 轮播图下方操作按钮
81
-    .swiper-actions{
81
+    .swiper_actions{
82 82
         display: flex;
83 83
         justify-content: space-around;
84 84
         align-items: center;
@@ -86,7 +86,7 @@
86 86
         background-color: #ffffff;
87 87
         border-bottom: 1rpx solid #e8e8e8;
88 88
         
89
-        .action-item{
89
+        .action_item{
90 90
             display: flex;
91 91
             flex-direction: column;
92 92
             align-items: center;
@@ -96,7 +96,7 @@
96 96
                 border-radius: 20rpx;
97 97
                 padding:20rpx;
98 98
             }
99
-            .action-text{
99
+            .action_text{
100 100
                 margin-top: 16rpx;
101 101
                 font-size: 22rpx;
102 102
                 font-weight: 500;
@@ -107,7 +107,7 @@
107 107
     
108 108
     
109 109
     // 底部功能按钮栏
110
-    .bottom-bar{
110
+    .bottom_bar{
111 111
         position: fixed;
112 112
         bottom: 0;
113 113
         left: 0;
@@ -119,7 +119,7 @@
119 119
         justify-content: space-around;
120 120
         box-shadow: 0 -2rpx 10rpx rgba(0, 0, 0, 0.1);
121 121
         
122
-        .bar-item{
122
+        .bar_item{
123 123
             flex: 1;
124 124
             height: 100%;
125 125
             display: flex;
@@ -135,32 +135,37 @@
135 135
                 border-radius: 20rpx;
136 136
                 background-color: #ca8a04;
137 137
                 box-shadow: 0 10px 15px -3px #fef08a, 0 4px 6px -4px #fef08a;
138
-                .bar-text{
138
+                .bar_text{
139 139
                     margin-top: 0;
140 140
                     color: #ffffff;
141 141
                     font-size: 23rpx;
142 142
                 }
143 143
             }
144 144
             
145
-            .bar-text{
145
+            .bar_text{
146 146
                 margin-top: 8rpx;
147 147
                 font-size: 20rpx;
148 148
                 font-weight: 500;
149 149
                 color: #9ca3af;
150 150
                 line-height: 32rpx;
151 151
             }
152
+
153
+            &.disabled{
154
+                cursor: not-allowed;
155
+                opacity: 0.5;
156
+            }
152 157
         }
153 158
     }
154 159
     
155 160
     // 核心信息区域样式
156
-    .core-info {
161
+    .core_info {
157 162
         background-color: #ffffff;
158 163
         margin: 20rpx 20rpx 0 20rpx;
159 164
         padding: 30rpx;
160 165
         border-radius: 16rpx;
161 166
         box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
162 167
         
163
-        .section-title {
168
+        .section_title {
164 169
             font-size: 32rpx;
165 170
             font-weight: 600;
166 171
             color: #303133;
@@ -169,18 +174,18 @@
169 174
             border-bottom: 1rpx solid #e8e8e8;
170 175
         }
171 176
         
172
-        .info-row {
177
+        .info_row {
173 178
             display: flex;
174 179
             padding: 16rpx 0;
175 180
             
176
-            .info-label {
181
+            .info_label {
177 182
                 flex: 1;
178 183
                 color: #909399;
179 184
                 font-size: 28rpx;
180 185
                 line-height: 40rpx;
181 186
             }
182 187
             
183
-            .info-value {
188
+            .info_value {
184 189
                 flex: 2;
185 190
                 color: #303133;
186 191
                 font-size: 28rpx;
@@ -207,14 +212,14 @@
207 212
     }
208 213
     
209 214
     // 财务与价格区域样式
210
-    .finance-price {
215
+    .finance_price {
211 216
         background-color: #ffffff;
212 217
         margin: 20rpx 20rpx 0 20rpx;
213 218
         padding: 30rpx;
214 219
         border-radius: 16rpx;
215 220
         box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
216 221
         
217
-        .section-title {
222
+        .section_title {
218 223
             font-size: 32rpx;
219 224
             font-weight: 600;
220 225
             color: #303133;
@@ -223,7 +228,7 @@
223 228
             border-bottom: 1rpx solid #e8e8e8;
224 229
         }
225 230
         
226
-        .price-group {
231
+        .price_group {
227 232
             display: flex;
228 233
             justify-content: space-between;
229 234
             margin-bottom: 24rpx;
@@ -233,7 +238,7 @@
233 238
             }
234 239
         }
235 240
         
236
-        .price-item {
241
+        .price_item {
237 242
             flex: 1;
238 243
             display: flex;
239 244
             flex-direction: column;
@@ -248,13 +253,13 @@
248 253
             }
249 254
         }
250 255
         
251
-        .price-label {
256
+        .price_label {
252 257
             color: #909399;
253 258
             font-size: 24rpx;
254 259
             margin-bottom: 12rpx;
255 260
         }
256 261
         
257
-        .price-value {
262
+        .price_value {
258 263
             font-size: 36rpx;
259 264
             font-weight: 600;
260 265
             
@@ -277,14 +282,14 @@
277 282
     }
278 283
     
279 284
     // 溯源与位置区域样式
280
-    .traceability-location {
285
+    .traceability_location {
281 286
         background-color: #ffffff;
282 287
         margin: 20rpx;
283 288
         padding: 30rpx;
284 289
         border-radius: 16rpx;
285 290
         box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
286 291
         
287
-        .section-title {
292
+        .section_title {
288 293
             font-size: 32rpx;
289 294
             font-weight: 600;
290 295
             color: #303133;
@@ -293,18 +298,18 @@
293 298
             border-bottom: 1rpx solid #e8e8e8;
294 299
         }
295 300
         
296
-        .info-row {
301
+        .info_row {
297 302
             display: flex;
298 303
             padding: 16rpx 0;
299 304
             
300
-            .info-label {
305
+            .info_label {
301 306
                 flex: 1;
302 307
                 color: #909399;
303 308
                 font-size: 28rpx;
304 309
                 line-height: 40rpx;
305 310
             }
306 311
             
307
-            .info-value {
312
+            .info_value {
308 313
                 flex: 2;
309 314
                 color: #303133;
310 315
                 font-size: 28rpx;
@@ -341,7 +346,7 @@
341 346
             }
342 347
         }
343 348
         
344
-        .action-button {
349
+        .action_button {
345 350
             margin-top: 24rpx;
346 351
             text-align: center;
347 352
             
@@ -353,6 +358,16 @@
353 358
                 font-size: 24rpx;
354 359
                 padding: 34rpx 0;
355 360
             }
361
+            .log_list{
362
+                display: flex;
363
+                flex-direction: column;
364
+                gap:20rpx;
365
+                .log_item{
366
+                    display: flex;
367
+                    text-align: left;
368
+                    font-size:26rpx;
369
+                }
370
+            }
356 371
         }
357 372
     }
358 373
 }

+ 8 - 6
pages/wareHouse/styles/index.scss

@@ -5,9 +5,9 @@
5 5
 }
6 6
 .page-container {
7 7
   // padding: 8rpx 15rpx;
8
-  // background-color: #f9fafb;
9
-  // background-color: red;
10
-  min-height: 100vh;
8
+  background-color: #f9fafb;
9
+  // min-height: 100vh;
10
+  padding-bottom:20rpx;
11 11
 }
12 12
 .nav-bar{
13 13
   border-bottom: 1px solid #f7f6f6 !important;
@@ -238,10 +238,12 @@
238 238
   flex-direction: column;
239 239
   gap: 10rpx;
240 240
   background-color: #f9fafb;
241
-  padding: 8rpx 15rpx;
241
+  ::v-deep .uni-scroll-view{
242
+    height: calc(100vh - 850rpx);
243
+  }
242 244
   .goods-item {
243
-    
244
-    background-color: #ffffff;
245
+    margin: 10rpx 15rpx;
246
+    background-color: #fff;
245 247
     border-radius: 20rpx;
246 248
     padding: 20rpx;
247 249
     box-sizing: border-box;

+ 9 - 0
pages/wareHouse/styles/searchFilter.scss

@@ -0,0 +1,9 @@
1
+::v-deep .u-form{
2
+    margin-top: 66rpx;
3
+    padding: 20rpx 30rpx;
4
+}
5
+.btns{
6
+    display: flex;
7
+    gap:20rpx;
8
+    padding: 20rpx;
9
+}

+ 13 - 7
utils/api.js

@@ -3,7 +3,7 @@ import qs from 'qs';
3 3
 
4 4
 import store from "../store/index.js";
5 5
 import config from '../uni_modules/uview-ui/libs/config/config.js';
6
-
6
+const mockApi = 'http://192.168.0.243:3001/mock-api/prod-api/crm';
7 7
 
8 8
 const install = (Vue, vm) => {
9 9
 	vm.$u.api = {
@@ -119,12 +119,18 @@ const install = (Vue, vm) => {
119 119
 		// 服务器地址: http://192.168.0.243:3001
120 120
 		// 手机预览时需要使用电脑局域网IP,不能用localhost
121 121
 		// 切换真实接口时,将 baseUrl 改为真实接口地址即可
122
-		getPersonCards:(params)=>http.get('http://192.168.0.243:3001/mock-api/prod-api/crm/personCenter/getPersonCards',{ params }),//个人中心-获取个人中心数据
123
-		getPersonLatestClue:(params)=>http.get('http://192.168.0.243:3001/mock-api/prod-api/crm/personCenter/getPersonLatestClue',{ params }),//个人中心-获取最新线索
124
-		getPersonRanking:(params)=>http.get('http://192.168.0.243:3001/mock-api/prod-api/crm/personCenter/getPersonRanking',{ params }),//个人中心-获取个人排名
125
-		getWareHouseCard:(params)=>http.get('http://192.168.0.243:3001/mock-api/prod-api/crm/warehouse/getWareHouseCard',{ params }),//仓库中心-获取仓库信息
126
-		addInquiry:(data)=>http.post('http://192.168.0.243:3001/mock-api/prod-api/crm/inquiryCenter/addInquiry',data),//添加询价
127
-		inquiryVerificationList:(params,data)=>http.post('http://192.168.0.243:3001/mock-api/prod-api/crm/inquiryCenter/inquiryVerificationList?' + qs.stringify(params), data),//  询价/核价列表
122
+		getPersonCards:(params)=>http.get(mockApi+'/personCenter/getPersonCards',{ params }),//个人中心-获取个人中心数据
123
+		getPersonLatestClue:(params)=>http.get(mockApi+'/personCenter/getPersonLatestClue',{ params }),//个人中心-获取最新线索
124
+		getPersonRanking:(params)=>http.get(mockApi+'/personCenter/getPersonRanking',{ params }),//个人中心-获取个人排名
125
+		getWareHouseCard:(params)=>http.get(mockApi+'/warehouse/getWareHouseCard',{ params }),//仓库中心-获取仓库信息
126
+		addInquiry:(data)=>http.post(mockApi+'/inquiryCenter/addInquiry',data),//添加询价
127
+		inquiryVerificationList:(params,data)=>http.post(mockApi+'/inquiryCenter/inquiryVerificationList?' + qs.stringify(params), data),//  询价/核价列表
128
+		wareHouseList:(params,data)=>http.post(mockApi+'/warehouse/wareHouseList?' + qs.stringify(params), data),//仓库中心-获取仓库列表
129
+		wareHouseDetail:(params)=>http.get(mockApi+'/warehouse/wareHouseDetail',{ params }),//仓库中心-获取仓库详情
130
+		wareHouseLog:(params)=>http.get(mockApi+'/warehouse/wareHouseLog',{ params }),//仓库中心-获取仓库操作日志
131
+		wareHouseUpdate:(data)=>http.post(mockApi+'/warehouse/wareHouseUpdate',data),//仓库中心-编辑商品库存
132
+		wareHouseLock:(data)=>http.post(mockApi+'/warehouse/wareHouseLock',data),//仓库中心-锁单
133
+		wareHouseDown:(data)=>http.post(mockApi+'/warehouse/wareHouseDown',data),//仓库中心-下架
128 134
 
129 135
 
130 136