| | |
| | | switch next.code{ |
| | | case 200:ob.onNext(next) |
| | | case 504: //登录设备最大限制 |
| | | let attribute = AttributedStringbuilder.build().add(string:next.msg, withFont: .systemFont(ofSize: 14, weight: .medium), withColor: .black.withAlphaComponent(0.6)).mutableAttributedString |
| | | // CommonAlertView.show(title: "提示", attribute: attribute, cancelStr: "关闭", completeStr: "关闭", isSingle: true, customBtnWidth: JQ_ScreenW - 170) { _ in |
| | | // |
| | | // } |
| | | break |
| | | case 503: //登录被冻结 |
| | | let attribute = AttributedStringbuilder.build().add(string:next.msg, withFont: .systemFont(ofSize: 14, weight: .medium), withColor: .black.withAlphaComponent(0.6)).mutableAttributedString |
| | | // CommonAlertView.show(title: "提示", attribute: attribute, cancelStr: "关闭", completeStr: "关闭", isSingle: true, customBtnWidth: JQ_ScreenW - 170) { _ in |
| | | // |
| | | // } |
| | | DispatchQueue.main.async { |
| | | alert(msg: next.msg) |
| | | } |
| | | // case 501: |
| | | // CommonAlertView.show(title: "提示", content: next.msg,isSingle: true) { _ in |
| | | // |
| | |
| | | sceneDelegate?.needLogin() |
| | | default: |
| | | if !ignoreAlert{ |
| | | alertError(msg: "\(next.msg)") |
| | | DispatchQueue.main.async { |
| | | alertError(msg: "\(next.msg)") |
| | | } |
| | | } |
| | | ob.onError(NetRequestError.Other(next.code,next.msg)) |
| | | } |