Commit ac978b88 authored by liqiuyu's avatar liqiuyu

feat(*): 我的已办模块开发

parent e364fa66
......@@ -10,17 +10,18 @@
<slot></slot>
</div>
<template #footer>
<div class="dialog-footer" v-if="btnGroup.length">
<div v-for="item in btnGroup" class="real-btn" :key="item.attrKey" @click="handleBtn(item.attrKey)">
{{ item.label }}
</div>
<div class="dialog-footer">
<el-button @click="closeDialog">关闭</el-button>
<el-button type="primary" v-if="btnGroup.length" v-for="item in btnGroup" class="real-btn" :key="item.attrKey" @click="handleBtn(item.attrKey)">
{{item.label}}
</el-button>
</div>
</template>
</el-dialog>
</template>
<script setup>
import { defineProps, defineEmits, ref, reactive,watch,onMounted } from 'vue';
import { defineProps, defineEmits } from 'vue';
const props = defineProps({
showDialog: {
......@@ -40,7 +41,7 @@ const props = defineProps({
default: () => ([])
}
});
const emit = defineEmits(['close:showDialog', 'handleBtn']);
const emit = defineEmits(['close:showDialog', 'handleBtn','onSave']);
/**
* @Description: 弹框关闭回调
* @author liqiuyu
......@@ -56,8 +57,16 @@ const closeDialog = () => {
* @date 2025/5/21
*/
const handleBtn = (key) => {
emit('handleBtn', key);
emit('handleBtn',key);
};
/**
* @Description: 确认按钮方法回调
* @author liqiuyu
* @date 2025/5/22
*/
const handleSave = ()=> {
emit('onSave');
}
</script>
<style scoped lang="scss">
......
This diff is collapsed.
This diff is collapsed.
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