|
@@ -42,6 +42,14 @@
|
|
|
>
|
|
|
{{ closeText }}
|
|
|
</v-btn>
|
|
|
+ <v-btn
|
|
|
+ v-if="props.otherBtnText"
|
|
|
+ color="primary"
|
|
|
+ text
|
|
|
+ @click="handleOtherBtn"
|
|
|
+ >
|
|
|
+ {{ otherBtnText }}
|
|
|
+ </v-btn>
|
|
|
<v-btn
|
|
|
color="primary"
|
|
|
text
|
|
@@ -61,7 +69,7 @@
|
|
|
<script setup>
|
|
|
import { ref, computed, watch } from 'vue'
|
|
|
defineOptions({ name: 'components-ct-dialog' })
|
|
|
-const emits = defineEmits(['update:visible', 'close', 'submit'])
|
|
|
+const emits = defineEmits(['update:visible', 'close', 'other', 'submit'])
|
|
|
|
|
|
const props = defineProps({
|
|
|
titleClass: {
|
|
@@ -100,6 +108,10 @@ const props = defineProps({
|
|
|
type: Boolean,
|
|
|
default: false
|
|
|
},
|
|
|
+ otherBtnText: {
|
|
|
+ type: String,
|
|
|
+ default: ''
|
|
|
+ },
|
|
|
closeable: {
|
|
|
type: Boolean,
|
|
|
default: true
|
|
@@ -123,6 +135,9 @@ const handleClose = () => {
|
|
|
// emits('update:visible', false)
|
|
|
emits('close', false)
|
|
|
}
|
|
|
+const handleOtherBtn = () => {
|
|
|
+ emits('other', false)
|
|
|
+}
|
|
|
const handleSave = () => {
|
|
|
emits('submit', false)
|
|
|
}
|