瀏覽代碼

对比方案及上传文件

zhuliu 3 年之前
父節點
當前提交
7af053c2f4

+ 4 - 0
RMS-FrontEnd/src/api/report.js

@@ -298,4 +298,8 @@ export default {
     return axios.get('/report/api/CompareFiles/settingAll',{params})
   },
 
+  //文件上传
+  upload(params){
+    return axios.post('/report/api/reportFile/add',params)
+  }
 }

+ 15 - 5
RMS-FrontEnd/src/views/components/articles/index.vue

@@ -1,6 +1,6 @@
 <template>
 <div :style="{ top: showPositionTop + 'px', left: showPositionLeft + 'px' }">
-  <div style="background:white;display:flex; justify-content:flex-end">
+  <div style="background:white;display:flex; justify-content:flex-end" >
     <el-button type="primary" size="small" @click="checkResult" style="margin-top:20px;margin-right:10px;height:32px;"> 查看结果 </el-button>
     <el-popover placement="bottom" title="关键词高亮" width="320" trigger="click" style="margin-top:20px">
       <patent-keywords-highlight :project-id="projectId" />
@@ -16,7 +16,7 @@
       active-color="#00BFFF"
       inactive-color="#D3D3D3">
     </el-switch>
-    <patent-list :patent-id="patentId" :project-id="projectId" @on-change="onChange" :taskId="taskId" :location="location1" :state="state" :ban='ban'/>
+    <patent-list v-if="taskId" :patent-id="patentId" :project-id="projectId" @on-change="onChange" :taskId="taskId" :location="location1" :state="state" :ban='ban'/>
   </div>       
               
   <!-- <el-button @click="two">对比</el-button> -->
@@ -126,7 +126,11 @@
         </el-upload>
        </el-form-item>
        <el-form-item label="权利特征" class="item" style="margin-bottom:5px">
-         <span v-for="item in ruleForm.features">[{{item.rightName}}]{{item.content}}&nbsp;&nbsp;</span>
+         <span v-for="item in ruleForm.features">[{{item.rightName}}]
+          <el-tooltip class="item" effect="dark" :content="item.content" placement="top">
+                      <span>特征{{item.featuresOrder}}</span>
+                    </el-tooltip>  
+          &nbsp;&nbsp;</span>
        </el-form-item>
      </el-form>
      <div style="max-height:300px;overflow:auto">
@@ -283,7 +287,7 @@ export default {
     
   },
   mounted() {
-    this.signPatentNo = localStorage.signPatentNo
+    this.signPatentNo = this.$s.getSession('params').signPatentNo
    this.taskId = this.$s.getSession('params').taskId
    this.type = this.$s.getSession('params').type
     this.reportId = this.$s.getSession('params').reportId
@@ -476,6 +480,7 @@ export default {
         this.ruleForm.featureslist.push(val[i].id)
        a.push({
           featureId:val[i].id,
+          featuresOrder:val[i].featuresOrder,
           comResult:val[i].comResult,
           rightName:val[i].pRightName,
           content:val[i].content
@@ -577,7 +582,12 @@ export default {
   }
 }
 </script>
-
+<style lang="less">
+  .item .el-form-item__label{
+    // color: blake;
+    font-family: '黑体';
+  }
+</style>
 <style lang="scss">
 .content-main{
   width:80% !important ;

+ 13 - 9
RMS-FrontEnd/src/views/report/Invalid/InvalidPage/Result.vue

@@ -70,7 +70,7 @@
      
       <el-table-column v-for="(item, index) in tableHeader" :key="index" align="center" :min-width="item.length > 7 ? '190' : '110'">
         <template slot="header">
-          <span>{{item.patentNo}}</span><el-tag style="font-size:12px;border-radius:50%" v-if="item.remark">{{item.remark}}</el-tag>
+          <span><el-link type="primary"  @click="editContrast(item.patentNo)">{{item.patentNo}}</el-link></span><el-tag style="font-size:12px;border-radius:50%" v-if="item.remark">{{item.remark}}</el-tag>
         </template>
             <template slot-scope="scope" >
               <!-- <div v-if="scope.row[item.patentNo]" style="width:calc(100% + 20px);margin-left:-10px">
@@ -136,13 +136,13 @@
       </el-table-column>
         <el-table-column v-for="(item, index) in tableHeader" :key="index" show-overflow-tooltip align="center" :min-width="item.length > 7 ? '190' : '110'">
           <template slot="header">
-            <span>{{item.patentNo}}</span><el-tag style="font-size:12px;border-radius:50%;" v-if="item.remark">{{item.remark}}</el-tag>
+            <span><el-link type="primary"  @click="editContrast(item.patentNo)">{{item.patentNo}}</el-link></span><el-tag style="font-size:12px;border-radius:50%;" v-if="item.remark">{{item.remark}}</el-tag>
           </template>
           <template slot-scope="scope">
             <el-checkbox-group v-model="checkRecord">
               <div class="innerTable" v-if="scope.row[item.patentNo]" style="width:calc(100% + 20px);margin-left:-10px">
-                 <p v-for="i in scope.row[item.patentNo]">
-                  <el-checkbox :label="item.patentNo+scope.row[item.patentNo]" @change="getFunInfo(scope.row,item.patentNo)" v-if="scope.row[item.patentNo]">
+                 <p v-for="(i,index) in scope.row[item.patentNo]">
+                  <el-checkbox :label="item.patentNo+scope.row[item.patentNo+'_Id'][index]" @change="getFunInfo(scope.row,item.patentNo,index)" v-if="scope.row[item.patentNo]">
                    {{i}}
                   </el-checkbox>
                 </p>
@@ -171,11 +171,12 @@
 
   
 <script>
-
+import { editContrast } from '../../components/mixins'
 export default {
   components: {
 
   },
+  mixins:[editContrast],
   props:['reportId2','signPatentNo'],
   data() {
     return {
@@ -413,8 +414,11 @@ export default {
         featuresIDList:this.featuresId,
         recordIDList:this.recordList
       }
+      // console.log(a)
       this.$api.addCompareScenarios(a).then(response=>{
         if(response.code == 200){
+          this.recordList = []
+          this.featuresId = []
           this.checkRecord = []
           this.ruleForm.result = ''
           this.$message.success('方案保存成功')
@@ -430,14 +434,14 @@ export default {
       this.isSelect = false
       this.show = false
     },
-    getFunInfo(row, patentNo) {
-      console.log(row,patentNo?row[patentNo+'_Id']:'1')
+    getFunInfo(row, patentNo,i) {
+      // console.log(row,patentNo?row[patentNo+'_Id']:'1')
       if(patentNo){
        var index = this.recordList.findIndex(item=>{
-          return item == row[patentNo+'_Id']
+          return item == row[patentNo+'_Id'][i]
         })
         if(index == -1){
-          this.recordList.push(row[patentNo+'_Id'])
+          this.recordList.push(row[patentNo+'_Id'][i])
         }
       }else{
         var index = this.featuresId.findIndex(item=>{

+ 1 - 1
RMS-FrontEnd/src/views/report/components/Card.vue

@@ -22,7 +22,7 @@
                       </el-dropdown-menu>
                     </el-dropdown>         
                 </div>
-                <p><span style="font-weight:bolder">标的专利:</span>  <el-link type="primary" style="font-size:16px" @click="toPatentDetails(item.signPatentNo)">{{item.signPatentNo}}</el-link> </p>
+                <p><span style="font-weight:bolder">标的专利:</span>  <el-link type="primary" style="font-size:16px" @click="toPatentDetails(item.signPatentNo,scope.row)">{{item.signPatentNo}}</el-link> </p>
                 <!-- <p><span style="font-weight:bolder">调查类型:</span> <span v-if="item.itFlag">{{item.itFlag[0]}}
                     <span v-if="item.itFlag.length>1">
                           <el-tooltip class="item" effect="light"  placement="top">

+ 34 - 2
RMS-FrontEnd/src/views/report/components/CreateReport.vue

@@ -45,6 +45,13 @@
             <el-form-item label="卷号" prop="volumeNumber" >
               <el-input v-model="form.volumeNumber" autocomplete="off" placeholder="请输入卷号"></el-input>
             </el-form-item>
+            <el-form-item label="上传附件">
+              <el-upload class="upload-file" drag action="#" :auto-upload="false" :show-file-list="false" :on-change="onChange" multiple>
+                <i :class="!file ? 'el-icon-upload' : 'el-icon-refresh'"></i>
+                <div class="el-upload__text">将文件拖到此处,或<em>点击上传</em></div>
+                <div class="el-upload__tip" slot="tip"></div>
+              </el-upload>
+            </el-form-item>
             <el-form-item label="备注" prop="remark" >
               <el-input type='textarea' v-model="form.remark" autocomplete="off" placeholder="请输入备注"></el-input>
             </el-form-item>
@@ -103,6 +110,7 @@ export default {
       }
     }
     return {
+      file:[],
       form: {
         signPatentNo: "",
       },
@@ -140,6 +148,18 @@ export default {
     this.getDictsFromPAS()
   },
   methods: {
+    onChange(file, fileList) {
+      this.file.push(file.raw) 
+    
+      // let formData = new FormData()
+      // formData.append('id', 1)
+
+      // formData.append('file', this.file)
+      // this.$api.upload(formData).then(response=>{
+      //   console.log(response)
+      // })
+      console.log(typeof(this.file) )
+    },
     //获取审核人
     getPerson(val){
       this.person = val
@@ -244,9 +264,21 @@ export default {
                       // });
                     }).catch(action => {
                       if(action == 'cancel'){
-                        this.form.status = 1
-                      this.$api.AddReport(this.form).then(response=>{
+                        let formData = new FormData()
+                        if(this.file){
+                          for (var i = 0; i < this.file.length; i++) {
+                              formData.append("file", this.file[i]);
+                          }
+                        }
+                        
+                        for(let key in this.form){
+                          formData.append(key, this.form[key])
+                        }
+                        formData.append('status', 1)
+                        // console.log(formData)
+                      this.$api.AddReport(formData).then(response=>{
                         if(response.code == 200){
+                          this.file = null
                           this.$message.success('报告创建成功')
                           this.$emit('getList',true)
                           this.handleClose()

+ 20 - 0
RMS-FrontEnd/src/views/report/components/mixins.js

@@ -56,4 +56,24 @@ export const explain = {
       this.pasteFile = file;
     },
   },
+}
+
+export const editContrast = {
+  methods: {
+    editContrast(patentNo){
+      var params = {
+        signPatentNo:this.patentNo,
+        type:2,
+        reportId:this.reportId
+      }
+      const router = this.$router.resolve({
+        path: '/ContrastIndex/' + patentNo,
+        query: {
+          patentNo:patentNo,
+        }
+      })
+    this.$s.setSession('params', params)
+    window.open(router.href, '_blank');
+    }
+  },
 }

+ 66 - 18
RMS-FrontEnd/src/views/report/reportDetails/components/ContrastPlan.vue

@@ -3,47 +3,63 @@
         <el-table
         :data="tableData"
         border
+        class="table"
         :span-method="objectSpanMethod"
+        :row-class-name="tableRowClassName"
         v-loading="loading"
         style="min-width: 100%; margin-top: 20px;overflow:auto">
 
-        <el-table-column prop="pRightName" label="权要"  align="center"  width="200px">
+        <el-table-column prop="right" label="权要"  align="center"  width="200px">
           <template slot-scope="scope">  
-            <el-tooltip class="item" effect="dark" :content="scope.row.pContent" placement="top">
-              <span>{{scope.row.pRightName}}</span>
+            <el-tooltip class="item" effect="dark" :content="scope.row.right" placement="top">
+              <span>{{scope.row.right}}</span>
             </el-tooltip>     
           </template>
         </el-table-column>
 
         <el-table-column prop="content" label="对比组合" align="center" width="300px">
           <template slot-scope="scope" >
-            <el-checkbox-group v-model="checkList" >
-
-                <el-checkbox  :label="scope.row.content" @change="getFunInfo(scope.row)" style="display: flex; align-items: center;">
-                  <el-input type="textarea" style="width:250px" autosize v-model="scope.row.content"> {{scope.row.content}}</el-input>
+            <div >
+              <el-checkbox-group v-model="checkList" >
+                <el-checkbox :label="scope.row.content" @change="getFunInfo(scope.row)" >
+                  <p>对比组合{{(scope.$index+1)}}</p> 
                 </el-checkbox>
-
-             </el-checkbox-group>
+              </el-checkbox-group>
+            </div>
+           
           </template>
         </el-table-column>
-        <el-table-column prop="content" label="特征"  align="center"  width="200px">
+        <el-table-column prop="assoRecordsFeatures" label="特征"  align="center"  width="200px">
           <template slot-scope="scope">  
-              <span>{{scope.row.content}}</span>
+              <!-- <span>{{scope.row.content}}</span> -->
+              <div class="innerTable" v-if="scope.row.assoRecordsFeatures" style="width:calc(100% + 20px);margin-left:-10px">
+                  <p v-for="i in scope.row.assoRecordsFeatures">
+                    <el-tooltip class="item" effect="dark" :content="i.features.content" placement="top">
+                      <span>特征{{i.features.featuresOrder}}</span>
+                    </el-tooltip>  
+                  </p>
+              </div>
           </template>
         </el-table-column>
         <el-table-column prop="patentNo" label="对比专利"  align="center"  width="200px">
           <template slot-scope="scope">  
-              <span>{{scope.row.patentNo}}</span>
+              <!-- <span>{{scope.row.patentNo}}</span> -->
+              <div class="innerTable" v-if="scope.row.assoRecordsFeatures" style="width:calc(100% + 20px);margin-left:-10px">
+                  <p v-for="i in scope.row.assoRecordsFeatures">{{i.compareRecords.patentNo}}</p>
+              </div>
           </template>
         </el-table-column>
-        <el-table-column prop="content" label="对比内容"  align="center"  width="200px">
+        <el-table-column prop="content" label="对比内容"  align="center" min-width="200px">
           <template slot-scope="scope">  
-              <span>{{scope.row.content}}</span>
+              <!-- <span>{{scope.row.content}}</span> -->
+              <div class="innerTable" v-if="scope.row.assoRecordsFeatures" style="width:calc(100% + 20px);margin-left:-10px">
+                  <p v-for="i in scope.row.assoRecordsFeatures">{{i.compareRecords.content}}</p>
+              </div>
           </template>
         </el-table-column>
-        <el-table-column prop="result" label="对比结论/理由"  align="center"  width="200px">
+        <el-table-column prop="contrastResult" label="对比结论/理由"  align="center"  width="300px">
           <template slot-scope="scope">  
-              <span>{{scope.row.content}}</span>
+              <span>{{scope.row.contrastResult}}</span>
           </template>
         </el-table-column>
       </el-table>
@@ -55,20 +71,31 @@ export default {
     props:['reportId'],
     data() {
         return {
+          checkList:[],
             tableData:[],
             loading:false,
             mergeObj: {},
-            mergeArr: ['id', 'pRightName'],
+            mergeArr: [ 'right'],
         }
     },
     mounted() {
         this.getContrastPlan()
     },
     methods: {
+      // 表格隔行变色
+      tableRowClassName({ row, rowIndex }) {
+        if (rowIndex % 2 === 0) {
+          return 'success-row'
+        } else  {
+          return ''
+        }
+      },
         getContrastPlan(){
             this.$api.selectCompareScenarios({reportID:this.reportId}).then(response=>{
                 if(response.code == 200){
                     console.log(response.data)
+                    this.tableData = response.data
+                    this.getSpanArr(this.tableData)
                 }
             })
         },
@@ -102,4 +129,25 @@ export default {
     }
     },
 }
-</script>
+</script>
+<style>
+.success-row {
+  background-color:#eaf3fb !important; 
+}
+.success-row:first-child td:first-child{
+  background-color: #FFF;
+}
+</style>
+<style lang="scss" scoped>
+.innerTable p{
+  padding:0 0 20px 0;
+border-bottom:1px solid #EBEEF5;
+}
+.innerTable p:last-child{
+  padding: 20px 0 0 0;
+  border-bottom: none;
+}
+.table{
+  cursor: pointer;
+}
+</style>

+ 3 - 2
RMS-FrontEnd/src/views/task/MyHandle.vue

@@ -198,14 +198,15 @@
     contrastTask(row) {
 		// this.$store.commit('SET_ADMIN_SIGNPATENTNO',row.signPatentNo)
 		// console.log(row.signPatentNo,this.$store.state.admin)
-		localStorage.signPatentNo = row.signPatentNo
+		// localStorage.signPatentNo = row.signPatentNo
       let a=this.$router.resolve({
         path: '/Incomplete',
         query: {
           // taskStatus: this.queryParams.taskStatus,
           taskId: row.id,
 		  reportId:row.reportId,
-		  type:row.type
+		  type:row.type,
+		  signPatentNo:row.signPatentNo
         }
       })
       window.open(a.href,"_blank")

+ 3 - 1
RMS-FrontEnd/src/views/task/components/Incomplete.vue

@@ -25,7 +25,7 @@
             <el-tab-pane label="已读" name="second">
             </el-tab-pane>
           </el-tabs>
-          <IncompletePage :taskId="queryParams.taskId" :reportId="reportId" :type="queryParams.type" :activeName="activeName" :onChangesIn="onChangesIn"></IncompletePage>
+          <IncompletePage :taskId="queryParams.taskId" :signPatentNo="signPatentNo" :reportId="reportId" :type="queryParams.type" :activeName="activeName" :onChangesIn="onChangesIn"></IncompletePage>
         </el-main>
       </el-container>
     </el-container>
@@ -80,6 +80,7 @@ export default {
       visible:false,
       activeName: 'first',
       reportId:'',
+      signPatentNo:'',
       // tableData: [],
       // loading: false,
       queryParams: {
@@ -97,6 +98,7 @@ export default {
     this.queryParams.taskId = this.$route.query.taskId
     this.queryParams.type = this.$route.query.type
     this.reportId = this.$route.query.reportId
+    this.signPatentNo = this.$route.query.signPatentNo
   },
   mounted() {
   },

+ 2 - 1
RMS-FrontEnd/src/views/task/components/IncompletePage.vue

@@ -29,12 +29,13 @@
 import { Contrast } from './mixins';
 export default {
   mixins:[Contrast],
-  props:["activeName","taskId","reportId","onChangesIn",'type'],
+  props:["activeName","taskId","reportId","onChangesIn",'type','signPatentNo'],
   data() {
     return {
       tableData: [],
       loading: false,
       queryParams: {
+        signPatentNo:this.signPatentNo,
         taskId: this.taskId,
         reportId:this.reportId,
         taskStatus:this.activeName=='first'?0:1,