feat: 更新素材管理和举报风险地图
This commit is contained in:
@ -30,6 +30,7 @@ final class ProfileViewController: BaseViewController {
|
||||
private let realNameRow = ProfileInfoRowView(title: "认证状态")
|
||||
private let statusRow = ProfileInfoRowView(title: "账号状态")
|
||||
private let scenicRow = ProfileInfoRowView(title: "当前景区")
|
||||
private let settingRow = ProfileInfoRowView(title: "设置中心")
|
||||
private let logoutButton = UIButton(type: .system)
|
||||
private var hasLoadedProfileOnce = false
|
||||
|
||||
@ -85,6 +86,7 @@ final class ProfileViewController: BaseViewController {
|
||||
passwordRow.addTarget(self, action: #selector(changePasswordTapped), for: .touchUpInside)
|
||||
withdrawalRow.addTarget(self, action: #selector(withdrawalTapped), for: .touchUpInside)
|
||||
realNameRow.addTarget(self, action: #selector(realNameTapped), for: .touchUpInside)
|
||||
settingRow.addTarget(self, action: #selector(settingTapped), for: .touchUpInside)
|
||||
|
||||
NotificationCenter.default.addObserver(
|
||||
self,
|
||||
@ -177,14 +179,15 @@ final class ProfileViewController: BaseViewController {
|
||||
|
||||
[
|
||||
nameRow, accountRow, phoneRow, withdrawalRow,
|
||||
passwordRow, realNameRow, statusRow, scenicRow
|
||||
passwordRow, realNameRow, statusRow, scenicRow,
|
||||
settingRow
|
||||
].forEach { infoCard.addArrangedSubview($0) }
|
||||
|
||||
nameRow.isUserInteractionEnabled = false
|
||||
phoneRow.isUserInteractionEnabled = false
|
||||
statusRow.isUserInteractionEnabled = false
|
||||
scenicRow.isUserInteractionEnabled = false
|
||||
scenicRow.showsDivider = false
|
||||
settingRow.showsDivider = false
|
||||
}
|
||||
|
||||
private func setupLogoutButton() {
|
||||
@ -224,6 +227,7 @@ final class ProfileViewController: BaseViewController {
|
||||
value: viewModel.currentScenicName,
|
||||
badge: .scenic
|
||||
)
|
||||
settingRow.configure(value: nil, accessory: .chevron)
|
||||
}
|
||||
|
||||
private func configureWithdrawalRow() {
|
||||
@ -342,6 +346,10 @@ final class ProfileViewController: BaseViewController {
|
||||
}
|
||||
}
|
||||
|
||||
@objc private func settingTapped() {
|
||||
navigationController?.pushViewController(SettingViewController(), animated: true)
|
||||
}
|
||||
|
||||
@objc private func logoutTapped() {
|
||||
let alert = UIAlertController(title: "确定退出登录?", message: "退出后将需要重新登录", preferredStyle: .alert)
|
||||
alert.addAction(UIAlertAction(title: "取消", style: .cancel))
|
||||
|
||||
Reference in New Issue
Block a user