Advertisement
fweng322

Diff of date format for Indico installed on Debian

Dec 14th, 2019
329
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 34.60 KB | None | 0 0
  1. diff --git a/modules/categories/client/js/calendar.js b/modules/categories/client/js/calendar.js
  2. index 5533706..5c5c67a 100644
  3. --- a/modules/categories/client/js/calendar.js
  4. +++ b/modules/categories/client/js/calendar.js
  5. @@ -47,7 +47,7 @@ import 'fullcalendar/dist/fullcalendar.css';
  6. });
  7. ajaxDialog({
  8. dialogClasses: 'all-events-dialog',
  9. - title: $T.gettext('Events happening on {0}').format(cellInfo.date.format('MMMM Do YYYY')),
  10. + title: $T.gettext('Events happening on {0}').format(cellInfo.date.format('YYYYMMMM D ?')),
  11. content,
  12. });
  13. },
  14. diff --git a/modules/categories/controllers/display.py b/modules/categories/controllers/display.py
  15. index f700828..5257fe3 100644
  16. --- a/modules/categories/controllers/display.py
  17. +++ b/modules/categories/controllers/display.py
  18. @@ -1,3 +1,5 @@
  19. +# coding=utf-8
  20. +
  21. # This file is part of Indico.
  22. # Copyright (C) 2002 - 2019 CERN
  23. #
  24. @@ -244,7 +246,7 @@ class RHDisplayCategoryEventsBase(RHDisplayCategoryBase):
  25. self.now = now_utc(exact=False).astimezone(self.category.display_tzinfo)
  26.  
  27. def format_event_date(self, event):
  28. - day_month = 'dd MMM'
  29. + day_month = 'MMMdd?'
  30. tzinfo = self.category.display_tzinfo
  31. start_dt = event.start_dt.astimezone(tzinfo)
  32. end_dt = event.end_dt.astimezone(tzinfo)
  33. @@ -260,7 +262,7 @@ class RHDisplayCategoryEventsBase(RHDisplayCategoryBase):
  34. def group_by_month(self, events):
  35. def _format_tuple(x):
  36. (year, month), events = x
  37. - return {'name': format_date(date(year, month, 1), format='MMMM yyyy'),
  38. + return {'name': format_date(date(year, month, 1), format='yyyy MMMM'),
  39. 'events': list(events),
  40. 'is_current': year == self.now.year and month == self.now.month}
  41.  
  42. diff --git a/modules/categories/controllers/display.pyc b/modules/categories/controllers/display.pyc
  43. index 49d6714..be0e06e 100644
  44. Binary files a/modules/categories/controllers/display.pyc and b/modules/categories/controllers/display.pyc differ
  45. diff --git a/modules/categories/templates/display/overview/week.html b/modules/categories/templates/display/overview/week.html
  46. index 5d0f594..02d97ca 100644
  47. --- a/modules/categories/templates/display/overview/week.html
  48. +++ b/modules/categories/templates/display/overview/week.html
  49. @@ -24,7 +24,7 @@
  50. <tr>
  51. {% for day, events in events_by_day %}
  52. <th>
  53. - {{ day|format_date(format='EEE d MMM') }}
  54. + {{ day|format_date(format='MMMd?(EEE)') }}
  55. </th>
  56. {% endfor %}
  57. </tr>
  58. diff --git a/modules/designer/placeholders.py b/modules/designer/placeholders.py
  59. index 33902fd..4184d3c 100644
  60. --- a/modules/designer/placeholders.py
  61. +++ b/modules/designer/placeholders.py
  62. @@ -85,7 +85,7 @@ class EventDatesPlaceholder(DesignerPlaceholder):
  63. interval = to_unicode(format_datetime(start_dt))
  64. elif start_dt.date().replace(day=1) == end_dt.date().replace(day=1):
  65. interval = "{} - {} {}".format(start_dt.day, end_dt.day,
  66. - to_unicode(format_date(start_dt, format='MMMM yyyy')))
  67. + to_unicode(format_date(start_dt, format='yyyy MMMM')))
  68. return interval
  69.  
  70.  
  71. diff --git a/modules/designer/placeholders.pyc b/modules/designer/placeholders.pyc
  72. index 8d854d1..7b6ca94 100644
  73. Binary files a/modules/designer/placeholders.pyc and b/modules/designer/placeholders.pyc differ
  74. diff --git a/modules/events/client/js/creation.js b/modules/events/client/js/creation.js
  75. index 7525de7..40ed406 100644
  76. --- a/modules/events/client/js/creation.js
  77. +++ b/modules/events/client/js/creation.js
  78. @@ -98,8 +98,8 @@ import {camelizeKeys} from 'indico/utils/case';
  79. if (occurrences && occurrences.length === 1) {
  80. setLectureTimes(occurrences[0]);
  81. } else {
  82. - startDt = moment(`${startDate} ${startTime}`, 'DD/MM/YYYY HH:mm');
  83. - endDt = moment(`${endDate} ${endTime}`, 'DD/MM/YYYY HH:mm');
  84. + startDt = moment(`${startDate} ${startTime}`, 'YYYY/MM/DD HH:mm');
  85. + endDt = moment(`${endDate} ${endTime}`, 'YYYY/MM/DD HH:mm');
  86. }
  87. }
  88.  
  89. @@ -222,11 +222,11 @@ import {camelizeKeys} from 'indico/utils/case';
  90. const startTime = $('#event-creation-start_dt-time').val();
  91. const endDate = $('#event-creation-end_dt-date').val();
  92. const endTime = $('#event-creation-end_dt-time').val();
  93. - startDt = moment(`${startDate} ${startTime}`, 'DD/MM/YYYY HH:mm');
  94. - endDt = moment(`${endDate} ${endTime}`, 'DD/MM/YYYY HH:mm');
  95. + startDt = moment(`${startDate} ${startTime}`, 'YYYY/MM/DD HH:mm');
  96. + endDt = moment(`${endDate} ${endTime}`, 'YYYY/MM/DD HH:mm');
  97. // workaround for automatic end date update if start date is after end date
  98. if (endDt.isBefore(startDt)) {
  99. - endDt = moment(`${startDate} ${endTime}`, 'DD/MM/YYYY HH:mm');
  100. + endDt = moment(`${startDate} ${endTime}`, 'YYYY/MM/DD HH:mm');
  101. }
  102. updateAvailability();
  103. });
  104. @@ -234,21 +234,21 @@ import {camelizeKeys} from 'indico/utils/case';
  105. $('#event-creation-start_dt-time').on('change', function() {
  106. const startDate = $('#event-creation-start_dt-date').val();
  107. const startTime = $('#event-creation-start_dt-time').val();
  108. - startDt = moment(`${startDate} ${startTime}`, 'DD/MM/YYYY HH:mm');
  109. + startDt = moment(`${startDate} ${startTime}`, 'YYYY/MM/DD HH:mm');
  110. updateAvailability();
  111. });
  112.  
  113. $('#event-creation-end_dt-date').on('change', function() {
  114. const endDate = $(this).val();
  115. const endTime = $('#event-creation-end_dt-time').val();
  116. - endDt = moment(`${endDate} ${endTime}`, 'DD/MM/YYYY HH:mm');
  117. + endDt = moment(`${endDate} ${endTime}`, 'YYYY/MM/DD HH:mm');
  118. updateAvailability();
  119. });
  120.  
  121. $('#event-creation-end_dt-time').on('change', function() {
  122. const endDate = $('#event-creation-end_dt-date').val();
  123. const endTime = $(this).val();
  124. - endDt = moment(`${endDate} ${endTime}`, 'DD/MM/YYYY HH:mm');
  125. + endDt = moment(`${endDate} ${endTime}`, 'YYYY/MM/DD HH:mm');
  126. updateAvailability();
  127. });
  128.  
  129. diff --git a/modules/events/contributions/client/js/index.js b/modules/events/contributions/client/js/index.js
  130. index cfd99e6..85684c5 100644
  131. --- a/modules/events/contributions/client/js/index.js
  132. +++ b/modules/events/contributions/client/js/index.js
  133. @@ -105,7 +105,7 @@ import 'indico/modules/events/util/types_dialog';
  134. ) {
  135. oldLabelHtml
  136. .filter('.label')
  137. - .text(' ' + moment.utc(data.start_dt).format('DD/MM/YYYY HH:mm'));
  138. + .text(' ' + moment.utc(data.start_dt).format('YYYY/MM/DD HH:mm'));
  139. startDateCol.html(oldLabelHtml);
  140. $this.itempicker('selectItem', oldSession ? oldSession.id : null);
  141. });
  142. diff --git a/modules/events/management/templates/_management_frame.html b/modules/events/management/templates/_management_frame.html
  143. index de0ce51..b4c5713 100644
  144. --- a/modules/events/management/templates/_management_frame.html
  145. +++ b/modules/events/management/templates/_management_frame.html
  146. @@ -25,8 +25,8 @@
  147.  
  148.  
  149. {% macro render_event_management_header_right(event, event_types) %}
  150. - {% set start_date = event.start_dt | format_date('d MMM', timezone=event.tzinfo) %}
  151. - {% set end_date = event.end_dt | format_date('d MMM', timezone=event.tzinfo) %}
  152. + {% set start_date = event.start_dt | format_date('MMMd?', timezone=event.tzinfo) %}
  153. + {% set end_date = event.end_dt | format_date('MMMd?', timezone=event.tzinfo) %}
  154.  
  155. <div class="banner full-width">
  156. <div class="title">
  157. diff --git a/modules/events/operations.py b/modules/events/operations.py
  158. index bf9b090..dab3549 100644
  159. --- a/modules/events/operations.py
  160. +++ b/modules/events/operations.py
  161. @@ -94,7 +94,7 @@ def create_event(category, event_type, data, add_creator_as_manager=True, featur
  162. if booking:
  163. logger.info('Booking %r created for event %r', booking, event)
  164. log_data = {'Room': booking.room.full_name,
  165. - 'Date': booking.start_dt.strftime('%d/%m/%Y'),
  166. + 'Date': booking.start_dt.strftime('%Y/%m/%d'),
  167. 'Times': '%s - %s' % (booking.start_dt.strftime('%H:%M'), booking.end_dt.strftime('%H:%M'))}
  168. event.log(EventLogRealm.event, EventLogKind.positive, 'Event', 'Room booked for the event',
  169. session.user, data=log_data)
  170. diff --git a/modules/events/operations.pyc b/modules/events/operations.pyc
  171. index cb640ba..81804f3 100644
  172. Binary files a/modules/events/operations.pyc and b/modules/events/operations.pyc differ
  173. diff --git a/modules/events/registration/fields/choices.py b/modules/events/registration/fields/choices.py
  174. index 601777b..acf5f40 100644
  175. --- a/modules/events/registration/fields/choices.py
  176. +++ b/modules/events/registration/fields/choices.py
  177. @@ -296,7 +296,7 @@ class MultiChoiceField(ChoiceBaseField):
  178.  
  179.  
  180. def _to_machine_date(date):
  181. - return datetime.strptime(date, '%d/%m/%Y').strftime('%Y-%m-%d')
  182. + return datetime.strptime(date, '%Y/%m/%d').strftime('%Y-%m-%d')
  183.  
  184.  
  185. def _to_date(date):
  186. diff --git a/modules/events/registration/fields/choices.pyc b/modules/events/registration/fields/choices.pyc
  187. index bec4397..c723d19 100644
  188. Binary files a/modules/events/registration/fields/choices.pyc and b/modules/events/registration/fields/choices.pyc differ
  189. diff --git a/modules/events/templates/display/conference/base.html b/modules/events/templates/display/conference/base.html
  190. index 4fe044a..061bf0a 100644
  191. --- a/modules/events/templates/display/conference/base.html
  192. +++ b/modules/events/templates/display/conference/base.html
  193. @@ -9,7 +9,7 @@
  194. {% if start_dt.date() == end_dt.date() %}
  195. {{ start_dt | format_date('long') }}
  196. {% elif start_dt.year == end_dt.year and start_dt.month == end_dt.month %}
  197. - {{ start_dt.day }}-{{ end_dt.day }} {{ start_dt | format_date('MMMM yyyy') }}
  198. + {{ start_dt.day }}-{{ end_dt.day }} {{ start_dt | format_date('yyyy MMMM') }}
  199. {% else %}
  200. {% trans start=start_dt|format_date('long'), end=end_dt|format_date('long') -%}
  201. {{ start }} to {{ end }}
  202. diff --git a/modules/events/timetable/templates/display/indico/meeting.html b/modules/events/timetable/templates/display/indico/meeting.html
  203. index de1dde2..79c402b 100644
  204. --- a/modules/events/timetable/templates/display/indico/meeting.html
  205. +++ b/modules/events/timetable/templates/display/indico/meeting.html
  206. @@ -23,7 +23,7 @@
  207. {% block day_header scoped %}
  208. <div class="day-header" style="width: 100%;">
  209. <div class="day-title" data-anchor="{{ anchor }}">
  210. - {{ item.start_dt | format_date(format='EEEE, d MMMM', timezone=timezone) }}
  211. + {{ item.start_dt | format_date(format='MMMMd?(EEEE)', timezone=timezone) }}
  212. </div>
  213. {% if days %}
  214. <a class="js-go-to-day icon-calendar arrow js-dropdown" data-toggle="dropdown"></a>
  215. @@ -31,7 +31,7 @@
  216. {% for day, _ in days %}
  217. <li>
  218. <a href="#day-{{ day.isoformat() }}">
  219. - {{ day | format_date(format='EEE, d MMM', timezone=timezone) }}
  220. + {{ day | format_date(format='MMMd?(EEE)', timezone=timezone) }}
  221. </a>
  222. </li>
  223. {% endfor %}
  224. diff --git a/modules/events/timetable/templates/move_entry.html b/modules/events/timetable/templates/move_entry.html
  225. index 1258cb5..1b4dd6e 100644
  226. --- a/modules/events/timetable/templates/move_entry.html
  227. +++ b/modules/events/timetable/templates/move_entry.html
  228. @@ -9,7 +9,7 @@
  229. {% for day, entries in top_level_entries.iteritems() | sort %}
  230. <button class="i-button big day {%- if day == current_day %} highlight{% endif %}"
  231. data-day="{{ day }}">
  232. - {{- day | format_date(format='EEE, d MMM') -}}
  233. + {{- day | format_date(format='MMMd?(EEE)') -}}
  234. </button>
  235. {% endfor %}
  236. </div>
  237. diff --git a/modules/rb/templates/emails/reservations/base_email_to_manager.txt b/modules/rb/templates/emails/reservations/base_email_to_manager.txt
  238. index 50c2ac2..7a23857 100644
  239. --- a/modules/rb/templates/emails/reservations/base_email_to_manager.txt
  240. +++ b/modules/rb/templates/emails/reservations/base_email_to_manager.txt
  241. @@ -4,6 +4,6 @@
  242. {% block email_body -%}
  243. {% block body %}{% endblock %}
  244.  
  245. -You can check the details of the booking here:
  246. +?????????????
  247. {{ reservation.external_details_url }}
  248. {%- endblock %}
  249. diff --git a/modules/rb/templates/emails/reservations/base_email_to_user.txt b/modules/rb/templates/emails/reservations/base_email_to_user.txt
  250. index 8f97081..f569f75 100644
  251. --- a/modules/rb/templates/emails/reservations/base_email_to_user.txt
  252. +++ b/modules/rb/templates/emails/reservations/base_email_to_user.txt
  253. @@ -4,9 +4,9 @@
  254. {% block email_body -%}
  255. {% block body %}{% endblock %}
  256.  
  257. -Booking details:
  258. +?????
  259. {{ reservation.external_details_url }}
  260.  
  261. -Remember you can always check your bookings here:
  262. +???????????????????
  263. {{ url_for('rb.my_bookings_link', _external=true) }}
  264. {%- endblock %}
  265. diff --git a/modules/rb/templates/emails/reservations/cancellation_email_to_manager.txt b/modules/rb/templates/emails/reservations/cancellation_email_to_manager.txt
  266. index 88a5c29..7af7e07 100644
  267. --- a/modules/rb/templates/emails/reservations/cancellation_email_to_manager.txt
  268. +++ b/modules/rb/templates/emails/reservations/cancellation_email_to_manager.txt
  269. @@ -1,5 +1,5 @@
  270. {% extends 'rb/emails/reservations/base_email_to_manager.txt' %}
  271.  
  272. {% block body -%}
  273. -A booking in your room '{{ reservation.room.full_name }}' has been CANCELLED by the user.
  274. +??????? '{{ reservation.room.full_name }}' ??????????????
  275. {%- endblock %}
  276. diff --git a/modules/rb/templates/emails/reservations/cancellation_email_to_user.txt b/modules/rb/templates/emails/reservations/cancellation_email_to_user.txt
  277. index 93f4d13..7f32036 100644
  278. --- a/modules/rb/templates/emails/reservations/cancellation_email_to_user.txt
  279. +++ b/modules/rb/templates/emails/reservations/cancellation_email_to_user.txt
  280. @@ -1,7 +1,7 @@
  281. {% extends 'rb/emails/reservations/base_email_to_user.txt' %}
  282.  
  283. {% block body -%}
  284. -You have CANCELLED your booking:
  285. +?????????
  286.  
  287. {% include 'rb/emails/reservations/reservation_info.txt' %}
  288. {%- endblock %}
  289. diff --git a/modules/rb/templates/emails/reservations/change_state_email_to_manager.txt b/modules/rb/templates/emails/reservations/change_state_email_to_manager.txt
  290. index 3a8f1ba..088fdfa 100644
  291. --- a/modules/rb/templates/emails/reservations/change_state_email_to_manager.txt
  292. +++ b/modules/rb/templates/emails/reservations/change_state_email_to_manager.txt
  293. @@ -1,5 +1,6 @@
  294. {% extends 'rb/emails/reservations/base_email_to_manager.txt' %}
  295.  
  296. {% block body -%}
  297. -A booking in a room you manage has been MODIFIED and the changes require approval.
  298. +?????????????????????????
  299. +
  300. {%- endblock %}
  301. diff --git a/modules/rb/templates/emails/reservations/change_state_email_to_user.txt b/modules/rb/templates/emails/reservations/change_state_email_to_user.txt
  302. index 200caea..48b8eb5 100644
  303. --- a/modules/rb/templates/emails/reservations/change_state_email_to_user.txt
  304. +++ b/modules/rb/templates/emails/reservations/change_state_email_to_user.txt
  305. @@ -1,7 +1,7 @@
  306. {% extends 'rb/emails/reservations/base_email_to_user.txt' %}
  307.  
  308. {% block body -%}
  309. -Your booking has been MODIFIED and the changes require approval.
  310. +???????????????
  311.  
  312. {% include 'rb/emails/reservations/reservation_info.txt' %}
  313. {%- endblock %}
  314. diff --git a/modules/rb/templates/emails/reservations/confirmation_email_to_manager.txt b/modules/rb/templates/emails/reservations/confirmation_email_to_manager.txt
  315. index 320d65b..f5fc29b 100644
  316. --- a/modules/rb/templates/emails/reservations/confirmation_email_to_manager.txt
  317. +++ b/modules/rb/templates/emails/reservations/confirmation_email_to_manager.txt
  318. @@ -1,5 +1,7 @@
  319. {% extends 'rb/emails/reservations/base_email_to_manager.txt' %}
  320.  
  321. {% block body -%}
  322. -A booking in your room '{{ reservation.room.full_name }}' has been CONFIRMED by a room manager.
  323. +
  324. +????? '{{ reservation.room.full_name }}' ????????????????
  325. +
  326. {%- endblock %}
  327. diff --git a/modules/rb/templates/emails/reservations/confirmation_email_to_user.txt b/modules/rb/templates/emails/reservations/confirmation_email_to_user.txt
  328. index cd4020a..8f2f079 100644
  329. --- a/modules/rb/templates/emails/reservations/confirmation_email_to_user.txt
  330. +++ b/modules/rb/templates/emails/reservations/confirmation_email_to_user.txt
  331. @@ -2,8 +2,9 @@
  332.  
  333. {% block body -%}
  334. {% block state -%}
  335. -Your booking has been ACCEPTED.
  336. -This is the final confirmation.
  337. +
  338. +?????????????????
  339. +
  340. {%- endblock %}
  341.  
  342. {% include 'rb/emails/reservations/reservation_info.txt' %}
  343. diff --git a/modules/rb/templates/emails/reservations/creation_email_to_manager.txt b/modules/rb/templates/emails/reservations/creation_email_to_manager.txt
  344. index 8d5d1da..3ddfd7a 100644
  345. --- a/modules/rb/templates/emails/reservations/creation_email_to_manager.txt
  346. +++ b/modules/rb/templates/emails/reservations/creation_email_to_manager.txt
  347. @@ -1,7 +1,8 @@
  348. {% extends 'rb/emails/reservations/base_email_to_manager.txt' %}
  349.  
  350. {% block body -%}
  351. -There is a new {% block prebooking_prefix %}{% endblock %}booking for your room.
  352. +
  353. +???????????? {% block prebooking_prefix %}{% endblock %} ???
  354.  
  355. {% include 'rb/emails/reservations/reservation_info.txt' %}
  356. {%- endblock %}
  357. diff --git a/modules/rb/templates/emails/reservations/creation_email_to_user.txt b/modules/rb/templates/emails/reservations/creation_email_to_user.txt
  358. index ecc43ba..0411481 100644
  359. --- a/modules/rb/templates/emails/reservations/creation_email_to_user.txt
  360. +++ b/modules/rb/templates/emails/reservations/creation_email_to_user.txt
  361. @@ -3,26 +3,29 @@
  362.  
  363. {% block body -%}
  364. {%- block booking_details -%}
  365. -The conference room {{ reservation.room.full_name }}
  366. -has been {% block prebooked_prefix %}{% endblock %}booked for {{ reservation.booked_for_name }}
  367. +
  368. +{{ reservation.booked_for_name}} ??{% block prebooked_prefix %}{% endblock %}???????{{ reservation.room.full_name }}?
  369. +
  370. {% if reservation.repeat_frequency == RepeatFrequency.NEVER -%}
  371. - on {{ reservation.start_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }} from {{ reservation.start_dt | format_time(locale='en_GB') }} to {{ reservation.end_dt | format_time(locale='en_GB') }}.
  372. +?????{{ reservation.start_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }}
  373. +?????{{ reservation.start_dt | format_time(locale='zh_TW') }} ? {{ reservation.end_dt | format_time(locale='zh_TW') }}.
  374. {%- else -%}
  375. - {{ RepeatMapping.get_message(reservation.repeat_frequency, reservation.repeat_interval) }} from {{ reservation.start_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }} to {{ reservation.end_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }} between {{ reservation.start_dt | format_time(locale='en_GB') }} and {{ reservation.end_dt | format_time(locale='en_GB') }}.
  376. + {{ RepeatMapping.get_message(reservation.repeat_frequency, reservation.repeat_interval) }}
  377. +?????{{ reservation.start_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }} ? {{ reservation.end_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }}
  378. +?????{{ reservation.start_dt | format_time(locale='zh_TW') }} ? {{ reservation.end_dt | format_time(locale='zh_TW') }}.
  379. {%- endif %}
  380. -Reason: {{ reservation.booking_reason }}
  381. +
  382. +?????{{ reservation.booking_reason }}
  383. +
  384. {%- endblock -%}
  385. {%- block confirmed_booking -%}
  386. {%- if excluded_days %}
  387. - (Note that there are {{ excluded_days }} excluded days. For further info, check your reservation)
  388. + ????????? {{ excluded_days }} ?????????????????
  389. {%- endif %}
  390.  
  391. -If you end up not needing this room, please cancel the booking from the
  392. -booking details so that the room can be booked by somebody else.
  393. +??????????????????????????????????
  394.  
  395. -Please be aware that in special (rare) cases the person responsible
  396. -for this room may reject your booking. Should that happen you will
  397. -be instantly notified by e-mail.
  398. +?????????????????????????????????????????
  399. {%- endblock %}
  400.  
  401. {%- include 'rb/emails/reservations/reservation_key_info.txt' %}
  402. diff --git a/modules/rb/templates/emails/reservations/creation_pre_email_to_user.txt b/modules/rb/templates/emails/reservations/creation_pre_email_to_user.txt
  403. index 4484965..801ab37 100644
  404. --- a/modules/rb/templates/emails/reservations/creation_pre_email_to_user.txt
  405. +++ b/modules/rb/templates/emails/reservations/creation_pre_email_to_user.txt
  406. @@ -2,11 +2,9 @@
  407.  
  408. {% block prebooking_warning %}
  409.  
  410. -Note:
  411. -Your pre-booking is NOT YET ACCEPTED by a room manager.
  412. -Please be aware that pre-bookings are subject to acceptance
  413. -or rejection. Expect an e-mail with acceptance/rejection
  414. -information.
  415. +????
  416. +???????????????
  417. +??????????????????????
  418. {%- endblock %}
  419.  
  420. {% block prebooked_prefix %}pre-{% endblock %}
  421. diff --git a/modules/rb/templates/emails/reservations/modification_email_to_manager.txt b/modules/rb/templates/emails/reservations/modification_email_to_manager.txt
  422. index 7f00084..87ed5b1 100644
  423. --- a/modules/rb/templates/emails/reservations/modification_email_to_manager.txt
  424. +++ b/modules/rb/templates/emails/reservations/modification_email_to_manager.txt
  425. @@ -1,5 +1,5 @@
  426. {% extends 'rb/emails/reservations/base_email_to_manager.txt' %}
  427.  
  428. {% block body -%}
  429. -A booking in a room you manage has been MODIFIED.
  430. +?????????????????
  431. {%- endblock %}
  432. diff --git a/modules/rb/templates/emails/reservations/modification_email_to_user.txt b/modules/rb/templates/emails/reservations/modification_email_to_user.txt
  433. index 70124bc..fe8f26b 100644
  434. --- a/modules/rb/templates/emails/reservations/modification_email_to_user.txt
  435. +++ b/modules/rb/templates/emails/reservations/modification_email_to_user.txt
  436. @@ -1,7 +1,7 @@
  437. {% extends 'rb/emails/reservations/base_email_to_user.txt' %}
  438.  
  439. {% block body -%}
  440. -Your booking has been MODIFIED.
  441. +?????????
  442.  
  443. {% include 'rb/emails/reservations/reservation_info.txt' %}
  444. {%- endblock %}
  445. diff --git a/modules/rb/templates/emails/reservations/occurrence_cancellation_email_to_manager.txt b/modules/rb/templates/emails/reservations/occurrence_cancellation_email_to_manager.txt
  446. index d116f15..2a4eb4a 100644
  447. --- a/modules/rb/templates/emails/reservations/occurrence_cancellation_email_to_manager.txt
  448. +++ b/modules/rb/templates/emails/reservations/occurrence_cancellation_email_to_manager.txt
  449. @@ -1,5 +1,5 @@
  450. {% extends 'rb/emails/reservations/base_email_to_manager.txt' %}
  451.  
  452. {% block body -%}
  453. -The date {{ reservation.start_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }} from a booking that concerns one of your rooms has been CANCELLED by the user.
  454. +???????????????? {{ reservation.start_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }} ???????????
  455. {%- endblock %}
  456. diff --git a/modules/rb/templates/emails/reservations/occurrence_cancellation_email_to_user.txt b/modules/rb/templates/emails/reservations/occurrence_cancellation_email_to_user.txt
  457. index 8032b1e..8f6081c 100644
  458. --- a/modules/rb/templates/emails/reservations/occurrence_cancellation_email_to_user.txt
  459. +++ b/modules/rb/templates/emails/reservations/occurrence_cancellation_email_to_user.txt
  460. @@ -1,7 +1,7 @@
  461. {% extends 'rb/emails/reservations/base_email_to_user.txt' %}
  462.  
  463. {% block body -%}
  464. -You have CANCELLED an occurrence of your booking on {{ occurrence.start_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }}.
  465. +??????? {{ occurrence.start_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }} ????
  466.  
  467. {% include 'rb/emails/reservations/reservation_info.txt' %}
  468. {%- endblock %}
  469. diff --git a/modules/rb/templates/emails/reservations/occurrence_rejection_email_to_manager.txt b/modules/rb/templates/emails/reservations/occurrence_rejection_email_to_manager.txt
  470. index 60f3d51..65486c7 100644
  471. --- a/modules/rb/templates/emails/reservations/occurrence_rejection_email_to_manager.txt
  472. +++ b/modules/rb/templates/emails/reservations/occurrence_rejection_email_to_manager.txt
  473. @@ -1,9 +1,9 @@
  474. {% extends 'rb/emails/reservations/base_email_to_manager.txt' %}
  475.  
  476. {% block body -%}
  477. -A booking has been REJECTED by the manager of the room '{{ reservation.room.full_name }}' for the {{ occurrence.start_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }}.
  478. +????{{ reservation.room.full_name }}?????? {{ occurrence.start_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }} ????????
  479.  
  480. -Rejection reason:
  481. +?????
  482. {{ occurrence.rejection_reason }}
  483.  
  484. {% include 'rb/emails/reservations/reservation_info.txt' %}
  485. diff --git a/modules/rb/templates/emails/reservations/occurrence_rejection_email_to_user.txt b/modules/rb/templates/emails/reservations/occurrence_rejection_email_to_user.txt
  486. index 5b8bf60..2e573d6 100644
  487. --- a/modules/rb/templates/emails/reservations/occurrence_rejection_email_to_user.txt
  488. +++ b/modules/rb/templates/emails/reservations/occurrence_rejection_email_to_user.txt
  489. @@ -1,9 +1,9 @@
  490. {% extends 'rb/emails/reservations/base_email_to_user.txt' %}
  491.  
  492. {% block body -%}
  493. -Your booking has been REJECTED by the manager of the room for the {{ occurrence.start_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }}.
  494. +????? {{ occurrence.start_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }} ????????????
  495.  
  496. -Rejection reason:
  497. +?????
  498. {{ occurrence.rejection_reason }}
  499.  
  500. {% include 'rb/emails/reservations/reservation_info.txt' %}
  501. diff --git a/modules/rb/templates/emails/reservations/rejection_email_to_manager.txt b/modules/rb/templates/emails/reservations/rejection_email_to_manager.txt
  502. index 3f3d587..6aa50c6 100644
  503. --- a/modules/rb/templates/emails/reservations/rejection_email_to_manager.txt
  504. +++ b/modules/rb/templates/emails/reservations/rejection_email_to_manager.txt
  505. @@ -1,9 +1,9 @@
  506. {% extends 'rb/emails/reservations/base_email_to_manager.txt' %}
  507.  
  508. {% block body -%}
  509. -A booking has been REJECTED by the manager of the room '{{ reservation.room.full_name }}'.
  510. +????{{ reservation.room.full_name }}?????????????
  511.  
  512. -Rejection reason:
  513. +?????
  514. {{ reservation.rejection_reason }}
  515.  
  516. {% include 'rb/emails/reservations/reservation_info.txt' %}
  517. diff --git a/modules/rb/templates/emails/reservations/rejection_email_to_user.txt b/modules/rb/templates/emails/reservations/rejection_email_to_user.txt
  518. index e6ca5d9..be13945 100644
  519. --- a/modules/rb/templates/emails/reservations/rejection_email_to_user.txt
  520. +++ b/modules/rb/templates/emails/reservations/rejection_email_to_user.txt
  521. @@ -1,9 +1,9 @@
  522. {% extends 'rb/emails/reservations/base_email_to_user.txt' %}
  523.  
  524. {% block body -%}
  525. -Your booking has been REJECTED by the manager of the room.
  526. +???????????????
  527.  
  528. -Rejection reason:
  529. +?????
  530. {{ reservation.rejection_reason }}
  531.  
  532. {% include 'rb/emails/reservations/reservation_info.txt' %}
  533. diff --git a/modules/rb/templates/emails/reservations/reminders/finishing_bookings.html b/modules/rb/templates/emails/reservations/reminders/finishing_bookings.html
  534. index b56e07c..7b4b454 100644
  535. --- a/modules/rb/templates/emails/reservations/reminders/finishing_bookings.html
  536. +++ b/modules/rb/templates/emails/reservations/reminders/finishing_bookings.html
  537. @@ -29,7 +29,7 @@
  538.  
  539.  
  540. {% macro _render_dates(reservation) -%}
  541. - <strong>{{ reservation.start_dt|format_datetime('EEEE dd/MM/yyyy HH:mm', locale='en_GB') }}</strong> - <strong>{{ reservation.end_dt|format_datetime('EEEE dd/MM/yyyy HH:mm', locale='en_GB') }}</strong>
  542. + <strong>{{ reservation.start_dt|format_datetime('yyyy/MM/dd HH:mm', locale='zh_TW') }}</strong> - <strong>{{ reservation.end_dt|format_datetime('yyyy/MM/dd HH:mm', locale='zh_TW') }}</strong>
  543. {%- endmacro %}
  544.  
  545.  
  546. diff --git a/modules/rb/templates/emails/reservations/reminders/upcoming_occurrence.html b/modules/rb/templates/emails/reservations/reminders/upcoming_occurrence.html
  547. index 6a80ae4..040f941 100644
  548. --- a/modules/rb/templates/emails/reservations/reminders/upcoming_occurrence.html
  549. +++ b/modules/rb/templates/emails/reservations/reminders/upcoming_occurrence.html
  550. @@ -22,14 +22,14 @@
  551.  
  552.  
  553. {% macro _render_time(occurrence) -%}
  554. - {{ occurrence.start_dt | format_time(locale='en_GB') }} - {{ occurrence.end_dt | format_time(locale='en_GB') }}
  555. + {{ occurrence.start_dt | format_time(locale='zh_TW') }} - {{ occurrence.end_dt | format_time(locale='zh_TW') }}
  556. {%- endmacro %}
  557.  
  558.  
  559. {% macro _render_occurrence(occurrence) -%}
  560. {% set reservation = occurrence.reservation -%}
  561.  
  562. - <strong>{{ occurrence.start_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }}</strong> (<strong>{{ _render_time(occurrence) }}</strong>)<br>
  563. + <strong>{{ occurrence.start_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }}</strong> (<strong>{{ _render_time(occurrence) }}</strong>)<br>
  564. Room: <strong>{{ reservation.room.full_name }}</strong><br>
  565. Reason: <strong>{{ reservation.booking_reason }}</strong><br>
  566. <br>
  567. diff --git a/modules/rb/templates/emails/reservations/reservation_info.txt b/modules/rb/templates/emails/reservations/reservation_info.txt
  568. index dad3a0b..f69190e 100644
  569. --- a/modules/rb/templates/emails/reservations/reservation_info.txt
  570. +++ b/modules/rb/templates/emails/reservations/reservation_info.txt
  571. @@ -1,5 +1,5 @@
  572. -Room: {{ reservation.room.full_name }}
  573. -For: {{ reservation.booked_for_name }}
  574. -Reason: {{ reservation.booking_reason }}
  575. -Dates: {{ reservation.start_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }} - {{ reservation.end_dt | format_date('EEEE dd/MM/yyyy', locale='en_GB') }}
  576. -Hours: {{ reservation.start_dt | format_time(locale='en_GB') }} - {{ reservation.end_dt | format_time(locale='en_GB') }}
  577. +???? {{ reservation.room.full_name }}
  578. +???? {{ reservation.booked_for_name }}
  579. +?????{{ reservation.booking_reason }}
  580. +?????{{ reservation.start_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }} - {{ reservation.end_dt | format_date('yyyy/MM/dd (EEEE)', locale='zh_TW') }}
  581. +?????{{ reservation.start_dt | format_time(locale='zh_TW') }} - {{ reservation.end_dt | format_time(locale='zh_TW') }}
  582. diff --git a/modules/rb/templates/emails/reservations/reservation_key_info.txt b/modules/rb/templates/emails/reservations/reservation_key_info.txt
  583. index 3888ba3..b4dd67f 100644
  584. --- a/modules/rb/templates/emails/reservations/reservation_key_info.txt
  585. +++ b/modules/rb/templates/emails/reservations/reservation_key_info.txt
  586. @@ -1,5 +1,5 @@
  587. {% if reservation.room.key_location %}
  588.  
  589. -How to find a key:
  590. +?????
  591. {{ reservation.room.key_location | striptags }}
  592. {%- endif %}
  593. diff --git a/util/date_time.py b/util/date_time.py
  594. index 448e19d..cc613c8 100644
  595. --- a/util/date_time.py
  596. +++ b/util/date_time.py
  597. @@ -115,7 +115,7 @@ def format_date(d, format='medium', locale=None, timezone=None):
  598. """
  599. inject_unicode = True
  600. if format == 'code':
  601. - format = 'dd/MM/yyyy'
  602. + format = 'yyyy/MM/dd'
  603. inject_unicode = False
  604. if not locale:
  605. locale = get_current_locale()
  606. diff --git a/util/date_time.pyc b/util/date_time.pyc
  607. index 06ed84d..e7a1476 100644
  608. Binary files a/util/date_time.pyc and b/util/date_time.pyc differ
  609. diff --git a/web/forms/fields/datetime.py b/web/forms/fields/datetime.py
  610. index 4c8aae5..fc68af1 100644
  611. --- a/web/forms/fields/datetime.py
  612. +++ b/web/forms/fields/datetime.py
  613. @@ -180,7 +180,7 @@ class IndicoDateField(DateField):
  614.  
  615. def __init__(self, *args, **kwargs):
  616. super(IndicoDateField, self).__init__(*args, parse_kwargs={'dayfirst': True},
  617. - display_format='%d/%m/%Y', **kwargs)
  618. + display_format='%Y/%m/%d', **kwargs)
  619.  
  620.  
  621. class IndicoDateTimeField(DateTimeField):
  622. diff --git a/web/forms/fields/datetime.pyc b/web/forms/fields/datetime.pyc
  623. index b06c2c6..2d380e5 100644
  624. Binary files a/web/forms/fields/datetime.pyc and b/web/forms/fields/datetime.pyc differ
  625. diff --git a/web/static/dist/js/jquery.e8708f7b.bundle.js b/web/static/dist/js/jquery.e8708f7b.bundle.js
  626. index 6e7007f..327278b 100644
  627. --- a/web/static/dist/js/jquery.e8708f7b.bundle.js
  628. +++ b/web/static/dist/js/jquery.e8708f7b.bundle.js
  629. @@ -121,7 +121,7 @@ var n;n=function(){return function(e){var t={};function i(n){if(t[n])return t[n]
  630. * Copyright jQuery Foundation and other contributors
  631. * Released under the MIT license.
  632. * http://jquery.org/license
  633. -[eliminated]
  634. +[eliminated]
  635. /*!
  636. * jQuery UI Dialog 1.12.1
  637. * http://jqueryui.com
  638. @@ -269,7 +269,7 @@ var n;n=function(){return function(e){var t={};function i(n){if(t[n])return t[n]
  639. * @author Tom Bertrand
  640. * @version 2.10.6 (2018-7-30)
  641. * @link http://www.runningcoder.org/jquerytypeahead/
  642. -[eliminated]
  643. +[eliminated]
  644. /*!
  645. * jQuery UI Widget 1.12.1
  646. * http://jqueryui.com
  647. @@ -313,4 +313,4 @@
  648. -[eliminated]
  649. -//# sourceMappingURL=jquery.e8708f7b.bundle.js.map
  650. \ No newline at end of file
  651. +//# sourceMappingURL=jquery.e8708f7b.bundle.js.map
  652. diff --git a/web/static/dist/js/jquery.e8708f7b.bundle.js.map b/web/static/dist/js/jquery.e8708f7b.bundle.js.map
  653. index dd3d1c1..8dba202 100644
  654. --- a/web/static/dist/js/jquery.e8708f7b.bundle.js.map
  655. +++ b/web/static/dist/js/jquery.e8708f7b.bundle.js.map
  656. @@ -1 +1 @@
  657. -[eliminated]
  658. \ No newline at end of file
  659. +[eliminated]
  660. diff --git a/web/static/dist/js/main.68ba26bc.bundle.js b/web/static/dist/js/main.68ba26bc.bundle.js
  661. index 4546993..8416602 100644
  662. --- a/web/static/dist/js/main.68ba26bc.bundle.js
  663. +++ b/web/static/dist/js/main.68ba26bc.bundle.js
  664. @@ -1,2 +1,2 @@
  665. -[eliminated]
  666. -//# sourceMappingURL=main.68ba26bc.bundle.js.map
  667. \ No newline at end of file
  668. +[eliminated]
  669. +//# sourceMappingURL=main.68ba26bc.bundle.js.map
  670. diff --git a/web/static/dist/js/main.68ba26bc.bundle.js.map b/web/static/dist/js/main.68ba26bc.bundle.js.map
  671. index 105e54f..db4c91c 100644
  672. --- a/web/static/dist/js/main.68ba26bc.bundle.js.map
  673. +++ b/web/static/dist/js/main.68ba26bc.bundle.js.map
  674. @@ -1 +1 @@
  675. -[eliminated]
  676. \ No newline at end of file
  677. +[eliminated]
  678. diff --git a/web/templates/forms/datetime_widget.html b/web/templates/forms/datetime_widget.html
  679. index f4093f9..b50986e 100644
  680. --- a/web/templates/forms/datetime_widget.html
  681. +++ b/web/templates/forms/datetime_widget.html
  682. @@ -4,7 +4,7 @@
  683. {% block html %}
  684. <div class="datetime-widget i-form-field-fixed-width">
  685. <input type="hidden" autofocus>
  686. - <input type="text" name="{{ field.name }}" id="{{ field.id }}-date" class="datepicker" placeholder="DD/MM/YYYY"
  687. + <input type="text" name="{{ field.name }}" id="{{ field.id }}-date" class="datepicker" placeholder="YYYY/MM/DD"
  688. {% if field.data and not field.date_missing %}value="{{ field.data | format_date('code', timezone=field.timezone) }}"{% endif %}
  689. {% if required %}required{% endif %}
  690. {% if disabled %}disabled{% endif %}>{#--#}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement