guhongwei 4 vuotta sitten
vanhempi
commit
0d6690599c

+ 2 - 0
src/store/index.js

@@ -13,6 +13,7 @@ import mechanism from '@common/src/store/mechanism';
 import code from '@common/src/store/code';
 import online from '@common/src/store/online';
 import policy from '@common/src/store/policy';
+import ticket from '@common/src/store/ticket';
 
 Vue.use(Vuex);
 
@@ -32,5 +33,6 @@ export default new Vuex.Store({
     online,
     code,
     policy,
+    ticket,
   },
 });

+ 62 - 9
src/views/service/index.vue

@@ -12,15 +12,20 @@
             </el-col>
           </el-col>
           <el-col :span="24" class="common two">
-            <el-col :span="12" class="left"
-              ><top topText="高企政策服务"></top>
+            <el-col :span="12" class="left">
+              <top topText="高企政策服务" :userMore="false"></top>
               <list type="1" :list="oneList"></list>
             </el-col>
-            <el-col :span="12" class="left"><top topText="创新劵服务"></top>创新劵服务</el-col>
+            <el-col :span="12" class="left"
+              ><top topText="创新劵服务" :userMore="false"></top>
+              <list type="2" :list="twoList"></list>
+            </el-col>
           </el-col>
           <el-col :span="24" class="common thr">
-            <el-col :span="12" class="left"><top topText="科技成果服务"></top>科技成果服务</el-col>
-            <el-col :span="12" class="left"><top topText="科技成果服务"></top>科技成果服务</el-col>
+            <el-col :span="24" class="left"
+              ><top topText="科技成果服务" :userMore="false"></top>
+              <list type="3" :list="thrList"></list>
+            </el-col>
           </el-col>
         </div>
       </el-col>
@@ -48,7 +53,7 @@ import { btnList } from './btnList.js';
 import { mapState, createNamespacedHelpers } from 'vuex';
 const { mapActions: organization } = createNamespacedHelpers('organization');
 const { mapActions: policy } = createNamespacedHelpers('policy');
-
+const { mapActions: ticket } = createNamespacedHelpers('ticket');
 export default {
   name: 'index',
   props: {},
@@ -67,6 +72,34 @@ export default {
       dialogType: undefined,
       // 高企政策服务-列表
       oneList: [],
+      // 创新券服务-列表
+      twoList: [
+        {
+          company: '22',
+        },
+        {
+          company: '十条数据',
+        },
+      ],
+      // 科技成果评价服务-列表
+      thrList: [
+        {
+          basic: {
+            achieve_name: '成果名称',
+            achieve_date: '2021-01-01 01:00:00',
+            achieve_type: '城固了捏',
+            achieve_form: '成果形式',
+          },
+        },
+        {
+          basic: {
+            achieve_name: '10条数据',
+            achieve_date: '2021-01-01 01:00:00',
+            achieve_type: '城固了捏',
+            achieve_form: '成果形式',
+          },
+        },
+      ],
     };
   },
   async created() {
@@ -74,11 +107,12 @@ export default {
   },
   methods: {
     ...policy({ policyQuery: 'query' }),
-    ...organization(['login']),
+    ...ticket({ ticketQuery: 'query' }),
+    ...organization(['login', 'fetch']),
     link(data) {
       const { type, name } = data;
       if (type == '1') {
-        console.log('1');
+        window.open('http://www.jlkjxm.com');
       } else if (type == '2') {
         this.dialog2 = true;
         this.dialogTitle = name;
@@ -88,7 +122,7 @@ export default {
         this.dialogTitle = name;
         this.dialogType = type;
       } else if (type == '4') {
-        window.location.href = 'http://broadcast.waityou24.cn/liveAchieve';
+        window.open('http://broadcast.waityou24.cn/liveAchieve');
       } else if (type == '5') {
         this.$router.push({ path: '/service/register', query: { type: type } });
       } else if (type == '6') {
@@ -122,6 +156,19 @@ export default {
       // 高企政策服务
       let res = await this.policyQuery({ skip, limit: 7, status: 1, ...info });
       if (this.$checkRes(res)) this.$set(this, `oneList`, res.data);
+      // res = await this.ticketQuery({ skip, limit: 7, ...info });
+      // if (this.$checkRes(res)) {
+      //   // for (const val of res.data) this.searchCompany(val);
+      //   // this.$set(this, `twoList`, res.data);
+      // }
+    },
+    // 查询企业详细信息
+    async searchCompany(data) {
+      let res = await this.fetch(data.user_id);
+      if (this.$checkRes(res)) {
+        data.company = res.data.name;
+        return data;
+      }
     },
   },
   computed: {
@@ -192,6 +239,12 @@ export default {
       margin: 0 0 10px 0;
     }
   }
+  .thr {
+    width: 100%;
+    .left {
+      width: 100%;
+    }
+  }
 }
 .dialog2 {
   .btn {

+ 115 - 2
src/views/service/parts/list.vue

@@ -3,7 +3,7 @@
     <el-row>
       <el-col :span="24" class="main">
         <el-col :span="24" class="one" v-if="type == '1'">
-          <el-col :span="24" class="list" v-for="(item, index) in list" :key="index">
+          <el-col :span="24" class="oneList" v-for="(item, index) in list" :key="index">
             <el-col :span="24" class="top">
               <el-col :span="20" class="company textOver">
                 {{ item.company }}
@@ -19,6 +19,39 @@
             </el-col>
           </el-col>
         </el-col>
+        <el-col :span="24" class="two" v-else-if="type == '2'">
+          <el-col :span="24" class="twoList" v-for="(item, index) in list" :key="index">
+            <el-col :span="24" class="top">
+              <el-col :span="20" class="company textOver">
+                {{ item.company }}
+              </el-col>
+              <el-col :span="4" class="date">
+                <!-- {{ getDate(item.meta) }} -->
+                2121-01-02
+              </el-col>
+            </el-col>
+          </el-col>
+        </el-col>
+        <el-col :span="24" class="thr" v-else-if="type == '3'">
+          <el-col :span="12" class="thrList" v-for="(item, index) in list" :key="index">
+            <el-col :span="24" class="name textOver">
+              {{ item.basic.achieve_name }}
+            </el-col>
+            <el-col :span="24" class="other">
+              <el-col :span="24" class="text textOver">
+                成果取得时间:<span>{{ item.basic.achieve_date }}</span>
+              </el-col>
+            </el-col>
+            <el-col :span="24" class="other">
+              <el-col :span="12" class="text textOver">
+                成果类别:<span>{{ item.basic.achieve_type }}</span>
+              </el-col>
+              <el-col :span="12" class="text textOver">
+                成果形式:<span>{{ item.basic.achieve_form }}</span>
+              </el-col>
+            </el-col>
+          </el-col>
+        </el-col>
       </el-col>
     </el-row>
   </div>
@@ -70,7 +103,45 @@ export default {
   .one {
     height: 430px;
     overflow: hidden;
-    .list {
+    .oneList {
+      padding: 8px 0;
+      border-bottom: 1px dashed #ccc;
+      .top {
+        margin: 0 0 5px 0;
+        .company {
+          font-size: 16px;
+        }
+        .date {
+          font-size: 16px;
+        }
+      }
+      .other {
+        .text {
+          font-size: 14px;
+          color: #666;
+          span {
+            color: #000;
+          }
+        }
+      }
+    }
+    .oneList:last-child {
+      border-bottom: none;
+    }
+    .oneList:hover {
+      cursor: pointer;
+      .top {
+        .company {
+          font-weight: bold;
+          color: #409eff;
+        }
+      }
+    }
+  }
+  .two {
+    height: 430px;
+    overflow: hidden;
+    .twoList {
       padding: 8px 0;
       border-bottom: 1px dashed #ccc;
       .top {
@@ -82,7 +153,33 @@ export default {
           font-size: 16px;
         }
       }
+    }
+    .twoList:last-child {
+      border-bottom: none;
+    }
+    .twoList:hover {
+      cursor: pointer;
+      .top {
+        .company {
+          font-weight: bold;
+          color: #409eff;
+        }
+      }
+    }
+  }
+  .thr {
+    height: 430px;
+    overflow: hidden;
+    .thrList {
+      padding: 5px 10px;
+      border-bottom: 1px dashed #ccc;
+      border-right: 1px dashed #ccc;
+      .name {
+        font-size: 16px;
+        margin: 0 0 5px 0;
+      }
       .other {
+        margin: 0 0 5px 0;
         .text {
           font-size: 14px;
           color: #666;
@@ -92,6 +189,22 @@ export default {
         }
       }
     }
+    .thrList:nth-child(2n) {
+      border-right: none;
+    }
+    .thrList:nth-child(9) {
+      border-bottom: none;
+    }
+    .thrList:nth-child(10) {
+      border-bottom: none;
+    }
+    .thrList:hover {
+      cursor: pointer;
+      .name {
+        font-weight: bold;
+        color: #409eff;
+      }
+    }
   }
 }
 </style>

+ 2 - 1
src/views/service/parts/top.vue

@@ -6,7 +6,7 @@
           <el-col :span="20" class="left">
             {{ topText }}
           </el-col>
-          <el-col :span="4" class="right">
+          <el-col :span="4" class="right" v-if="userMore">
             <el-link :underline="false" @click="more">MORE</el-link>
           </el-col>
         </el-col>
@@ -21,6 +21,7 @@ export default {
   name: 'top',
   props: {
     topText: { type: String },
+    userMore: { type: Boolean, default: true },
   },
   components: {},
   data: function () {