電気契約容量
-
+ handleTextInput('contract_capacity', e.target.value)}
+ />
-
-
- 電気袋設備※複数選択可能
-
-
-
-
-
+
設置希望システム
@@ -93,34 +166,7 @@ export default function RoofInfoForm() {
-
-
+
保存
-
+ router.push('/survey-sale')}>
リスト
diff --git a/src/components/survey-sale/detail/form/MultiCheckbox.tsx b/src/components/survey-sale/detail/form/MultiCheckbox.tsx
new file mode 100644
index 0000000..7abfca9
--- /dev/null
+++ b/src/components/survey-sale/detail/form/MultiCheckbox.tsx
@@ -0,0 +1,81 @@
+import { SurveyDetailRequest } from '@/types/Survey'
+import { useState } from 'react'
+
+const supplementary_facilities = [
+ { id: 1, name: 'エコキュート' },
+ { id: 2, name: 'エネパーム' },
+ { id: 3, name: '蓄電池システム' },
+ { id: 4, name: '太陽光発電' },
+]
+
+const roof_material = [
+ { id: 1, name: 'スレート' },
+ { id: 2, name: 'アスファルトシングル' },
+ { id: 3, name: '瓦' },
+ { id: 4, name: '金属屋根' },
+]
+
+export default function MultiCheckbox({
+ column,
+ setDetailInfoData,
+ detailInfoData,
+}: {
+ column: string
+ setDetailInfoData: (data: any) => void
+ detailInfoData: SurveyDetailRequest
+}) {
+ const selectList = column === 'supplementary_facilities' ? supplementary_facilities : roof_material
+
+ const [isOtherChecked, setIsOtherChecked] = useState(false)
+
+ const handleCheckbox = (dataName: string) => {
+ const value = column === 'supplementary_facilities' ? detailInfoData.supplementary_facilities : detailInfoData.roof_material
+ setDetailInfoData({
+ ...detailInfoData,
+ [column]: `${value}, ${dataName}`,
+ })
+ }
+
+ return (
+ <>
+ {column === 'supplementary_facilities' ? (
+ <>
+
+ 電気袋設備※複数選択可能
+
+ >
+ ) : (
+ <>
+
+ 屋根材※最大2個まで選択可能
+
+ >
+ )}
+
+
+
+
+ >
+ )
+}