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

Merge branch 'product' into noveltySearch2

zhuliu преди 10 месеца
родител
ревизия
9f637b027d

+ 9 - 0
src/api/newApi/patent.js

@@ -360,4 +360,13 @@ export default {
   deletePatents(data) {
     return axios.post("/xiaoshi/patent/deletePatents", data);
   },
+
+  /**
+   * 获取专利相似度(外部检索)
+   * @param {*} data 
+   * @returns 
+   */
+  getPatentSimilarMess(data) {
+    return axios.post("/xiaoshi/patentStar/getPatentSimilarMess", data);
+  },
 }

+ 36 - 0
src/views/components/import/conditionImport/searchResult.vue

@@ -577,6 +577,7 @@ export default {
           this.$store.commit("SET_PATENT_PARAMS", queryParams);
           this.$store.commit("SET_PATENT_RECORDS", records);
           this.getImageAndStatus()
+          // this.getPatentSimilarMess()
           this.loading = false;
           if(response.data.redisKey && !this.condition.redisKey){
             this.condition.redisKey = response.data.redisKey
@@ -621,6 +622,41 @@ export default {
       })
       
     },
+    //获取专利相似度
+    getPatentSimilarMess(){
+      if(this.tableData.length == 0 || !this.noveltySearch){
+        return
+      }
+      var params = {
+        projectId:this.projectId,
+        patentScoreDTOList:[]
+      }
+      this.tableData.forEach(item=>{
+        var obj = {
+          patentNo:item.patentNo,
+          appNo:item.appNo,
+          rowApplicationNo:item.rowApplicationNo,
+          publicNo:item.publicNo,
+          grantNo:item.grantNo
+        }
+        params.patentScoreDTOList.push(obj)
+      })
+      this.$api.getPatentSimilarMess(params).then(response=>{
+        if(response.code == 200){
+          var data = response.data.patentScoreDTOList
+          for(var i = 0;i<this.tableData.length;i++){
+            var item = this.tableData[i]
+            var index = data.findIndex(j=>{
+              return j.patentNo == item.patentNo
+            })
+            if(index!=-1){
+              this.$set(item, 'score', data[index].score.toFixed(4))
+              data.splice(index,1)
+            }
+          }
+        }
+      })
+    },
     handleSelect(data) {
       // this.queryParams.selected = data
     },

+ 7 - 0
src/views/project/patentCollection/components/mixins/index.js

@@ -60,6 +60,13 @@ export const projectData = {
 
   data() {
     return {
+      customColors: [
+        { color: '#f56c6c', percentage: 20 },
+        { color: '#e6a23c', percentage: 40 },
+        { color: '#5cb87a', percentage: 60 },
+        { color: '#1989fa', percentage: 80 },
+        { color: '#6f7ad3', percentage: 100 }
+      ],
     }
   },
 

+ 1 - 0
src/views/project/patentCollection/components/views/Abstract.vue

@@ -60,6 +60,7 @@
                       simpleStatus[patent.simpleStatus] }}</el-tag>
                     <el-tag class="margin-left_10" style="cursor: pointer;" type="primary" effect="plain" size="small" @click="openAddRemark(patent)" v-if="noveltySearch && !noveltyIsRemark(patent)">添加查新标注</el-tag>
                     <el-tag class="margin-left_10" style="cursor: pointer;" type="primary" effect="plain" size="small"  v-if="noveltySearch && noveltyIsRemark(patent)" @click="openAddRemark(patent)">已标注</el-tag>
+                    <el-progress style="display:inline-block;width:300px;margin-left:20px;" v-if="noveltySearch && patent.score" :text-inside="true" :stroke-width="20"  :percentage="patent.score*100"  :color="customColors" ></el-progress>
                   </div>
                   <div style="font-size: 13px;">
                     <el-row>

+ 3 - 0
src/views/project/patentCollection/components/views/Picture.vue

@@ -28,6 +28,9 @@
           <myTooltip :content="getView(item, 'title')">
             <div class="noWrap" v-html="getView(item, 'title')"></div>
           </myTooltip>
+          <div v-if="noveltySearch && item.score">
+            <span>相关度</span><el-progress style="display:inline-block;width:calc(100% - 50px);margin-left:10px;" v-if="noveltySearch && item.score" :text-inside="true" :stroke-width="20"  :percentage="item.score*100"  :color="customColors" ></el-progress>
+          </div>
         </div>
         <div class="picture text-align_center" style="height: 200px;width:100%;line-height:200px;">
           <el-image fit="contain" :src="outside?item.pictureGuid:$commonJS.checkViewer(item.pictureGuid)"

+ 6 - 0
src/views/project/patentCollection/components/views/Table.vue

@@ -99,6 +99,11 @@
           <div v-else v-html="getView(scope.row, item.value, item.type)"></div>
         </template>
       </el-table-column>
+      <!-- <el-table-column v-if="noveltySearch" label="相关度" width="100" fixed="right">
+        <template slot-scope="scope">
+          <el-progress v-if="scope.row.score" :text-inside="true" :stroke-width="20"  :percentage="scope.row.score*100"  :color="customColors"></el-progress>
+        </template>
+      </el-table-column> -->
     </el-table>
     <addRemark ref="addRemark" :projectId="projectId" v-on="$listeners"></addRemark>
   </div>
@@ -120,6 +125,7 @@ export default {
   },
   data() {
     return {
+      
     }
   },
   watch:{

+ 16 - 20
src/views/report/components/dialog/addAndEditReport.vue

@@ -118,18 +118,18 @@
               </el-col>
             </el-row>
         
-        <template v-if="!form.id && form.status == 3">
+        <template>
           <div>
             <el-form-item label="报告结果" prop="cronIds">
               <el-checkbox-group v-model="form.cronIds">
-                <el-checkbox v-for="item in conclusion" :key="item.value" :label="item.value">{{
+                <el-checkbox v-for="item in conclusion" :key="parseInt(item.value)" :label="parseInt(item.value)">{{
                   item.label }}</el-checkbox>
               </el-checkbox-group>
             </el-form-item>
             <el-form-item label="结果论述" prop="cronDescription">
               <el-input v-model="form.cronDescription" type="textarea" placeholder="请输入结果论述"></el-input>
             </el-form-item>
-            <el-form-item label="后续跟进事项" prop="followUps">
+            <el-form-item label="后续跟进事项" prop="followUps" v-if="!form.id && form.status == 3">
               <span v-if="form.followUps"><span v-for="item in form.followUps" :key="item.name"
                   style="margin-right:10px">{{ item.name }}</span></span>
               <span>
@@ -778,6 +778,12 @@ export default {
 
       var reportType = this.dictMessage.REPORT_TYPE.filter(item => { return item.value == this.form.reportType })[0].label
       this.title = a + reportType + '报告'
+      //报告结果选项
+      this.conclusion = this.dictMessage[this.reportAsDicItem[this.form.reportType]]
+      if(!this.form.cronIds){
+        this.$set(this.form,'cronIds',[])
+      }
+      
       // 负责人
       if(!this.form.headId){
         this.$set(this.form,'headId',Number(this.userinfo.id))
@@ -879,21 +885,10 @@ export default {
       if (val == 3) {
         this.rules.headId[0].required = false
         this.rules.entrustId[0].required = false
-        if (!this.form.id) {
-          this.$set(this.form, 'cronIds', [])
-        }
-        let params = {
-          reportType: this.form.reportType
-        }
-        // await this.$api.queryCrons(params).then(res => {
-        //   if (res.code == 200) {
-        //     this.conclusion = res.data.data
-        //   }
-        // }).catch(error => {
-        //   this.conclusion = []
-        //   this.$message.error(error.message)
-        // })
-        this.conclusion = this.dictMessage[this.reportAsDicItem[this.form.reportType]]
+        // if (!this.form.id) {
+        //   this.$set(this.form, 'cronIds', [])
+        // }
+        // this.conclusion = this.dictMessage[this.reportAsDicItem[this.form.reportType]]
         this.matterType = 2
       } else {
         this.rules.headId[0].required = true
@@ -1079,8 +1074,8 @@ export default {
               return false
             }
           }else if(this.form.status != 3 && !this.form.id){
-            this.form.cronIds = []
-            this.form.cronDescription=''
+            // this.form.cronIds = []
+            // this.form.cronDescription=''
             this.followUps = []
           }
           
@@ -1159,6 +1154,7 @@ export default {
         matterIds: [],
         systemFileList: [],
         fileGuids: [],
+        cronIds:[]
       }
       this.show = false
       this.showDialog = false

+ 1 - 1
src/views/report/components/dialog/cronConclusion.vue

@@ -4,7 +4,7 @@
             <el-form :model="form" label-width="120px">
                 <el-form-item label="报告结果">
                 <el-checkbox-group v-model="form.cronIds">
-                    <el-checkbox v-for="item in conclusion" :key="item.value" :label="item.value">{{ item.label }}</el-checkbox>
+                    <el-checkbox v-for="item in conclusion" :key="parseInt(item.value)" :label="parseInt(item.value)">{{ item.label }}</el-checkbox>
                 </el-checkbox-group>
                 </el-form-item>
                 <el-form-item label="结论论述" >