|
@@ -1719,6 +1719,13 @@ class KMMemberCenterManager: NSObject {
|
|
|
|
|
|
// MARK: Error Code
|
|
|
|
|
|
+ static func quickShowAlert(result: KMMemberProductResult?, callback: ((NSApplication.ModalResponse?, Any ...)->Void)?) {
|
|
|
+ guard let data = result else {
|
|
|
+ return
|
|
|
+ }
|
|
|
+ showAlert(code: .init(rawValue: data.code ?? 0), message: data.msg, callback: callback)
|
|
|
+ }
|
|
|
+
|
|
|
static func showAlert(code: KMMemberCenterErrorCodeType?, message: String?, callback: ((NSApplication.ModalResponse?, Any ...)->Void)?) {
|
|
|
let string = self.getCodeMessage(code: code, message: message)
|
|
|
KMMainThreadExecute {
|