Update app.py
Browse files
app.py
CHANGED
|
@@ -61,24 +61,24 @@ def fx_rq(date:str):
|
|
| 61 |
for c in date:
|
| 62 |
if c in chinese_data_dict:
|
| 63 |
date = date.replace(c, chinese_data_dict[c])
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
| 71 |
-
|
| 72 |
|
| 73 |
-
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
|
| 79 |
-
|
| 80 |
|
| 81 |
-
|
| 82 |
return date
|
| 83 |
|
| 84 |
|
|
|
|
| 61 |
for c in date:
|
| 62 |
if c in chinese_data_dict:
|
| 63 |
date = date.replace(c, chinese_data_dict[c])
|
| 64 |
+
y = date.split('-')[0]
|
| 65 |
+
m = date.split('-')[1]
|
| 66 |
+
temp = ''
|
| 67 |
+
if len(m) == 2:
|
| 68 |
+
temp += chinese_data2_dict[m[0]]
|
| 69 |
+
if m[1] != "〇":
|
| 70 |
+
temp += m[1]
|
| 71 |
+
m = temp
|
| 72 |
|
| 73 |
+
d = date.split('-')[2]
|
| 74 |
+
temp = ''
|
| 75 |
+
if len(d) == 2:
|
| 76 |
+
temp += chinese_data2_dict[d[0]]
|
| 77 |
+
if d[1] != "〇":
|
| 78 |
+
temp += d[1]
|
| 79 |
+
d = temp
|
| 80 |
|
| 81 |
+
date = y + '年' + m + '月' + d + '日'
|
| 82 |
return date
|
| 83 |
|
| 84 |
|