Преглед на файлове

Merge branch 'master' of http://git.cc-lotus.info/service-platform/web-test

wuhongyu преди 5 години
родител
ревизия
a2cee9f4ba
променени са 4 файла, в които са добавени 21 реда и са изтрити 13 реда
  1. 0 2
      src/layout/market/zhuanjia.vue
  2. 17 10
      src/views/dynamic/dealDetail.vue
  3. 1 0
      src/views/hall/dock/zhanjiaduijie.vue
  4. 3 1
      src/views/market/marketlists.vue

+ 0 - 2
src/layout/market/zhuanjia.vue

@@ -127,8 +127,6 @@ export default {
           obj.seller_id = this.zhuanjiainfo.userid;
           obj.seller_name = this.zhuanjiainfo.name;
         }
-        console.log(obj);
-
         let res = await this.create(obj);
         if (this.$checkRes(res)) {
           this.$set(this, `room`, res.data);

+ 17 - 10
src/views/dynamic/dealDetail.vue

@@ -63,6 +63,7 @@
 import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: transaction } = createNamespacedHelpers('transaction');
 const { mapActions: product } = createNamespacedHelpers('enterpriseproject');
+const { mapActions: expertsuser } = createNamespacedHelpers('expertsuser');
 export default {
   name: 'dealDetail',
   props: {},
@@ -83,6 +84,7 @@ export default {
   methods: {
     ...transaction(['fetch']),
     ...product({ list: 'newquery', newfetch: 'newfetch' }),
+    ...expertsuser({ expertsuserFetch: 'fetch' }),
     async search() {
       let res = await this.fetch(this.id);
       res.data.status = parseInt(res.data.status);
@@ -90,16 +92,21 @@ export default {
       this.$set(this, `dealDetails`, res.data);
     },
     async onclick() {
-      console.log(this.dealDetails);
-      // const res = await this.newfetch(this.id);
-      // console.log(res);
-      // if (res.data.totaltype == '0') {
-      //   this.$router.push({ path: '/market/marketlists', query: { totaltype: 0, id: this.dealDetails.product_id, column_name: '技术供求', display: 2 } });
-      // } else if (res.data.totaltype == '1') {
-      //   this.$router.push({ path: '/market/marketlists', query: { totaltype: 1, id: this.dealDetails.product_id, column_name: '科技产品', display: 2 } });
-      // } else if (res.data.totaltype == '2') {
-      //   this.$router.push({ path: '/market/marketlists', query: { totaltype: 2, id: this.dealDetails.product_id, display: 2, column_name: '科技产品' } });
-      // }
+      if (this.dealDetails.type == '0') {
+        let product_id = this.dealDetails.product_id;
+        const res = await this.newfetch(product_id);
+        if (res.data.totaltype == '0') {
+          this.$router.push({ path: '/market/marketlists', query: { totaltype: 0, id: product_id, column_name: '技术供求', display: 2 } });
+        } else if (res.data.totaltype == '1') {
+          this.$router.push({ path: '/market/marketlists', query: { totaltype: 1, id: product_id, column_name: '科技产品', display: 2 } });
+        } else if (res.data.totaltype == '2') {
+          this.$router.push({ path: '/market/marketlists', query: { totaltype: 2, id: product_id, column_name: '科技产品', display: 2 } });
+        }
+      } else {
+        let export_id = this.dealDetails.product_id;
+        const res = await this.expertsuserFetch(export_id);
+        this.$router.push({ path: '/market/marketlists', query: { id: export_id, column_name: '专家供求', display: 3 } });
+      }
     },
   },
   filters: {

+ 1 - 0
src/views/hall/dock/zhanjiaduijie.vue

@@ -199,6 +199,7 @@ export default {
       form.market_userid = this.detailInfo.id;
       form.market_username = this.detailInfo.name;
       form.status = '0';
+      form.type = '1';
       if (!this.user.uid) {
         this.$message.error('游客身份无法与卖家对话,请先注册');
         return;

+ 3 - 1
src/views/market/marketlists.vue

@@ -241,7 +241,7 @@ export default {
       } else {
       }
     },
-
+    // 专家
     async zjsubmit() {
       let form = {};
       form.userid = this.user.uid;
@@ -251,6 +251,7 @@ export default {
       form.market_userid = this.zhuanjiainfo.id;
       form.market_username = this.zhuanjiainfo.name;
       form.status = '0';
+      form.type = '1';
       if (!this.user.uid) {
         this.$message.error('游客身份无法与卖家对话,请先注册');
         return;
@@ -259,6 +260,7 @@ export default {
         this.$checkRes(res, '购买申请成功', res.errmsg || '购买申请失败');
       }
     },
+    // 技术产品服务
     async onSubmit() {
       let form = {};
       form.userid = this.user.uid;