This commit is contained in:
wangdan-fit2cloud 2024-01-31 15:19:12 +08:00
parent d31c6399f6
commit fac2065ec6

View File

@ -211,7 +211,7 @@ const prologueList = computed(() => {
const temp = props.data?.prologue const temp = props.data?.prologue
let arr: any = [] let arr: any = []
const lines = temp?.split('\n') const lines = temp?.split('\n')
lines.forEach((str: string, index: number) => { lines?.forEach((str: string, index: number) => {
if (isMdArray(str)) { if (isMdArray(str)) {
arr[index] = { arr[index] = {
type: 'question', type: 'question',
@ -288,11 +288,13 @@ function getChartOpenId() {
applicationApi applicationApi
.getChatOpen(props.appId) .getChatOpen(props.appId)
.then((res) => { .then((res) => {
console.log(res)
chartOpenId.value = res.data chartOpenId.value = res.data
chatMessage() chatMessage()
}) })
.catch((res) => { .catch((res) => {
if (res.response.status === 401) { console.log(res)
if (res.code === 401 || res.response.status === 401) {
application.asyncAppAuthentication(accessToken).then(() => { application.asyncAppAuthentication(accessToken).then(() => {
getChartOpenId() getChartOpenId()
}) })