From 5b33c3d8298191a7e0578662cf2f94522d2c0602 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Mon, 30 Jun 2025 04:23:27 +0900
Subject: [PATCH 01/20] =?UTF-8?q?feat:=20=E7=81=AB=E6=B0=97=E4=BD=BF?=
=?UTF-8?q?=E7=94=A8=E7=94=B3=E8=AB=8BUI=E5=AE=9F=E8=A3=85?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../pages/fire_equipment_orders/_id.vue | 211 ++++++++++++++
.../pages/fire_equipment_orders/index.vue | 266 ++++++++++++++++++
2 files changed, 477 insertions(+)
create mode 100644 admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
create mode 100644 admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
new file mode 100644
index 000000000..aebdd5d31
--- /dev/null
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
@@ -0,0 +1,211 @@
+
+
+
+
+
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
new file mode 100644
index 000000000..f06b649be
--- /dev/null
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
@@ -0,0 +1,266 @@
+
+
+
+
+ 追加
+
+
+ CSV
+
+
+
+
+
+
+ {{ refYears }}
+
+
+
+
+
+
+
+ |
+ {{ header }}
+ |
+
+
+
+ $router.push({
+ path: `/fire_equipment_orders/` + order.id,
+ })
+ "
+ :key="order.id"
+ >
+ | {{ order.id }} |
+ {{ getGroupName(order.group_id) }} |
+ {{ order.name }} |
+ {{ order.quantity }} |
+ {{ getFuelName(order.fuel) }} |
+ {{ order.usage }} |
+ {{ order.is_takeaway ? "はい" : "いいえ" }} |
+ {{ order.remark }} |
+
+
+
+
+
+
+
+
+
団体名
+
+
+
+
品目
+
+
+
+
数量
+
+
+
+
燃料
+
+
+
+
使用場所
+
+
+
+
持ち帰り
+
+
+
+
備考
+
+
+
+
+ 登録
+
+
+
+
+ {{ message }}
+
+
+
+
+
From 4a74430b20f7312842f4ee347c6ad1593828f8a2 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Mon, 30 Jun 2025 04:23:46 +0900
Subject: [PATCH 02/20] =?UTF-8?q?feat:=20dashboard=E3=81=AB=E4=BB=98?=
=?UTF-8?q?=E4=B8=8E?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
admin_view/nuxt-project/components/Menu.vue | 5 +++++
admin_view/nuxt-project/pages/dashboard.vue | 11 +++++++++++
2 files changed, 16 insertions(+)
diff --git a/admin_view/nuxt-project/components/Menu.vue b/admin_view/nuxt-project/components/Menu.vue
index 80bf09427..e53094717 100644
--- a/admin_view/nuxt-project/components/Menu.vue
+++ b/admin_view/nuxt-project/components/Menu.vue
@@ -169,6 +169,11 @@ export default {
title: "調理工程申請",
icon: "restaurant",
click: "/cooking_process_order",
+ },
+ {
+ title: "火気使用申請",
+ icon: "local_fire_department",
+ click: "/fire_equipment_orders",
}
],
// 操作系
diff --git a/admin_view/nuxt-project/pages/dashboard.vue b/admin_view/nuxt-project/pages/dashboard.vue
index 9655b8384..43cf190bf 100644
--- a/admin_view/nuxt-project/pages/dashboard.vue
+++ b/admin_view/nuxt-project/pages/dashboard.vue
@@ -39,6 +39,17 @@
+
+
+
+ 火気使用申請
+
+
+ 申請数:{{ dashboard_data.fire_equipment_orders_length }}
+ 持ち帰り有:{{ dashboard_data.takeaway_true_num }}
+ 持ち帰り無:{{ dashboard_data.takeaway_false_num }}
+
+
閲覧権限がありません
From a507c2474134e50a3c34ab8e245613283e1a263b Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Mon, 30 Jun 2025 04:24:14 +0900
Subject: [PATCH 03/20] feat: Add fire equipment order statistics to dashboard
API
---
api/app/controllers/api/v1/dashboard_api_controller.rb | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/api/app/controllers/api/v1/dashboard_api_controller.rb b/api/app/controllers/api/v1/dashboard_api_controller.rb
index 8c715c6db..c5c2f7d18 100644
--- a/api/app/controllers/api/v1/dashboard_api_controller.rb
+++ b/api/app/controllers/api/v1/dashboard_api_controller.rb
@@ -26,6 +26,9 @@ def get_dashboard_info
progress_assign_item_1 = (assign_item_status_1*100) / all_length
progress_assign_item_2 = (assign_item_status_2*100) / all_length
progress_assign_item_3 = (assign_item_status_3*100) / all_length
+ fire_equipment_orders_length = FireEquipmentOrder.all.length
+ takeaway_true_num = FireEquipmentOrder.where(is_takeaway: true).length
+ takeaway_false_num = FireEquipmentOrder.where(is_takeaway: false).length
group_data = {
all_user_num: all_user_num,
manager_num: manager_num,
@@ -44,6 +47,9 @@ def get_dashboard_info
progress_assign_item_1: progress_assign_item_1,
progress_assign_item_2: progress_assign_item_2,
progress_assign_item_3: progress_assign_item_3,
+ fire_equipment_orders_length: fire_equipment_orders_length,
+ takeaway_true_num: takeaway_true_num,
+ takeaway_false_num: takeaway_false_num,
}
render json: group_data
From 31123c6d474312623de905bf7e87962f67cd20e5 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Mon, 30 Jun 2025 04:24:40 +0900
Subject: [PATCH 04/20] =?UTF-8?q?feat:=20=E7=81=AB=E6=B0=97=E4=BD=BF?=
=?UTF-8?q?=E7=94=A8=E7=94=B3=E8=AB=8B=E3=80=81addmodal=E7=94=A8=E5=8F=96?=
=?UTF-8?q?=E5=BE=97API?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
api/app/controllers/api/v1/groups_api_controller.rb | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/api/app/controllers/api/v1/groups_api_controller.rb b/api/app/controllers/api/v1/groups_api_controller.rb
index bb0008ea9..4d73e3bc0 100644
--- a/api/app/controllers/api/v1/groups_api_controller.rb
+++ b/api/app/controllers/api/v1/groups_api_controller.rb
@@ -98,4 +98,14 @@ def get_search_groups
end
end
+ def get_groups_for_fire_equipment_order
+ fes_year_id = params[:fes_year_id]
+ if fes_year_id.present? && fes_year_id.to_i != 0
+ @groups = Group.where(fes_year_id: fes_year_id).order(:id)
+ else
+ @groups = Group.all.order(:id)
+ end
+ render json: { data: @groups }
+ end
+
end
From 5dcce1b83aab89f71d084bccb447f001d0d25d02 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Mon, 30 Jun 2025 04:24:55 +0900
Subject: [PATCH 05/20] =?UTF-8?q?wip:=20=E5=8B=95=E4=BD=9C=E6=9C=AA?=
=?UTF-8?q?=E6=A4=9C=E8=A8=BC=E3=80=81csv=E5=87=BA=E5=8A=9B?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../api/v1/output_csv_controller.rb | 59 ++++++++++++++-----
1 file changed, 45 insertions(+), 14 deletions(-)
diff --git a/api/app/controllers/api/v1/output_csv_controller.rb b/api/app/controllers/api/v1/output_csv_controller.rb
index a77198aa3..f071719a4 100644
--- a/api/app/controllers/api/v1/output_csv_controller.rb
+++ b/api/app/controllers/api/v1/output_csv_controller.rb
@@ -413,13 +413,13 @@ def output_users_csv
@groups = Group.where(fes_year_id: params[:fes_year_id]).preload(:user, :sub_rep, user: :user_detail) # 必要な関連を事前にロード
filename_year = FesYear.find(params[:fes_year_id]).year_num
end
-
+
@categories = []
for i in 1..6 do
group = @groups.where(group_category_id: i)
@categories << group
end
-
+
bom = "\uFEFF"
csv_data = CSV.generate(bom) do |csv|
column_name = %w(参加団体形式 団体番号 団体名 氏名 電話番号 メールアドレス 備考欄)
@@ -452,10 +452,10 @@ def output_users_csv
end
end
end
-
+
send_data(csv_data, filename: "連絡先リスト_#{filename_year}年度.csv")
end
-
+
def output_announcements_csv
@announcements = Announcement.all
@@ -483,8 +483,8 @@ def output_cooking_process_orders_csv
@cooking_process_orders.each do |cooking_process_order|
column_values = [
cooking_process_order.group.name,
- cooking_process_order.pre_open_kitchen ? "申請する" : "申請しない",
- cooking_process_order.during_open_kitchen ? "申請する" : "申請しない",
+ cooking_process_order.pre_open_kitchen ? "申請する" : "申請しない",
+ cooking_process_order.during_open_kitchen ? "申請する" : "申請しない",
cooking_process_order.tent
]
csv << column_values
@@ -503,18 +503,16 @@ def output_public_relations_csv
end
bom = "\uFEFF"
csv_data = CSV.generate(bom) do |csv|
- column_name = %w(参加団体名 PR文 URL アナウンス有無)
+ column_name = %w(参加団体名 PR文 PR画像)
csv << column_name
- @public_relations.each do |public_relations|
- # データが存在しない場合はスキップする
- if public_relations.nil?
+ @public_relations.each do |public_relation|
+ if public_relation.nil?
next
end
column_values = [
- public_relations.group.name,
- public_relations.blurb,
- public_relations.picture_path,
- public_relations.is_announcement_requested ? "有" : "無",
+ public_relation.group.name,
+ public_relation.pr_comment,
+ public_relation.pr_image,
]
csv << column_values
end
@@ -522,4 +520,37 @@ def output_public_relations_csv
send_data(csv_data, filename:"参加団体PR申請_#{filename_year}年度.csv")
end
+ def output_fire_equipment_orders_csv
+ if params[:fes_year_id].to_i == 0
+ @fire_equipment_orders = FireEquipmentOrder.all
+ filename_year = "全"
+ else
+ fes_year = FesYear.find(params[:fes_year_id])
+ @fire_equipment_orders = FireEquipmentOrder.joins(:group).where(groups: { fes_year_id: fes_year.id })
+ filename_year = fes_year.year_num
+ end
+ bom = "\uFEFF"
+ csv_data = CSV.generate(bom) do |csv|
+ column_name = %w(ID 団体名 品目 数量 燃料 使用場所 持ち帰り 備考)
+ csv << column_name
+ @fire_equipment_orders.each do |order|
+ if order.nil?
+ next
+ end
+ column_values = [
+ order.id,
+ order.group.name,
+ order.name,
+ order.quantity,
+ order.fuel,
+ order.usage,
+ order.is_takeaway ? 'はい' : 'いいえ',
+ order.remark,
+ ]
+ csv << column_values
+ end
+ end
+ send_data(csv_data, filename: "火気使用申請_#{filename_year}年度.csv")
+ end
+
end
From 745361190033d6c85a5597630ebe413070db44f0 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Mon, 30 Jun 2025 04:25:03 +0900
Subject: [PATCH 06/20] feat: Add routes for fire equipment order and related
CSV outputs
---
api/config/routes.rb | 11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)
diff --git a/api/config/routes.rb b/api/config/routes.rb
index b00d55244..688426781 100644
--- a/api/config/routes.rb
+++ b/api/config/routes.rb
@@ -242,6 +242,9 @@
post "get_search_cooking_process_orders" => "cooking_process_orders_api#get_search_cooking_process_orders"
get "get_groups_have_no_cooking_process_order" => "groups_api#get_groups_have_no_cooking_process_order"
+ #---火気使用申請
+ get "get_groups_for_fire_equipment_order" => "groups_api#get_groups_for_fire_equipment_order"
+
#---実行委員担当者申請ページ
get "get_contact_person_index_for_admin_view" => "contact_persons_api#get_contact_person_index_for_admin_view"
get "get_contact_person_show_for_admin_view/:id" => "contact_persons_api#get_contact_person_show_for_admin_view"
@@ -286,6 +289,12 @@
get "get_announcements_csv" => "output_csv#output_announcements_csv"
get "get_cooking_process_orders_csv" => "output_csv#output_cooking_process_orders_csv"
get "get_public_relations_csv/:fes_year_id" => "output_csv#output_public_relations_csv"
+ get "get_fire_equipment_orders_csv/:fes_year_id" => "output_csv#output_fire_equipment_orders_csv"
+
+ #---pdf出力
+ get "output_pdf/rental_items" => "print_pdf#rental_items_pdf"
+ get "output_pdf/power_orders" => "print_pdf#power_orders_pdf"
+ get "get_project_check_list_pdf/:group_id" => "output_pdf#output_project_check_list_pdf"
# ダッシュボード
get "dashboard" => "dashboard_api#get_dashboard_info"
@@ -340,4 +349,4 @@
end
end
-end
\ No newline at end of file
+end
From 7c51e83b255a4173cae4d690e85e48b4d19f930d Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 6 Jul 2025 19:08:57 +0900
Subject: [PATCH 07/20] =?UTF-8?q?=E6=A9=9F=E8=83=BD=E8=BF=BD=E5=8A=A0:=20?=
=?UTF-8?q?=E7=81=AB=E6=B0=97=E4=BD=BF=E7=94=A8=E7=94=B3=E8=AB=8BAPI?=
=?UTF-8?q?=E3=81=A7fes=5Fyear=5Fid=E3=81=AB=E3=82=88=E3=82=8B=E7=B5=9E?=
=?UTF-8?q?=E3=82=8A=E8=BE=BC=E3=81=BF=E3=81=A8=E5=9B=A3=E4=BD=93=E6=83=85?=
=?UTF-8?q?=E5=A0=B1=E3=81=AE=E4=BB=98=E4=B8=8E=E3=81=AB=E5=AF=BE=E5=BF=9C?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../controllers/fire_equipment_orders_controller.rb | 11 ++++++++---
api/app/models/fire_equipment_order.rb | 1 +
2 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/api/app/controllers/fire_equipment_orders_controller.rb b/api/app/controllers/fire_equipment_orders_controller.rb
index 29edd5394..1bdbf4845 100644
--- a/api/app/controllers/fire_equipment_orders_controller.rb
+++ b/api/app/controllers/fire_equipment_orders_controller.rb
@@ -4,13 +4,18 @@ class FireEquipmentOrdersController < ApplicationController
# GET /fire_equipment_orders
def index
- @fire_equipment_orders = FireEquipmentOrder.all
- render json: fmt(ok, @fire_equipment_orders)
+ fes_year_id = params[:fes_year_id]
+ if fes_year_id.present? && fes_year_id.to_i != 0
+ @fire_equipment_orders = FireEquipmentOrder.joins(:group).where(groups: { fes_year_id: fes_year_id })
+ else
+ @fire_equipment_orders = FireEquipmentOrder.includes(:group).all
+ end
+ render json: fmt(ok, @fire_equipment_orders.as_json(include: { group: { only: [:id, :name] } }))
end
# GET /fire_equipment_orders/:id
def show
- render json: fmt(ok, @fire_equipment_order)
+ render json: fmt(ok, @fire_equipment_order.as_json(include: { group: { only: [:id, :name] } }))
end
# POST /fire_equipment_orders
diff --git a/api/app/models/fire_equipment_order.rb b/api/app/models/fire_equipment_order.rb
index a4e0b9d8e..8fdf4d70f 100644
--- a/api/app/models/fire_equipment_order.rb
+++ b/api/app/models/fire_equipment_order.rb
@@ -1,4 +1,5 @@
class FireEquipmentOrder < ApplicationRecord
+ belongs_to :group
# enum gas_bottle: ガスボンベ、lp_gas: LPガス、charcoal: 炭
enum fuel: { gas_bottle: 1, lp_gas: 2, charcoal: 3 }
end
From d7316f447b5a80a8e4f0d62bd8b2d7a2585eb1f8 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 6 Jul 2025 19:09:17 +0900
Subject: [PATCH 08/20] =?UTF-8?q?feat:=20=E7=81=AB=E6=B0=97=E4=BD=BF?=
=?UTF-8?q?=E7=94=A8=E7=94=B3=E8=AB=8B=E3=81=AECSV=E5=87=BA=E5=8A=9B?=
=?UTF-8?q?=E3=82=92=E6=94=B9=E5=96=84=EF=BC=88=E7=87=83=E6=96=99=E3=81=AE?=
=?UTF-8?q?=E6=97=A5=E6=9C=AC=E8=AA=9E=E5=A4=89=E6=8F=9B=E3=83=BBnil?=
=?UTF-8?q?=E3=83=87=E3=83=BC=E3=82=BF=E5=AF=BE=E5=BF=9C=EF=BC=89?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../controllers/api/v1/output_csv_controller.rb | 16 +++++++++++-----
1 file changed, 11 insertions(+), 5 deletions(-)
diff --git a/api/app/controllers/api/v1/output_csv_controller.rb b/api/app/controllers/api/v1/output_csv_controller.rb
index f071719a4..413f4b065 100644
--- a/api/app/controllers/api/v1/output_csv_controller.rb
+++ b/api/app/controllers/api/v1/output_csv_controller.rb
@@ -534,15 +534,21 @@ def output_fire_equipment_orders_csv
column_name = %w(ID 団体名 品目 数量 燃料 使用場所 持ち帰り 備考)
csv << column_name
@fire_equipment_orders.each do |order|
- if order.nil?
- next
- end
+ next if order.nil?
+ # fuelを日本語に変換
+ fuel_jp = case order.fuel
+ when "gas_bottle" then "ガスボンベ"
+ when "lp_gas" then "LPガス"
+ when "charcoal" then "炭"
+ else order.fuel.to_s
+ end
+ group_name = order.group&.name || ""
column_values = [
order.id,
- order.group.name,
+ group_name,
order.name,
order.quantity,
- order.fuel,
+ fuel_jp,
order.usage,
order.is_takeaway ? 'はい' : 'いいえ',
order.remark,
From abd0002bb5c241d84052f87eb103f9056e35658a Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 6 Jul 2025 19:09:23 +0900
Subject: [PATCH 09/20] =?UTF-8?q?fix:=20=E4=BF=AE=E6=AD=A3=E7=81=AB?=
=?UTF-8?q?=E6=B0=97=E4=BD=BF=E7=94=A8=E7=94=B3=E8=AB=8B=E3=81=AE=E8=A1=A8?=
=?UTF-8?q?=E7=A4=BA=E3=81=A8=E5=85=A5=E5=8A=9B=E3=83=95=E3=82=A9=E3=83=BC?=
=?UTF-8?q?=E3=83=A0=E3=81=AE=E6=94=B9=E5=96=84=EF=BC=88=E7=87=83=E6=96=99?=
=?UTF-8?q?=E9=81=B8=E6=8A=9E=E8=82=A2=E3=81=AE=E8=BF=BD=E5=8A=A0=E3=81=A8?=
=?UTF-8?q?=E3=83=87=E3=83=BC=E3=82=BF=E5=8F=96=E5=BE=97=E3=81=AE=E4=BF=AE?=
=?UTF-8?q?=E6=AD=A3=EF=BC=89?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../pages/fire_equipment_orders/_id.vue | 22 +++++++++++-----
.../pages/fire_equipment_orders/index.vue | 26 ++++++++++++-------
2 files changed, 32 insertions(+), 16 deletions(-)
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
index aebdd5d31..f55e43579 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
@@ -23,7 +23,7 @@
| 団体 |
- {{ group.name }} |
+ {{ fireEquipmentOrder.group.name }} |
| 品目 |
@@ -35,7 +35,7 @@
| 燃料 |
- {{ fireEquipmentOrder.fuel }} |
+ {{ getFuelName(fireEquipmentOrder.fuel) }} |
| 使用方法 |
@@ -77,7 +77,12 @@
燃料
-
+
使用方法
@@ -138,11 +143,8 @@ export default {
const routeId = route.path.replace("/fire_equipment_orders/", "");
const url = "/fire_equipment_orders/" + routeId;
const response = await $axios.$get(url);
- const groupUrl = "/api/v1/get_group_show_for_admin_view/" + response.data.group_id;
- const groupRes = await $axios.$get(groupUrl);
return {
fireEquipmentOrder: response.data,
- group: groupRes.data,
routeId: routeId,
};
},
@@ -206,6 +208,14 @@ export default {
await this.$axios.$delete(url);
this.$router.push("/fire_equipment_orders");
},
+ getFuelName(fuel) {
+ const fuelMap = {
+ gas_bottle: "ガスボンベ",
+ lp_gas: "LPガス",
+ charcoal: "炭",
+ };
+ return fuelMap[fuel] || fuel;
+ },
},
};
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
index f06b649be..b083575b1 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
@@ -24,9 +24,7 @@
- |
- {{ header }}
- |
+ {{ header }} |
| {{ order.id }} |
- {{ getGroupName(order.group_id) }} |
+ {{ order.group.name }} |
{{ order.name }} |
{{ order.quantity }} |
{{ getFuelName(order.fuel) }} |
@@ -85,7 +83,8 @@
燃料
@@ -141,7 +140,7 @@ export default {
groupId: null,
name: "",
quantity: 1,
- fuel: "gas_bomve",
+ fuel: "",
usage: "",
isTakeaway: false,
remark: "",
@@ -217,10 +216,7 @@ export default {
const groupsRes = await this.$axios.$get(groupsUrl);
this.groups = groupsRes.data;
},
- getGroupName(groupId) {
- const group = this.groups.find((g) => g.id === groupId);
- return group ? group.name : "";
- },
+
getFuelName(fuel) {
const fuelMap = {
gas_bomve: "ガスボンベ",
@@ -246,6 +242,14 @@ export default {
await this.refinement(this.refYearID);
this.closeAddModal();
this.openSnackBar("申請を追加しました");
+ // フォームの内容をリセット
+ this.groupId = null;
+ this.name = "";
+ this.quantity = 1;
+ this.fuel = "";
+ this.usage = "";
+ this.isTakeaway = false;
+ this.remark = "";
},
async downloadCSV() {
const url =
@@ -257,7 +261,9 @@ export default {
const link = document.createElement("a");
link.href = window.URL.createObjectURL(blob);
link.download = `火気使用申請一覧_${this.refYears}.csv`;
+ document.body.appendChild(link);
link.click();
+ document.body.removeChild(link);
window.URL.revokeObjectURL(link.href);
this.openSnackBar("火気使用申請のCSVをダウンロードしました");
},
From 9077b6f06ef6b43de69e1096fe62c7cd9f1afb92 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Fri, 18 Jul 2025 16:48:45 +0900
Subject: [PATCH 10/20] feat: Enhance order status check UI and API to include
fire equipment order status
---
.../pages/order_status_check/index.vue | 34 +++++++++++++++----
.../v1/order_status_check_api_controller.rb | 3 +-
2 files changed, 30 insertions(+), 7 deletions(-)
diff --git a/admin_view/nuxt-project/pages/order_status_check/index.vue b/admin_view/nuxt-project/pages/order_status_check/index.vue
index 1203da967..b82375ec8 100644
--- a/admin_view/nuxt-project/pages/order_status_check/index.vue
+++ b/admin_view/nuxt-project/pages/order_status_check/index.vue
@@ -92,6 +92,14 @@
ー
✖️
+
+ ◯
+ ー
+ ✖️
+ |
+
+ {{ getFireStatusLabel(group.fire_equipment_order_status, group.group_category) }}
+ |
◯
ー
@@ -116,11 +124,6 @@
ー
✖️
|
-
- ◯
- ー
- ✖️
- |
@@ -145,12 +148,14 @@ export default {
"ステージ",
"ステージオプション",
"従業員",
+ "火気使用申請",
"販売品",
"購入品",
"PR",
"アナウンス",
"模擬店平面図",
"調理工程",
+ "火気使用申請",
],
groups: [],
unregisteredGroups: [],
@@ -371,10 +376,27 @@ export default {
},
// 申請しないデータかどうかを判定するメソッド
isUnregistered(groupId, orderType) {
- return this.unregisteredGroups.some(item =>
+ return this.unregisteredGroups.some(item =>
item.group_id === groupId && item.order_type === orderType
);
},
+ getFireStatusLabel(status, groupCategory) {
+ if (!status && groupCategory === 1) return '未申請';
+ if (!status) return 'ー';
+ switch (status) {
+ case 'pending':
+ case '申請中':
+ return '申請中';
+ case 'approved':
+ case '承認済み':
+ return '承認済み';
+ case 'rejected':
+ case '却下':
+ return '却下';
+ default:
+ return status;
+ }
+ },
},
};
diff --git a/api/app/controllers/api/v1/order_status_check_api_controller.rb b/api/app/controllers/api/v1/order_status_check_api_controller.rb
index 88e2c7f21..06e778260 100644
--- a/api/app/controllers/api/v1/order_status_check_api_controller.rb
+++ b/api/app/controllers/api/v1/order_status_check_api_controller.rb
@@ -26,7 +26,8 @@ def fit_group_index_for_admin_view(groups)
"public_relation": group.public_relation.nil? ? nil : group.public_relation.id,
"venue_map": group.venue_map.nil? ? nil : group.venue_map.id,
"announcement": group.announcement.nil? ? nil : group.announcement.status,
- "cooking_process_order": group.cooking_process_order.nil? ? nil : group.cooking_process_order.id
+ "cooking_process_order": group.cooking_process_order.nil? ? nil : group.cooking_process_order.id,
+ "fire_equipment_order_status": group.fire_equipment_orders.count == 0 ? "未申請" : group.fire_equipment_orders[0].status
}
}
end
From 121de5dffc7ddea98771e44d843bc075cd8afa92 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Fri, 18 Jul 2025 17:10:47 +0900
Subject: [PATCH 11/20] =?UTF-8?q?refactor:=20Update=20terminology=20from?=
=?UTF-8?q?=20"=E4=BD=BF=E7=94=A8=E6=96=B9=E6=B3=95"=20to=20"=E4=BD=BF?=
=?UTF-8?q?=E7=94=A8=E7=94=A8=E9=80=94"=20in=20UI=20and=20CSV=20output=20f?=
=?UTF-8?q?or=20fire=20equipment=20orders?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue | 4 ++--
admin_view/nuxt-project/pages/fire_equipment_orders/index.vue | 4 ++--
api/app/controllers/api/v1/output_csv_controller.rb | 2 +-
3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
index f55e43579..a365796c4 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
@@ -38,7 +38,7 @@
{{ getFuelName(fireEquipmentOrder.fuel) }} |
- | 使用方法 |
+ 使用用途 |
{{ fireEquipmentOrder.usage }} |
@@ -85,7 +85,7 @@
-
使用方法
+ 使用用途
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
index b083575b1..1ab78e5b8 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
@@ -90,7 +90,7 @@
-
使用場所
+ 使用用途
@@ -128,7 +128,7 @@ export default {
"品目",
"数量",
"燃料",
- "使用場所",
+ "使用用途",
"持ち帰り",
"備考",
],
diff --git a/api/app/controllers/api/v1/output_csv_controller.rb b/api/app/controllers/api/v1/output_csv_controller.rb
index 413f4b065..d97b23e54 100644
--- a/api/app/controllers/api/v1/output_csv_controller.rb
+++ b/api/app/controllers/api/v1/output_csv_controller.rb
@@ -531,7 +531,7 @@ def output_fire_equipment_orders_csv
end
bom = "\uFEFF"
csv_data = CSV.generate(bom) do |csv|
- column_name = %w(ID 団体名 品目 数量 燃料 使用場所 持ち帰り 備考)
+ column_name = %w(ID 団体名 品目 数量 燃料 使用用途 持ち帰り 備考)
csv << column_name
@fire_equipment_orders.each do |order|
next if order.nil?
From 50c7a189de7776610c1e43244681f6aed699cbfc Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Fri, 18 Jul 2025 17:21:07 +0900
Subject: [PATCH 12/20] =?UTF-8?q?refactor:=20Update=20terminology=20from?=
=?UTF-8?q?=20"=E5=93=81=E7=9B=AE"=20and=20"=E6=95=B0=E9=87=8F"=20to=20"?=
=?UTF-8?q?=E7=81=AB=E6=B0=97=E3=81=AE=E5=90=8D=E7=A7=B0"=20and=20"?=
=?UTF-8?q?=E7=81=AB=E6=B0=97=E3=81=AE=E5=8F=B0=E6=95=B0"=20in=20UI=20and?=
=?UTF-8?q?=20CSV=20output=20for=20fire=20equipment=20orders?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../nuxt-project/pages/fire_equipment_orders/_id.vue | 8 ++++----
.../nuxt-project/pages/fire_equipment_orders/index.vue | 8 ++++----
api/app/controllers/api/v1/output_csv_controller.rb | 2 +-
3 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
index a365796c4..a3359104a 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
@@ -26,11 +26,11 @@
{{ fireEquipmentOrder.group.name }} |
- | 品目 |
+ 火気の名称 |
{{ fireEquipmentOrder.name }} |
- | 数量 |
+ 火気の台数 |
{{ fireEquipmentOrder.quantity }} |
@@ -68,11 +68,11 @@
>
-
品目
+ 火気の名称
-
数量
+ 火気の台数
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
index 1ab78e5b8..e8645acd3 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
@@ -69,11 +69,11 @@
-
品目
+ 火気の名称
-
数量
+ 火気の台数
Date: Fri, 18 Jul 2025 17:41:05 +0900
Subject: [PATCH 13/20] refactor: Update CSV output columns for public
relations and fire equipment orders to improve clarity and consistency
---
api/app/controllers/api/v1/output_csv_controller.rb | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/api/app/controllers/api/v1/output_csv_controller.rb b/api/app/controllers/api/v1/output_csv_controller.rb
index 362b7624d..ec5d4241f 100644
--- a/api/app/controllers/api/v1/output_csv_controller.rb
+++ b/api/app/controllers/api/v1/output_csv_controller.rb
@@ -503,7 +503,7 @@ def output_public_relations_csv
end
bom = "\uFEFF"
csv_data = CSV.generate(bom) do |csv|
- column_name = %w(参加団体名 PR文 PR画像)
+ column_name = %w(参加団体名 PR文 URL アナウンス有無)
csv << column_name
@public_relations.each do |public_relation|
if public_relation.nil?
@@ -511,8 +511,9 @@ def output_public_relations_csv
end
column_values = [
public_relation.group.name,
- public_relation.pr_comment,
- public_relation.pr_image,
+ public_relation.blurb,
+ public_relation.picture_path,
+ public_relation.is_announcement_requested ? "有" : "無",
]
csv << column_values
end
@@ -531,7 +532,7 @@ def output_fire_equipment_orders_csv
end
bom = "\uFEFF"
csv_data = CSV.generate(bom) do |csv|
- column_name = %w(ID 団体名 火気の名称 火気の台数 燃料 使用用途 持ち帰り 備考)
+ column_name = %w(ID 団体名 火気の名称 火気の台数 燃料 使用用途 備考)
csv << column_name
@fire_equipment_orders.each do |order|
next if order.nil?
@@ -550,7 +551,6 @@ def output_fire_equipment_orders_csv
order.quantity,
fuel_jp,
order.usage,
- order.is_takeaway ? 'はい' : 'いいえ',
order.remark,
]
csv << column_values
From f7ee90a55d8deab073ad0614bd88b7400a1b6b2f Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Fri, 18 Jul 2025 18:02:38 +0900
Subject: [PATCH 14/20] refactor: Replace fuel name retrieval with direct
Japanese translations in fire equipment order UI and API responses
---
.../pages/fire_equipment_orders/_id.vue | 11 ++----
.../pages/fire_equipment_orders/index.vue | 11 ++----
.../api/v1/output_csv_controller.rb | 9 +----
.../fire_equipment_orders_controller.rb | 12 +++++--
api/app/models/concerns/fuel_translatable.rb | 19 ++++++++++
api/app/models/fire_equipment_order.rb | 2 ++
api/spec/models/fire_equipment_order_spec.rb | 36 +++++++++++++++++++
7 files changed, 72 insertions(+), 28 deletions(-)
create mode 100644 api/app/models/concerns/fuel_translatable.rb
create mode 100644 api/spec/models/fire_equipment_order_spec.rb
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
index a3359104a..cafa40a5e 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
@@ -35,7 +35,7 @@
| 燃料 |
- {{ getFuelName(fireEquipmentOrder.fuel) }} |
+ {{ fireEquipmentOrder.fuel_japanese }} |
| 使用用途 |
@@ -208,14 +208,7 @@ export default {
await this.$axios.$delete(url);
this.$router.push("/fire_equipment_orders");
},
- getFuelName(fuel) {
- const fuelMap = {
- gas_bottle: "ガスボンベ",
- lp_gas: "LPガス",
- charcoal: "炭",
- };
- return fuelMap[fuel] || fuel;
- },
+
},
};
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
index e8645acd3..beebb5d5b 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
@@ -41,7 +41,7 @@
{{ order.group.name }} |
{{ order.name }} |
{{ order.quantity }} |
- {{ getFuelName(order.fuel) }} |
+ {{ order.fuel_japanese }} |
{{ order.usage }} |
{{ order.is_takeaway ? "はい" : "いいえ" }} |
{{ order.remark }} |
@@ -217,14 +217,7 @@ export default {
this.groups = groupsRes.data;
},
- getFuelName(fuel) {
- const fuelMap = {
- gas_bomve: "ガスボンベ",
- lp_gas: "LPガス",
- charcoal: "炭",
- };
- return fuelMap[fuel] || "";
- },
+
async submit() {
const url = `/fire_equipment_orders`;
const params = {
diff --git a/api/app/controllers/api/v1/output_csv_controller.rb b/api/app/controllers/api/v1/output_csv_controller.rb
index ec5d4241f..ee8738c2f 100644
--- a/api/app/controllers/api/v1/output_csv_controller.rb
+++ b/api/app/controllers/api/v1/output_csv_controller.rb
@@ -536,20 +536,13 @@ def output_fire_equipment_orders_csv
csv << column_name
@fire_equipment_orders.each do |order|
next if order.nil?
- # fuelを日本語に変換
- fuel_jp = case order.fuel
- when "gas_bottle" then "ガスボンベ"
- when "lp_gas" then "LPガス"
- when "charcoal" then "炭"
- else order.fuel.to_s
- end
group_name = order.group&.name || ""
column_values = [
order.id,
group_name,
order.name,
order.quantity,
- fuel_jp,
+ order.fuel_japanese,
order.usage,
order.remark,
]
diff --git a/api/app/controllers/fire_equipment_orders_controller.rb b/api/app/controllers/fire_equipment_orders_controller.rb
index 1bdbf4845..28d51fcce 100644
--- a/api/app/controllers/fire_equipment_orders_controller.rb
+++ b/api/app/controllers/fire_equipment_orders_controller.rb
@@ -10,12 +10,20 @@ def index
else
@fire_equipment_orders = FireEquipmentOrder.includes(:group).all
end
- render json: fmt(ok, @fire_equipment_orders.as_json(include: { group: { only: [:id, :name] } }))
+ orders_with_fuel_japanese = @fire_equipment_orders.map do |order|
+ order.as_json(include: { group: { only: [:id, :name] } }).merge(
+ fuel_japanese: order.fuel_japanese
+ )
+ end
+ render json: fmt(ok, orders_with_fuel_japanese)
end
# GET /fire_equipment_orders/:id
def show
- render json: fmt(ok, @fire_equipment_order.as_json(include: { group: { only: [:id, :name] } }))
+ order_with_fuel_japanese = @fire_equipment_order.as_json(include: { group: { only: [:id, :name] } }).merge(
+ fuel_japanese: @fire_equipment_order.fuel_japanese
+ )
+ render json: fmt(ok, order_with_fuel_japanese)
end
# POST /fire_equipment_orders
diff --git a/api/app/models/concerns/fuel_translatable.rb b/api/app/models/concerns/fuel_translatable.rb
new file mode 100644
index 000000000..332eae2fc
--- /dev/null
+++ b/api/app/models/concerns/fuel_translatable.rb
@@ -0,0 +1,19 @@
+module FuelTranslatable
+ extend ActiveSupport::Concern
+
+ FUEL_TRANSLATIONS = {
+ 'gas_bottle' => 'ガスボンベ',
+ 'lp_gas' => 'LPガス',
+ 'charcoal' => '炭'
+ }.freeze
+
+ def fuel_japanese
+ FUEL_TRANSLATIONS[self.fuel] || self.fuel.to_s
+ end
+
+ class_methods do
+ def fuel_options_for_select
+ FUEL_TRANSLATIONS.map { |key, value| [value, key] }
+ end
+ end
+end
diff --git a/api/app/models/fire_equipment_order.rb b/api/app/models/fire_equipment_order.rb
index 8fdf4d70f..0e98ec37d 100644
--- a/api/app/models/fire_equipment_order.rb
+++ b/api/app/models/fire_equipment_order.rb
@@ -1,4 +1,6 @@
class FireEquipmentOrder < ApplicationRecord
+ include FuelTranslatable
+
belongs_to :group
# enum gas_bottle: ガスボンベ、lp_gas: LPガス、charcoal: 炭
enum fuel: { gas_bottle: 1, lp_gas: 2, charcoal: 3 }
diff --git a/api/spec/models/fire_equipment_order_spec.rb b/api/spec/models/fire_equipment_order_spec.rb
new file mode 100644
index 000000000..79e66d30c
--- /dev/null
+++ b/api/spec/models/fire_equipment_order_spec.rb
@@ -0,0 +1,36 @@
+require 'rails_helper'
+
+RSpec.describe FireEquipmentOrder, type: :model do
+ describe '#fuel_japanese' do
+ it 'returns Japanese translation for gas_bottle' do
+ order = build(:fire_equipment_order, fuel: 'gas_bottle')
+ expect(order.fuel_japanese).to eq('ガスボンベ')
+ end
+
+ it 'returns Japanese translation for lp_gas' do
+ order = build(:fire_equipment_order, fuel: 'lp_gas')
+ expect(order.fuel_japanese).to eq('LPガス')
+ end
+
+ it 'returns Japanese translation for charcoal' do
+ order = build(:fire_equipment_order, fuel: 'charcoal')
+ expect(order.fuel_japanese).to eq('炭')
+ end
+
+ it 'returns original value for unknown fuel' do
+ order = build(:fire_equipment_order, fuel: 'unknown')
+ expect(order.fuel_japanese).to eq('unknown')
+ end
+ end
+
+ describe '.fuel_options_for_select' do
+ it 'returns array of [Japanese name, English key] pairs' do
+ options = FireEquipmentOrder.fuel_options_for_select
+ expect(options).to contain_exactly(
+ ['ガスボンベ', 'gas_bottle'],
+ ['LPガス', 'lp_gas'],
+ ['炭', 'charcoal']
+ )
+ end
+ end
+end
From c7b21c03fec4999cab040f163ea76a582a527a70 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 20 Jul 2025 15:29:42 +0900
Subject: [PATCH 15/20] =?UTF-8?q?refactor:=20=E7=87=83=E6=96=99=E7=BF=BB?=
=?UTF-8?q?=E8=A8=B3=E3=83=AD=E3=82=B8=E3=83=83=E3=82=AF=E3=82=92FireEquip?=
=?UTF-8?q?mentOrder=E3=83=A2=E3=83=87=E3=83=AB=E3=81=AB=E7=B5=B1=E5=90=88?=
=?UTF-8?q?=E3=81=97=E3=80=81FuelTranslatable=20concern=E3=82=92=E5=89=8A?=
=?UTF-8?q?=E9=99=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
api/app/models/concerns/fuel_translatable.rb | 19 -----------
api/app/models/fire_equipment_order.rb | 16 +++++++--
api/spec/models/fire_equipment_order_spec.rb | 36 --------------------
3 files changed, 14 insertions(+), 57 deletions(-)
delete mode 100644 api/app/models/concerns/fuel_translatable.rb
delete mode 100644 api/spec/models/fire_equipment_order_spec.rb
diff --git a/api/app/models/concerns/fuel_translatable.rb b/api/app/models/concerns/fuel_translatable.rb
deleted file mode 100644
index 332eae2fc..000000000
--- a/api/app/models/concerns/fuel_translatable.rb
+++ /dev/null
@@ -1,19 +0,0 @@
-module FuelTranslatable
- extend ActiveSupport::Concern
-
- FUEL_TRANSLATIONS = {
- 'gas_bottle' => 'ガスボンベ',
- 'lp_gas' => 'LPガス',
- 'charcoal' => '炭'
- }.freeze
-
- def fuel_japanese
- FUEL_TRANSLATIONS[self.fuel] || self.fuel.to_s
- end
-
- class_methods do
- def fuel_options_for_select
- FUEL_TRANSLATIONS.map { |key, value| [value, key] }
- end
- end
-end
diff --git a/api/app/models/fire_equipment_order.rb b/api/app/models/fire_equipment_order.rb
index 0e98ec37d..9a5d6f9e0 100644
--- a/api/app/models/fire_equipment_order.rb
+++ b/api/app/models/fire_equipment_order.rb
@@ -1,7 +1,19 @@
class FireEquipmentOrder < ApplicationRecord
- include FuelTranslatable
-
belongs_to :group
# enum gas_bottle: ガスボンベ、lp_gas: LPガス、charcoal: 炭
enum fuel: { gas_bottle: 1, lp_gas: 2, charcoal: 3 }
+
+ FUEL_TRANSLATIONS = {
+ 'gas_bottle' => 'ガスボンベ',
+ 'lp_gas' => 'LPガス',
+ 'charcoal' => '炭'
+ }.freeze
+
+ def fuel_japanese
+ FUEL_TRANSLATIONS[self.fuel] || self.fuel.to_s
+ end
+
+ def self.fuel_options_for_select
+ FUEL_TRANSLATIONS.map { |key, value| [value, key] }
+ end
end
diff --git a/api/spec/models/fire_equipment_order_spec.rb b/api/spec/models/fire_equipment_order_spec.rb
deleted file mode 100644
index 79e66d30c..000000000
--- a/api/spec/models/fire_equipment_order_spec.rb
+++ /dev/null
@@ -1,36 +0,0 @@
-require 'rails_helper'
-
-RSpec.describe FireEquipmentOrder, type: :model do
- describe '#fuel_japanese' do
- it 'returns Japanese translation for gas_bottle' do
- order = build(:fire_equipment_order, fuel: 'gas_bottle')
- expect(order.fuel_japanese).to eq('ガスボンベ')
- end
-
- it 'returns Japanese translation for lp_gas' do
- order = build(:fire_equipment_order, fuel: 'lp_gas')
- expect(order.fuel_japanese).to eq('LPガス')
- end
-
- it 'returns Japanese translation for charcoal' do
- order = build(:fire_equipment_order, fuel: 'charcoal')
- expect(order.fuel_japanese).to eq('炭')
- end
-
- it 'returns original value for unknown fuel' do
- order = build(:fire_equipment_order, fuel: 'unknown')
- expect(order.fuel_japanese).to eq('unknown')
- end
- end
-
- describe '.fuel_options_for_select' do
- it 'returns array of [Japanese name, English key] pairs' do
- options = FireEquipmentOrder.fuel_options_for_select
- expect(options).to contain_exactly(
- ['ガスボンベ', 'gas_bottle'],
- ['LPガス', 'lp_gas'],
- ['炭', 'charcoal']
- )
- end
- end
-end
From b0043765bc94c2c26faf823b5b8f763864dcd578 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 20 Jul 2025 15:49:19 +0900
Subject: [PATCH 16/20] =?UTF-8?q?refactor:=20=E3=83=80=E3=83=83=E3=82=B7?=
=?UTF-8?q?=E3=83=A5=E3=83=9C=E3=83=BC=E3=83=89UI=E3=81=8B=E3=82=89?=
=?UTF-8?q?=E6=9C=AA=E4=BD=BF=E7=94=A8=E3=81=AE=E9=98=B2=E7=81=AB=E5=99=A8?=
=?UTF-8?q?=E5=85=B7=E7=94=B3=E8=AB=8B=E3=82=BB=E3=82=AF=E3=82=B7=E3=83=A7?=
=?UTF-8?q?=E3=83=B3=E3=82=92=E5=89=8A=E9=99=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
admin_view/nuxt-project/pages/dashboard.vue | 11 -----------
1 file changed, 11 deletions(-)
diff --git a/admin_view/nuxt-project/pages/dashboard.vue b/admin_view/nuxt-project/pages/dashboard.vue
index 43cf190bf..9655b8384 100644
--- a/admin_view/nuxt-project/pages/dashboard.vue
+++ b/admin_view/nuxt-project/pages/dashboard.vue
@@ -39,17 +39,6 @@
-
-
-
- 火気使用申請
-
-
- 申請数:{{ dashboard_data.fire_equipment_orders_length }}
- 持ち帰り有:{{ dashboard_data.takeaway_true_num }}
- 持ち帰り無:{{ dashboard_data.takeaway_false_num }}
-
-
閲覧権限がありません
From 10671e925d706be698b0c4ef1a22ffaa1cbac878 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 20 Jul 2025 15:52:52 +0900
Subject: [PATCH 17/20] =?UTF-8?q?fix:=20=E3=82=A4=E3=83=B3=E3=83=87?=
=?UTF-8?q?=E3=83=B3=E3=83=88=E4=BF=AE=E6=AD=A3?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue | 2 +-
admin_view/nuxt-project/pages/fire_equipment_orders/index.vue | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
index cafa40a5e..972dc5133 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/_id.vue
@@ -35,7 +35,7 @@
| 燃料 |
- {{ fireEquipmentOrder.fuel_japanese }} |
+ {{ fireEquipmentOrder.fuel_japanese }} |
| 使用用途 |
diff --git a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
index beebb5d5b..9db343b96 100644
--- a/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
+++ b/admin_view/nuxt-project/pages/fire_equipment_orders/index.vue
@@ -41,7 +41,7 @@
{{ order.group.name }} |
{{ order.name }} |
{{ order.quantity }} |
- {{ order.fuel_japanese }} |
+ {{ order.fuel_japanese }} |
{{ order.usage }} |
{{ order.is_takeaway ? "はい" : "いいえ" }} |
{{ order.remark }} |
From a56146c88054d7c105fe896aee3f79100a774214 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 20 Jul 2025 16:08:19 +0900
Subject: [PATCH 18/20] =?UTF-8?q?fix:=20=E7=81=AB=E6=B0=97=E4=BD=BF?=
=?UTF-8?q?=E7=94=A8=E7=94=B3=E8=AB=8B=E3=81=AE=E7=94=B3=E8=AB=8B=E7=8A=B6?=
=?UTF-8?q?=E6=B3=81=E3=82=92=E6=AD=A3=E5=BC=8F=E3=81=AA=E3=82=82=E3=81=AE?=
=?UTF-8?q?=E3=81=AB=E8=A8=82=E6=AD=A3?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../pages/order_status_check/index.vue | 27 +++++--------------
1 file changed, 6 insertions(+), 21 deletions(-)
diff --git a/admin_view/nuxt-project/pages/order_status_check/index.vue b/admin_view/nuxt-project/pages/order_status_check/index.vue
index b82375ec8..1dcd76b10 100644
--- a/admin_view/nuxt-project/pages/order_status_check/index.vue
+++ b/admin_view/nuxt-project/pages/order_status_check/index.vue
@@ -97,9 +97,6 @@
ー
✖️
-
- {{ getFireStatusLabel(group.fire_equipment_order_status, group.group_category) }}
- |
◯
ー
@@ -124,6 +121,11 @@
ー
✖️
|
+
+ ◯
+ ー
+ ✖️
+ |
@@ -148,7 +150,6 @@ export default {
"ステージ",
"ステージオプション",
"従業員",
- "火気使用申請",
"販売品",
"購入品",
"PR",
@@ -380,23 +381,7 @@ export default {
item.group_id === groupId && item.order_type === orderType
);
},
- getFireStatusLabel(status, groupCategory) {
- if (!status && groupCategory === 1) return '未申請';
- if (!status) return 'ー';
- switch (status) {
- case 'pending':
- case '申請中':
- return '申請中';
- case 'approved':
- case '承認済み':
- return '承認済み';
- case 'rejected':
- case '却下':
- return '却下';
- default:
- return status;
- }
- },
+
},
};
From ea8721352183a0678bc4af6496ee6b1765c44444 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 20 Jul 2025 16:09:35 +0900
Subject: [PATCH 19/20] =?UTF-8?q?fix:=20AI=E3=81=AE=E7=94=9F=E7=94=A3?=
=?UTF-8?q?=E7=89=A9=E3=81=A0=E3=81=8B=E3=82=89=E5=89=8A=E9=99=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
api/app/controllers/api/v1/dashboard_api_controller.rb | 6 ------
1 file changed, 6 deletions(-)
diff --git a/api/app/controllers/api/v1/dashboard_api_controller.rb b/api/app/controllers/api/v1/dashboard_api_controller.rb
index c5c2f7d18..8c715c6db 100644
--- a/api/app/controllers/api/v1/dashboard_api_controller.rb
+++ b/api/app/controllers/api/v1/dashboard_api_controller.rb
@@ -26,9 +26,6 @@ def get_dashboard_info
progress_assign_item_1 = (assign_item_status_1*100) / all_length
progress_assign_item_2 = (assign_item_status_2*100) / all_length
progress_assign_item_3 = (assign_item_status_3*100) / all_length
- fire_equipment_orders_length = FireEquipmentOrder.all.length
- takeaway_true_num = FireEquipmentOrder.where(is_takeaway: true).length
- takeaway_false_num = FireEquipmentOrder.where(is_takeaway: false).length
group_data = {
all_user_num: all_user_num,
manager_num: manager_num,
@@ -47,9 +44,6 @@ def get_dashboard_info
progress_assign_item_1: progress_assign_item_1,
progress_assign_item_2: progress_assign_item_2,
progress_assign_item_3: progress_assign_item_3,
- fire_equipment_orders_length: fire_equipment_orders_length,
- takeaway_true_num: takeaway_true_num,
- takeaway_false_num: takeaway_false_num,
}
render json: group_data
From b0ddf32ec1a486b93d0de1c61d2a5ae8173ea590 Mon Sep 17 00:00:00 2001
From: hikahana <22.h.hanada.nutfes@gmail.com>
Date: Sun, 20 Jul 2025 16:14:24 +0900
Subject: [PATCH 20/20] =?UTF-8?q?fix:=20nil=E3=82=92=E8=BF=94=E3=81=99?=
=?UTF-8?q?=E3=82=88=E3=81=86=E3=81=AB?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
api/app/controllers/api/v1/order_status_check_api_controller.rb | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/api/app/controllers/api/v1/order_status_check_api_controller.rb b/api/app/controllers/api/v1/order_status_check_api_controller.rb
index 06e778260..d3d5ef1b7 100644
--- a/api/app/controllers/api/v1/order_status_check_api_controller.rb
+++ b/api/app/controllers/api/v1/order_status_check_api_controller.rb
@@ -27,7 +27,7 @@ def fit_group_index_for_admin_view(groups)
"venue_map": group.venue_map.nil? ? nil : group.venue_map.id,
"announcement": group.announcement.nil? ? nil : group.announcement.status,
"cooking_process_order": group.cooking_process_order.nil? ? nil : group.cooking_process_order.id,
- "fire_equipment_order_status": group.fire_equipment_orders.count == 0 ? "未申請" : group.fire_equipment_orders[0].status
+ "fire_equipment_order": group.fire_equipment_orders.count == 0 ? nil : group.fire_equipment_orders[0].status
}
}
end