-
-
Notifications
You must be signed in to change notification settings - Fork 72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add "enum" for countries #52
Conversation
Addition of countries and selection from menu
Hi @zachantre, thanks for your contribution. |
Well, openwrt timezone need time format... right now it submits continent/city which is not proper for openwrt. With fix, on site you see continent/city but submit the actual timezone |
That shouldn't be an issue because the library supplies the correct value upon rendering/generation. But I would like to accept your patch in order to address the mismatch so the implementation would become cleaner, I'm trying your patch but lots of things go wrong. Have you tried running unit tests as explained in the README? Federico |
I see many failing tests with an error which I think it's hard to overcome: OpenWRT has quite a few timezones of different areas which have the same value, but specifying an Example:
Supplying a list which has duplicate values to To understand what I'm trying to say, run this command:
The other change to countries should easier to include. |
@@ -782,6 +783,9 @@ | |||
"country": { | |||
"type": "string", | |||
"maxLength": 2, | |||
"default": "IT", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this line please, there's no reason for which the default country should be Italy ;-)
I see... Sorry for my mistake, I have just started learning python. |
Great! We just need to cleanup a few style issues before I can merge your patch. |
See the failing build: You just have to remove a few trailing spaces from the indicated lines. Then when you are done, do the following to squash your commits:
Leave the last commit untouched and set the previous ones as "squash", then provide a better commit message and save, then push to your repository using Thank you @zachantre! |
On my pc I had some issues with tests... not properly set virtual env... |
Thank you @zachantre, I squashed the commits and merged manually in d23d8fb. 👍 |
Fixed timezone in openwrt backend
Addition of countries and selection from menu