Skip to content

Commit 270eedb

Browse files
clear wk for moodle export
1 parent 10d92b7 commit 270eedb

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

common_grade_export/src/utils/gspread.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,11 @@ def write_data_to_table(
4545
wk_content = sh.worksheet_by_title(sheet_name)
4646

4747
# wk_content.set_dataframe(df_data, "A1", copy_head=True) # problem w/float dot
48-
stream = StringIO(df_data.to_csv(sep=',', encoding='utf-8', decimal=','))
49-
df = pd.read_csv(stream)
50-
df_data = pd.DataFrame(df.to_dict("records"))
51-
wk_content.set_dataframe(df=df_data, start="A1", copy_head=True)
48+
#stream = StringIO(df_data.to_csv(sep=',', encoding='utf-8', decimal=','))
49+
#df = pd.read_csv(stream)
50+
#df_data = pd.DataFrame(df.to_dict("records"))
51+
wk_content.clear()
52+
wk_content.set_dataframe(df=df_data, start="A1", copy_head=True, copy_index=False)
5253

5354

5455
def add_csv_to_table_dis(

0 commit comments

Comments
 (0)