Showing
2 changed files
with
15 additions
and
13 deletions
No preview for this file type
| ... | @@ -10,8 +10,9 @@ import SwiftUI | ... | @@ -10,8 +10,9 @@ import SwiftUI |
| 10 | import Combine | 10 | import Combine |
| 11 | import Foundation | 11 | import Foundation |
| 12 | import UIKit | 12 | import UIKit |
| 13 | -import RSBarcodes_Swift | 13 | +// TODO: Uncomment for barcode |
| 14 | -import AVFoundation | 14 | +//import RSBarcodes_Swift |
| 15 | +//import AVFoundation | ||
| 15 | 16 | ||
| 16 | 17 | ||
| 17 | 18 | ||
| ... | @@ -196,18 +197,19 @@ extension CouponBarcodeView { | ... | @@ -196,18 +197,19 @@ extension CouponBarcodeView { |
| 196 | 197 | ||
| 197 | // let isValid = RSUnifiedCodeValidator.shared.isValid(barcodeString, machineReadableCodeObjectType: AVMetadataObject.ObjectType.ean13.rawValue) | 198 | // let isValid = RSUnifiedCodeValidator.shared.isValid(barcodeString, machineReadableCodeObjectType: AVMetadataObject.ObjectType.ean13.rawValue) |
| 198 | 199 | ||
| 199 | - if let barcodeImage = RSUnifiedCodeGenerator.shared.generateCode(barcodeString, machineReadableCodeObjectType: AVMetadataObject.ObjectType.ean13.rawValue, targetSize: CGSize(width: self.uiscreen.width * 0.8, height: self.uiscreen.height * 0.1)) { | 200 | + // TODO: Uncomment for barcode |
| 200 | - | 201 | +// if let barcodeImage = RSUnifiedCodeGenerator.shared.generateCode(barcodeString, machineReadableCodeObjectType: AVMetadataObject.ObjectType.ean13.rawValue, targetSize: CGSize(width: self.uiscreen.width * 0.8, height: self.uiscreen.height * 0.1)) { |
| 201 | // | 202 | // |
| 202 | - VStack(alignment: .center) { | 203 | +//// |
| 203 | - Image(uiImage: barcodeImage) | 204 | +// VStack(alignment: .center) { |
| 204 | - .resizable() | 205 | +// Image(uiImage: barcodeImage) |
| 205 | - .aspectRatio(contentMode: .fit) | 206 | +// .resizable() |
| 206 | - .frame(width: self.uiscreen.width * 0.8, height: self.uiscreen.height * 0.1) | 207 | +// .aspectRatio(contentMode: .fit) |
| 207 | - } | 208 | +// .frame(width: self.uiscreen.width * 0.8, height: self.uiscreen.height * 0.1) |
| 208 | - .frame(maxWidth: .infinity) | 209 | +// } |
| 209 | - .padding(.top, self.uiscreen.height * 0.01) | 210 | +// .frame(maxWidth: .infinity) |
| 210 | - } | 211 | +// .padding(.top, self.uiscreen.height * 0.01) |
| 212 | +// } | ||
| 211 | 213 | ||
| 212 | 214 | ||
| 213 | Text(barcodeString) | 215 | Text(barcodeString) | ... | ... |
-
Please register or login to post a comment