|
@@ -47,7 +47,7 @@ export default {
|
|
|
},
|
|
|
created() {},
|
|
|
async mounted() {
|
|
|
- this.column = await this.$commonJS.getCustomField(this.type)
|
|
|
+ this.column = await this.$commonJS.getCustomField(this.type,{ projectId: this.projectId })
|
|
|
this.init()
|
|
|
this.getClaims()
|
|
|
// this.getCompareLiterature()
|
|
@@ -384,7 +384,9 @@ export default {
|
|
|
// if(!(parts.length>1 && parts[parts.length - 1]!='claimText'+row.id)){
|
|
|
// return
|
|
|
// }
|
|
|
-
|
|
|
+ if(['courtOpinions1','courtOpinions2'].indexOf(this.editMessage.field.field)!=-1){
|
|
|
+ this.closeEdit()
|
|
|
+ }
|
|
|
}
|
|
|
// this.editField = null
|
|
|
},
|
|
@@ -395,7 +397,7 @@ export default {
|
|
|
},
|
|
|
//修改数据
|
|
|
changeMessage(field,row,value){
|
|
|
- var value1 = this.getColumnData(this.editMessage.row,field)
|
|
|
+ var value1 = this.getColumnData(this.editMessage.data,field)
|
|
|
if(value == value1){
|
|
|
this.closeEdit()
|
|
|
return
|
|
@@ -420,19 +422,30 @@ export default {
|
|
|
params[part] = value
|
|
|
api = 'editFeature'
|
|
|
}
|
|
|
-
|
|
|
+ var message = this.$message({
|
|
|
+ message: '信息保存中...',
|
|
|
+ type: 'warning',
|
|
|
+ duration:0
|
|
|
+ });
|
|
|
this.$api[api](params).then(response=>{
|
|
|
if(response.code == 200){
|
|
|
+ message.close()
|
|
|
this.$message.success('编辑成功')
|
|
|
+
|
|
|
if(sign){
|
|
|
this.init()
|
|
|
}else{
|
|
|
this.getData(row,field,value)
|
|
|
}
|
|
|
this.closeEdit()
|
|
|
+
|
|
|
}
|
|
|
}).catch(error=>{
|
|
|
-
|
|
|
+ message.close()
|
|
|
+ this.$message.success('编辑失败')
|
|
|
+ if(this.$refs[field.field+row.proofGroupId] && this.$refs[field.field+row.proofGroupId][0]){
|
|
|
+ this.$refs[field.field+row.proofGroupId][0].setFocus()
|
|
|
+ }
|
|
|
})
|
|
|
},
|
|
|
//添加特征
|
|
@@ -450,21 +463,44 @@ export default {
|
|
|
}else{
|
|
|
obj.featureSort = Number(featureSort) + 1
|
|
|
}
|
|
|
+ this.loading = true
|
|
|
+ var that = this
|
|
|
this.$api.addFeature(obj).then(response=>{
|
|
|
if(response.code == 200){
|
|
|
+ that.loading = false
|
|
|
var data = {
|
|
|
invalidReasonDTO:row.invalidReasonDTO,
|
|
|
...obj,
|
|
|
proofGroupId:response.data,
|
|
|
}
|
|
|
+ that.updateSort(obj.featureSort,obj.invalidStatueId,'add')
|
|
|
if(type == 'up'){
|
|
|
- this.tableData.splice(index,0,data)
|
|
|
+ that.tableData.splice(index,0,data)
|
|
|
}else{
|
|
|
- this.tableData.splice(index+1,0,data)
|
|
|
+ that.tableData.splice(index+1,0,data)
|
|
|
}
|
|
|
- this.getSpanArr(this.tableData)
|
|
|
+ that.getSpanArr(this.tableData)
|
|
|
}
|
|
|
+ }).catch(error=>{
|
|
|
+ this.loading = false
|
|
|
+ })
|
|
|
+ },
|
|
|
+ //更新序号
|
|
|
+ updateSort(sort,invalidStatueId,type){
|
|
|
+ var arr = this.tableData.filter(item=>{
|
|
|
+ return item.invalidReasonDTO.invalidStatueId == invalidStatueId
|
|
|
})
|
|
|
+ for(var i = 0;i<arr.length;i++){
|
|
|
+ var featureSort = Number(arr[i].featureSort)
|
|
|
+ if(featureSort>= sort){
|
|
|
+ if(type == 'add'){
|
|
|
+ arr[i].featureSort = featureSort+1
|
|
|
+ }else if(type == 'del'){
|
|
|
+ arr[i].featureSort = featureSort-1
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return true
|
|
|
},
|
|
|
//删除无效理由
|
|
|
delInvalidStatue(scope){
|