<template>
    <div class="common-btn-box font12" @click="handleBtnClick()">
        <span>打印</span>
    </div>
</template>

<script setup lang="ts">
import { useMsg } from "@/hooks/useMsg";
const props: any = defineProps<{
    selectionList?: any[];
    handleBtnItemCallback?: () => void;
    ruleForm: any;
}>();
const emits = defineEmits<{
    (e: "handleBtnItemCallback", result: Record<string, any>): void;
}>();

// 提交事件
const handleBtnClick = () => {
    if (!props.selectionList.length) {
        useMsg("warning", "请选择需要打印的数据 ！");
        return false;
    }
    emits("handleBtnItemCallback", {
        type: "Print"
    });
};
</script>

<style scoped>
@import "../index.scss";
</style>
