|
@@ -400,7 +400,16 @@ class GCStruct:
|
|
|
df_translate[t_from] = df[df[last + "_Nr"] != ""][from_label].rename(
|
|
|
columns=dict(zip(from_label, to_label))
|
|
|
)
|
|
|
- # print(df_translate[t_to].head())
|
|
|
+
|
|
|
+ df_t4 = df_translate["Konto_Nr"].copy()
|
|
|
+ df_t4 = df_t4[df_t4["SKR51_Nr"].str.match(r"^[01]")]
|
|
|
+ df_t5 = df_t4.copy()
|
|
|
+ df_t4["SKR51_Nr"] = df_t4["SKR51_Nr"] + "_A"
|
|
|
+ df_t4["SKR51"] = df_t4["SKR51"] + "_A"
|
|
|
+ df_t5["SKR51_Nr"] = df_t5["SKR51_Nr"] + "_P"
|
|
|
+ df_t5["SKR51"] = df_t5["SKR51"] + "_P"
|
|
|
+ df_translate["Konto_Nr"] = pd.concat([df_translate["Konto_Nr"], df_t4, df_t5])
|
|
|
+ # print(df_translate[t_to].head())
|
|
|
|
|
|
df2 = []
|
|
|
for ac_file in accounts_combined_files:
|
|
@@ -416,7 +425,12 @@ class GCStruct:
|
|
|
df_source = pd.concat(df2)
|
|
|
df3 = df_source.copy()
|
|
|
df3["Konto_Nr"] = df3["Konto_Nr"] + "_STK"
|
|
|
- df_source = pd.concat([df_source, df3])
|
|
|
+ df4 = df_source.copy()
|
|
|
+ df4 = df4[df4["Konto_Nr"].str.match(r"^[01]")]
|
|
|
+ df5 = df4.copy()
|
|
|
+ df4["Konto_Nr"] = df4["Konto_Nr"] + "_A"
|
|
|
+ df5["Konto_Nr"] = df5["Konto_Nr"] + "_P"
|
|
|
+ df_source = pd.concat([df_source, df3, df4, df5])
|
|
|
|
|
|
for t_from, t_to in self.translate.items():
|
|
|
if t_to == "SKR51":
|