Skip to content

#305 - Add the accept_proposals_at on Event Form#311

Open
chawki27000 wants to merge 2 commits into
luanfonceca:masterfrom
chawki27000:feature/update-event-form
Open

#305 - Add the accept_proposals_at on Event Form#311
chawki27000 wants to merge 2 commits into
luanfonceca:masterfrom
chawki27000:feature/update-event-form

Conversation

@chawki27000

Copy link
Copy Markdown

for the issue N° 305.
I added to widgets dictionary accept_proposals_at key and a new CustomDateTimeWidget as value in forms.py file.
I added a date in event_data dictionary in test_create_event function in EventTest class.

Comment thread deck/forms.py
'accept_proposals_at': CustomDateTimeWidget(attrs={
'id': 'id_accept_proposals',
'class': 'inline-input',
'placeholder': 'Date Accept Proposals'

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this needs to be translated.

@chawki27000 chawki27000 Oct 16, 2017

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i write this chunk of code, because when the template generates the html page, it puts inline-input as a class and Date Accept Proposals as placeholder to input tag

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What i mean was that you need to use the ugettext function. _('Date Accept Proposals'), it would be something like this.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm sorry, I don't see the ugettext function

Comment thread deck/forms.py
'placeholder': 'Due Date'
}),
'accept_proposals_at': CustomDateTimeWidget(attrs={
'id': 'id_accept_proposals',

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be id_accept_proposals_at

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants