// // CommonHelper.swift // Sirani // // Created by Hendi on 04/01/24. // Copyright © 2024 PT. Mitra Sinerji Teknoindo. All rights reserved. // import Foundation import UIKit class CommonHelper { class func showNoConnection(in viewController: UIViewController) { let alertNoConnection = UIAlertController( title: Constants.instance.ALERT_NO_CONNECTION_TITLE, message: Constants.instance.ALERT_NO_CONNECTION_MSG, preferredStyle: .alert ) alertNoConnection.addAction( UIAlertAction(title: Constants.instance.ALERT_NO_CONNECTION_YESS, style: .default, handler: nil) ) viewController.present(alertNoConnection, animated: true, completion: nil) } class func showNotAllowConnection(in viewController: UIViewController) { let alertNoConnection = UIAlertController( title: Constants.instance.ALERT_NO_CONNECTION_TITLE, message: Constants.instance.ALERT_NOT_ALLOW_MSG, preferredStyle: .alert ) alertNoConnection.addAction( UIAlertAction(title: Constants.instance.ALERT_NO_CONNECTION_YESS, style: .default, handler: nil) ) viewController.present(alertNoConnection, animated: true, completion: nil) } // CommonHelper.showNoConnection(in: self) // CommonHelper.showNotAllowConnection(in: self) }