panhui 4 лет назад
Родитель
Сommit
a22f34772c
1 измененных файлов с 25 добавлено и 10 удалено
  1. 25 10
      src/main/comos/src/views/product/Search.vue

+ 25 - 10
src/main/comos/src/views/product/Search.vue

@@ -89,16 +89,31 @@ export default {
     },
     },
     methods: {
     methods: {
         beforeData() {
         beforeData() {
-            return {
-                query: {
-                    onShelf: true,
-                    type: this.type,
-                    source: this.source,
-                    minterId: this.minterId,
-                    del: false
-                },
-                search: this.search
-            };
+            if (this.source === 'TRANSFER') {
+                return {
+                    query: {
+                        onShelf: true,
+                        type: this.type,
+                        source: this.source,
+                        minterId: this.minterId,
+                        del: false,
+                        salable: true
+                    },
+                    search: this.search,
+                    sort: 'price,asc'
+                };
+            } else {
+                return {
+                    query: {
+                        onShelf: true,
+                        type: this.type,
+                        source: this.source,
+                        minterId: this.minterId,
+                        del: false
+                    },
+                    search: this.search
+                };
+            }
         }
         }
     },
     },
     activated() {
     activated() {