Commit 5bb10a73 authored by Cristian Aguirre's avatar Cristian Aguirre

Update match-and-exclude-records-actions_v1.py fix bug 1-Many

parent e1e05db6
...@@ -173,9 +173,14 @@ class MatchAndExcludeRecordsAction(ActionInterface): ...@@ -173,9 +173,14 @@ class MatchAndExcludeRecordsAction(ActionInterface):
merged = total_merged.merge(ctp_df2, 'inner', left_on=pivot_cols, right_on=ctp_cols) merged = total_merged.merge(ctp_df2, 'inner', left_on=pivot_cols, right_on=ctp_cols)
merged['DIFF'] = merged['DIFF'].where(merged['DIFF'].notnull(), if self.exclude_pivot:
merged['DIFF'] = merged['DIFF'].where(merged['DIFF'].notnull(),
merged[self.pivot_params["amount-column"]] - merged[ merged[self.pivot_params["amount-column"]] - merged[
self.ctp_params["amount-column"]]) self.ctp_params["amount-column"]])
else:
merged['DIFF'] = merged['DIFF'].where(merged['DIFF'].notnull(),
merged[self.ctp_params["amount-column"]] - merged[
self.pivot_params["amount-column"]])
merged = merged.dropna(subset=["DIFF"]) merged = merged.dropna(subset=["DIFF"])
if merged.known_divisions: if merged.known_divisions:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment