Skip to content

Commit

Permalink
Merge pull request #1651 from coderdojo-japan/publish-coderdojo-stats…
Browse files Browse the repository at this point in the history
…-in-2024

📊 Publish CoderDojo Stats in 2024 ☯️✨
  • Loading branch information
yasulab authored Jan 1, 2025
2 parents d097157 + 811497c commit 76562ad
Show file tree
Hide file tree
Showing 3 changed files with 85 additions and 6 deletions.
4 changes: 2 additions & 2 deletions app/controllers/stats_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ def show
return
end

# 2012年1月1日〜2023年12月31日までの集計結果
# 2012年1月1日〜2024年12月31日までの集計結果
@period_start = 2012
@period_end = 2023
@period_end = 2024
period = Time.zone.local(@period_start).beginning_of_year..Time.zone.local(@period_end).end_of_year
stats = Stat.new(period)

Expand Down
6 changes: 3 additions & 3 deletions app/models/high_charts_builder.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def build_annual_event_histories(source)
f.series(type: 'line', name: '累積合計', yAxis: 1, data: data[:cumulative_sums])
f.yAxis [
{ title: { text: '開催回数' }, tickInterval: 500, max: 2000 },
{ title: { text: '累積合計' }, tickInterval: 2500, max: 10000, opposite: true }
{ title: { text: '累積合計' }, tickInterval: 3000, max: 12000, opposite: true }
]
f.chart(width: 600, alignTicks: false)
f.colors(["#F4C34F", "#BD2561"])
Expand All @@ -49,8 +49,8 @@ def build_annual_participants(source)
f.series(type: 'column', name: '参加者数', yAxis: 0, data: data[:increase_nums])
f.series(type: 'line', name: '累積合計', yAxis: 1, data: data[:cumulative_sums])
f.yAxis [
{ title: { text: '参加者数' }, tickInterval: 2500, max: 12500 },
{ title: { text: '累積合計' }, tickInterval: 12000, max: 60000, opposite: true }
{ title: { text: '参加者数' }, tickInterval: 2500, max: 12500 },
{ title: { text: '累積合計' }, tickInterval: 14000, max: 64000, opposite: true }
]
f.chart(width: 600, alignTicks: false)
f.colors(["#EF685E", "#35637D"])
Expand Down
81 changes: 80 additions & 1 deletion db/static_event_histories.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,36 @@
# https://dojocon-japan.doorkeeper.jp/events/past
#
# ID 194: CoderDojo 三次 - https://www.facebook.com/dojo.miyoshi/past_hosted_events
# MEMO: データ追加のサンプルとして2023年のイベント情報を入れてみています。
# MEMO: データ追加のサンプルとして2023〜2024年のイベント情報を入れてみています。
# 「興味あり」はカウントせず、「参加者」のみをカウントしています。
#
# 2024
- dojo_id: 194
event_url: https://www.facebook.com/events/436353945837073/
evented_at: 2024-06-09 14:00
participants: 1
- dojo_id: 194
event_url: https://www.facebook.com/events/1550750222136890/
evented_at: 2024-05-12 14:00
participants: 1
- dojo_id: 194
event_url: https://www.facebook.com/events/967674081399396/
evented_at: 2024-04-14 14:00
participants: 1
- dojo_id: 194
event_url: https://www.facebook.com/events/800050015495383/
evented_at: 2024-03-10 14:00
participants: 1
- dojo_id: 194
event_url: https://www.facebook.com/events/1581483302667332/
evented_at: 2024-02-11 14:00
participants: 1
- dojo_id: 194
event_url: https://www.facebook.com/events/1072946490568386/
evented_at: 2024-01-14 14:00
participants: 1

# 2023
- dojo_id: 194
event_url: https://www.facebook.com/events/359085903440917/
evented_at: 2023-12-10 14:00
Expand Down Expand Up @@ -69,6 +98,50 @@
evented_at: 2023-01-08 14:00
participants: 2

# ID 268: CoderDojo 吉備 as DojoCon Japan 2024
- dojo_id: 268
event_url: https://dojocon-japan.doorkeeper.jp/events/176163 # 入場チケット
evented_at: 2024-09-15 10:00
participants: 114
- dojo_id: 268
event_url: https://dojocon-japan.doorkeeper.jp/events/176169 # 同伴者1
evented_at: 2024-09-15 10:00
participants: 20
- dojo_id: 268
event_url: https://dojocon-japan.doorkeeper.jp/events/176171 # 同伴者2
evented_at: 2024-09-15 10:00
participants: 5
- dojo_id: 268
event_url: https://dojocon-japan.doorkeeper.jp/events/176202 # 同伴者3
evented_at: 2024-09-15 10:00
participants: 1
- dojo_id: 268
event_url: https://dojocon-japan.doorkeeper.jp/events/176203 # 同伴者4
evented_at: 2024-09-15 10:00
participants: 0
- dojo_id: 268
event_url: https://dojocon-japan.doorkeeper.jp/events/177221 # マイクラ
evented_at: 2024-09-15 10:00
participants: 8
- dojo_id: 268
event_url: https://dojocon-japan.doorkeeper.jp/events/177223 # CoderDojo WS
evented_at: 2024-09-15 10:00
participants: 2
- dojo_id: 268
event_url: https://dojocon-japan.doorkeeper.jp/events/177222 # M5Stack
evented_at: 2024-09-15 10:00
participants: 6

# NOTE: 懇親会は Stats の利用シーンの性質と合わないかもなので一旦除外
#- dojo_id: 268
# event_url: https://dojocon-japan.doorkeeper.jp/events/177349 # 懇親会
# evented_at: 2024-09-15 10:00
# participants: 40
#- dojo_id: 268
# event_url: https://dojocon-japan.doorkeeper.jp/events/177350 # 懇親会 LT
# evented_at: 2024-09-15 10:00
# participants: 7


# ID 35: CoderDojo 奈良 as DojoCon Japan 2023
- dojo_id: 35
Expand Down Expand Up @@ -104,6 +177,12 @@
evented_at: 2023-08-27 15:00
participants: 10

# ID 248: CoderDojo 矢吹 (共催) as やぶきプログラミングフェス with DecaDojo (2024)
# 開催レポート: https://coderdojoshirakawa.hateblo.jp/entry/2024/07/20/220134
- dojo_id: 248
event_url: https://coderdojoshirakawa.hateblo.jp/entry/2024/07/20/220134
evented_at: 2024/06/15 13:00
participants: 100

# ID 79: CoderDojo 会津 as 福島でかドージョー2023
- dojo_id: 79
Expand Down

0 comments on commit 76562ad

Please sign in to comment.