diff --git a/data/mail_templates.xml b/data/mail_templates.xml index 67a32ec..5edcd49 100755 --- a/data/mail_templates.xml +++ b/data/mail_templates.xml @@ -41,31 +41,31 @@
- +
Poor
- +
Fair
- +
Good
- +
Very Good
- +
Excellent
diff --git a/models/helpdesk_ticket.py b/models/helpdesk_ticket.py index 6bfdaab..184e781 100755 --- a/models/helpdesk_ticket.py +++ b/models/helpdesk_ticket.py @@ -12,6 +12,18 @@ class HelpdeskTicket(models.Model): help='HTML representation of rating stars' ) + def get_base_url(self): + """ + Returns the base URL for the current record, prioritizing the domain + of the website associated with the helpdesk team. + """ + self.ensure_one() + # Check if website_id exists on team_id (added by website_helpdesk) + # and if it has a domain configured. + if 'website_id' in self.team_id._fields and self.team_id.website_id.domain: + return self.team_id.website_id.domain.rstrip('/') + return super().get_base_url() + @api.depends('rating_ids', 'rating_ids.rating', 'rating_ids.create_date', 'rating_count') def _compute_rating_stars_html(self): """Compute HTML representation of rating stars"""