修复了课表周数硬编码
This commit is contained in:
8
.idea/.gitignore
generated
vendored
Normal file
8
.idea/.gitignore
generated
vendored
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
# 默认忽略的文件
|
||||||
|
/shelf/
|
||||||
|
/workspace.xml
|
||||||
|
# 基于编辑器的 HTTP 客户端请求
|
||||||
|
/httpRequests/
|
||||||
|
# Datasource local storage ignored files
|
||||||
|
/dataSources/
|
||||||
|
/dataSources.local.xml
|
||||||
9
.idea/frontend.iml
generated
Normal file
9
.idea/frontend.iml
generated
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<module type="JAVA_MODULE" version="4">
|
||||||
|
<component name="NewModuleRootManager" inherit-compiler-output="true">
|
||||||
|
<exclude-output />
|
||||||
|
<content url="file://$MODULE_DIR$" />
|
||||||
|
<orderEntry type="inheritedJdk" />
|
||||||
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
</component>
|
||||||
|
</module>
|
||||||
448
.idea/gradle.xml
generated
Normal file
448
.idea/gradle.xml
generated
Normal file
@@ -0,0 +1,448 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="GradleSettings">
|
||||||
|
<option name="linkedExternalProjectsSettings">
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/@expo/dom-webview/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/@expo/dom-webview/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/@expo/log-box/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/@expo/log-box/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/@react-native-async-storage/async-storage/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/@react-native-async-storage/async-storage/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/@react-native/gradle-plugin" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/@react-native/gradle-plugin" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-application/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-application/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-background-fetch/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-background-fetch/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-constants/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-constants/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-constants/scripts" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-constants/scripts" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-dev-client/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-dev-client/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-dev-launcher/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-dev-launcher/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-dev-launcher/expo-dev-launcher-gradle-plugin" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-dev-launcher/expo-dev-launcher-gradle-plugin" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-dev-menu-interface/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-dev-menu-interface/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-dev-menu/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-dev-menu/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-eas-client/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-eas-client/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-file-system/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-file-system/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-font/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-font/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-haptics/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-haptics/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-image-loader/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-image-loader/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-image-picker/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-image-picker/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-image/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-image/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-json-utils/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-json-utils/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-linear-gradient/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-linear-gradient/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-linking/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-linking/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-manifests/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-manifests/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-media-library/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-media-library/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-modules-autolinking/android/expo-gradle-plugin" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-modules-autolinking/android/expo-gradle-plugin" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-modules-core/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-modules-core/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-modules-core/expo-module-gradle-plugin" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-modules-core/expo-module-gradle-plugin" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-notifications/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-notifications/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-router/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-router/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-sqlite/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-sqlite/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-structured-headers/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-structured-headers/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-system-ui/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-system-ui/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-task-manager/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-task-manager/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-updates-interface/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-updates-interface/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-updates/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-updates/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-updates/expo-updates-gradle-plugin" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-updates/expo-updates-gradle-plugin" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo-video/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo-video/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo/node_modules/expo-asset/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo/node_modules/expo-asset/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/expo/node_modules/expo-keep-awake/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/expo/node_modules/expo-keep-awake/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/react-native" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/react-native" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/react-native-gesture-handler/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/react-native-gesture-handler/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/react-native-pager-view/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/react-native-pager-view/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/react-native-reanimated/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/react-native-reanimated/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/react-native-safe-area-context/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/react-native-safe-area-context/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/react-native-screens/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/react-native-screens/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/react-native-worklets/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/react-native-worklets/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
<GradleProjectSettings>
|
||||||
|
<option name="externalProjectPath" value="$PROJECT_DIR$/node_modules/unimodules-app-loader/android" />
|
||||||
|
<option name="gradleJvm" value="ms-21" />
|
||||||
|
<option name="modules">
|
||||||
|
<set>
|
||||||
|
<option value="$PROJECT_DIR$/node_modules/unimodules-app-loader/android" />
|
||||||
|
</set>
|
||||||
|
</option>
|
||||||
|
</GradleProjectSettings>
|
||||||
|
</option>
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
7
.idea/misc.xml
generated
Normal file
7
.idea/misc.xml
generated
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ExternalStorageConfigurationManager" enabled="true" />
|
||||||
|
<component name="ProjectRootManager">
|
||||||
|
<output url="file://$PROJECT_DIR$/out" />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
8
.idea/modules.xml
generated
Normal file
8
.idea/modules.xml
generated
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="ProjectModuleManager">
|
||||||
|
<modules>
|
||||||
|
<module fileurl="file://$PROJECT_DIR$/.idea/frontend.iml" filepath="$PROJECT_DIR$/.idea/frontend.iml" />
|
||||||
|
</modules>
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
6
.idea/vcs.xml
generated
Normal file
6
.idea/vcs.xml
generated
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project version="4">
|
||||||
|
<component name="VcsDirectoryMappings">
|
||||||
|
<mapping directory="" vcs="Git" />
|
||||||
|
</component>
|
||||||
|
</project>
|
||||||
@@ -13,7 +13,6 @@ import { colors, spacing, borderRadius } from '../../theme';
|
|||||||
import { SystemMessageResponse, SystemMessageType } from '../../types/dto';
|
import { SystemMessageResponse, SystemMessageType } from '../../types/dto';
|
||||||
import Text from '../common/Text';
|
import Text from '../common/Text';
|
||||||
import Avatar from '../common/Avatar';
|
import Avatar from '../common/Avatar';
|
||||||
import { useResponsive, useResponsiveValue } from '../../hooks/useResponsive';
|
|
||||||
|
|
||||||
interface SystemMessageItemProps {
|
interface SystemMessageItemProps {
|
||||||
message: SystemMessageResponse;
|
message: SystemMessageResponse;
|
||||||
@@ -165,14 +164,6 @@ const SystemMessageItem: React.FC<SystemMessageItemProps> = ({
|
|||||||
onRequestAction,
|
onRequestAction,
|
||||||
requestActionLoading = false,
|
requestActionLoading = false,
|
||||||
}) => {
|
}) => {
|
||||||
// 响应式适配
|
|
||||||
const { isWideScreen, isDesktop } = useResponsive();
|
|
||||||
const containerPadding = useResponsiveValue({ xs: spacing.md, lg: spacing.lg, xl: spacing.xl });
|
|
||||||
const avatarSize = useResponsiveValue({ xs: 40, lg: 48, xl: 52 });
|
|
||||||
const iconSize = useResponsiveValue({ xs: 20, lg: 22, xl: 24 });
|
|
||||||
const contentFontSize = useResponsiveValue({ xs: 14, lg: 15, xl: 16 });
|
|
||||||
const titleFontSize = useResponsiveValue({ xs: 14, lg: 15, xl: 16 });
|
|
||||||
const timeFontSize = useResponsiveValue({ xs: 12, lg: 13, xl: 14 });
|
|
||||||
// 格式化时间
|
// 格式化时间
|
||||||
const formatTime = (dateString: string): string => {
|
const formatTime = (dateString: string): string => {
|
||||||
try {
|
try {
|
||||||
@@ -198,7 +189,15 @@ const SystemMessageItem: React.FC<SystemMessageItemProps> = ({
|
|||||||
requestStatus === 'pending' &&
|
requestStatus === 'pending' &&
|
||||||
!!onRequestAction;
|
!!onRequestAction;
|
||||||
|
|
||||||
const styles = React.useMemo(() => StyleSheet.create({
|
// 使用固定的响应式值,兼容移动端和Web端
|
||||||
|
const containerPadding = spacing.md;
|
||||||
|
const avatarSize = 44;
|
||||||
|
const iconSize = 22;
|
||||||
|
const contentFontSize = 14;
|
||||||
|
const titleFontSize = 14;
|
||||||
|
const timeFontSize = 12;
|
||||||
|
|
||||||
|
const styles = StyleSheet.create({
|
||||||
container: {
|
container: {
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
alignItems: 'flex-start',
|
alignItems: 'flex-start',
|
||||||
@@ -208,7 +207,7 @@ const SystemMessageItem: React.FC<SystemMessageItemProps> = ({
|
|||||||
borderBottomColor: colors.divider,
|
borderBottomColor: colors.divider,
|
||||||
},
|
},
|
||||||
iconContainer: {
|
iconContainer: {
|
||||||
marginRight: isWideScreen ? spacing.lg : spacing.md,
|
marginRight: spacing.md,
|
||||||
},
|
},
|
||||||
iconWrapper: {
|
iconWrapper: {
|
||||||
width: avatarSize,
|
width: avatarSize,
|
||||||
@@ -220,6 +219,7 @@ const SystemMessageItem: React.FC<SystemMessageItemProps> = ({
|
|||||||
content: {
|
content: {
|
||||||
flex: 1,
|
flex: 1,
|
||||||
justifyContent: 'center',
|
justifyContent: 'center',
|
||||||
|
minWidth: 0,
|
||||||
},
|
},
|
||||||
titleRow: {
|
titleRow: {
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
@@ -237,7 +237,7 @@ const SystemMessageItem: React.FC<SystemMessageItemProps> = ({
|
|||||||
fontSize: timeFontSize,
|
fontSize: timeFontSize,
|
||||||
},
|
},
|
||||||
messageContent: {
|
messageContent: {
|
||||||
lineHeight: isWideScreen ? 22 : 18,
|
lineHeight: 20,
|
||||||
fontSize: contentFontSize,
|
fontSize: contentFontSize,
|
||||||
},
|
},
|
||||||
extraInfo: {
|
extraInfo: {
|
||||||
@@ -245,7 +245,7 @@ const SystemMessageItem: React.FC<SystemMessageItemProps> = ({
|
|||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
marginTop: spacing.xs,
|
marginTop: spacing.xs,
|
||||||
backgroundColor: colors.background.default,
|
backgroundColor: colors.background.default,
|
||||||
paddingHorizontal: isWideScreen ? spacing.md : spacing.sm,
|
paddingHorizontal: spacing.sm,
|
||||||
paddingVertical: spacing.xs,
|
paddingVertical: spacing.xs,
|
||||||
borderRadius: borderRadius.sm,
|
borderRadius: borderRadius.sm,
|
||||||
alignSelf: 'flex-start',
|
alignSelf: 'flex-start',
|
||||||
@@ -259,8 +259,8 @@ const SystemMessageItem: React.FC<SystemMessageItemProps> = ({
|
|||||||
marginTop: spacing.sm,
|
marginTop: spacing.sm,
|
||||||
},
|
},
|
||||||
actionBtn: {
|
actionBtn: {
|
||||||
paddingVertical: isWideScreen ? spacing.sm : spacing.xs,
|
paddingVertical: spacing.xs,
|
||||||
paddingHorizontal: isWideScreen ? spacing.lg : spacing.md,
|
paddingHorizontal: spacing.md,
|
||||||
borderRadius: borderRadius.sm,
|
borderRadius: borderRadius.sm,
|
||||||
borderWidth: 1,
|
borderWidth: 1,
|
||||||
marginRight: spacing.sm,
|
marginRight: spacing.sm,
|
||||||
@@ -278,8 +278,9 @@ const SystemMessageItem: React.FC<SystemMessageItemProps> = ({
|
|||||||
justifyContent: 'center',
|
justifyContent: 'center',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
height: 20,
|
height: 20,
|
||||||
|
width: 24,
|
||||||
},
|
},
|
||||||
}), [containerPadding, isWideScreen, avatarSize, titleFontSize, timeFontSize, contentFontSize]);
|
});
|
||||||
|
|
||||||
// 判断是否显示操作者头像
|
// 判断是否显示操作者头像
|
||||||
const showOperatorAvatar = ['follow', 'like_post', 'like_comment', 'like_reply', 'favorite_post', 'comment', 'reply', 'mention', 'group_join_apply'].includes(
|
const showOperatorAvatar = ['follow', 'like_post', 'like_comment', 'like_reply', 'favorite_post', 'comment', 'reply', 'mention', 'group_join_apply'].includes(
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ import {
|
|||||||
TouchableOpacity,
|
TouchableOpacity,
|
||||||
RefreshControl,
|
RefreshControl,
|
||||||
ActivityIndicator,
|
ActivityIndicator,
|
||||||
|
Dimensions,
|
||||||
} from 'react-native';
|
} from 'react-native';
|
||||||
import { SafeAreaView, useSafeAreaInsets } from 'react-native-safe-area-context';
|
import { SafeAreaView, useSafeAreaInsets } from 'react-native-safe-area-context';
|
||||||
import { useIsFocused } from '@react-navigation/native';
|
import { useIsFocused } from '@react-navigation/native';
|
||||||
@@ -25,7 +26,6 @@ import { messageService } from '../../services/messageService';
|
|||||||
import { commentService } from '../../services/commentService';
|
import { commentService } from '../../services/commentService';
|
||||||
import { SystemMessageItem } from '../../components/business';
|
import { SystemMessageItem } from '../../components/business';
|
||||||
import { Text, EmptyState, ResponsiveContainer } from '../../components/common';
|
import { Text, EmptyState, ResponsiveContainer } from '../../components/common';
|
||||||
import { useResponsive, useBreakpointGTE } from '../../hooks/useResponsive';
|
|
||||||
import { RootStackParamList } from '../../navigation/types';
|
import { RootStackParamList } from '../../navigation/types';
|
||||||
import { useMessageManagerSystemUnreadCount, useUserStore } from '../../stores';
|
import { useMessageManagerSystemUnreadCount, useUserStore } from '../../stores';
|
||||||
|
|
||||||
@@ -48,9 +48,27 @@ export const NotificationsScreen: React.FC<{ onBack?: () => void }> = ({ onBack
|
|||||||
const { setSystemUnreadCount, decrementSystemUnreadCount } = useMessageManagerSystemUnreadCount();
|
const { setSystemUnreadCount, decrementSystemUnreadCount } = useMessageManagerSystemUnreadCount();
|
||||||
const navigation = useNavigation<NativeStackNavigationProp<RootStackParamList>>();
|
const navigation = useNavigation<NativeStackNavigationProp<RootStackParamList>>();
|
||||||
|
|
||||||
// 响应式布局
|
// 修复竞态条件:使用本地状态管理窗口尺寸,避免 hydration 问题
|
||||||
const { isDesktop, isTablet } = useResponsive();
|
const [windowSize, setWindowSize] = useState({ width: 0, height: 0 });
|
||||||
const isWideScreen = useBreakpointGTE('lg');
|
const [isHydrated, setIsHydrated] = useState(false);
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
// 延迟设置窗口尺寸,确保在客户端完全加载后再获取
|
||||||
|
const timer = setTimeout(() => {
|
||||||
|
const { width, height } = Dimensions.get('window');
|
||||||
|
setWindowSize({ width, height });
|
||||||
|
setIsHydrated(true);
|
||||||
|
}, 100);
|
||||||
|
return () => clearTimeout(timer);
|
||||||
|
}, []);
|
||||||
|
|
||||||
|
// 使用本地尺寸状态计算断点 (lg = 768)
|
||||||
|
const isWideScreen = windowSize.width >= 768;
|
||||||
|
const isDesktop = windowSize.width >= 1024;
|
||||||
|
const isTablet = windowSize.width >= 768 && windowSize.width < 1024;
|
||||||
|
|
||||||
|
// Web端使用更大的容器宽度
|
||||||
|
const containerMaxWidth = isDesktop ? 1200 : isTablet ? 1000 : 900;
|
||||||
|
|
||||||
const [messages, setMessages] = useState<SystemMessageResponse[]>([]);
|
const [messages, setMessages] = useState<SystemMessageResponse[]>([]);
|
||||||
const [activeType, setActiveType] = useState('all');
|
const [activeType, setActiveType] = useState('all');
|
||||||
@@ -320,7 +338,7 @@ export const NotificationsScreen: React.FC<{ onBack?: () => void }> = ({ onBack
|
|||||||
const shouldShowBackButton = onBack && !isWideScreen;
|
const shouldShowBackButton = onBack && !isWideScreen;
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<View style={[styles.header, isWideScreen && styles.headerWide]}>
|
<View style={[styles.header, isWideScreen ? styles.headerWide : null]}>
|
||||||
{shouldShowBackButton ? (
|
{shouldShowBackButton ? (
|
||||||
<TouchableOpacity
|
<TouchableOpacity
|
||||||
style={styles.backButton}
|
style={styles.backButton}
|
||||||
@@ -342,21 +360,34 @@ export const NotificationsScreen: React.FC<{ onBack?: () => void }> = ({ onBack
|
|||||||
|
|
||||||
// 渲染空状态
|
// 渲染空状态
|
||||||
const renderEmpty = () => (
|
const renderEmpty = () => (
|
||||||
|
<View style={[styles.emptyContainer, isWideScreen && styles.emptyContainerWeb]}>
|
||||||
<EmptyState
|
<EmptyState
|
||||||
title="暂无通知"
|
title="暂无通知"
|
||||||
description="关注一些用户来获取通知吧"
|
description="关注一些用户来获取通知吧"
|
||||||
icon="bell-outline"
|
icon="bell-outline"
|
||||||
/>
|
/>
|
||||||
|
</View>
|
||||||
);
|
);
|
||||||
|
|
||||||
|
// 如果还未hydrated,显示加载占位符,避免竞态条件导致的渲染问题
|
||||||
|
if (!isHydrated) {
|
||||||
|
return (
|
||||||
|
<SafeAreaView style={styles.container} edges={[]}>
|
||||||
|
<View style={styles.loadingContainer}>
|
||||||
|
<ActivityIndicator size="large" color={colors.primary.main} />
|
||||||
|
</View>
|
||||||
|
</SafeAreaView>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<SafeAreaView style={styles.container} edges={[]}>
|
<SafeAreaView style={styles.container} edges={[]}>
|
||||||
{isWideScreen ? (
|
{isWideScreen ? (
|
||||||
<ResponsiveContainer maxWidth={900}>
|
<ResponsiveContainer maxWidth={containerMaxWidth}>
|
||||||
{/* 头部 - 大屏模式下隐藏返回按钮 */}
|
{/* 头部 - 大屏模式下隐藏返回按钮 */}
|
||||||
{renderHeader()}
|
{renderHeader()}
|
||||||
{/* 分类筛选 */}
|
{/* 分类筛选 */}
|
||||||
<View style={[styles.filterContainer, isWideScreen && styles.filterContainerWide]}>
|
<View style={[styles.filterContainer, isWideScreen && styles.filterContainerWideWeb]}>
|
||||||
{MESSAGE_TYPES.map(type => {
|
{MESSAGE_TYPES.map(type => {
|
||||||
const count = type.key === 'all'
|
const count = type.key === 'all'
|
||||||
? displayMessages.length
|
? displayMessages.length
|
||||||
@@ -518,10 +549,11 @@ const styles = StyleSheet.create({
|
|||||||
borderBottomWidth: 1,
|
borderBottomWidth: 1,
|
||||||
borderBottomColor: colors.divider,
|
borderBottomColor: colors.divider,
|
||||||
},
|
},
|
||||||
filterContainerWide: {
|
filterContainerWideWeb: {
|
||||||
paddingHorizontal: spacing.xl,
|
paddingHorizontal: spacing.xl,
|
||||||
paddingVertical: spacing.md,
|
paddingVertical: spacing.md,
|
||||||
justifyContent: 'center',
|
justifyContent: 'center',
|
||||||
|
backgroundColor: colors.background.paper,
|
||||||
},
|
},
|
||||||
filterTag: {
|
filterTag: {
|
||||||
flexDirection: 'row',
|
flexDirection: 'row',
|
||||||
@@ -596,4 +628,14 @@ const styles = StyleSheet.create({
|
|||||||
loadingMoreText: {
|
loadingMoreText: {
|
||||||
marginLeft: spacing.sm,
|
marginLeft: spacing.sm,
|
||||||
},
|
},
|
||||||
|
emptyContainer: {
|
||||||
|
flex: 1,
|
||||||
|
justifyContent: 'center',
|
||||||
|
alignItems: 'center',
|
||||||
|
},
|
||||||
|
emptyContainerWeb: {
|
||||||
|
minHeight: 500,
|
||||||
|
justifyContent: 'center',
|
||||||
|
paddingTop: 100,
|
||||||
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -30,6 +30,7 @@ import {
|
|||||||
TimeSlot,
|
TimeSlot,
|
||||||
getCourseColor,
|
getCourseColor,
|
||||||
hasCourseInWeek,
|
hasCourseInWeek,
|
||||||
|
getCurrentWeek,
|
||||||
} from '../../types/schedule';
|
} from '../../types/schedule';
|
||||||
import type { ScheduleStackParamList } from '../../navigation/types';
|
import type { ScheduleStackParamList } from '../../navigation/types';
|
||||||
import { scheduleService } from '../../services/scheduleService';
|
import { scheduleService } from '../../services/scheduleService';
|
||||||
@@ -130,9 +131,17 @@ const getWeekDates = (weekOffset: number = 0) => {
|
|||||||
return getWeekInfo(weekOffset).dates;
|
return getWeekInfo(weekOffset).dates;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 学期起始日期字符串(用于 getCurrentWeek 函数)
|
||||||
|
const SEMESTER_START_DATE = '2026-03-09';
|
||||||
|
|
||||||
|
// 计算当前实际周数
|
||||||
|
const getInitialWeek = (): number => {
|
||||||
|
return getCurrentWeek(SEMESTER_START_DATE, TOTAL_WEEKS);
|
||||||
|
};
|
||||||
|
|
||||||
export const ScheduleScreen: React.FC = () => {
|
export const ScheduleScreen: React.FC = () => {
|
||||||
const navigation = useNavigation<NativeStackNavigationProp<ScheduleStackParamList>>();
|
const navigation = useNavigation<NativeStackNavigationProp<ScheduleStackParamList>>();
|
||||||
const [currentWeek, setCurrentWeek] = useState(1);
|
const [currentWeek, setCurrentWeek] = useState(getInitialWeek);
|
||||||
const [courses, setCourses] = useState<Course[]>([]);
|
const [courses, setCourses] = useState<Course[]>([]);
|
||||||
const [isAddModalVisible, setIsAddModalVisible] = useState(false);
|
const [isAddModalVisible, setIsAddModalVisible] = useState(false);
|
||||||
const [pendingDay, setPendingDay] = useState<number>(0);
|
const [pendingDay, setPendingDay] = useState<number>(0);
|
||||||
@@ -163,8 +172,10 @@ export const ScheduleScreen: React.FC = () => {
|
|||||||
};
|
};
|
||||||
}, []);
|
}, []);
|
||||||
const todayColumnIndex = getTodayColumnIndex();
|
const todayColumnIndex = getTodayColumnIndex();
|
||||||
// currentWeek === 1 对应今天所在的真实周(offset 0),其他周不高亮今日列
|
// 获取当前实际周数,用于判断是否在查看当前周
|
||||||
const isViewingCurrentWeek = currentWeek === 1;
|
const actualCurrentWeek = getInitialWeek();
|
||||||
|
// 只有在查看当前实际周时才高亮今日列
|
||||||
|
const isViewingCurrentWeek = currentWeek === actualCurrentWeek;
|
||||||
const activeTodayColumn = isViewingCurrentWeek ? todayColumnIndex : -1;
|
const activeTodayColumn = isViewingCurrentWeek ? todayColumnIndex : -1;
|
||||||
|
|
||||||
const dayColumnWidth = getDayColumnWidth();
|
const dayColumnWidth = getDayColumnWidth();
|
||||||
|
|||||||
@@ -45,7 +45,17 @@ interface SyncScheduleResponse {
|
|||||||
error_message?: string;
|
error_message?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
const toCourse = (dto: ScheduleCourseDTO): Course => ({
|
const toCourse = (dto: ScheduleCourseDTO): Course => {
|
||||||
|
// 调试日志:检查后端返回的 weeks 字段
|
||||||
|
console.log('[ScheduleService] 转换课程 DTO:', {
|
||||||
|
id: dto.id,
|
||||||
|
name: dto.name,
|
||||||
|
day_of_week: dto.day_of_week,
|
||||||
|
weeks: dto.weeks,
|
||||||
|
weeksType: typeof dto.weeks,
|
||||||
|
weeksLength: dto.weeks?.length,
|
||||||
|
});
|
||||||
|
return {
|
||||||
id: dto.id,
|
id: dto.id,
|
||||||
name: dto.name,
|
name: dto.name,
|
||||||
teacher: dto.teacher,
|
teacher: dto.teacher,
|
||||||
@@ -55,12 +65,22 @@ const toCourse = (dto: ScheduleCourseDTO): Course => ({
|
|||||||
endSection: dto.end_section,
|
endSection: dto.end_section,
|
||||||
weeks: dto.weeks ?? [],
|
weeks: dto.weeks ?? [],
|
||||||
color: dto.color,
|
color: dto.color,
|
||||||
});
|
};
|
||||||
|
};
|
||||||
|
|
||||||
class ScheduleService {
|
class ScheduleService {
|
||||||
async getCourses(week?: number): Promise<Course[]> {
|
async getCourses(week?: number): Promise<Course[]> {
|
||||||
const params = week ? { week } : undefined;
|
const params = week ? { week } : undefined;
|
||||||
|
console.log('[ScheduleService] 获取课程列表, params:', params);
|
||||||
const response = await api.get<ScheduleCourseListResponse>('/schedule/courses', params);
|
const response = await api.get<ScheduleCourseListResponse>('/schedule/courses', params);
|
||||||
|
console.log('[ScheduleService] 课程列表响应, 数量:', response.data.list.length);
|
||||||
|
// 打印原始响应数据中的 weeks 字段
|
||||||
|
response.data.list.forEach((item, index) => {
|
||||||
|
console.log(`[ScheduleService] 课程[${index}] ${item.name}:`, {
|
||||||
|
day_of_week: item.day_of_week,
|
||||||
|
weeks: item.weeks,
|
||||||
|
});
|
||||||
|
});
|
||||||
return response.data.list.map(toCourse);
|
return response.data.list.map(toCourse);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -79,7 +99,9 @@ class ScheduleService {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async syncSchedule(req: SyncScheduleRequest): Promise<SyncScheduleResponse> {
|
async syncSchedule(req: SyncScheduleRequest): Promise<SyncScheduleResponse> {
|
||||||
|
console.log('[ScheduleService] 开始同步教务系统, username:', req.username);
|
||||||
const response = await api.post<SyncScheduleResponse>('/schedule/sync', req);
|
const response = await api.post<SyncScheduleResponse>('/schedule/sync', req);
|
||||||
|
console.log('[ScheduleService] 同步响应:', response.data);
|
||||||
return response.data;
|
return response.data;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user