Commit bcebac61 authored by nick zheng's avatar nick zheng

fix: 应用广场的应用点击返回回到应用广场&web端应用开始聊天后剔除应用介绍

parent 48611576
...@@ -128,7 +128,7 @@ function handleGetMallCategoryList() { ...@@ -128,7 +128,7 @@ function handleGetMallCategoryList() {
} }
function handleToUseAgentApplication(agentId: string) { function handleToUseAgentApplication(agentId: string) {
router.replace({ name: 'ShareWebApplication', params: { agentId: agentId } }) router.push({ name: 'ShareWebApplication', params: { agentId: agentId } })
} }
function handleAddAgentApplications() { function handleAddAgentApplications() {
router.push({ name: 'PersonalAppSetting' }) router.push({ name: 'PersonalAppSetting' })
......
...@@ -17,7 +17,7 @@ const { t } = useI18n() ...@@ -17,7 +17,7 @@ const { t } = useI18n()
defineProps<Props>() defineProps<Props>()
const emit = defineEmits<{ const emit = defineEmits<{
backHomePage: [] back: []
toCreateApplication: [] toCreateApplication: []
toLogin: [] toLogin: []
}>() }>()
...@@ -28,8 +28,8 @@ const isLogin = computed(() => { ...@@ -28,8 +28,8 @@ const isLogin = computed(() => {
return userStore.isLogin return userStore.isLogin
}) })
function handleBackHomePage() { function handleBack() {
emit('backHomePage') emit('back')
} }
function handleToCreateApplication() { function handleToCreateApplication() {
...@@ -47,7 +47,7 @@ function handleToLogin() { ...@@ -47,7 +47,7 @@ function handleToLogin() {
<CustomIcon <CustomIcon
icon="weui:back-outlined" icon="weui:back-outlined"
class="hover:text-theme-color mr-5 cursor-pointer outline-none" class="hover:text-theme-color mr-5 cursor-pointer outline-none"
@click="handleBackHomePage" @click="handleBack"
/> />
<img :src="agentApplicationConfig.baseInfo.agentAvatar" class="mr-5 h-10 w-10 rounded-md" /> <img :src="agentApplicationConfig.baseInfo.agentAvatar" class="mr-5 h-10 w-10 rounded-md" />
......
...@@ -94,10 +94,14 @@ async function handleCreateDialogues() { ...@@ -94,10 +94,14 @@ async function handleCreateDialogues() {
} }
} }
function handleBackHomePage() { function handleBack() {
router.push({ if (!history.state.back) {
name: 'Home', router.replace({
}) name: 'Home',
})
} else {
router.back()
}
} }
function handleToLoginPage() { function handleToLoginPage() {
...@@ -167,7 +171,7 @@ function handleResetContinueQuestionList() { ...@@ -167,7 +171,7 @@ function handleResetContinueQuestionList() {
<PageHeader <PageHeader
:agent-application-config="agentApplicationConfig" :agent-application-config="agentApplicationConfig"
:agent-member-info="agentMemberInfo" :agent-member-info="agentMemberInfo"
@back-home-page="handleBackHomePage" @back="handleBack"
@to-login="handleToLoginPage" @to-login="handleToLoginPage"
@to-create-application="handleCreateApplicationPage" @to-create-application="handleCreateApplicationPage"
/> />
...@@ -179,7 +183,7 @@ function handleResetContinueQuestionList() { ...@@ -179,7 +183,7 @@ function handleResetContinueQuestionList() {
</div> </div>
<div v-if="messageList.length > 0" class="flex w-full flex-1 flex-col overflow-hidden"> <div v-if="messageList.length > 0" class="flex w-full flex-1 flex-col overflow-hidden">
<div class="my-5 ml-16 mr-5 border-b border-[#e8e9eb] py-6"> <!-- <div class="my-5 ml-16 mr-5 border-b border-[#e8e9eb] py-6">
<div class="flex items-start"> <div class="flex items-start">
<img :src="agentApplicationConfig.baseInfo.agentAvatar" class="h-14 w-14 rounded-xl" /> <img :src="agentApplicationConfig.baseInfo.agentAvatar" class="h-14 w-14 rounded-xl" />
<p class="font-500 ml-4 line-clamp-1 h-8 max-w-[90%] break-all text-2xl leading-8 text-[#151b26]"> <p class="font-500 ml-4 line-clamp-1 h-8 max-w-[90%] break-all text-2xl leading-8 text-[#151b26]">
...@@ -192,8 +196,8 @@ function handleResetContinueQuestionList() { ...@@ -192,8 +196,8 @@ function handleResetContinueQuestionList() {
> >
{{ agentApplicationConfig.commConfig.preamble }} {{ agentApplicationConfig.commConfig.preamble }}
</div> </div>
</div> </div> -->
<div class="flex-1 overflow-auto"> <div class="mt-16 flex-1 overflow-auto">
<MessageList <MessageList
ref="messageListRef" ref="messageListRef"
:agent-application-config="agentApplicationConfig" :agent-application-config="agentApplicationConfig"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment