You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
109 lines
2.7 KiB
Vue
109 lines
2.7 KiB
Vue
10 months ago
|
<!--
|
||
|
* @description: 共性指标
|
||
|
* @fileName: CommonIndex
|
||
|
* @author: 17076
|
||
|
* @date: 2024/6/26-下午3:12
|
||
|
* @version: V1.0.0
|
||
|
-->
|
||
|
|
||
|
<template>
|
||
|
<div class="common-content">
|
||
|
<vxe-grid v-bind="gridOptions" style="margin-top: 10px">
|
||
|
<template #opera="{row}">
|
||
|
<el-button type="text" icon="el-icon-check" @click="handelStart(row)" />
|
||
|
<el-button type="text" icon="el-icon-close" @click="handleDel(row)" />
|
||
|
</template>
|
||
|
<template #result="{row}">
|
||
|
<el-tag :type="row.indexResult === 'true' ? 'success' : 'error'">{{ row.indexResult === 'true' ? '符合' : '不符合' }}</el-tag>
|
||
|
</template>
|
||
|
</vxe-grid>
|
||
|
<div style="text-align: center">
|
||
|
<cs-page
|
||
|
:page.sync="queryForm.page"
|
||
|
:limit.sync="queryForm.size"
|
||
|
:total="queryForm.total"
|
||
|
@pagination="fetchData"
|
||
|
/>
|
||
|
</div>
|
||
|
</div>
|
||
|
</template>
|
||
|
|
||
|
<script>
|
||
|
import mixin from '@/views/mixin'
|
||
|
import { queryIndexDetail } from '@/api/caseDetails'
|
||
|
|
||
|
export default {
|
||
|
name: 'CommonIndex',
|
||
|
mixins: [mixin],
|
||
|
props: {
|
||
|
// 是否编辑
|
||
|
isEdit: {
|
||
|
type: Boolean,
|
||
|
default: false
|
||
|
},
|
||
|
// 是否展开
|
||
|
isExpand: {
|
||
|
type: Boolean,
|
||
|
default: true
|
||
|
}
|
||
|
},
|
||
|
data() {
|
||
|
return {
|
||
|
gridOptions: {
|
||
|
...mixin.data().gridOptions,
|
||
|
treeConfig: {},
|
||
|
columns: [
|
||
|
{ title: '', width: '50px', treeNode: true },
|
||
|
{ title: '序号', type: 'seq', width: '50px' },
|
||
|
{ title: '指标名称', field: 'indexName' },
|
||
|
{ title: '分值', field: 'score' },
|
||
|
{ title: '笔录结果', field: 'record' },
|
||
|
{ title: '分析结果', field: 'indexResult', slots: { default: 'result' }}
|
||
|
// { title: '原子指标', field: 'atomicIndex' }
|
||
|
// { title: '必要证据', field: 'questioner' },
|
||
|
// { title: '评估结果', field: 'startTime' },
|
||
|
// { title: '评估操作', slots: { default: 'opera' }, fixed: 'right', width: '100px' }
|
||
|
],
|
||
|
data: []
|
||
|
}
|
||
|
}
|
||
|
},
|
||
|
watch: {
|
||
|
isExpand: {
|
||
|
handler: function(newVal, oldVal) {
|
||
|
if (newVal !== oldVal) {
|
||
|
this.tableHeight(this.isExpand ? 500 : 330)
|
||
|
}
|
||
|
},
|
||
|
immediate: true
|
||
|
}
|
||
|
},
|
||
|
mounted() {
|
||
|
this.fetchData()
|
||
|
},
|
||
|
methods: {
|
||
|
// 获取数据
|
||
|
fetchData() {
|
||
|
queryIndexDetail({ caseId: this.$route.params['id'], indexType: '1' }, this.queryForm.page, this.queryForm.size).then(res => {
|
||
|
this.gridOptions.data = res.data.result
|
||
|
this.queryForm.total = res.data.total
|
||
|
})
|
||
|
},
|
||
|
// 开始分析
|
||
|
handelStart(row) {
|
||
|
|
||
|
},
|
||
|
// 删除
|
||
|
handleDel(row) {
|
||
|
this.$baseConfirm('你确定要删除当前项吗', null, async() => {
|
||
|
|
||
|
})
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
</script>
|
||
|
|
||
|
<style scoped lang="scss">
|
||
|
|
||
|
</style>
|