Feat(云灵AI):对话接口对接完成
This commit is contained in:
+12
-4
@@ -1,6 +1,7 @@
|
||||
import {
|
||||
getSseConfigV1,
|
||||
getCompletions
|
||||
getCompletions,
|
||||
deleteChatItemByConversationId
|
||||
} from '@/api/chat/index'
|
||||
import { VUE_APP_API_URL } from '@/config'
|
||||
import settings from '@/config/baseSetting.js'
|
||||
@@ -12,7 +13,8 @@ export const chatMixins = {
|
||||
return {
|
||||
token: cookie.get('login_status'),
|
||||
userInfo: cookie.get('userInfo'),
|
||||
webUrl: this.$webUrl,
|
||||
webUrl: this.$VUE_APP_RESOURCES_URL,
|
||||
scrollData: {},
|
||||
scrollTop: 0,
|
||||
isScrollToBottom: false,
|
||||
// 状态栏高度
|
||||
@@ -49,6 +51,7 @@ export const chatMixins = {
|
||||
}
|
||||
},
|
||||
onPageScroll(e) {
|
||||
this.scrollData = e
|
||||
const scrollTop = e.scrollTop
|
||||
this.scrollTop = scrollTop
|
||||
const query = wx.createSelectorQuery().in(this)
|
||||
@@ -77,8 +80,6 @@ export const chatMixins = {
|
||||
_this.statusBarHeight = statusBar
|
||||
}
|
||||
})
|
||||
console.log(this.token)
|
||||
console.log(this.userInfo)
|
||||
_this.createdCallbak()
|
||||
},
|
||||
methods: {
|
||||
@@ -133,6 +134,13 @@ export const chatMixins = {
|
||||
init: 0
|
||||
})
|
||||
},
|
||||
// 大家都在问
|
||||
topicItemClickHandle(question) {
|
||||
this.streamReq({
|
||||
prompt: question,
|
||||
init: 0
|
||||
})
|
||||
},
|
||||
streamReq(params) {
|
||||
const _this = this
|
||||
// 需要校验登录状态
|
||||
|
||||
Reference in New Issue
Block a user