feat: localize teaching requests and evaluations

This commit is contained in:
biss committed 2026-11-01 20:33:11 +08:00
1 parent 1a1ecfb912
commit f3b5cc5e73
6 files changed
+235 -217

No files matched your search

+2 -2
View File
@@ -16,7 +16,7 @@ const missing = [...reference].filter((key) => !candidate.has(key))
const extra = [...candidate].filter((key) => !reference.has(key))
// Fully migrated pages must not silently reintroduce hardcoded Chinese UI copy.
const completedViews = ['CoursesView.vue', 'OtherExamsView.vue', 'BaseDataView.vue', 'OfficialDocumentsView.vue', 'CampusRegistrationsView.vue', 'ClassroomReservationsView.vue']
const completedViews = ['CoursesView.vue', 'OtherExamsView.vue', 'BaseDataView.vue', 'OfficialDocumentsView.vue', 'CampusRegistrationsView.vue', 'ClassroomReservationsView.vue', 'CourseAdjustmentsView.vue']
const hardcoded = completedViews.filter((name) => {
const file = fileURLToPath(new URL(`../src/views/${name}`, import.meta.url))
let source = readFileSync(file, 'utf8')
@@ -26,7 +26,7 @@ const hardcoded = completedViews.filter((name) => {
})
// These pages retain Chinese API values or editable business defaults in script.
// Guard their templates separately, ignoring non-rendered comments.
for (const name of ['TeachingMonitoringView.vue', 'AcademicPlanningView.vue', 'PersonnelView.vue', 'StatisticsView.vue']) {
for (const name of ['TeachingMonitoringView.vue', 'AcademicPlanningView.vue', 'PersonnelView.vue', 'StatisticsView.vue', 'EvaluationView.vue', 'ApprovalCenterView.vue']) {
const source = readFileSync(new URL(`../src/views/${name}`, import.meta.url), 'utf8')
const start = source.indexOf('<template>')
const end = source.lastIndexOf('</template>')