mirror of
https://github.com/spiral-project/ihatemoney.git
synced 2025-05-06 13:01:50 +02:00
Testing to find the issue
This commit is contained in:
parent
015a00f7a3
commit
912b663523
2 changed files with 6 additions and 4 deletions
|
@ -87,9 +87,9 @@ class EditProjectForm(FlaskForm):
|
||||||
password = StringField(_("Private code"), validators=[DataRequired()])
|
password = StringField(_("Private code"), validators=[DataRequired()])
|
||||||
contact_email = StringField(_("Email"), validators=[DataRequired(), Email()])
|
contact_email = StringField(_("Email"), validators=[DataRequired(), Email()])
|
||||||
currency_helper = CurrencyConverter()
|
currency_helper = CurrencyConverter()
|
||||||
default_currency = SelectField(
|
# default_currency = SelectField(
|
||||||
_("Default Currency"), choices=currency_helper.get_currencies(), validators=[DataRequired()]
|
# _("Default Currency"), choices=currency_helper.get_currencies(), validators=[DataRequired()]
|
||||||
)
|
# )
|
||||||
|
|
||||||
def save(self):
|
def save(self):
|
||||||
"""Create a new project with the information given by this form.
|
"""Create a new project with the information given by this form.
|
||||||
|
@ -101,7 +101,7 @@ class EditProjectForm(FlaskForm):
|
||||||
id=self.id.data,
|
id=self.id.data,
|
||||||
password=generate_password_hash(self.password.data),
|
password=generate_password_hash(self.password.data),
|
||||||
contact_email=self.contact_email.data,
|
contact_email=self.contact_email.data,
|
||||||
default_currency=self.default_currency.data
|
# default_currency=self.default_currency.data
|
||||||
)
|
)
|
||||||
return project
|
return project
|
||||||
|
|
||||||
|
|
|
@ -277,6 +277,8 @@ def create_project():
|
||||||
project = form.save()
|
project = form.save()
|
||||||
db.session.add(project)
|
db.session.add(project)
|
||||||
db.session.commit()
|
db.session.commit()
|
||||||
|
print(project.name)
|
||||||
|
print(project.default_currency)
|
||||||
|
|
||||||
# create the session object (authenticate)
|
# create the session object (authenticate)
|
||||||
session[project.id] = True
|
session[project.id] = True
|
||||||
|
|
Loading…
Reference in a new issue