修改已知问题
This commit is contained in:
+8
-4
@@ -177,11 +177,13 @@
|
||||
//导出
|
||||
handleExport() {
|
||||
let query = {
|
||||
lawsOpinionGatherId: this.lawsOpinionGatherId,
|
||||
actiProcInstId: this.actiProcInstId
|
||||
pageSize:this.pageSize,
|
||||
pageNo:this.pageNo
|
||||
// lawsOpinionGatherId: this.lawsOpinionGatherId,
|
||||
// actiProcInstId: this.actiProcInstId
|
||||
}
|
||||
downloadFile('/lawsOpinionGather/lawsOpinionAssessmentResultEO/exportXls',
|
||||
this.$t('evaluationResults') + '.xls', query)
|
||||
this.$t('evaluationResults') + '.zip', query)
|
||||
},
|
||||
getData(row) {
|
||||
this.visible = true
|
||||
@@ -206,7 +208,9 @@
|
||||
getList() {
|
||||
let query = {
|
||||
lawsOpinionGatherId: this.lawsOpinionGatherId,
|
||||
actiProcInstId: this.actiProcInstId
|
||||
actiProcInstId: this.actiProcInstId,
|
||||
pageSize:this.pageSize,
|
||||
pageNo:this.pageNo
|
||||
}
|
||||
this.loading = true
|
||||
getAction('/lawsOpinionGather/lawsOpinionAssessmentResultEO/page', query).then((res) => {
|
||||
|
||||
@@ -27,16 +27,16 @@
|
||||
</div>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<div v-for="(item,index) in dataList" :key="index">
|
||||
<div v-for="(item,index) in formInline.dataList" :key="index">
|
||||
<div class="feedbackPoint">
|
||||
{{$t('feedbackPoint')+(index+1)}}
|
||||
<a-icon class="icon-size"
|
||||
@click="addData"
|
||||
v-if="(dataList.length-1) == index"
|
||||
v-if="(formInline.dataList.length-1) == index"
|
||||
type="plus-circle"/>
|
||||
<a-icon class="icon-size"
|
||||
@click="deleteData"
|
||||
v-if="dataList.length > 1 && (dataList.length - 1) == index"
|
||||
v-if="formInline.dataList.length > 1 && (formInline.dataList.length - 1) == index"
|
||||
type="minus-circle"/>
|
||||
</div>
|
||||
<a-row :gutter="24">
|
||||
@@ -46,7 +46,11 @@
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('relevantSections')">{{$t('relevantSections')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="relatedSection">
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.relatedSection'"
|
||||
:rules="[{ required: true, message: $t('relevantSections') + $t('cannotEmpty'), trigger: 'blur'},
|
||||
{max: 300,message: $t('relevantSections') + $t('cannotExceed') + 300 + $t('Characters'),trigger: 'blur'
|
||||
}]">
|
||||
<a-input class="box-input"
|
||||
:disabled="disabled"
|
||||
v-model="item.relatedSection"
|
||||
@@ -61,7 +65,10 @@
|
||||
<span class="title-text-text"
|
||||
:title="$t('problemDescription')">{{$t('problemDescription')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="issueOrSuggest">
|
||||
<a-form-model-item class="itemModel" :prop="'dataList.'+index+'.issueOrSuggest'"
|
||||
:rules="[{ required: true, message: $t('problemDescription') + $t('cannotEmpty'), trigger: 'blur'},
|
||||
{max: 300,message: $t('problemDescription') + $t('cannotExceed') + 300 + $t('Characters'),trigger: 'blur'
|
||||
}]">
|
||||
<a-input class="box-input"
|
||||
:disabled="disabled"
|
||||
v-model="item.issueOrSuggest"
|
||||
@@ -97,6 +104,7 @@
|
||||
<script>
|
||||
import { getAction, postAction } from '@/api/manage'
|
||||
import uploadFile from '@/components/uploadFile/file'
|
||||
|
||||
export default {
|
||||
name: 'evaluatorFeedback',
|
||||
components: {
|
||||
@@ -107,44 +115,78 @@
|
||||
type: String,
|
||||
default: ''
|
||||
},
|
||||
feedbackDataList:{
|
||||
feedbackDataList: {
|
||||
type: Array,
|
||||
default: (()=>{
|
||||
default: (() => {
|
||||
return []
|
||||
})
|
||||
},
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
formInline: {},
|
||||
disabled:false,
|
||||
rules: {},
|
||||
uploadIndex:'',
|
||||
disabled: false,
|
||||
rules: {
|
||||
flag:[
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('complianceResults') + this.$t('cannotEmpty'),
|
||||
trigger: 'change'
|
||||
},
|
||||
],
|
||||
relatedSection: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('relevantSections') + this.$t('cannotEmpty'),
|
||||
trigger: 'blur'
|
||||
},
|
||||
{
|
||||
max: 300,
|
||||
message: this.$t('relevantSections') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
|
||||
trigger: 'blur'
|
||||
}
|
||||
],
|
||||
issueOrSuggest: [
|
||||
{
|
||||
required: true,
|
||||
message: this.$t('problemDescription') + this.$t('cannotEmpty'),
|
||||
trigger: 'blur'
|
||||
},
|
||||
{
|
||||
max: 300,
|
||||
message: this.$t('problemDescription') + this.$t('cannotExceed') + 300 + this.$t('Characters'),
|
||||
trigger: 'blur'
|
||||
}
|
||||
]
|
||||
},
|
||||
uploadIndex: '',
|
||||
dataList: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
if (this.feedbackDataList && this.feedbackDataList.length > 0){
|
||||
this.dataList = this.feedbackDataList
|
||||
this.dataList = [...this.dataList]
|
||||
}else{
|
||||
this.dataList = [
|
||||
{
|
||||
relatedSection: '',
|
||||
issueOrSuggest: '',
|
||||
reason: '',
|
||||
accessoryFile: ''
|
||||
}
|
||||
]
|
||||
}
|
||||
this.$nextTick(() => {
|
||||
if (this.feedbackDataList && this.feedbackDataList.length > 0) {
|
||||
this.formInline.dataList = this.feedbackDataList
|
||||
} else {
|
||||
this.formInline.dataList = [
|
||||
{
|
||||
relatedSection: '',
|
||||
issueOrSuggest: '',
|
||||
reason: '',
|
||||
accessoryFile: ''
|
||||
}
|
||||
]
|
||||
}
|
||||
this.formInline = { ...this.formInline }
|
||||
})
|
||||
},
|
||||
methods: {
|
||||
clickButtonToUpload(item,index) {
|
||||
clickButtonToUpload(item, index) {
|
||||
this.$refs.uploadFile.perentHandleFunc()
|
||||
this.$refs.uploadFile.visible = true
|
||||
this.uploadName = item
|
||||
this.uploadIndex = index
|
||||
getAction('sys/common/getFileInfos', { id: this.dataList[this.uploadIndex][this.uploadName] }).then((res) => {
|
||||
getAction('sys/common/getFileInfos', { id: this.formInline.dataList[this.uploadIndex][this.uploadName] }).then((res) => {
|
||||
if (res.success) {
|
||||
this.$refs.uploadFile.perentHandleFunc(res.result)
|
||||
} else {
|
||||
@@ -161,22 +203,29 @@
|
||||
})
|
||||
}
|
||||
/** 赋值给当前对应的表单文件 */
|
||||
this.dataList[this.uploadIndex][this.uploadName] = attIdList.join(',')
|
||||
this.dataList = [...this.dataList]
|
||||
this.formInline.dataList[this.uploadIndex][this.uploadName] = attIdList.join(',')
|
||||
this.formInline = [...this.formInline]
|
||||
},
|
||||
addData() {
|
||||
this.dataList.push({
|
||||
this.formInline.dataList.push({
|
||||
relatedSection: '',
|
||||
issueOrSuggest: '',
|
||||
reason: '',
|
||||
accessoryFile: ''
|
||||
})
|
||||
this.dataList = [...this.dataList]
|
||||
this.formInline = [...this.formInline]
|
||||
},
|
||||
deleteData() {
|
||||
this.dataList.pop()
|
||||
this.dataList = [...this.dataList]
|
||||
}
|
||||
this.formInline.dataList.pop()
|
||||
this.formInline = [...this.formInline]
|
||||
},
|
||||
submitData(callBack){
|
||||
this.$refs.ruleForm.validate(valid => {
|
||||
if (valid) {
|
||||
callBack && callBack(this.formInline)
|
||||
}
|
||||
})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -7,16 +7,16 @@
|
||||
</div>
|
||||
<div class="content-text">
|
||||
<a-form-model :model="formInline" class="formAdd" :rules="rules" ref="ruleForm">
|
||||
<div v-for="(item,index) in dataList" :key="index">
|
||||
<div v-for="(item,index) in formInline.dataList" :key="index">
|
||||
<div class="feedbackPoint">
|
||||
{{$t('feedbackPoint')+(index+1)}}
|
||||
<a-icon class="icon-size"
|
||||
@click="addData"
|
||||
v-if="(dataList.length-1) == index"
|
||||
v-if="(formInline.dataList.length-1) == index"
|
||||
type="plus-circle"/>
|
||||
<a-icon class="icon-size"
|
||||
@click="deleteData"
|
||||
v-if="dataList.length > 1 && (dataList.length - 1) == index"
|
||||
v-if="formInline.dataList.length > 1 && (formInline.dataList.length - 1) == index"
|
||||
type="minus-circle"/>
|
||||
</div>
|
||||
<a-row :gutter="24">
|
||||
@@ -26,7 +26,11 @@
|
||||
<span class="Required">*</span>
|
||||
<span class="title-text-text" :title="$t('relevantSections')">{{$t('relevantSections')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="relatedSection">
|
||||
<a-form-model-item class="itemModel"
|
||||
:prop="'dataList.'+index+'.relatedSection'"
|
||||
:rules="[{ required: true, message: $t('relevantSections') + $t('cannotEmpty'), trigger: 'blur'},
|
||||
{max: 300,message: $t('relevantSections') + $t('cannotExceed') + 300 + $t('Characters'),trigger: 'blur'
|
||||
}]">
|
||||
<a-input class="box-input"
|
||||
:disabled="disabled"
|
||||
v-model="item.relatedSection"
|
||||
@@ -41,7 +45,10 @@
|
||||
<span class="title-text-text"
|
||||
:title="$t('questionsSuggestions')">{{$t('questionsSuggestions')}}</span>
|
||||
</div>
|
||||
<a-form-model-item class="itemModel" prop="issueOrSuggest">
|
||||
<a-form-model-item class="itemModel" :prop="'dataList.'+index+'.issueOrSuggest'"
|
||||
:rules="[{ required: true, message: $t('questionsSuggestions') + $t('cannotEmpty'), trigger: 'blur'},
|
||||
{max: 300,message: $t('questionsSuggestions') + $t('cannotExceed') + 300 + $t('Characters'),trigger: 'blur'
|
||||
}]">
|
||||
<a-input class="box-input"
|
||||
:disabled="disabled"
|
||||
v-model="item.issueOrSuggest"
|
||||
@@ -101,44 +108,48 @@
|
||||
type: String,
|
||||
default: ''
|
||||
},
|
||||
feedbackDataList:{
|
||||
feedbackDataList: {
|
||||
type: Array,
|
||||
default: (()=>{
|
||||
return []
|
||||
default: (() => {
|
||||
return []
|
||||
})
|
||||
},
|
||||
}
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
formInline: {},
|
||||
disabled:false,
|
||||
disabled: false,
|
||||
rules: {},
|
||||
uploadIndex:'',
|
||||
uploadIndex: '',
|
||||
dataList: []
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
if (this.feedbackDataList && this.feedbackDataList.length > 0){
|
||||
this.dataList = this.feedbackDataList
|
||||
this.dataList = [...this.dataList]
|
||||
}else{
|
||||
this.dataList = [
|
||||
{
|
||||
relatedSection: '',
|
||||
issueOrSuggest: '',
|
||||
reason: '',
|
||||
accessoryFile: ''
|
||||
}
|
||||
]
|
||||
}
|
||||
this.$nextTick(() => {
|
||||
if (this.feedbackDataList && this.feedbackDataList.length > 0) {
|
||||
this.formInline.dataList = this.feedbackDataList
|
||||
this.formInline = { ...this.formInline }
|
||||
} else {
|
||||
this.formInline.dataList = [
|
||||
{
|
||||
relatedSection: '',
|
||||
issueOrSuggest: '',
|
||||
reason: '',
|
||||
accessoryFile: ''
|
||||
}
|
||||
]
|
||||
}
|
||||
this.formInline = { ...this.formInline }
|
||||
})
|
||||
|
||||
},
|
||||
methods: {
|
||||
clickButtonToUpload(item,index) {
|
||||
clickButtonToUpload(item, index) {
|
||||
this.$refs.uploadFile.perentHandleFunc()
|
||||
this.$refs.uploadFile.visible = true
|
||||
this.uploadName = item
|
||||
this.uploadIndex = index
|
||||
getAction('sys/common/getFileInfos', { id: this.dataList[this.uploadIndex][this.uploadName] }).then((res) => {
|
||||
getAction('sys/common/getFileInfos', { id: this.formInline.dataList[this.uploadIndex][this.uploadName] }).then((res) => {
|
||||
if (res.success) {
|
||||
this.$refs.uploadFile.perentHandleFunc(res.result)
|
||||
} else {
|
||||
@@ -155,21 +166,21 @@
|
||||
})
|
||||
}
|
||||
/** 赋值给当前对应的表单文件 */
|
||||
this.dataList[this.uploadIndex][this.uploadName] = attIdList.join(',')
|
||||
this.dataList = [...this.dataList]
|
||||
this.formInline.dataList[this.uploadIndex][this.uploadName] = attIdList.join(',')
|
||||
this.formInline = { ...this.formInline }
|
||||
},
|
||||
addData() {
|
||||
this.dataList.push({
|
||||
this.formInline.dataList.push({
|
||||
relatedSection: '',
|
||||
issueOrSuggest: '',
|
||||
reason: '',
|
||||
accessoryFile: ''
|
||||
})
|
||||
this.dataList = [...this.dataList]
|
||||
this.formInline = { ...this.formInline }
|
||||
},
|
||||
deleteData() {
|
||||
this.dataList.pop()
|
||||
this.dataList = [...this.dataList]
|
||||
this.formInline.dataList.pop()
|
||||
this.formInline = { ...this.formInline }
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -170,8 +170,9 @@
|
||||
})
|
||||
},
|
||||
submit() {
|
||||
let dataList = this.$refs.feedbackInformationRef.dataList
|
||||
this.insertBatch(dataList, 2)
|
||||
this.$refs.evaluatorFeedbackRef.submitData()
|
||||
// let dataList = this.$refs.feedbackInformationRef.dataList
|
||||
// this.insertBatch(dataList, 2)
|
||||
},
|
||||
completeTask() {
|
||||
let query = {
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
},
|
||||
preservation() {
|
||||
this.loading = true
|
||||
let dataList = this.$refs.feedbackInformationRef.dataList
|
||||
let dataList = this.$refs.feedbackInformationRef.formInline.dataList
|
||||
this.insertBatch(dataList, 1)
|
||||
},
|
||||
insertBatch(list, num) {
|
||||
@@ -162,7 +162,7 @@
|
||||
})
|
||||
},
|
||||
submit() {
|
||||
let dataList = this.$refs.feedbackInformationRef.dataList
|
||||
let dataList = this.$refs.feedbackInformationRef.formInline.dataList
|
||||
this.insertBatch(dataList, 2)
|
||||
},
|
||||
completeTask() {
|
||||
|
||||
Reference in New Issue
Block a user