Conditions | 1 |
Total Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | # coding: utf-8 |
||
30 | def right_now(model): |
||
31 | """ |
||
32 | return a dict of 2 property set with current date and time |
||
33 | """ |
||
34 | now_date = arrow.utcnow().to(settings.TIME_ZONE).format('YYYY-MM-DD') |
||
35 | now_hour = arrow.utcnow().to(settings.TIME_ZONE).format('HH:mm:ss') |
||
36 | my_date = 'date_' + model |
||
37 | my_hour = 'hour_' + model |
||
38 | return {my_date: now_date, my_hour: now_hour} |
||
39 |