<template>
    <div class="page">
        <LayoutTable :data="tableData" :config="tableConfig">
                    </LayoutTable>


        <drawer-show ref="drawerform" @ok="getData" />
    </div>
</template>

<script>
    /** 表单弹出框模式需引入 */
    import drawerShow from "./drawershow";
    import table from "@/assets/mixins/table";
    export default {
        name: "CareDoworkRecordsList",
        components: {
            drawerShow
},
        mixins: [table],
        created() {
        },
        methods: {
            /** 重写新增方法 */
            toAdd(row) {
                this.$refs.drawerform.add(row);
            },
            /** 重写编辑方法 */
            toEdit(row) {
                this.$refs.drawerform.edit(row);
            },
            /** 重写查看方法 */
            toView(row) {
                this.$refs.drawerform.view(row);
            },

        },
        data() {
            return {
                config: {
                    search: [
                    ],
                    columns: [
                        {type: "selection", width: 60},
                        {type: "index",label: "序号",width: 50},

                        {label: "站点Id", prop: "siteId", formatter: this.formatter},


                            {label: "站点名称", prop: "siteName"},


                        {label: "个人信息ID", prop: "personId", formatter: this.formatter},

                        {label: "办理号ID与等待号id一致", prop: "doWorkId", formatter: this.formatter},


                            {label: "姓名", prop: "name"},



                            {label: "联系方式", prop: "contact"},



                            {label: "身份证号码", prop: "idCard"},


                        {label: "业务Id", prop: "bussinessId", formatter: this.formatter},


                            {label: "预约业务", prop: "bussinessName"},



                            {label: "办理业务", prop: "service"},



                            {label: "排队编号", prop: "queueNo"},


                        {label: "排队开始时间", prop: "takeTime", formatter: this.formatterDate},

                        {label: "排队结束时间-业务办理开始时间", prop: "callTime", formatter: this.formatterDate},

                        {label: "办理结束时间", prop: "endTime", formatter: this.formatterDate},

                        {label: "最终办理时长，秒", prop: "waitTime",formatter: this.formatter},

                        {label: "告警次数", prop: "careCount",formatter: this.formatter},

                        {label: "短信发送次数", prop: "smsCount",formatter: this.formatter},


                            {label: "评价", prop: "assessment"},

                        {
                            label: "操作",
                            width: 240,
                            formatter: row => {
                                return (
                                    <table-buttons noAdd row={row} onEdit={this.toEdit} onView={this.toView} onDel={this.toDel} />
                            );
                            }
                        }
                    ]
                }
            };
        }
    };
</script>