index.vue 3.37 KB
<template>
    <div class="main">
        <div class="button">
            <el-button type="primary" @click="newAdd">新增</el-button>
        </div>
        <div class="table">
            <table border="1">
                <tr>
                    <td>序号</td>
                    <td>宗地代码</td>
                    <td>不动产单元号</td>
                    <td>项目名称</td>
                    <td>不动产权证号</td>
                    <td>权利人</td>
                    <td>坐落</td>
                </tr>
                <tr v-if="Object.keys(bgqData)==0">
                    <td colspan="7">
                        <span class="noData">暂无数据</span>
                    </td>
                </tr>
                <tr v-else>
                    <!--<tr v-else v-for="(item,index) in bgqData" :key="index">-->
                    <td>1</td>
                    <td><input type="text" class="formInput" v-model="bgqData.zddm" readonly="readonly"/></td>
                    <td><input type="text" class="formInput" v-model="bgqData.bdcdyh" readonly="readonly"/></td>
                    <td><input type="text" class="formInput" v-model="bgqData.xmmc" readonly="readonly"/></td>
                    <td><input type="text" class="formInput" v-model="bgqData.bdcqzh" readonly="readonly"/></td>
                    <td><input type="text" class="formInput" v-model="bgqData.qlr" readonly="readonly"/></td>
                    <td><input type="text" class="formInput" v-model="bgqData.zl" readonly="readonly"/></td>
                </tr>
            </table>
        </div>
        <query-data @getData="getData" :centerDialogVisible.sync="centerDialogVisible" @close="close"></query-data>
    </div>
</template>

<script>
    import QueryData from './../../../../components/queryData/queryData'

    export default {
        name: "",
        components: {QueryData},
        props: {},
        data() {
            return {
                centerDialogVisible: false,
                bgqData: {}
            }
        },
        created() {
        },
        mounted() {
        },
        methods: {
            close: function () {
                this.centerDialogVisible = false;
            },
            newAdd: function () {
                this.centerDialogVisible = true;
            },
            addData: function (val) {
                this.centerDialogVisible = false;
                this.bgqData = val
            },
            getData: function (data) {
                this.bgqData = data
            },
        },
        computed: {},
        watch: {},
    }
</script>
<style scoped lang="less">
    .main {
        box-sizing: border-box;
        padding: 18px;
        height: auto;
        width: 80%;
        table {
            margin-top: 10px;
            background-color: #fff;
            font-size: 14px;
            width: 100%;

            .formInput {
                margin: 0;
                height: 36px;
                outline: none;
                border: none;
                color: #606764;
                overflow: visible;
                text-align: center;
                cursor: text;
            }

        }

        td {
            text-align: center;
            height: 36px;
            min-width: 50px;
        }

        table:hover {
            cursor: pointer;
        }

        .noData {
            color: #b2b2b2;
        }
    }
</style>