评分考核
This commit is contained in:
@@ -97,7 +97,7 @@
|
|||||||
<p class="text" v-if="item.explain">{{ item.explain }}</p>
|
<p class="text" v-if="item.explain">{{ item.explain }}</p>
|
||||||
<div class="left-item__item--wrapper">
|
<div class="left-item__item--wrapper">
|
||||||
<template v-if="(item.fieldType === 'radio')">
|
<template v-if="(item.fieldType === 'radio')">
|
||||||
<el-radio-group v-model="item.fieldValue" :disabled="item.inputType !== '2'">
|
<el-radio-group v-model="item.fieldValue" :disabled="item.inputType !== '2' || isDetail">
|
||||||
<el-radio :label="v.dictName" v-for="v in dict.getDict(item.dictionaryCode)" :key="v.dictName">{{ v.dictName }}</el-radio>
|
<el-radio :label="v.dictName" v-for="v in dict.getDict(item.dictionaryCode)" :key="v.dictName">{{ v.dictName }}</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</template>
|
</template>
|
||||||
@@ -106,12 +106,12 @@
|
|||||||
v-model="item.fieldValue"
|
v-model="item.fieldValue"
|
||||||
value-format="yyy-MM-DD"
|
value-format="yyy-MM-DD"
|
||||||
type="date"
|
type="date"
|
||||||
:disabled="item.inputType !== '2'"
|
:disabled="item.inputType !== '2' || isDetail"
|
||||||
:placeholder="`请选择${item.fieldName}`">
|
:placeholder="`请选择${item.fieldName}`">
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="(item.fieldType === 'score')">
|
<template v-if="(item.fieldType === 'score')">
|
||||||
<el-input-number :disabled="item.inputType !== '2'" style="width: 300px" size="small" :placeholder="`请输入${item.fieldName}`" v-model="item.fieldValue" :precision="1" :step="0.1" :max="10"></el-input-number>
|
<el-input-number :disabled="item.inputType !== '2' || isDetail" style="width: 300px" size="small" :placeholder="`请输入${item.fieldName}`" v-model="item.fieldValue" :precision="1" :step="0.1" :max="10"></el-input-number>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="item.fieldType === 'upload'">
|
<template v-if="item.fieldType === 'upload'">
|
||||||
<img style="width: 100%; height: 100%;" :src="formInfo[`field_${i}`]" v-if="formInfo[`field_${i}`]">
|
<img style="width: 100%; height: 100%;" :src="formInfo[`field_${i}`]" v-if="formInfo[`field_${i}`]">
|
||||||
@@ -122,13 +122,13 @@
|
|||||||
<template v-if="item.fieldType === 'select'">
|
<template v-if="item.fieldType === 'select'">
|
||||||
<ai-select
|
<ai-select
|
||||||
v-model="item.fieldValue"
|
v-model="item.fieldValue"
|
||||||
:disabled="item.inputType !== '2'"
|
:disabled="item.inputType !== '2' || isDetail"
|
||||||
:placeholder="`请输入${item.fieldName}`"
|
:placeholder="`请输入${item.fieldName}`"
|
||||||
:selectList="dict.getDict(item.dictionaryCode)">
|
:selectList="dict.getDict(item.dictionaryCode)">
|
||||||
</ai-select>
|
</ai-select>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="(item.fieldType === 'checkbox')">
|
<template v-if="(item.fieldType === 'checkbox')">
|
||||||
<el-checkbox-group :disabled="item.inputType !== '2'" v-model="item.fieldValue">
|
<el-checkbox-group :disabled="item.inputType !== '2' || isDetail" v-model="item.fieldValue">
|
||||||
<el-checkbox :label="v.dictName" v-for="v in dict.getDict(item.dictionaryCode)" :key="v.dictName">{{ v.dictName }}</el-checkbox>
|
<el-checkbox :label="v.dictName" v-for="v in dict.getDict(item.dictionaryCode)" :key="v.dictName">{{ v.dictName }}</el-checkbox>
|
||||||
</el-checkbox-group>
|
</el-checkbox-group>
|
||||||
</template>
|
</template>
|
||||||
@@ -137,10 +137,10 @@
|
|||||||
<img v-else style="width: 200px; height: 200px" :src="item.fieldValue" />
|
<img v-else style="width: 200px; height: 200px" :src="item.fieldValue" />
|
||||||
</template>
|
</template>
|
||||||
<template v-if="(item.fieldType === 'input')">
|
<template v-if="(item.fieldType === 'input')">
|
||||||
<el-input :disabled="item.inputType !== '2'" size="small" :placeholder="`请输入${item.fieldName}`" v-model="item.fieldValue"></el-input>
|
<el-input :disabled="item.inputType !== '2' || isDetail" size="small" :placeholder="`请输入${item.fieldName}`" v-model="item.fieldValue"></el-input>
|
||||||
</template>
|
</template>
|
||||||
<template v-if="(item.fieldType === 'textarea')">
|
<template v-if="(item.fieldType === 'textarea')">
|
||||||
<el-input :disabled="item.inputType !== '2'" size="small" type="textarea" :placeholder="`请输入${item.fieldName}`" v-model="item.fieldValue"></el-input>
|
<el-input :disabled="item.inputType !== '2' || isDetail" size="small" type="textarea" :placeholder="`请输入${item.fieldName}`" v-model="item.fieldValue"></el-input>
|
||||||
</template>
|
</template>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -150,8 +150,9 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="dialog-footer" slot="footer">
|
<div class="dialog-footer" slot="footer">
|
||||||
<el-button @click="onCancel">拒绝</el-button>
|
<el-button @click="isDetail = false, isShowForm = false" v-if="isDetail">关闭</el-button>
|
||||||
<el-button @click="onConfirm" type="primary" style="width: 92px;">通过</el-button>
|
<el-button @click="onCancel" v-if="!isDetail">拒绝</el-button>
|
||||||
|
<el-button @click="onConfirm" v-if="!isDetail" type="primary" style="width: 92px;">通过</el-button>
|
||||||
</div>
|
</div>
|
||||||
</ai-dialog>
|
</ai-dialog>
|
||||||
</template>
|
</template>
|
||||||
@@ -218,6 +219,7 @@
|
|||||||
],
|
],
|
||||||
tempInfo: {},
|
tempInfo: {},
|
||||||
list: [],
|
list: [],
|
||||||
|
isDetail: false,
|
||||||
filedList: []
|
filedList: []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -282,6 +284,56 @@
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
toDetail (id) {
|
||||||
|
this.instance.post(`/app/appassessmentscorev2task/queryDataInfoById2`, null, {
|
||||||
|
params: {
|
||||||
|
taskDetailId: id
|
||||||
|
}
|
||||||
|
}).then(res => {
|
||||||
|
if (res.code == 0) {
|
||||||
|
let list = {}
|
||||||
|
const filedList = res.data.filter(v => {
|
||||||
|
return v.inputType < 3
|
||||||
|
})
|
||||||
|
this.filedList = filedList
|
||||||
|
|
||||||
|
const dicts = filedList.filter(v => v.dictionaryCode).map(v => v.dictionaryCode)
|
||||||
|
this.dict.load(dicts)
|
||||||
|
let groups = this.unique(filedList.map(v => v.groupLevel1Name))
|
||||||
|
|
||||||
|
groups.forEach(item => {
|
||||||
|
let arr = {}
|
||||||
|
if (!list[item]) {
|
||||||
|
list[item] = []
|
||||||
|
}
|
||||||
|
|
||||||
|
const groupList = filedList.filter(v => v.groupLevel1Name === item)
|
||||||
|
const groups2 = this.unique(groupList.map(v => v.groupLevel2Name))
|
||||||
|
if (groups2.length) {
|
||||||
|
groups2.forEach(v => {
|
||||||
|
if (!arr[v]) {
|
||||||
|
arr[v] = []
|
||||||
|
}
|
||||||
|
|
||||||
|
arr[v] = groupList.filter(e => v === e.groupLevel2Name)
|
||||||
|
})
|
||||||
|
|
||||||
|
list[item] = arr
|
||||||
|
} else {
|
||||||
|
list[item] = {
|
||||||
|
'0': groupList
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
this.targetList = list
|
||||||
|
}
|
||||||
|
})
|
||||||
|
this.taskDetailId = id
|
||||||
|
this.isDetail = true
|
||||||
|
this.isShowForm = true
|
||||||
|
},
|
||||||
|
|
||||||
getInfo () {
|
getInfo () {
|
||||||
this.instance.post(`/app/appassessmentscorev2task/queryDetailById?id=${this.params.id}`).then(res => {
|
this.instance.post(`/app/appassessmentscorev2task/queryDetailById?id=${this.params.id}`).then(res => {
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user