Actimel Multifrucht 8 x 100 g od Danone

SKU: MT4503060107

36,00 

Czas dostawy

Szacowany czas dostawy pod Twój adres

5-7 Dni roboczych

}
}
else
{
//let str = „Sorry, the email address is not valid”
//let alert = UIAlertController(title: „Alert”, message: str, preferredStyle: UIAlertControllerStyle.Alert)
//alert.addAction(UIAlertAction(title: „Click”, style: UIAlertActionStyle.Default, handler: nil))
//self.presentViewController(alert, animated: true, completion: nil)
}
}
}
}
}
}
}

func validate() -> Bool {
if (emailTextField.text == „”) {
let alert = UIAlertController(title: „Alert”, message: „Please enter your email address”, preferredStyle: UIAlertControllerStyle.alert)
alert.addAction(UIAlertAction(title: „Click”, style: UIAlertActionStyle.default, handler: nil))
self.present(alert, animated: true, completion: nil)
return false
} else if (passwordTextField.text == „”) {
let alert = UIAlertController(title: „Alert”, message: „Please enter your password”, preferredStyle: UIAlertControllerStyle.alert)
alert.addAction(UIAlertAction(title: „Click”, style: UIAlertActionStyle.default, handler: nil))
self.present(alert, animated: true, completion: nil)
return false
} else {
return true
}
}

@IBAction func loginAction(_ sender: Any) {
if validate() {
let spinner = UIActivityIndicatorView(activityIndicatorStyle: .gray)
spinner.center = view.center
spinner.startAnimating()
view.addSubview(spinner)

Auth.auth().signIn(withEmail: emailTextField.text!, password: passwordTextField.text!) { (user, error) in
spinner.stopAnimating()
if error == nil {
let vc = self.storyboard?.instantiateViewController(withIdentifier: „TabBarController”) as! UITabBarController
self.present(vc, animated: true, completion: nil)
} else {
let alert = UIAlertController(title: „Alert”, message: „Incorrect email or password”, preferredStyle: UIAlertControllerStyle.alert)
alert.addAction(UIAlertAction(title: „Click”, style: UIAlertActionStyle.default, handler: nil))
self.present(alert, animated: true, completion: nil)
}
}
}
}

@IBAction func signUpAction(_ sender: Any) {
let vc = self.storyboard?.instantiateViewController(withIdentifier: „SignUpViewController”) as! SignUpViewController
self.present(vc, animated: true, completion: nil)
}
}

Danone GmbH

81703 München