Skip to content

Commit

Permalink
FIX don't sync mailchimp contacts from res_users
Browse files Browse the repository at this point in the history
  • Loading branch information
ecino committed May 24, 2022
1 parent f1ed937 commit e95e22f
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
1 change: 1 addition & 0 deletions mass_mailing_switzerland/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@
from . import mailchimp_lists
from . import res_partner_category
from . import mailchimp_merge_fields
from . import res_users
22 changes: 22 additions & 0 deletions mass_mailing_switzerland/models/res_users.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
##############################################################################
#
# Copyright (C) 2022 Compassion CH (http://www.compassion.ch)
# Releasing children from poverty in Jesus' name
# @author: Emanuel Cino <[email protected]>
#
# The licence is in the file __manifest__.py
#
##############################################################################
from odoo import models


class ResUsers(models.Model):
_inherit = "res.users"

def create(self, vals_list):
"""No need to update mailchimp from res_users"""
return super(ResUsers, self.with_context(no_need=True)).create(vals_list)

def write(self, vals):
"""No need to update mailchimp from res_users"""
return super(ResUsers, self.with_context(no_need=True)).write(vals)

0 comments on commit e95e22f

Please sign in to comment.