KN SOLVRO WEBSITE

I created this project for academic circle Solvro recruitment. It was my first big project in Swift programming language and for iOS device.

Main goal of this project was to create functional fridge app in which you could add/remove products from fridge. Products were having quantity and consume date with alert when time to consume date was lesser than specific value.

Here's a photo of main screen.

fridge-app-img

Technology I used:

  • Swift

Snippet of my code:

      
  @IBOutlet weak var myTableView: UITableView!
  override func viewDidLoad() {
      super.viewDidLoad()
      overrideUserInterfaceStyle = .light
      let screenSize = UIScreen.main.bounds
      let rowHeight = screenSize.height/7.382
      myTableView.rowHeight = rowHeight
      constrainTableFridge.constant = screenSize.height/20.3
      print(constrainTableFridge.constant)
      do {
          let documentDirectory = try FileManager.default.url(for: .documentDirectory, in: .userDomainMask, appropriateFor: nil, create: true)
          let fileUrl = documentDirectory.appendingPathComponent("products").appendingPathExtension("sqlite3")
          let database = try Connection(fileUrl.path)
          databaseData = database
      } catch { print(error)}
      
      creatingTable()
      DataManager.shared.firstVC = self
      let tap: UITapGestureRecognizer = UITapGestureRecognizer(target: self, action: #selector(UIInputViewController.dismissKeyboard))
      view.addGestureRecognizer(tap)
  }
  
  @objc func dismissKeyboard() {
  view.endEditing(true)
  }
      
    
LinkedIn Facebook Website

© 2021 Karol Olszański.