Skip to content

Commit

Permalink
演習の具体的な実施手順等を示す資料を作るためのページを作成
Browse files Browse the repository at this point in the history
  • Loading branch information
komagata committed Feb 18, 2025
1 parent 7acd800 commit 62269ff
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# frozen_string_literal: true

class Paper::ExerciseProcedureDocumentController < PaperController
def show
ignore_practice_ids = [6, 19, 23, 25, 57]
@categories = Course.find(1).categories.where.not(id: ignore_practice_ids)
end
end
45 changes: 45 additions & 0 deletions app/views/paper/exercise_procedure_document/show.html.slim
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
.book-name 演習の具体的な実施手順等を示す資料

.book-company_name 株式会社ロッカ
.book-updated #{Date.current.year}#{Date.current.month}

div(style="page-break-before:always")

h2 演習の具体的な実施手順等を示す資料の概要

p
| 本資料は、提出物が必要なカリキュラム項目をまとめたものです。
| 提出物が不要なカリキュラムは含まれていません。
| 資料内では、提出物の内容と具体的な手順について詳述しています。

h2 受講生の提出物の確認プロセス

p 提出物はメンターによって確認され、内容に問題がなければ該当カリキュラムは修了となります。
p 課題の文章と解答例を記載しています。

div(style="page-break-before:always")

h2 目次

- @categories.each_with_index do |category, i|
- category.practices.where(submission: true).each_with_index do |practice, h|
| #{i + 1}.#{h + 1}&nbsp;
= link_to practice.title, "##{practice.id}"
br

div(style="page-break-before:always")

- @categories.each_with_index do |category, i|
- category.practices.where(submission: true).each_with_index do |practice, h|
h3.practice_title(id="#{practice.id}")
| #{i + 1}.#{h + 1} #{practice.title.strip}

h4 課題

.a-long-text.is-md.js-markdown-view = practice.goal

h4 解答例

.a-long-text.is-md.js-markdown-view = practice.submission_answer.description

div(style="page-break-before:always")
1 change: 1 addition & 0 deletions config/routes/paper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
Rails.application.routes.draw do
namespace :paper do
root to: "home#index", as: :root
resource :exercise_procedure_document, only: %i(show), controller: "exercise_procedure_document"
end
end

0 comments on commit 62269ff

Please sign in to comment.