'commit'
This commit is contained in:
66432
Data/SchoolArea.json
Normal file
66432
Data/SchoolArea.json
Normal file
File diff suppressed because it is too large
Load Diff
@@ -136,7 +136,8 @@ try:
|
|||||||
area_code = 'unknown'
|
area_code = 'unknown'
|
||||||
name_conversion_errors.append(f"行 {row_num}: '{raw_name}'")
|
name_conversion_errors.append(f"行 {row_num}: '{raw_name}'")
|
||||||
|
|
||||||
area_data = {
|
# 循环中创建区域数据字典(重命名变量)
|
||||||
|
current_area_data = {
|
||||||
'area_name': area_name,
|
'area_name': area_name,
|
||||||
'area_code': area_code,
|
'area_code': area_code,
|
||||||
'raw_name': raw_name
|
'raw_name': raw_name
|
||||||
@@ -231,10 +232,10 @@ try:
|
|||||||
year_data['teaching_total'] = 0
|
year_data['teaching_total'] = 0
|
||||||
|
|
||||||
stage_data[str(year)] = year_data
|
stage_data[str(year)] = year_data
|
||||||
area_data[stage] = stage_data
|
# 修复:将阶段数据添加到当前区域字典,而非区域列表
|
||||||
|
current_area_data[stage] = stage_data
|
||||||
# 修复:将字典变量重命名并添加到列表
|
|
||||||
current_area_data = area_data
|
# 将当前区域数据添加到列表
|
||||||
area_data.append(current_area_data)
|
area_data.append(current_area_data)
|
||||||
|
|
||||||
workbook.close()
|
workbook.close()
|
||||||
|
Reference in New Issue
Block a user