Fixbug structure

This commit is contained in:
Andros Fenollosa
2017-05-11 18:31:59 +02:00
parent 3b431c6d0a
commit ce763d6493
4 changed files with 39 additions and 25 deletions

View File

@ -1,4 +1,4 @@
from models import db, Contacts
from models import db, Contact
from faker import Factory
fake = Factory.create()
@ -15,6 +15,6 @@ for num in range(100):
email = fake.email()
phone = fake.phone_number()
# Save in database
mi_contacto = Contacts(name, surname, email, phone)
mi_contacto = Contact(name, surname, email, phone)
db.session.add(mi_contacto)
db.session.commit()