diff --git a/src/pages/KeywordSelectionPage.js b/src/pages/KeywordSelectionPage.js
index c248de6..769320b 100644
--- a/src/pages/KeywordSelectionPage.js
+++ b/src/pages/KeywordSelectionPage.js
@@ -12,8 +12,7 @@ const keywords = {
"수면 여부 확인": ["아침", "밤"],
"식사 여부 확인": ["아침", "점심", "저녁"],
"약 복용 여부 확인": ["아침", "점심", "저녁"],
- "활동 여부 확인": ["외출", "청소", "교회", "운동", "목욕"],
- "심리적 상태 체크": ["O", "X"]
+ "활동 여부 확인": ["외출", "청소", "교회", "운동", "목욕"]
};
const timeSettingKeywords = new Set([
@@ -111,6 +110,8 @@ const KeywordSelectionPage = () => {
])
)
);
+
+ const [guardianTitle, setGuardianTitle] = useState("");
useEffect(() => {
const fetchData = async () => {
@@ -210,6 +211,14 @@ const KeywordSelectionPage = () => {
}
}
+ if (guardianTitle.trim() !== "") {
+ payload.push({
+ scheduleTitle : "GuardianTitle_" + guardianTitle.trim(),
+ startTime: "00:00:00",
+ days: []
+ });
+ }
+
try {
const response = await axios.post(
`${ SPRING_API_URL}/basic-schedules`,
@@ -230,8 +239,21 @@ const KeywordSelectionPage = () => {
return (
-
-
확인하고 싶은 키워드를 선택해주세요.
+
+
확인하고 싶은 키워드를 선택해주세요.
+
+
+
+
+
+ setGuardianTitle(e.target.value)}
+ />
+
+
{Object.entries(keywords).map(([category, options]) => (
• {category}
@@ -249,6 +271,8 @@ const KeywordSelectionPage = () => {
))}
+
+
);
@@ -269,6 +293,23 @@ const styles = {
fontWeight: "bold",
marginBottom: "20px",
},
+ inputGroup: {
+ width: "100%",
+ maxWidth: "400px",
+ marginBottom: "15px",
+ },
+ label: {
+ display: "block",
+ marginBottom : "5px",
+ fontWeight: "bold",
+ },
+ input: {
+ width: "100%",
+ padding: "10px",
+ borderRadius: "10px",
+ border: "1px solid #ccc",
+ boxSizing: "border-box",
+ },
category: {
marginBottom: "15px",
textAlign: "left",
@@ -329,7 +370,19 @@ const styles = {
border: "1px solid #888",
cursor: "pointer",
fontSize: "12px",
- }
+ },
+ contentWrapper: {
+ display: "flex",
+ justifyContent: "flex-start",
+ width: "100%",
+ maxWidth: "800px",
+ },
+ leftColumn: {
+ display: "flex",
+ flexDirection: "column",
+ alignItems: "flex-start",
+ width: "100%",
+ },
};
export default KeywordSelectionPage;
diff --git a/src/pages/VoiceTrainingPage.js b/src/pages/VoiceTrainingPage.js
index d3a4153..1d6335f 100644
--- a/src/pages/VoiceTrainingPage.js
+++ b/src/pages/VoiceTrainingPage.js
@@ -49,7 +49,7 @@ const VoiceTrainingPage = () => {
formData.append("file", audioFile);
try {
- const res = await fetch(`${FASTAPI_API_URL}/upload`, {
+ const res = await fetch(`${FASTAPI_API_URL}/voices`, {
method: "POST",
body: formData,
});
@@ -85,7 +85,7 @@ const VoiceTrainingPage = () => {
{blobURL && (