Browse Source

排序公用方法以及自定义栏位

zhuliu 1 year ago
parent
commit
9053bd6ae3

+ 32 - 0
src/api/newApi/common.js

@@ -78,4 +78,36 @@ export default {
   deleteCustomField(data) {
     return axios.post("/xiaoshi/customField/deleteCustomField", data);
   },
+  /**
+   * 新增自定义栏位选项
+   * @param {*} data 
+   * @returns 
+   */
+  addCustomOption(data) {
+    return axios.post("/xiaoshi/customOption/addCustomOption", data);
+  },
+  /**
+   * 查询自定义栏位选项
+   * @param {*} data 
+   * @returns 
+   */
+  queryCustomOption(data) {
+    return axios.post("/xiaoshi/customOption/queryCustomOption", data);
+  },
+  /**
+   * 更新自定义栏位选项
+   * @param {*} data 
+   * @returns 
+   */
+  updateCustomOption(data) {
+    return axios.post("/xiaoshi/customOption/updateCustomOption", data);
+  },
+  /**
+   * 删除自定义栏位选项
+   * @param {*} data 
+   * @returns 
+   */
+  deleteCustomOption(data) {
+    return axios.post("/xiaoshi/customOption/deleteCustomOption", data);
+  },
 };

+ 1 - 0
src/assets/css/main.scss

@@ -90,6 +90,7 @@
     background: var(--bg) !important;
     color: var(--color);
   }
+
   // .el-table tr td{
   //   border-bottom: 1px solid rgba(124,124,124) !important;
   // }

+ 33 - 29
src/router/index.js

@@ -35,7 +35,8 @@ const routes = [
         name: 'Home',
         meta: {
           title: '首页',
-          sign:'home'
+          sign:'home',
+          belong:'home'
         },
         component: () => import('@/views/home/index.vue'),
       },
@@ -50,29 +51,29 @@ const routes = [
             path:'/',
             meta: {
               title: '专题库',
-              sign:'project'
+              sign:'project',
+              belong:'project'
             },
             component: () => import('@/views/project/index.vue'),
           },
-      //     {
-      //       path: 'folder',
-      //       meta: {
-      //         // keepAlive: true,
-      //         title: '专利文件夹',
-      //         // button: ['a', 'b', 'c', 'd'],
-      //         showProjectName:true
-      //       },
-      //       component: () => import('@/views/workspace/folder/index.vue')
-      //     },
-      //     {
-      //       path: 'folder/:id',
-      //       meta: {
-      //         title: '专利文章',
-      //         // button: [],
-      //         showProjectName:true
-      //       },
-      //       component: () => import('@/views/workspace/folder/articles')
-      //     },
+          {
+            path: 'patentCollection',
+            meta: {
+              title: '专利列表',
+              sign:'patentCollection',
+              belong:'project'
+            },
+            component: () => import('@/views/project/patentCollection/index.vue')
+          },
+          // {
+          //   path: 'folder/:id',
+          //   meta: {
+          //     title: '专利文章',
+          //     // button: [],
+          //     showProjectName:true
+          //   },
+          //   component: () => import('@/views/workspace/folder/articles')
+          // },
         ],
       },
       //企业专利数据库
@@ -102,7 +103,8 @@ const routes = [
             path:'/',
             meta: {
               title: '专利挖掘',
-              sign:'patentMining'
+              sign:'patentMining',
+              belong:'patentMining'
             },
             component: () => import('@/views/patentMining/index.vue'),
           },
@@ -110,7 +112,6 @@ const routes = [
             path:'/details',
             meta: {
               title: '专利挖掘详情',
-              // allowPath:true
             },
             component: () => import('@/views/patentMining/components/details/index.vue'),
           },
@@ -118,7 +119,6 @@ const routes = [
             path:'/excavateTask',
             meta: {
               title: '专利挖掘任务',
-              // allowPath:true
             },
             component: () => import('@/views/patentMining/components/excavateTask/index.vue'),
           },
@@ -126,7 +126,6 @@ const routes = [
             path:'/handleExamine',
             meta: {
               title: '专利挖掘任务详情',
-              // allowPath:true
             },
             component: () => import('@/views/patentMining/components/handleExamine/index.vue'),
           },
@@ -143,7 +142,8 @@ const routes = [
             path:'/',
             meta: {
               title: '产品',
-              sign:'product'
+              sign:'product',
+              belong:'Product'
             },
             component: () => import('@/views/product/index.vue'),
           },
@@ -182,7 +182,7 @@ const routes = [
             meta: {
               title: '产品架构',
               sign: 'frameworkIndex',
-              button: [],
+              belong:'Product'
            },
            component: () => import('@/views/product/components/framework/index.vue'),
          
@@ -192,7 +192,7 @@ const routes = [
             meta: {
               title: '产品商品化专利',
               sign:'commodity',
-             button: [],
+              belong:'Product'
            },
            component: () => import('@/views/product/components/commodity/index.vue'),
          
@@ -212,6 +212,7 @@ const routes = [
             meta: {
               title: '事件',
               sign:'event',
+              belong:'Event'
             },
             component: () => import('@/views/event/index.vue'),
           }
@@ -228,7 +229,8 @@ const routes = [
             path:'/',
             meta: {
               title: '报告',
-              sign:'report'
+              sign:'report',
+              belong:'AllReport'
             },
             component: () => import('@/views/report/index.vue'),
           },
@@ -406,6 +408,7 @@ const routes = [
         meta: {
           title: '场景可视化',
           sign:'visual',
+          belong:'visual'
         },
         component: () => import('@/views/visual')
       },
@@ -415,6 +418,7 @@ const routes = [
         meta: {
           sign:'flowPath',
           title: '可视化平台',
+          belong:'visual'
         },
         component: () => import('@/views/visual/title/index.vue')
       },

+ 41 - 0
src/utils/common.js

@@ -125,5 +125,46 @@ export default {
       return []
     });
     return a
+  },
+
+  //获取排序字段(sortProp:{order})
+  getSortData({sort,column, prop, order,sortProp,defaultValue,multiple}){
+    var sortProp1 = sortProp || {
+      "orderBy": "orderBy",
+      "orderType": 'orderType'
+    }
+    if(multiple){
+      var sortData = sort
+    }else{
+      var sortData = []
+    }
+    if (order == null) {
+      if(defaultValue){
+        this.sort = [defaultValue]
+      }
+      this.sort = [
+        {
+          "orderBy": "createTime",
+          "orderType": 1
+        } 
+      ]
+    }else{
+      var orderType = {
+        ascending: 0,
+        descending: 1
+      }
+      var params = sortData.find(item => {
+        return item[sortProp1.orderBy] == prop
+      })
+      if (params) {
+        params[sortProp1.orderType] = orderType[order]
+      } else {
+        params = {}
+        params[sortProp1.orderBy] = prop
+        params[sortProp1.orderType] = orderType[order]
+        sortData.push(params)
+      }
+    }
+    return sortData
   }
 }

+ 64 - 44
src/views/components/drawer/Field.vue

@@ -25,21 +25,21 @@
             </el-table-column>
             <el-table-column label="状态" align="center" show-overflow-tooltip>
               <template slot-scope="scope">
-                <span>{{ statusObj[scope.row.status] }}</span>
+                <span>{{ statusObj.find(item=>item.value == scope.row.status).label }}</span>
               </template>
             </el-table-column>
             <el-table-column prop="createName" label="创建人" align="center" show-overflow-tooltip></el-table-column>
             <el-table-column prop="createTime" label="创建时间" align="center" show-overflow-tooltip>
               <template slot-scope="scope">
-                <span>{{ $d(scope.row.createTime) }}</span>
+                <span>{{ (scope.row.createTime) }}</span>
               </template>
             </el-table-column>
             <el-table-column prop="description" label="备注" align="center" show-overflow-tooltip></el-table-column>
             <el-table-column label="操作" align="center" width="150">
               <template slot-scope="scope">
                 <el-dropdown  split-button type="primary" size="small">
-                 <p @click="handleEdit(scope.row)" v-if="$permission('/workspace/common/customField/modify')">编辑</p>
-                 <p v-else :disabled="true">编辑</p>
+                 <span @click="handleEdit(scope.row)" v-if="$permission('/workspace/common/customField/modify')">编辑</span>
+                 <span v-else :disabled="true">编辑</span>
                   <el-dropdown-menu slot="dropdown" class="text-align_center">
                     <el-dropdown-item @click.native="handleEditOption(scope.row)" v-if="[3, 4, 5, 6].indexOf(scope.row.type) !== -1 && $permission('/workspace/common/customField/managementOptions')">选项管理</el-dropdown-item>
                     <el-dropdown-item v-else-if="[3, 4, 5, 6].indexOf(scope.row.type) !== -1" type="primary" size="small" @click.native="handleEditOption(scope.row)">选项查看</el-dropdown-item>
@@ -51,12 +51,12 @@
               </template>
             </el-table-column>
           </el-table>
-          <div class="pagination">
-            <el-pagination :current-page.sync="queryParams.current" :page-size="queryParams.size" :total="total" @current-change="handleCurrentChange" layout="total, prev, pager, next, jumper" background></el-pagination>
-          </div>
+          
         </el-main>
-        <el-footer class="footer-common">
-          <el-button @click="close">关 闭</el-button>
+        <el-footer class="pagination">
+          <!-- <div class="pagination"> -->
+            <el-pagination :current-page.sync="queryParams.current" :page-size="queryParams.size" :total="total" @current-change="handleCurrentChange" layout="total, prev, pager, next, jumper" background></el-pagination>
+          <!-- </div> -->
         </el-footer>
       </el-container>
     </el-drawer>
@@ -68,12 +68,12 @@
         </el-form-item>
         <el-form-item label="字段类型" prop="type">
           <el-select v-model="ruleForm.type" placeholder="请选择字段类型" class="width_100">
-            <el-option v-for="(item, key) in typeObj" :label="item" :value="parseInt(key)"></el-option>
+            <el-option v-for="(item, key) in typeObj" :key="key" :label="item" :value="parseInt(key)"></el-option>
           </el-select>
         </el-form-item>
         <el-form-item label="字段状态" prop="status">
           <el-select v-model="ruleForm.status" placeholder="请选择字段状态" style="width: 100%;">
-            <el-option v-for="(item, key) in statusObj" :label="item" :value="parseInt(key)"></el-option>
+            <el-option v-for="(item, key) in statusObj" :key="key" :label="item.label" :value="item.value"></el-option>
           </el-select>
         </el-form-item>
         <el-form-item label="备注" prop="description">
@@ -126,8 +126,8 @@
       </div>
     </el-dialog>
 
-    <import-field-dialog ref="importFieldDialog" @close="getList" />
-    <copy-field-dialog ref="copyFieldDialog" @close="getList" />
+    <!-- <import-field-dialog ref="importFieldDialog" @close="getList" />
+    <copy-field-dialog ref="copyFieldDialog" @close="getList" /> -->
   </div>
 </template>
 
@@ -175,10 +175,16 @@ export default {
         1: '标引',
         2: '分类'
       },
-      statusObj: {
-        0: '关闭',
-        1: '正常',
-      },
+      statusObj: [
+        {
+          label:'关闭',
+          value:false
+        },
+        {
+          label:"正常",
+          value:true
+        }
+      ],
       drawer: false,
       dialogVisible: false,
       dialogVisible2: false,
@@ -226,7 +232,7 @@ export default {
         projectId: this.projectId,
         name: '',
         type: 6,
-        status: 1,
+        status: true,
         description: '',
         option: []
       }
@@ -245,8 +251,8 @@ export default {
       this.title = '选项管理'
       this.dialogVisible2 = true
       let params = {
-        fieldId: this.ruleForm.id,
-        type: this.ruleForm.type
+        customFieldId: this.ruleForm.id,
+        // type: this.ruleForm.type
       }
       if (this.ruleForm.type === 6) {
         this.optionDialogWidth = '600px'
@@ -254,8 +260,8 @@ export default {
         this.optionDialogWidth = '500px'
       }
       this.optionLoading = true
-      this.$api.getProjectFieldOptionList(params).then(response => {
-        this.$set(this.ruleForm, 'option', response.data)
+      this.$api.queryCustomOption(params).then(response => {
+        this.$set(this.ruleForm, 'option', response.data.data)
         this.optionLoading = false
       }).catch(error => {
         this.optionLoading = false
@@ -269,7 +275,7 @@ export default {
         return false
       }
       this.optionLoading = true
-      this.$api.deleteProjectFieldOption({ id: item.id, type: this.ruleForm.type }).then(response => {
+      this.$api.deleteCustomOption({ id: item.id, type: this.ruleForm.type }).then(response => {
         this.ruleForm.option.splice(index, 1)
         this.$message.success('操作成功')
         this.optionLoading = false
@@ -307,7 +313,7 @@ export default {
         return false
       }
       this.optionLoading = true
-      this.$api.deleteProjectFieldOption({ id: data.id, type: this.ruleForm.type }).then(response => {
+      this.$api.deleteCustomOption({ id: data.id, type: this.ruleForm.type }).then(response => {
         children.splice(children.findIndex(d => d.id === data.id), 1)
         this.$message.success('操作成功')
         this.optionLoading = false
@@ -348,21 +354,34 @@ export default {
       let data = {
         id: item.id,
         name: item.name,
-        fieldId: this.ruleForm.id,
+        customFieldId: this.ruleForm.id,
         type: this.ruleForm.type,
         parentId: item.parentId,
         order: item.order,
       }
       this.optionLoading = true
-      this.$api.updateProjectFieldOption(data).then(response => {
-        this.$set(item, 'id', response.data)
-        this.$message.success('操作成功')
-        this.optionLoading = false
-        this.lockOption = false
-        this.valueChange = false
-      }).catch(error => {
-        this.optionLoading = false
-      })
+      if(!item.id){
+        this.$api.addCustomOption(data).then(response => {
+          this.$set(item, 'id', response.data)
+          this.$message.success('操作成功')
+          this.optionLoading = false
+          this.lockOption = false
+          this.valueChange = false
+        }).catch(error => {
+          this.optionLoading = false
+        })
+      }else{
+        this.$api.updateCustomOption(data).then(response => {
+          // this.$set(item, 'id', response.data)
+          this.$message.success('操作成功')
+          this.optionLoading = false
+          this.lockOption = false
+          this.valueChange = false
+        }).catch(error => {
+          this.optionLoading = false
+        })
+      }
+      
     },
     handleAddOption() {
       if (this.ruleForm.type === 6) {
@@ -382,12 +401,13 @@ export default {
     },
     getList() {
       this.loading = true
-      // var params = {
-      //   ...this.queryParams,
-      //   searchQuery:this.$commonJS.
-      // }
-      this.$api.queryCustomField(this.queryParams).then(response => {
-        this.tableData = response.data.records
+      var params = {
+        ...this.queryParams,
+        searchQuery:this.$commonJS.objectToString(this.searchOption),
+        orderDTOList: this.sort,
+      }
+      this.$api.queryCustomField(params).then(response => {
+        this.tableData = response.data.data
         this.total = response.data.total
         this.loading = false
       }).catch(error => {
@@ -479,10 +499,10 @@ export default {
 
 <style lang="scss">
 .project-field {
-  .pagination {
-    text-align: center;
-    margin: 20px 0;
-  }
+  // .pagination {
+  //   text-align: center;
+  //   margin: 20px 0;
+  // }
   .project-field-header-form {
     margin-left: 20px;
   }

+ 11 - 11
src/views/layout/components/UserBar.vue

@@ -1,9 +1,9 @@
 <template>
   <div class="admin-user-bar">
     <div class="menu">
-      <el-link :underline="true" v-for="item in menu" :key="item.path" @click="changePage(item.path)" :type="item.sign==sign?'primary':'default'">{{ item.label }}</el-link>
+      <el-link :underline="true" v-for="item in menu" :key="item.path" @click="changePage(item.path)" :type="item.belong==belong?'primary':'default'">{{ item.label }}</el-link>
       <el-dropdown @command="importPatent">
-        <el-link :underline="true" :type="sign == '专利检索'?'danger':'default'" class="el-dropdown-link">
+        <el-link :underline="true" :type="belong == 'conditionImport'?'danger':'default'" class="el-dropdown-link">
           专利检索<i class="el-icon-arrow-down el-icon--right"></i>
           </el-link>
         <el-dropdown-menu slot="dropdown">
@@ -146,43 +146,43 @@ export default {
           value:'5',
           label:'场景可视化',
           path:'/visual',
-          sign:'visual'
+          belong:'visual'
         },
         {
           value:'3',
           label:'事件',
           path:'/Event',
-          sign:'event'
+          belong:'event'
         },
         {
           value:'1',
           label:'专利数据库',
           path:'/project',
-          sign:'project'
+          belong:'project'
         },
         {
           value:'4',
           label:'报告',
           path:'/AllReport',
-          sign:'report'
+          belong:'report'
         },
         {
           value:'2',
           label:'产品',
           path:'/product',
-          sign:'product'
+          belong:'product'
         },
         {
           value:'6',
           label:'专利挖掘',
           path:'/patentMining',
-          sign:'patentMining'
+          belong:'patentMining'
         },
         {
           value:'8',
           label:'我的任务',
           path:'/rTaskList',
-          sign:'task'
+          belong:'task'
         },
       ],
       clientTitle:'',
@@ -216,8 +216,8 @@ export default {
   },
   computed: {
     ...mapGetters(['userinfo']),
-    sign(){
-      return this.$route.meta.sign
+    belong(){
+      return this.$route.meta.belong
     }
   },
   mounted() {

+ 1 - 1
src/views/layout/index.vue

@@ -143,7 +143,7 @@ export default {
 <style lang="scss" scoped>
 #work-platform {
   width: 100%;
-  min-width: 1024px;
+  min-width: 1200px;
   height: 100%;
 
   .header {

+ 11 - 9
src/views/project/components/mixins/index.js

@@ -19,15 +19,17 @@ export const workspaceOptions = {
   },
   methods: {
     renderSize,
-    handleClick(row) {
-      const router = this.$router.resolve({
-        path: '/workspace/folder',
-        query: {
-          id: row.id,
-        }
-      })
-      this.$s.setSession('projectName', row.name)
-      window.open(router.href, '_blank');
+    handleClick(row,key) {
+      if(key == 'name'){
+        const router = this.$router.resolve({
+          path: '/project/patentCollection',
+          query: {
+            id: row.id,
+          }
+        })
+        window.open(router.href, '_blank');
+      }
+      
     },
     //操作列
     handleCommand(event, row) {

+ 3 - 6
src/views/project/components/view/table.vue

@@ -9,10 +9,10 @@
           </template>
         </el-table-column>
 
-        <el-table-column v-for="item in column.filter(item=>!item.ifHidden)" :key="item.value" :prop="item.value" :label="item.name" sortable="custom" align="center">
+        <el-table-column v-for="item in column.filter(item=>!item.ifHidden)"  :key="item.value" :prop="item.value" :label="item.name" sortable="custom" align="center">
           <template slot-scope="scope">
             <div v-if="['name', 'eventNumber', 'projectNumber'].includes(item.value)">
-              <el-link @click="handleItem(scope.row, item.value)">{{ scope.row[item.value] }}</el-link>
+              <el-link @click="handleClick(scope.row, item.value)">{{ scope.row[item.value] }}</el-link>
             </div>
             <div v-else v-html="$commonJS.getColumnData(scope.row, item)"></div>
           </template>
@@ -234,10 +234,7 @@ export default {
       this.tableData.splice(0)
       this.getList()
     },
-    // 点击名称等事件
-    handleItem(row, key) {
-      // console.log(row,key);
-    },
+
 
 
 

+ 6 - 18
src/views/project/index.vue

@@ -312,25 +312,13 @@ export default {
     },
     //排序
     handleSort({ column, prop, order, str }) {
-      this.sort = []//如需要多个字段排序,则不需要清空
-      if (order == null) {
-        return;
-      }
-      var orderType = {
-        ascending: 0,
-        descending: 1
-      }
-      var params = this.sort.find(item => {
-        return item.orderBy == prop
-      })
-      if (params) {
-        params.orderType = orderType[order]
-      } else {
-        params = {}
-        params.orderBy = prop
-        params.orderType = orderType[order]
-        this.sort.push(params)
+      var params = {
+        sort:this.sort,
+        column,
+        prop,
+        order,
       }
+      this.sort = this.$commonJS.getSortData(params)//如需要多个字段排序,则不需要清空
       this.queryParams.current = 1
       //1表示展开行2表示基础表格
       if (str == '1') {

+ 11 - 11
src/views/project/patentCollection/components/views/Table.vue

@@ -13,9 +13,9 @@
         :cell-class-name="cellClassName"
     >
       <el-table-column width="80" align="center">
-        <template slot="header">
+        <!-- <template slot="header">
           <patent-table-view-sort prop="id" @on-sort="onSort" />
-        </template>
+        </template> -->
         <template slot-scope="scope">
           <div v-if="refresh">
             <el-checkbox :label="scope.row.id" @change="changeSelect(scope.row)" :checked="selected.indexOf(scope.row.id) !== -1 || patentNoList.indexOf(scope.row.patentNo)!== -1 || patentNoList.indexOf(scope.row.applicationNo)!== -1 ">
@@ -25,9 +25,9 @@
         </template>
       </el-table-column>
       <el-table-column label="专利号" show-overflow-tooltip align="center" width="180">
-        <template slot="header">
+        <!-- <template slot="header">
           <patent-table-view-sort title="专利号" prop="patentNo" @on-sort="onSort" />
-        </template>
+        </template> -->
         <template slot-scope="scope">
           <el-popover placement="right-start" width="500" trigger="hover" >
             <table class="patent-popover-table" >
@@ -61,9 +61,9 @@
         </template>
       </el-table-column>
       <el-table-column v-for="column in columnList" :label="column.name" show-overflow-tooltip align="center">
-        <template slot="header">
+        <!-- <template slot="header">
           <patent-table-view-sort :title="column.name" :prop="column.key" :projectId="projectId" @on-sort="onSort" />
-        </template>
+        </template> -->
         <template slot-scope="scope">
           <div style="" v-for="data in getColumnValue(scope.row, column)">
             <template v-if="column.key === 'name'">
@@ -93,15 +93,15 @@
 </template>
 
 <script>
-import { commonMixins } from "../../articles/components/mixins"
-import { patentViewList, patentKeywordsHighlight } from '../mixins'
-import PatentTableViewSort from "./TableSort";
+// import { commonMixins } from "../../articles/components/mixins"
+// import { patentViewList, patentKeywordsHighlight } from '../mixins'
+// import PatentTableViewSort from "./TableSort";
 
 export default {
   props: ['viewField'],
-  mixins: [patentViewList, patentKeywordsHighlight,commonMixins],
+  // mixins: [patentViewList, patentKeywordsHighlight,commonMixins],
   components: {
-    PatentTableViewSort
+    // PatentTableViewSort
   },
   data() {
     return {

+ 396 - 4
src/views/project/patentCollection/index.vue

@@ -1,20 +1,412 @@
 <template>
-  <div></div>
+  <div>
+    <el-container>
+      <el-aside width="200px">Aside</el-aside>
+      <el-container>
+        <el-header style="display:flex;justify-content:space-between">
+            <div style="display:flex">
+                <el-tooltip class="item" effect="dark" :content="(showLeft ? '隐藏' : '显示') + '左侧菜单'" placement="top">
+                    <i :class="showLeft ? 'el-icon-s-fold' : 'el-icon-s-unfold'" style="font-size: 25px;position: relative; top: 5px; color: #2f2f2f; cursor: pointer" @click="showLeft = !showLeft"></i>
+                </el-tooltip>
+                <mySearch :SearchFields="searchFiled" @search="search" :searchValue="searchOption"></mySearch>
+                <el-popover placement="bottom" title="关键词高亮" width="320" trigger="click">
+                    <!-- <patent-keywords-highlight :project-id="projectId" /> -->
+                    <el-button slot="reference" size="small" type="primary" class="margin-right_10 margin-left_10" :disabled="!$permission('/workspace/common/highlight')">
+                    高亮<i class="el-icon-arrow-down el-icon--right"></i>
+                    </el-button>
+                </el-popover>
+            </div>
+            <div>
+                <el-button-group class="margin-left_10">
+                    <el-tooltip v-for="item in viewList" :key="item.value" class="item" effect="dark" :content="item.title" placement="top">
+                    <el-button @click="handleChangeView(item)" size="small" :type="viewSelected === item.value ? 'primary' : ''" >
+                        <i :class="item.btn" style="font-size: 12px !important;"></i>
+                        </el-button>
+                    </el-tooltip>
+                </el-button-group>
+                <el-dropdown trigger="click" split-button type="primary" size="small">
+                    <span @click="handleField" v-disabled="!($permission('/workspace/common/customField') && $r(projectId,[1,2]))">自定义栏位管理</span>
+                    <el-dropdown-menu slot="dropdown" class="text-align_center">
+                    <el-dropdown-item @click.native="handleFile">报告文档</el-dropdown-item>
+                    <el-dropdown-item @click.native="handleQuestion" v-if="$permission('/workspace/event')">事 件</el-dropdown-item>
+                    <el-dropdown-item @click.native="handleFieldManage">显示栏位管理</el-dropdown-item>
+                    <el-dropdown-item @click.native="exportPDF">导出PDF首页</el-dropdown-item>
+                    <el-dropdown-item @click.native="handleBatch" :disabled="!($permission('/workspace/folder/batchUploadSpecification') && $r(projectId,[1,2]))">批量上传说明书</el-dropdown-item>
+                    <el-dropdown-item>
+                        <el-dropdown trigger="hover" placement="right-start">
+                            <span>
+                            导出专利<i class="el-icon-arrow-right el-icon--right"></i>
+                            </span>
+                            <el-dropdown-menu slot="dropdown">
+                            <el-dropdown-item @click.native="handleExport(false)">当前全部</el-dropdown-item>
+                            <el-dropdown-item @click.native="handleExport(true)">当前所选</el-dropdown-item>
+                            </el-dropdown-menu>
+                        </el-dropdown>
+                    </el-dropdown-item>
+                    <el-dropdown-item>
+                        <el-dropdown  trigger="hover" placement="right-start">
+                        <span>
+                            {{ familyObj[queryParams.family] }}<i class="el-icon-arrow-right el-icon--right"></i>
+                        </span>
+                        <el-dropdown-menu slot="dropdown">
+                            <el-dropdown-item v-for="(item, key) in familyObj" :key="key" @click.native="onChangeFamily(key)">{{ item }}</el-dropdown-item>
+                        </el-dropdown-menu>
+                        </el-dropdown>
+                    </el-dropdown-item>
+                    <el-dropdown-item :disabled="!$permission('/workspace/folder/merge')">
+                        <el-dropdown trigger="hover" placement="right-start">
+                        <span >
+                            合并<i class="el-icon-arrow-right el-icon--right"></i>
+                        </span>
+                        <el-dropdown-menu slot="dropdown">
+                            <el-dropdown-item @click.native="handleMerge2" :disabled="!($permission('/workspace/folder/merge/inventorMerge') && $r(projectId,[1,2]))">发明人</el-dropdown-item>
+                            <el-dropdown-item @click.native="handleMerge" :disabled="!($permission('/workspace/folder/merge/applicationMerge') && $r(projectId,[1,2]))">申请人/权利人</el-dropdown-item>
+                        </el-dropdown-menu>
+                        </el-dropdown>
+                    </el-dropdown-item>
+                    <el-dropdown-item v-if="$permission('/workspace/createReport')">
+                        <el-dropdown trigger="hover" placement="right-start">
+                        <span>
+                            创建报告<i class="el-icon-arrow-right el-icon--right"></i>
+                        </span>
+                        <el-dropdown-menu slot="dropdown" style="margin-top:0px">
+                            <!-- 遍历按钮 -->
+                            <el-dropdown-item  @click.native="handleAnalyses(3)" v-if="$permission('/workspace/createReport/FTO')">FTO调查</el-dropdown-item>
+                            </el-dropdown-menu>
+                        </el-dropdown>
+                    </el-dropdown-item>
+                    <el-dropdown-item @click.native="handleAnalyse('custom')" :disabled="!($permission('/workspace/folder/analyticSystem/chartAnalysis') && $r(projectId,[1,2,4]))">图表分析</el-dropdown-item>
+                    </el-dropdown-menu>
+                </el-dropdown>
+            </div>
+            
+        </el-header>
+        <el-main v-loading="loading">
+            <div>
+              <component
+                  ref="patentViewList"
+                  :is="viewSelected"
+                  @download="handleDownload"
+                  @change-read="handleChangeRead"
+                  @select-change="handleSelect"
+                  :projectId="projectId"
+                  :selected.sync="queryParams.selected"
+                  :patentNoList.sync="patentNoList"
+                  :view-field="customList"
+                  @index-setting="handleIndexSetting"
+                  @on-sort="handleSort"
+                  :queryParams="queryParams"
+              ></component>
+            </div>
+        </el-main>
+        <el-footer>
+            <el-pagination
+                background
+                layout="total, sizes, prev, pager, next, jumper"
+                :current-page.sync="queryParams.current"
+                :page-sizes="sizeArr"
+                :page-size.sync="queryParams.size"
+                @current-change="handleCurrentChange"
+                @size-change="getList"
+                :total="total">
+            </el-pagination>
+        </el-footer>
+      </el-container>
+    </el-container>
+  </div>
 </template>
 
 <script>
+import { downLoad2, getTreeDataList, getTreeLastChildren, getPatentCountry } from "@/utils"
+
+// import PatentAbstractListView from './components/views/Abstract'
+import PatentTableListView from './components/views/Table'
+// import PatentPictureListView from './components/views/Picture'
+// import PatentPDFListView from './components/views/PDF.vue'
 export default {
-  components: {},
+  components: {
+    // PatentAbstractListView,
+    PatentTableListView,
+    // PatentPictureListView
+  },
   props: {},
   data() {
     return {
+        //是否隐藏左侧
+        showLeft:false,
+        //检索字段
+        searchFiled: [
+            {
+            label: "项目名称",
+            value: "name",
+            type: 1,
+            placeholder: "请输入项目名称",
+            },
+            {
+            label: "技术主题",
+            value: "technicalTheme",
+            type: 1,
+            placeholder: "请输入技术主题",
+            },
+            {
+            label: "负责部门",
+            value: "departmentId",
+            type: 3,
+            placeholder: "请选择负责部门",
+            },
+            {
+            label: "内部案卷",
+            value: "innerFile",
+            type: 1,
+            placeholder: "请输入内部案卷",
+            },
+        ],
+        //检索条件
+        searchOption: {
+            name: localStorage.searchContent,
+        },
+        //专题库ID
+        projectId:0,
+        //视图方式
+        viewList: [
+            {
+                value: 'patent-table-list-view',
+                title: '表格视图',
+                btn: 'el-icon-tickets',
+            },
+            {
+                value: 'patent-abstract-list-view',
+                title: '摘要视图',
+                btn: 'el-icon-news',
+            },
+            {
+                value: 'patent-picture-list-view',
+                title: '图片视图',
+                btn: 'el-icon-picture-outline',
+            },
+            {
+                value:'PatentPDFListView',
+                title: 'PDF视图',
+                btn: 'iconfont icon-pdf',
+            }
+        ],
+        //选择的视图
+        viewSelected:"patent-table-list-view",
+        //显示栏位
+        customList:[],
+        //同族
+        familyObj: {
+            0: '不区分同族',
+            1: '简单同族',
+            2: 'INPADOC同族',
+            3: '扩展同族',
+        },
+        //页大小
+        sizeArr:[10, 20, 30, 40, 50, 100],
+        //分页
+        queryParams:{
+            current:1,
+            size:10
+        },
+        //总数
+        total:0,
+        //排序
+        sort:[
+            {
+                "orderBy": "createTime",
+                "orderType": 1
+            }
+        ],
+        //选择的专利集合
+        patentNoList:[],
+        //加载
+        loading:false,
     };
   },
   watch: {},
   computed: {},
   created() {},
-  mounted() {},
-  methods: {},
+  async mounted() {
+    this.customList = await this.$commonJS.getCustomField('reportProject')
+  },
+  methods: {
+    //检索
+    search(val){
+        
+    },
+    //切换视图
+    async handleChangeView(item) {
+      this.viewSelected = item.value
+      this.queryParams.current = 1
+      if(this.viewSelected == 'PatentPDFListView'){
+        return false
+      }
+      if (this.viewSelected === 'patent-picture-list-view') {
+        
+        this.$set(this.queryParams,'size',20)
+      } else {
+        this.queryParams.size = 10
+      }
+      this.getList()
+    },
+    //获取专利信息
+    getList(){
+
+    },
+    //排序
+    handleSort(data) {
+      this.queryParams.sort = data
+      this.getList()
+    },
+    //分页
+    handleCurrentChange(val) {
+      this.queryParams.current = val;
+      this.getList();
+    },
+    //自定义栏位管理
+    handleField() {
+      this.$refs.projectFieldDrawer.open(this.projectId)
+    },
+    //显示栏位管理
+    async handleFieldManage() {
+      this.$refs.patentViewField.open(this.patentViewField, this.projectId, this.viewSelected)
+    },
+    //批量上传说明书
+    handleBatch() {
+      this.$refs.batchInstructionDialog.open()
+    },
+    //报告文档
+    handleFile() {
+      this.$refs.projectFileDrawer.open(this.projectId, 1)
+    },
+    // 事件按钮
+    handleQuestion() {
+      let a=this.$router.resolve({
+        path: '/questionEvent',
+        query: {
+          projectId:this.projectId
+        }
+      })
+      window.open(a.href, '_blank');
+    },
+    //PDF首页导出
+    exportPDF(){
+      let params = JSON.parse(JSON.stringify(this.queryParams))
+      params.tree.map(tree => {
+        let field = params.field.filter(item => item.key === tree.key)
+        if (field.length === 0) {
+          params.field.push(tree)
+        }
+      })
+      params.tree = undefined
+      this.$api.pdfFirstPage(params).then(response=>{
+        if(response.code == 200){
+          const router = this.$router.resolve({
+            path: '/taskList',
+            query: {
+              projectId:this.projectId,
+            }
+          })
+          window.open(router.href,'_blank')
+        }
+      })
+    },
+    //导出专利
+    async handleExport(selectId) {
+      this.exportLoading = true
+      const key = await this.saveSelectPatent(selectId)
+      if (!key) {
+        return false
+      }
+      this.exportLoading = false
+      this.$router.push({
+        path: '/workspace/folder/export/patent',
+        query: {
+          id: this.projectId,
+          key: key
+        }
+      })
+    },
+    //切换同族
+    onChangeFamily(key) {
+      this.queryParams.current = 1
+      this.queryParams.family = parseInt(key)
+      this.getList()
+    },
+    //合并申请人
+    handleMerge() {
+      this.$refs.patentApplicantMergeDrawer.open(this.projectId)
+    },
+    //合并发明人
+    handleMerge2() {
+      this.$refs.patentInventorMergeDrawer.open(this.projectId)
+    },
+    //创建FTO报告
+    handleAnalyses(id) {
+      this.$api.getProject({id:this.projectId}).then(response=>{
+        var form = {
+          type:id,
+          projectId:this.projectId,
+          departmentId:response.data[0].departmentId,
+          personId:response.data[0].personnelId,
+          clientId:response.data[0].clientId,
+          proTec:response.data[0].technicalTheme,
+          scenarioList:response.data[0].scenarioList
+      }
+        this.$refs.ReportForm.open(form)
+      })
+    },
+    //图表分析
+    async handleAnalyse(path) {
+      this.chartLoading = true
+      const key = await this.saveSelectPatent(false)
+      this.chartLoading = false
+      const router = this.$router.resolve({
+        path: '/analyse/' + path,
+        query: {
+          id: this.projectId,
+          key: key
+        }
+      })
+      window.open(router.href, '_blank');
+    },
+    //下载PDF
+    async handleDownload(patent) {
+      const { data } = await this.$api.getPatentInstructionList({ current: 1, size: 9999, patentNo: patent.patentNo })
+      if (data.records.length !== 0) {
+        downLoad2(data.records[0].url)
+      } else {
+        this.$alert('专利暂未上传说明书文档', '请求错误', {
+          confirmButtonText: '确定',
+          type: 'error',
+          callback: action => {}
+        });
+      }
+    },
+    //切换已读未读
+    handleChangeRead(ids, status) {
+      let params = {
+        patentIds: ids,
+        projectId: this.projectId,
+        status: status,
+        folder: this.queryParams.folder
+      }
+      this.fastEditLoading = true
+      this.$api.updatePatentReadStatus(params).then(response => {
+        this.$refs.patentQueryFilter.getPatentReadTotal()
+        this.fastEditLoading = false
+        this.getList()
+      }).catch(error => {
+        this.fastEditLoading = false
+      })
+    },
+    //自定义栏位以及标签设置值
+    handleIndexSetting(patent, field) {
+      if (field) {
+        this.$refs.patentIndexSetting.open(this.queryParams.projectId, patent, field)
+      }
+    },
+  },
 };
 </script>
 <style lang="scss" scoped>

+ 1 - 0
src/views/visual/components/sceneSVG.vue

@@ -98,5 +98,6 @@ export default {
   flex-direction: row;
   justify-content: center;
   max-width: 1420px;
+  
 }
 </style>

+ 2 - 0
src/views/visual/index.vue

@@ -38,6 +38,8 @@ export default {
 </script>
 <style lang="scss" scoped>
 .visual {
+  padding: 50px 60px;
+  height: calc(100% - 110px) !important;
   .visual-header {
     // padding-top: 20px;
     img {