Suzhou-SafetyToolsWarning-WX/pages/profile/index/index.wxml

58 lines
2.1 KiB
Plaintext
Raw Normal View History

2025-11-07 14:54:09 +08:00
<!--pages/profile/index/index.wxml-->
<view class="container">
2025-11-10 13:32:14 +08:00
<view class="profile-header" bindtap="handleHeaderTap">
2025-11-07 14:54:09 +08:00
<view class="avatar">
2025-11-10 13:32:14 +08:00
<image wx:if="{{isLoggedIn && userInfo.avatarUrl}}" src="{{userInfo.avatarUrl}}" class="avatar-img" />
<t-icon wx:else name="user" size="80rpx" color="#fff" />
2025-11-07 14:54:09 +08:00
</view>
<view class="user-info">
2025-11-10 13:32:14 +08:00
<view class="username">{{isLoggedIn ? userInfo.nickName : '未登录'}}</view>
<view class="user-role">{{isLoggedIn ? '已登录' : '点击登录'}}</view>
2025-11-07 14:54:09 +08:00
</view>
2025-11-10 13:32:14 +08:00
<t-icon name="chevron-right" size="32rpx" color="rgba(255,255,255,0.8)" />
2025-11-07 14:54:09 +08:00
</view>
<view class="menu-section">
<t-cell-group>
2025-11-10 13:32:14 +08:00
<t-cell title="消息通知" arrow hover bindtap="goToNotificationSettings">
<t-icon slot="left-icon" name="notification" size="40rpx" />
<view slot="note">
<t-tag wx:if="{{isSubscribed}}" theme="success" size="small">已开启</t-tag>
<t-tag wx:else theme="default" size="small">未开启</t-tag>
</view>
2025-11-07 14:54:09 +08:00
</t-cell>
<t-cell title="预警设置" arrow hover bindtap="goToWarningSettings">
2025-11-10 13:32:14 +08:00
<t-icon slot="left-icon" name="time" size="40rpx" />
</t-cell>
<t-cell title="单位管理" arrow hover bindtap="goToUnitManage">
<t-icon slot="left-icon" name="building" size="40rpx" />
2025-11-07 14:54:09 +08:00
</t-cell>
<t-cell title="数据导出" arrow hover bindtap="exportData">
<t-icon slot="left-icon" name="download" size="40rpx" />
</t-cell>
</t-cell-group>
</view>
<view class="menu-section">
<t-cell-group>
<t-cell title="关于我们" arrow hover bindtap="goToAbout">
<t-icon slot="left-icon" name="info-circle" size="40rpx" />
</t-cell>
<t-cell title="帮助中心" arrow hover bindtap="goToHelp">
<t-icon slot="left-icon" name="help-circle" size="40rpx" />
</t-cell>
</t-cell-group>
</view>
2025-11-10 13:32:14 +08:00
<view class="menu-section" wx:if="{{isLoggedIn}}">
<t-button theme="default" size="large" block bindtap="handleLogout">
退出登录
</t-button>
</view>
2025-11-07 14:54:09 +08:00
<view class="version-info">
<text>版本号v1.0.0</text>
</view>
</view>