forbit ask when answering

This commit is contained in:
AceDataCloud committed 2023-04-07 20:00:48 +08:00
1 parent 35a5854133
commit e55b894309
2 files changed
+10 -1

No files matched your search

@@ -2,7 +2,7 @@
<div class="new-message-box">
<el-input
v-model="value"
:disabled="!application"
:disabled="!application || answering"
class="new-message-input"
:placeholder="$t('conversation.message.newMessagePlaceholder')"
@keyup.enter="$emit('send')"
@@ -63,6 +63,11 @@ export default defineComponent({
required: false,
default: false
},
answering: {
type: Boolean,
required: false,
default: false
},
modelValue: {
type: String,
required: true
+4
View File
@@ -33,6 +33,7 @@
<new-message-box
v-model="input"
:initializing="loading"
:answering="answering"
class="new-message"
:api="api"
:application="application"
@@ -209,6 +210,9 @@ export default defineComponent({
this.input = content;
},
onSend() {
if (this.answering) {
return;
}
if (!this.input) {
ElMessage.error(this.$t('conversation.message.noInput'));
return;