pms-aomei/src/components/BaseAgreeOrNot.vue

31 lines
562 B
Vue
Raw Normal View History

2023-01-16 11:08:54 +08:00
<template>
<!-- 同意或不同意组件点击不同意的时候出现额外的输入框说明原因 -->
<el-row>
<el-button type="primary" @click="doAgree">同意</el-button>
<el-button @click="dontAgree">不同意</el-button>
</el-row>
</template>
<script>
export default {
name: '',
props: {},
emits: ['not-agree', 'agree'],
data() {
return {
reason: 'dont agree reason',
};
},
methods: {
doAgree() {
this.$emit('agree');
},
dontAgree() {
this.$emit('not-agree', this.reason);
},
},
};
</script>
<style scoped></style>