<template>
    <el-card shadow="always" class="search_header_top_row1">

        <el-form :inline="true" :model="filterForm" class="demo-form-inline">
            <el-form-item label="姓名/身份证/联系方式"> 
                <el-input v-model.trim="filterForm.keyword" placeholder="请输入姓名/身份证/联系方式" clearable style="width:250px;" />
            </el-form-item>
            <el-form-item label="系统角色" prop="roleType">
                <el-select v-model.trim="filterForm.roleType" placeholder="请选择系统角色" clearable filterable>
                    <el-option v-for="item in roleTypeInfo.list" :key="item.value" :label="item.label"
                        :value="item.value" />
                </el-select>
            </el-form-item>

            <el-form-item>
                <el-button type="primary" @click="serachFn">查询</el-button>
                <el-button type="plain" @click="resetFn">重置</el-button>

            </el-form-item>
        </el-form>
        <div>
            <el-button type="primary" @click="addFn">新增</el-button>
            <el-button type="primary" @click="batchDownFn">下载</el-button>
            <el-button type="primary" @click="exportFn">导出</el-button>
        </div>

    </el-card>
</template>

<script lang="ts" setup>
const emits = defineEmits(['search', 'reset', 'export','add','batchDown'])

const filterForm = reactive({
    keyword: '',
    roleType: ''
})

const roleTypeInfo = reactive({
    list: [{

        value: 'Option1',
        label: 'Option1',
    },
    {
        value: 'Option2',
        label: 'Option2',

    }]
})
const serachFn = () => {
    emits('search', filterForm)
}

const resetFn = () => {
    emits('reset')
}

const exportFn = () => {
    emits('export')
}
const addFn = () => {
    emits('add')
}
const batchDownFn = () => {
    emits('batchDown')
}
 
</script>

<style scoped lang="scss"></style>
