diff options
author | Alban Gruin | 2017-11-25 20:43:21 +0100 |
---|---|---|
committer | Alban Gruin | 2017-11-25 20:43:21 +0100 |
commit | 4aebed8ca3f879aa4e2996620657a14ac9538477 (patch) | |
tree | 645005f9275000a7f1431bb9d901e6501552726f /utils.py | |
parent | d1191533a29b5f80543faa0758c7303d0a4b450c (diff) |
get_week() convertit automatiquement les chaines de caractères en int
Diffstat (limited to 'utils.py')
-rw-r--r-- | utils.py | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -30,7 +30,7 @@ def get_current_or_next_week(): def get_week(year, week): start = timezone.make_aware(datetime.datetime.strptime( - "{0}-W{1:02d}-1".format(year, week), "%Y-W%W-%w")) + "{0}-W{1:02d}-1".format(year, int(week)), "%Y-W%W-%w")) end = start + datetime.timedelta(weeks=1) return start, end |