From 6fce1a6e343ef33f18b4cffb9c529b4206860a38 Mon Sep 17 00:00:00 2001 From: liuye Date: Wed, 24 Jul 2024 13:59:29 +0800 Subject: [PATCH] =?UTF-8?q?=E5=AF=B9=E8=AF=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/project/biaopin/AppDialogue/AppDialogue.vue | 7 ++++++- src/project/biaopin/AppDialogue/Record.vue | 6 ++++++ src/project/biaopin/AppDialogue/Talk.vue | 3 ++- 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/src/project/biaopin/AppDialogue/AppDialogue.vue b/src/project/biaopin/AppDialogue/AppDialogue.vue index 1c8afa2e..545bc1d7 100644 --- a/src/project/biaopin/AppDialogue/AppDialogue.vue +++ b/src/project/biaopin/AppDialogue/AppDialogue.vue @@ -7,7 +7,7 @@ - + @@ -59,6 +59,11 @@ export default { this.showDetail = false } }, + onReachBottom() { + if(this.tabIndex == 1) { + this.$refs.Record.nextPage() + } + } }; diff --git a/src/project/biaopin/AppDialogue/Record.vue b/src/project/biaopin/AppDialogue/Record.vue index fdbbe704..fd03813a 100644 --- a/src/project/biaopin/AppDialogue/Record.vue +++ b/src/project/biaopin/AppDialogue/Record.vue @@ -67,6 +67,7 @@ export default { if(!this.user.token) { return this.$u.toast("请先进行登录") } + if(this.current > this.pages) return this.$loading() this.$http.post(`/app/appaicopilotinfo/listHistory?current=${this.current}&size=10&content=${this.searchVal}`).then(res => { if(res.code == 0 && res.data.records.length) { @@ -95,6 +96,7 @@ export default { }, getSearchList() { this.current = 1 + this.pages = 2 this.getHistoryList() }, handerClear() { @@ -117,6 +119,10 @@ export default { }) }).catch(() => { }) + }, + nextPage() { + this.current ++ + this.getHistoryList() } }, } diff --git a/src/project/biaopin/AppDialogue/Talk.vue b/src/project/biaopin/AppDialogue/Talk.vue index 82d4ecdc..0a76045e 100644 --- a/src/project/biaopin/AppDialogue/Talk.vue +++ b/src/project/biaopin/AppDialogue/Talk.vue @@ -315,6 +315,7 @@ export default { confirmType(val) { this.aiConfigId = val[0].value this.aiConfigName = val[0].label + this.messageList = [] }, getAiTypeList() { this.$http.post(`/app/appaiconfiginfo/list?status=1`).then(res => { @@ -326,7 +327,7 @@ export default { this.typeList = res.data.records this.aiConfigId = this.typeList[0].dictValue this.aiConfigName = this.typeList[0].dictName - this.getHistoryList() + // this.getHistoryList() } }) }