guhongwei 3 роки тому
батько
коміт
53a2e555df
2 змінених файлів з 119 додано та 3 видалено
  1. 116 0
      src/layout/patentInfo/list-2.vue
  2. 3 3
      src/views/market/patentInfo/index.vue

+ 116 - 0
src/layout/patentInfo/list-2.vue

@@ -0,0 +1,116 @@
+<template>
+  <div id="list-2">
+    <van-row>
+      <van-col span="24" class="main">
+        <van-col span="24" class="list" v-for="(item, index) in list" :key="index">
+          <van-col span="24" class="title textOver">
+            {{ item.name }}
+          </van-col>
+          <van-col span="24" class="other">
+            <van-col span="24" class="otherInfo">
+              专利有效性:<span>{{ item.term || '暂无' }}</span>
+            </van-col>
+            <van-col span="24" class="otherInfo">
+              申请时间:<span>{{ item.create_date || '暂无' }}</span>
+            </van-col>
+          </van-col>
+          <van-col span="24" class="btn">
+            <van-button type="info" size="small" @click="toView(item)">详细信息</van-button>
+          </van-col>
+        </van-col>
+      </van-col>
+    </van-row>
+  </div>
+</template>
+<script>
+import { mapState, createNamespacedHelpers } from 'vuex';
+const moment = require('moment');
+export default {
+  name: 'list-2',
+  props: { list: { type: Array } },
+  components: {},
+  data: function () {
+    return {};
+  },
+  created() {},
+  methods: {
+    // 详细信息
+    toView(data) {
+      this.$emit('toView', data);
+    },
+    // 修改信息
+    toEdit(data) {
+      this.$emit('toEdit', data);
+    },
+    // 刪除信息
+    toDel(data) {
+      this.$emit('toDel', data);
+    },
+    // 国知局反馈信息
+    toGzj(data) {
+      this.$router.push({ path: '/patent/user/apply/apply/gzjDetail', query: { name: data.name, create_number: data.create_number } });
+    },
+    // 价值评估
+    toAssess(data) {
+      this.$router.push({ path: '/patent/user/apply/assessment', query: { id: data.id } });
+    },
+    // 专利交易
+    toTrans(data) {
+      this.$router.push({ path: '/patent/user/patent/information/trans_create', query: { id: data.id } });
+    },
+    // 过滤时间
+    getDate(val) {
+      let newDate = moment(val).format('YYYY-MM-DD');
+      if (newDate) return newDate;
+    },
+  },
+  computed: {
+    ...mapState(['user']),
+  },
+  metaInfo() {
+    return { title: this.$route.meta.title };
+  },
+  watch: {
+    test: {
+      deep: true,
+      immediate: true,
+      handler(val) {},
+    },
+  },
+};
+</script>
+
+<style lang="less" scoped>
+.main {
+  margin: 8px 0 0 0;
+  .list {
+    background-color: #fff;
+    margin: 0 0 10px 0;
+    box-shadow: 0 0 5px #f1f1f1;
+    padding: 8px;
+    .title {
+      font-size: 16px;
+      font-weight: bold;
+      margin: 0 0 5px 0;
+    }
+    .other {
+      margin: 0 0 5px 0;
+      .otherInfo {
+        font-size: 14px;
+        color: #666;
+        margin: 0 0 5px 0;
+        span {
+          color: #000;
+        }
+      }
+    }
+    .btn {
+      text-align: center;
+
+      .van-button {
+        margin: 0 10px 5px 10px;
+      }
+    }
+  }
+}
+</style>

+ 3 - 3
src/views/market/patentInfo/index.vue

@@ -7,7 +7,7 @@
           <span class="total">({{ total }})</span>
         </van-col>
         <van-col :span="24" class="two">
-          <list-1 :list="list" @toView="toView"></list-1>
+          <list-2 :list="list" @toView="toView"></list-2>
         </van-col>
       </template>
     </admin-frame>
@@ -20,7 +20,7 @@
 
 <script>
 import search1 from '@/layout/patentInfo/search-1.vue';
-import list1 from '@/layout/patentInfo/list-1.vue';
+import list2 from '@/layout/patentInfo/list-2.vue';
 import info1 from '@/layout/patentInfo/info-1.vue';
 import adminFrame from '@frame/src/components/mobile-frame/mobile-main.vue';
 import { mapState, createNamespacedHelpers } from 'vuex';
@@ -30,7 +30,7 @@ export default {
   props: {},
   components: {
     adminFrame,
-    list1,
+    list2,
     search1,
     info1,
   },