Commit 9f8b168e authored by 何鹏程's avatar 何鹏程

完成功能

parent 758ef089
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
:title="title" :title="title"
:visible.sync="dialogVisible" :visible.sync="dialogVisible"
width="1000px" width="1000px"
append-to-body
@closed="closedHandler" @closed="closedHandler"
:close-on-click-modal="false" :close-on-click-modal="false"
class="emergencyCarDialog" class="emergencyCarDialog"
...@@ -509,6 +510,8 @@ export default { ...@@ -509,6 +510,8 @@ export default {
if (type === 'update' || type === 'detail') { if (type === 'update' || type === 'detail') {
if (!id) { if (!id) {
this.$message.error('救护车id不能为空') this.$message.error('救护车id不能为空')
this.dialogVisible = false
this.loading = false
return return
} }
queryTeamEmergencyCarInfo({ id: id }).then(res => { queryTeamEmergencyCarInfo({ id: id }).then(res => {
......
...@@ -2,7 +2,8 @@ ...@@ -2,7 +2,8 @@
<el-dialog <el-dialog
:title="title + '救护车信息明细'" :title="title + '救护车信息明细'"
:visible.sync="dialogVisible" :visible.sync="dialogVisible"
width="1200px" append-to-body
width="1300px"
:close-on-click-modal="false" :close-on-click-modal="false"
class="detailDialog" class="detailDialog"
> >
...@@ -50,17 +51,38 @@ ...@@ -50,17 +51,38 @@
<span v-else>{{ scope.row[scope.column.property] }}</span> <span v-else>{{ scope.row[scope.column.property] }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column
label="操作"
align="left"
width="auto"
min-width="100px"
>
<template slot-scope="scope">
<el-link
type="primary"
@click="showEmergencyCarDialog('detail',scope.row.id)"
>查看详情</el-link>
</template>
</el-table-column>
</el-table> </el-table>
</table-mixin> </table-mixin>
<EmergencyCarDialog
ref="emergencyCarDialog"
@subsucc="search"
/>
</el-dialog> </el-dialog>
</template> </template>
<script> <script>
import { queryTotalCarInfoByHospital } from '@/api/emergencyCar' import { queryTotalCarInfoByHospital } from '@/api/emergencyCar'
import { tableDataMixin } from '../../../common/js/mixin' import { tableDataMixin } from '../../../common/js/mixin'
import EmergencyCarDialog from '../../emergencyCar/components/emergencyCarDialog.vue'
export default { export default {
name: 'detailDialog', name: 'detailDialog',
mixins: [tableDataMixin], mixins: [tableDataMixin],
components: {
EmergencyCarDialog
},
data() { data() {
return { return {
dialogVisible: false, dialogVisible: false,
...@@ -172,6 +194,12 @@ export default { ...@@ -172,6 +194,12 @@ export default {
} }
}) })
}, },
showEmergencyCarDialog(type = 'add', id = '') {
this.$refs.emergencyCarDialog.init(type, id)
},
search() {
}
} }
} }
</script> </script>
......
...@@ -140,11 +140,11 @@ const dist = { ...@@ -140,11 +140,11 @@ const dist = {
val: 3, val: 3,
id: 3 id: 3
}, },
{ // {
name: '已删除', // name: '已删除',
val: 4, // val: 4,
id: 4 // id: 4
}, // },
{ {
name: '删除审核中', name: '删除审核中',
val: 5, val: 5,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment