-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjson.html
More file actions
79 lines (76 loc) · 3.05 KB
/
json.html
File metadata and controls
79 lines (76 loc) · 3.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
---
layout: nil
sitemap: false
---
[
{% assign sorted_warsztaty = site.warsztaty | sort: 'event_date' %}
{% for warsztat in sorted_warsztaty %}
{% capture nowtime %}{{site.time | date: '%s'}}{% endcapture %}
{% capture eventtime %}{{warsztat.event_date | date: '%s'}}{% endcapture %}
{% if eventtime < nowtime %}
{% continue %}
{% endif %}
{% assign prowadzacy = site.data.prowadzacy[warsztat.prowadzacy] %}
{% assign lokalizacja = site.data.lokalizacje[warsztat.lokalizacja] %}
{% assign button_class = 'btn btn-xl' %}
{% assign event_date = warsztat.event_date %}
{% assign item_class = '' %}
{% if warsztat.type %}
{% if warsztat.type == 'meetup' %}
{% assign button_text = 'MEETUP' %}
{% assign event_link = warsztat.meetup_link %}
{% elsif warsztat.type == 'bootcamp' %}
{% assign button_text = 'ZAREJESTRUJ SIĘ' %}
{% assign event_link = warsztat.evenea_link %}
{% assign button_class = 'btn btn-xl workshop-bootcamp' %}
{% assign item_class = 'item-bootcamp' %}
{% elsif warsztat.type == 'planowane' %}
{% assign button_text = 'Rejestracja wkrótce' %}
{% assign event_link = '#' %}
{% assign button_class = 'btn btn-xl workshop-future' %}
{% assign m = warsztat.event_date | date: "%-m" %}
{% capture event_date %}
{% case m %}
{% when '1' %}Styczeń
{% when '2' %}Luty
{% when '3' %}Marzec
{% when '4' %}Kwiecień
{% when '5' %}Maj
{% when '6' %}Czerwiec
{% when '7' %}Lipiec
{% when '8' %}Sierpień
{% when '9' %}Wrzesień
{% when '10' %}Październik
{% when '11' %}Listopad
{% when '12' %}Grudzień
{% endcase %}
{{ warsztat.event_date | date: "%Y" }}
{% endcapture %}
{% else %}
{% assign button_text = 'ZAREJESTRUJ SIĘ' %}
{% assign event_link = warsztat.url %}
{% endif %}
{% else %}
{% assign button_text = 'ZAREJESTRUJ SIĘ' %}
{% assign event_link = warsztat.url %}
{% endif %}
{
"title" : "{{ warsztat.title | replace: '"', '\"' | newline_to_br | strip_newlines }}",
"url" : "{{ event_link }}",
"date" : "{{ event_date }}",
"price" : "{{ warsztat.cena }}",
"city" : "{{ lokalizacja.miasto }}",
{% if warsztat.type %}
"type" : "{{ warsztat.type }}",
{% else %}
"type" : "aktywne",
{% endif %}
"overview" : "{{ warsztat.opis.informacje | replace: '"', '\"' | newline_to_br | strip_newlines }}",
"agenda" : "{{ warsztat.opis.program | replace: '"', '\"' | newline_to_br | strip_newlines }}",
"additional_info" : "{{ warsztat.opis.uwaga | replace: '"', '\"' | newline_to_br | strip_newlines }}",
"duration" : "{{ warsztat.dlugosc }}"{% if warsztat.opis.krotki_opis %},
"shortDescription" : "{{ warsztat.opis.krotki_opis | replace: '"', '\"' | newline_to_br | strip_newlines }}"
{% endif %}
} {% if forloop.last %}{% else %},{% endif %}
{% endfor %}
]