Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FW][FIX] l10n_ar_edi_ux: obtener actividades monotributista. #329

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions l10n_ar_edi_ux/models/res_partner.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,10 @@ def get_data_from_padron_afip(self):
actividades = [str(act["idActividad"])
for act in data_rg.get("actividad", []) + data_mt_actividades]

def check_activity(data_rg):
def check_activity(data_rg, data_mt):
res = []
new_activity = {}
afip_activities = data_rg.get('actividad')
afip_activities = data_rg.get("actividad", []) + ([data_mt.get("actividadMonotributista")] if data_mt else [])
actividades = self.env['afip.activity'].sudo()
activity_codes = actividades.search([]).mapped('code')
for act in afip_activities:
Expand All @@ -97,7 +97,7 @@ def check_activity(data_rg):
else:
res.append(act)
return res
check_activity(data_rg)
check_activity(data_rg, data_mt)

def check_taxes(data_mt, data_rg):
res = []
Expand Down