Parcourir la source

Merge branch 'product' of http://1.116.113.26:8088/zhuliu/xiaoshi_system into product

zhuliu il y a 1 an
Parent
commit
c666407be2

+ 6 - 0
src/api/newApi/patentMining.js

@@ -30,4 +30,10 @@ export default {
   deletePatentDigProject(data) {
     return axios.post("/xiaoshi/patentDigProject/deletePatentDigProject", data);
   },
+  /**
+   * 专利挖掘项目分组
+   */
+  groupPatentDigProject(data) {
+    return axios.post("/xiaoshi/patentDigProject/groupPatentDigProject", data);
+  },
 };

+ 5 - 18
src/views/event/components/index.vue

@@ -94,10 +94,7 @@ export default {
       //检索字段
       searchFiled: [],
       //检索条件
-      searchOption: {
-        // name: this.eventName,
-        // applicationScenario: this.applicationScenario
-      },
+      searchOption: { },
       //分组的值
       groupingValue: '',
       //分组
@@ -167,8 +164,6 @@ export default {
     handleSuccess(val) {
       this.handleMessage = val
       this.queryParams.current = 1
-      this.searchOption.searchQuery=''
-      // this.getList()
       this.isGrouping()
       this.clearMessage()
     },
@@ -190,15 +185,8 @@ export default {
       let params = ['event']
       await this.$api.getParamsCommon(params).then(res => {
         if (res.code == 200) {
-          // 显示栏位
-          // this.columnList = res.data[0].conditionDTOList.filter(item => {
-          //   return item.name != 'Id' && item.ifShow == true
-          // })
-          // 分组字段
           let conditionDTOList= JSON.parse(JSON.stringify(res.data[0].conditionDTOList))
-          // this.groupingOption = conditionDTOList.filter(item => {
-          //   return item.ifGroup == true
-          // })
+          // 分组字段
           this.groupingOption = this.$commonJS.getField(conditionDTOList,(u)=> u.ifGroup == true,{
             name: 'name',
             value: 'value',
@@ -236,8 +224,7 @@ export default {
         }
       })
       // 返回条件对象
-      this.searchOption.searchQuery=params
-      // this.searchOption.searchQuery=this.$commonJS.objectToString(params)
+      this.searchOption=params
       // 调用查询接口
       this.queryParams.current=1
       this.isGrouping()
@@ -253,7 +240,7 @@ export default {
     getList() {
       let params = {
         ...this.queryParams,//分页信息
-        searchQuery:this.$commonJS.objectToString(this.searchOption.searchQuery || {}),//检索条件
+        searchQuery:this.$commonJS.objectToString(this.searchOption || {}),//检索条件
         orderDTOList: this.sort,//排序
       }
       this.$api.queryEvent(params).then(res => {
@@ -284,7 +271,7 @@ export default {
     getGrouping() {
       let params = {
         ...this.queryParams,//分页信息
-        // ...this.searchOption,//检索信息
+        searchQuery:this.$commonJS.objectToString(this.searchOption || {}),//检索条件
         orderDTOList:this.sort,//排序
         groupBy:this.groupingValue,//分组信息
       }

+ 2 - 4
src/views/event/components/view/table.vue

@@ -164,8 +164,7 @@ export default {
           this.tableData.splice(startIndex,1)
         let params = {
           ...this.params,
-          // ...this.row.searchOption,//检索条件
-          searchQuery:this.$commonJS.objectToString(this.row.searchOption.searchQuery || {}),//检索条件
+          searchQuery:this.$commonJS.objectToString(this.row.searchOption || {}),//检索条件
           orderDTOList: this.sort,//排序
           groupField: this.row.groupBy,
           groupFieldValue: this.row.row.value,
@@ -219,8 +218,7 @@ export default {
       this.params.current += 1
       let params = {
         ...this.params,
-        // ...this.row.searchOption,//检索条件
-        searchQuery:this.$commonJS.objectToString(this.row.searchOption.searchQuery || {}),//检索条件
+        searchQuery:this.$commonJS.objectToString(this.row.searchOption || {}),//检索条件
         orderDTOList: this.sort,//排序
         groupField: this.row.groupBy,
         groupFieldValue: this.row.row.value,

+ 1 - 1
src/views/patentMining/components/mixins/index.js

@@ -45,7 +45,7 @@ export default {
         } 
       }
       var isLast = false
-      if(option == 10){//删除
+      if(option == '1'){//删除
         this.action={
           type:'1',
           id:row.id

+ 4 - 11
src/views/patentMining/components/view/MergeTable.vue

@@ -1,5 +1,5 @@
 <template>
-  <div class="workspace-merge-table height_100" v-DivHeight="getDivHeight">
+  <div class="workspace-merge-table height_100">
     <el-table :data="commandData" border header-row-class-name="custom-table-header" @expand-change="expandChange"
       @sort-change="sortChange">
       <el-table-column type="expand">
@@ -32,8 +32,8 @@ export default {
     // 分组数据
     commandData: {
       type: Array,
-      default: () =>{
-        return []  
+      default: () => {
+        return []
       }
     },
     // 检索条件
@@ -88,14 +88,7 @@ export default {
     },
     //展开行
     expandChange(row, expandedRows) {
-      var index = this.expends.findIndex(item => {
-        return item == row.id
-      })
-      if (index == -1) {
-        this.expends.push(row.id)
-      } else {
-        this.expends.splice(index, 1)
-      }
+      row.data = []
     },
 
   }

+ 12 - 7
src/views/patentMining/components/view/commonTable.vue

@@ -1,7 +1,8 @@
 <template>
-  <div>
-    <el-table :data="tableData" border style="width: 100%" header-row-class-name="custom-table-header"
-      @sort-change="sortChange">
+  <div class="height_100" v-DivHeight="getDivHeight">
+    <el-table :data="tableData" border header-row-class-name="custom-table-header" @sort-change="sortChange"   
+    v-if="showTable" :maxHeight="tableHeight" v-el-table-infinite-scroll="getList" :infinite-scroll-distance="10" 
+    :infinite-scroll-disabled="disabled" style="width: 100%">
 
       <el-table-column label="#" width="60" type="index" align="center">
         <template slot-scope="scope">
@@ -38,9 +39,10 @@
 </template>
   
 <script>
+import { getTableHeight } from '@/views/components/mixins'
 import mixins from '../mixins'
 export default {
-  mixins: [mixins],
+  mixins: [mixins,getTableHeight],
   components: {},
   props: {
     column: {//显示栏位管理数组
@@ -94,6 +96,7 @@ export default {
     }
   },
   mounted() {
+    console.log(this.row);
     if (!this.row) {
       this.disabled = true
     } else {
@@ -132,7 +135,7 @@ export default {
     },
 
     getList2(params, type) {
-      this.$api.queryPatentProject(params).then(res => {
+      this.$api.queryPatentDigProject(params).then(res => {
         if (res.code == 200) {
           if (type == 1) {
             var startIndex = (params.current - 1) * size
@@ -154,7 +157,9 @@ export default {
 
 
     getList() {
+      console.log(1);
       if (!this.row) return;
+      console.log(2);
       if (this.params.current * this.params.size >= this.params.total) {
         this.isMore = true
         this.disabled = true
@@ -174,10 +179,10 @@ export default {
       }
       this.isMore = false;
       this.isFlag = true;
-      this.$api.queryPatentProject(params).then(res => {
+      this.$api.queryPatentDigProject(params).then(res => {
         if (res.code == 200) {
           this.tableData.push(...res.data.data)
-          this.params.total = res.data.total
+          this.params.total = res.data.total  
         }
       }).catch(err => {
       })

+ 2 - 3
src/views/patentMining/components/viewIndex.vue

@@ -31,7 +31,7 @@
       </el-header>
       <el-main>
         <component :is="viewType" v-bind="$attrs" v-on="$listeners" :isOperate="isOperate" :tableData="dataList"
-          :column="columnList" :group="group" :queryParams="queryParams" @option="handleOption" @on-sort="handleSort"
+          :column="columnList" :groupingOption="groupingOption" :groupBy="group" :queryParams="queryParams" @option="handleOption" @on-sort="handleSort"
           :commandData="commandData" :searchOption="searchOption" :handleMessage="handleMessage">
         </component>
       </el-main>
@@ -151,7 +151,6 @@ export default {
     isSuccess(val) {
       this.handleMessage = val
       this.queryParams.current = 1
-      this.searchOption={}
       this.isGrouping()
       this.clearMessage()
     },
@@ -239,7 +238,7 @@ export default {
         groupBy: this.group,//分组的值
       }
       this.loading = true
-      this.$api.groupPatentProject(params).then(response => {
+      this.$api.groupPatentDigProject(params).then(response => {
         this.commandData = response.data.data.values
         this.total = response.data.total
         this.loading = false

+ 3 - 3
src/views/project/components/mixins/index.js

@@ -29,12 +29,12 @@ export const workspaceOptions = {
         })
         window.open(router.href, '_blank');
       }
-      
+
     },
     //操作列
     handleCommand(event, row) {
       var isLast = false
-      if(event == 10){
+      if(event == 10){//删除
         this.action={
           type:'1',
           id:row.id
@@ -43,7 +43,7 @@ export const workspaceOptions = {
           isLast = true
         }
       }
-      if(event == 'e'){
+      if(event == 'e'){//编辑
         this.action={
           type:'2',
           id:row.id

+ 4 - 7
src/views/project/components/view/table.vue

@@ -1,7 +1,7 @@
 <template>
-  <div class="height_100">
+  <div class="height_100"  v-DivHeight="getDivHeight">
       <el-table :data="tableData" border style="width: 100%" header-row-class-name="custom-table-header"
-        @sort-change="sortChange"  v-el-table-infinite-scroll="getList" :infinite-scroll-distance="10" 
+      v-if="showTable" :maxHeight="tableHeight" @sort-change="sortChange"  v-el-table-infinite-scroll="getList" :infinite-scroll-distance="10" 
         :infinite-scroll-disabled="disabled">
         <el-table-column label="#" width="60" type="index" align="center">
           <template slot-scope="scope">
@@ -11,8 +11,9 @@
 
         <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)">
+            <div v-if="['name'].includes(item.value)">
               <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 +235,6 @@ export default {
       this.tableData.splice(0)
       this.getList()
     },
-
-
-
-
   },
 };
 </script>

+ 4 - 39
src/views/project/index.vue

@@ -54,7 +54,7 @@
                 :queryParams="queryParams" :column="fieldList" @option="handleOption" @on-sort="handleSort" :handleMessage="handleMessage"></component>
             </div>
             <div class="pagination" v-if="[2].indexOf(isOperate) == -1">
-              <el-pagination backgroundx layout="total, prev, pager, next, jumper"
+              <el-pagination background layout="total, prev, pager, next, jumper"
                 :current-page.sync="queryParams.current" :page-size.sync="queryParams.size"
                 @current-change="handleCurrentChange" :total="total">
               </el-pagination>
@@ -105,36 +105,9 @@ export default {
   data() {
     return {
       //检索字段
-      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: "请输入内部案卷",
-        },
-      ],
+      searchFiled: [],
       //检索条件
-      searchOption: {
-        name: localStorage.searchContent,
-      },
+      searchOption: {},
       //专题库数据总数
       total: 0,
       //分页信息
@@ -143,12 +116,7 @@ export default {
         current: 1,
       },
       //排序
-      sort: [
-        {
-          "orderBy": "createTime",
-          "orderType": 1
-        }
-      ],
+      sort: [],
       //分组集合
       groupingOption: [],
       //分组
@@ -381,11 +349,8 @@ export default {
     getMessage(val) {
       this.handleMessage = val
       this.queryParams.current = 1
-      // this.getList()
       this.isGrouping()
       this.clearMessage()
-      // this.handleMessage = val
-      // this.getList()
     },
     clearMessage() {
       this.$nextTick(() => {

+ 1 - 31
src/views/report/components/index.vue

@@ -91,35 +91,7 @@ export default {
       //当前视图类型
       viewType: 'Table',
       //检索字段
-      searchFiled: [
-        {
-          label: '报告名称',
-          value: 'name',
-          type: 1,
-          placeholder: '请输入报告名称'
-        },
-        {
-          label: '报告类型',
-          value: 'types',
-          type: 3,
-          placeholder: '请选择报告类型',
-          // options:this.dictMessage.REPORT_TYPE||[]
-        },
-        {
-          label: '报告状态',
-          value: 'statuses',
-          type: 3,
-          placeholder: '请选择报告状态',
-          // options:this.dictMessage.REPORT_STATE||[]
-        },
-        {
-          label: '核心结论',
-          value: 'cronIds',
-          type: 3,
-          placeholder: '请选择核心结论',
-          options: []
-        },
-      ],
+      searchFiled: [],
 
       //检索条件
       searchOption: {
@@ -364,7 +336,6 @@ export default {
       }
       this.queryParams.current = 1
       this.isGrouping()
-      // this.getList()
     },
     //分页
     handleCurrentChange(val) {
@@ -583,7 +554,6 @@ export default {
     isGetList(val) {
       this.handleMessage = val
       this.queryParams.current = 1
-      this.searchOption={}
       this.isGrouping()
       this.clearMessage()
     },

+ 1 - 46
src/views/report/components/view/mergeTable.vue

@@ -46,48 +46,7 @@ export default {
       type: Array,
       default: () => {
         return [
-          {
-            ifGroup: false,
-            ifSearch: true,
-            name: "事件名称",
-            type: "String",
-            value: "name",
-          },
-          {
-            name: "创建人",
-            type: "String",
-            value: "createName",
-            ifSearch: true,
-            ifGroup: false
-          },
-          {
-            name: "创建时间",
-            type: "DateTime",
-            value: "createTime",
-            ifSearch: true,
-            ifGroup: true
-          },
-          {
-            name: "发生时间",
-            type: "DateTime",
-            value: "eventDate",
-            ifSearch: true,
-            ifGroup: true
-          },
-          {
-            name: "描述",
-            type: "String",
-            value: "description",
-            ifSearch: true,
-            ifGroup: false
-          },
-          {
-            name: "应用场景",
-            type: "Integer",
-            value: "scenarioId",
-            ifSearch: true,
-            ifGroup: true
-          }
+         
         ]
       }
     }
@@ -98,11 +57,7 @@ export default {
   },
   data() {
     return {
-      // columnList: [],
-      tableData: [],
-      showData: [],
       expandList: [],
-
       sort:[
         {
           "orderBy": "createTime",

+ 6 - 5
src/views/report/components/view/table.vue

@@ -1,7 +1,9 @@
 <template>
   <div>
-    <div>
-      <el-table :data="tableData" border style="width: 100%" header-row-class-name="custom-table-header" @sort-change="sortChange">
+    <div class="height_100"  v-DivHeight="getDivHeight">
+      <el-table :data="tableData" border style="width: 100%" header-row-class-name="custom-table-header"
+      v-if="showTable" :maxHeight="tableHeight" @sort-change="sortChange"  v-el-table-infinite-scroll="getList" :infinite-scroll-distance="10" 
+        :infinite-scroll-disabled="disabled">
         <el-table-column label="#" width="60" type="index" align="center">
           <template slot-scope="scope">
             <span>{{ (scope.$index + 1) + ((queryParams.current - 1) * queryParams.size) }}</span>
@@ -49,9 +51,10 @@
 </template>
 
 <script>
+import { getTableHeight } from '@/views/components/mixins'
 import mixins from '../mixins';
 export default {
-  mixins:[mixins],
+  mixins:[mixins,getTableHeight],
   props: {
     isOperate: {//控制显示
       type: [String,Number],
@@ -109,7 +112,6 @@ export default {
           this.tableData.splice(startIndex,1)
         let params = {
           ...this.params,
-          // ...this.row.searchOption,//检索条件
           searchQuery : this.$commonJS.objectToString(this.row.searchOption),//检索条件
           orderDTOList: this.sort,//排序
           groupField: this.row.groupBy,
@@ -163,7 +165,6 @@ export default {
       this.params.current += 1
       let params = {
         ...this.params,
-        // ...this.row.searchOption,//检索条件
         searchQuery : this.$commonJS.objectToString(this.row.searchOption),//检索条件
         orderDTOList: this.sort,//排序
         groupField: this.row.groupBy,