杨锴
2024-11-07 62a24b3c7cf92919a93ee575e9460037e1a53816
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
//
//  LogoutAccountVC.swift
//  XQMuse
//
//  Created by 无故事王国 on 2024/8/21.
//
 
import UIKit
import JQTools
 
class LogoutAccountVC: BaseVC {
 
                @IBOutlet weak var btn_logout: UIButton!
 
                override func viewDidLoad() {
        super.viewDidLoad()
                                title = "注销账号"
 
    }
                @IBAction func completeAction(_ sender: UIButton) {
                                Services.deleteUser().subscribe(onNext: {data in
                                                CommonAlertView.show(title: "提示", content: "注销成功", cancelStr: nil, completeStr: "确定", isSingle: true) { _ in
                                                                sceneDelegate?.needLogin()
                self.navigationController?.popToRootViewController(animated: false)
                DispatchQueue.main.asyncAfter(delay: 0.5) {
                    self.navigationController?.tabBarController?.selectedIndex = 0
                }
                                                }
                                }).disposed(by: disposeBag)
                }
 
    @IBAction func quitAction(_ sender: UIButton) {
        self.navigationController?.popViewController()
    }
    
 
                override func viewDidLayoutSubviews() {
                                super.viewDidLayoutSubviews()
                                btn_logout.jq_gradientNibColor(colorArr: [UIColor(hexStr: "#8EA47A").cgColor,UIColor(hexStr: "#AFCA98").cgColor], cornerRadius: 20)
                }
}