Manos Chorianopoulos
...@@ -6,6 +6,7 @@ ...@@ -6,6 +6,7 @@
6 // 6 //
7 7
8 import Foundation 8 import Foundation
9 +import SwiftUI
9 10
10 public class swiftApi { 11 public class swiftApi {
11 12
...@@ -338,4 +339,12 @@ public class swiftApi { ...@@ -338,4 +339,12 @@ public class swiftApi {
338 public func getCampaigns() -> Array<CampaignItemModel> { 339 public func getCampaigns() -> Array<CampaignItemModel> {
339 return CampaignDataModel().getData 340 return CampaignDataModel().getData
340 } 341 }
342 +
343 + public func openCoupon(parent: UIView, coupon: CouponSetItemModel) -> UIViewController {
344 + return UIHostingController(rootView: CouponView(parentView: parent, coupon: coupon))
345 + }
346 +
347 + public func openCouponBarcode(parent: UIView, coupon: CouponSetItemModel) -> UIViewController {
348 + return UIHostingController(rootView: CouponBarcodeView(parentView: parent, coupon: coupon))
349 + }
341 } 350 }
......