Skip to content

TA#83757 [14.0][ADD] delivery_custom_notification : custom delivery notifications to specific contacts#244

Merged
qtiplb merged 4 commits into
14.0from
14.0-delivery_custom_notification
Jun 15, 2026
Merged

TA#83757 [14.0][ADD] delivery_custom_notification : custom delivery notifications to specific contacts#244
qtiplb merged 4 commits into
14.0from
14.0-delivery_custom_notification

Conversation

@qtiplb

@qtiplb qtiplb commented Jun 15, 2026

Copy link
Copy Markdown
Contributor

Summary

This module enables sending custom delivery notification emails to designated contacts when deliveries are validated, with fine-grained control at the carrier level.

Key Features

  • Contact Typing: Tag contacts as "Delivery Contacts" with dedicated boolean field
  • Filtered Selection: Only tagged delivery contacts appear in selection dropdown
  • Carrier-Level Configuration: Custom email templates per delivery carrier
  • Intelligent Recipient Selection: Sends to delivery contact or fallback to main partner
  • Chatter Traceability: All sent emails appear in delivery order's message history
  • Template Flexibility: Support for alternative mail servers (e.g., Mailgun)
  • Multi-Company Support: Includes check_company=True for data consistency
  • 2Ship Integration: Compatible with delivery_2ship and other carrier integrations

Configuration

  1. Tag contacts as "Delivery Contacts" in Sales & Purchase tab
  2. Assign delivery contact on partner form
  3. Create email template (leave recipient fields empty)
  4. Enable notification on delivery carrier and select template

Technical Details

Models Extended:

  • res.partner: Adds is_delivery_contact and delivery_contact_id fields
  • delivery.carrier: Adds send_delivery_notification and delivery_notification_template_id fields
  • stock.picking: Overrides _send_confirmation_email() method

Business Logic:

  • Filters outgoing pickings with custom notification enabled
  • Sends email using message_post_with_template() for Chatter integration
  • Falls back to standard Odoo behavior for non-configured carriers

Testing

The module has been developed following Numigi coding standards:

  • Standard copyright headers
  • README.rst documentation format
  • Proper manifest structure
  • Clean code separation

qtiplb added 4 commits June 15, 2026 15:59
…ons to specific contacts

* Add delivery_contact_id field on res.partner
* Add notification settings on delivery.carrier
* Override _send_confirmation_email() to send custom notifications
* Support for custom email templates per carrier
* Multi-company support with check_company=True
* Intelligent recipient selection (delivery contact or fallback to partner)
* Compatible with delivery_2ship and other carrier integrations
* Add is_delivery_contact boolean field on res.partner
* Filter delivery contact selection to only tagged contacts
* Add Is Delivery Contact checkbox in partner form (visible only for contacts)
* Auto-tag new delivery contacts created on-the-fly
* Add search filter for delivery contacts
* Update manifest version to 14.0.1.1.0
* Update documentation with new configuration steps
…ty for sent emails

* Replace send_mail() with message_post_with_template() to ensure emails appear in picking chatter
* Add detailed email template configuration section in README
* Explain why recipient fields must be left empty in templates
* Document email traceability benefit for operations teams
* Add inline code comment explaining template configuration requirement
…tandards

* Update copyright headers to Numigi standard format in all Python files
* Update XML encoding from utf-8 to UTF-8 and remove copyright comments
* Update __manifest__.py: add maintainer, update website URL, use double quotes
* Convert README.md to README.rst following Numigi documentation format
* Remove static/description/index.html (not used in Numigi modules)
* Remove unnecessary manifest keys (application, auto_install, description)
@codacy-production

codacy-production Bot commented Jun 15, 2026

Copy link
Copy Markdown

Not up to standards ⛔

🔴 Issues 4 high · 7 minor

Alerts:
⚠ 11 issues (≤ 0 issues of at least minor severity)

Results:
11 new issues

Category Results
Documentation 6 minor
ErrorProne 4 high
CodeStyle 1 minor

View in Codacy

🟢 Metrics 8 complexity · 0 duplication

Metric Results
Complexity 8
Duplication 0

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@qtiplb
qtiplb merged commit 5541f3b into 14.0 Jun 15, 2026
1 of 4 checks passed
@qtiplb
qtiplb deleted the 14.0-delivery_custom_notification branch June 15, 2026 21:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant