Skip to content

Commit 49fc98e

Browse files
committed
Highlight session's date to check Active/In-active easier in events#latest
1 parent a936528 commit 49fc98e

File tree

2 files changed

+16
-5
lines changed

2 files changed

+16
-5
lines changed

app/views/events/latest.html.erb

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,13 @@
3737
td {
3838
padding: 1px 10px 1px 10px;
3939
text-align: right;
40+
font-size: smaller;
41+
}
42+
span.expired {
43+
a {
44+
color: red;
45+
background-color: #ffe5e5; /* 薄い赤背景 */
46+
}
4047
}
4148
td.url-cell {
4249
white-space: normal; /* 改行を許可 */
@@ -74,9 +81,12 @@
7481
<td>
7582
<small>
7683
<% if dojo[:event_url].nil? %>
77-
<%= dojo[:event_at] %>
84+
<span><%= dojo[:event_at] %></span>
85+
<% elsif dojo[:event_at] <= Time.current.prev_year && !dojo[:note].include?('Active') %>
86+
<!-- 1年以上開催が確認できていない Dojo で、"Active" の確認が無い場合はハイライトする -->
87+
<span class='expired'><a href="<%= dojo[:event_url] %>"><%= dojo[:event_at] %></a></span>
7888
<% else %>
79-
<a href="<%= dojo[:event_url] %>"><%= dojo[:event_at] %></a>
89+
<span><a href="<%= dojo[:event_url] %>"><%= dojo[:event_at] %></a></span>
8090
<% end %>
8191
</small>
8292
</td>

db/dojos.yaml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -807,7 +807,7 @@
807807
- toio
808808
- id: 86
809809
order: '122041'
810-
note: Forms 管理に移行
810+
note: Active - Forms 管理に移行 - https://funabashi.coderdojo.chiba.jp/
811811
created_at: '2017-05-16'
812812
name: 船橋
813813
prefecture_id: 12
@@ -3613,7 +3613,7 @@
36133613
- Minecraft
36143614
- id: 188
36153615
order: '363421'
3616-
note: 独自サービスでイベント管理 https://www.in-kamiyama.jp/events
3616+
note: Active - 独自サービスでイベント管理 https://www.in-kamiyama.jp/events
36173617
created_at: '2018-12-13'
36183618
name: 神山
36193619
prefecture_id: 36
@@ -3841,11 +3841,12 @@
38413841
- micro:bit
38423842
- id: 269
38433843
order: '412015'
3844+
note: Active - peatix でイベント管理 https://peatix.com/group/10488940
38443845
created_at: '2021-05-03'
38453846
name: さが
38463847
prefecture_id: 41
38473848
logo: "/img/dojos/saga.webp"
3848-
url: https://peatix.com/group/10488940/view
3849+
url: https://peatix.com/group/10488940
38493850
description: 佐賀市で毎月開催
38503851
tags:
38513852
- Viscuit

0 commit comments

Comments
 (0)