AI 客服未登录给出明确提示与登录入口
This commit is contained in:
+18
-2
@@ -1,4 +1,11 @@
|
||||
<view class="chat-container">
|
||||
<!-- 未登录提示条:提前说明「能不能聊」,把登录入口放在这里,
|
||||
用户不必等打完字被拦下来才知道要先登录 -->
|
||||
<view class="login-notice" wx:if="{{authChecked && !isLoggedIn}}">
|
||||
<text class="login-notice-text">尚未登录,暂时无法与 AI 客服对话</text>
|
||||
<text class="login-notice-link" bindtap="goLogin" aria-role="link">去登录</text>
|
||||
</view>
|
||||
|
||||
<!-- 消息列表区域 -->
|
||||
<scroll-view
|
||||
class="message-list"
|
||||
@@ -35,8 +42,17 @@
|
||||
wx:key="id"
|
||||
id="msg-{{item.id}}"
|
||||
>
|
||||
<!-- 连接或服务错误是系统状态,不使用用户/AI 头像,也不带 AI 内容声明。 -->
|
||||
<text wx:if="{{item.type === 'system'}}" class="system-message">{{item.content}}</text>
|
||||
<!-- 连接或服务错误是系统状态,不使用用户/AI 头像,也不带 AI 内容声明。
|
||||
未登录提示额外带一个登录入口,避免只给一句「请先登录」的死胡同 -->
|
||||
<view wx:if="{{item.type === 'system'}}" class="system-message">
|
||||
<text>{{item.content}}</text>
|
||||
<text
|
||||
wx:if="{{item.contentType === 'login'}}"
|
||||
class="system-login-link"
|
||||
bindtap="goLogin"
|
||||
aria-role="link"
|
||||
>去登录</text>
|
||||
</view>
|
||||
<block wx:else>
|
||||
<view class="message-head">
|
||||
<!-- AI:品牌标记(暖墨线稿);底色与用户侧同构,身份只由图形区分 -->
|
||||
|
||||
Reference in New Issue
Block a user