1. Overview
The Communication module provides dual-channel messaging inside Vertex ERP: internal messages between users and groups, and external email via SMTP/IMAP, plus search, audit, and operational monitoring.
| Area | Capabilities |
|---|---|
| Internal | Inbox, sent, compose, threads, reply, groups, attachments |
| External email | Accounts, SMTP/IMAP, compose, inbox/sent, queue, logs, templates |
| Discovery | Dashboard KPIs, unified search (internal), audit trail |
| Planned / limited | ERP document links, email policies, export, in-app push from this module |
Internal messages use numeric enums for type, priority, and delivery status. External mail uses folder and queue statuses. UI labels may appear in Arabic or English depending on language settings.
Cross-module note: Compose and groups load users from Identity. ERP link search is a placeholder. A notification bridge toward HR internal notifications exists in code but is not actively pushed from send/read today.
2. Getting started
2.1 Recommended setup order
- Grant Communication permissions to roles (admin seed may already grant all).
- Configure tenant SMTP/IMAP under Email SMTP/IMAP settings.
- Create email accounts used as From identities.
- Create groups and members before group messaging.
- Use internal compose, inbox, and sent for day-to-day messaging.
- Use external compose and inbox after SMTP works; watch the queue and logs.
- Optionally maintain email templates for reuse.
- Treat ERP links and email policies as not ready for production use.
2.2 Main navigation
| Menu | Path | Purpose |
|---|---|---|
| Dashboard | /communication/dashboard |
KPIs and quick links |
| Internal inbox | /communication/inbox |
Received internal messages |
| Internal sent | /communication/sent |
Messages you sent |
| Compose message | /communication/compose |
New internal message |
| Groups | /communication/groups |
Group CRUD and members |
| External inbox | /communication/external-inbox |
Received email |
| External sent | /communication/external-sent |
Sent email |
| Compose email | /communication/compose-email |
New external email |
| Email accounts | /communication/email-accounts |
Mailbox identities |
| SMTP/IMAP settings | /communication/email-smtp-settings |
Tenant server and OAuth |
| Email templates | /communication/email-templates |
Named HTML templates |
| Email queue | /communication/email-queue |
Outbound queue, retry, cancel |
| Email logs | /communication/email-logs |
Operational email log |
| Audit log | /communication/audit |
Module audit trail |
| Unified search | /communication/search |
Search accessible internal messages |
Thread detail opens at /communication/threads/:id when you open a message.
2.3 Host setting
| Setting | Effect |
|---|---|
Communication:UseMockEmail |
When true, outbound email uses a mock adapter instead of real SMTP |
Confirm this is off in environments that must deliver real mail.
3. Dashboard
Requires Communication.Dashboard.
Shows live KPIs such as:
- Unread internal messages (non-archived)
- Messages you sent today
- Active groups
- Pending and failed email queue items
- Total internal messages
Quick links jump to inbox, compose, groups, and related screens. Use the dashboard as a daily pulse, not as a full mailbox replacement.
4. Internal messaging
4.1 Capabilities
| Action | Where | Notes |
|---|---|---|
| View inbox | /communication/inbox |
Messages addressed to you |
| View sent | /communication/sent |
Messages you authored |
| Compose | /communication/compose |
Users and/or one group; attachments supported |
| Open thread | /communication/threads/:id |
Conversation history and reply |
| Mark as read | Inbox / thread | Updates delivery status |
| Reply | Thread | Continues the same thread |
| Forward | API available | No dedicated forward screen in the UI today |
| Archive | API available | No archive control in the UI today |
4.2 Message model
| Field | Values / guidance |
|---|---|
| Type | Internal or Group when created from compose |
| Priority | Low, Normal, High, Urgent |
| Status on create | Sent |
| Recipients | To users, or Group members |
| Thread | Created or continued automatically |
4.3 Internal send and read flow
- Choose recipients (users) and/or a group.
- Enter subject, body, and priority.
- Attach files if needed (requires Attach permission).
- Send — recipients appear in their inbox with delivery status Delivered.
- Opening / marking read sets delivery status to Read.
Group sends also require SendGroup when a group is selected.
4.4 What is not available in the UI yet
- Forward and archive actions (backend exists; no primary UI)
- Soft delete of messages (permissions exist; no delete API/UI)
- Export of messages
5. Groups
Requires CreateGroup and/or ManageGroup.
Key data
| Field | Guidance |
|---|---|
| Name | Display name of the group |
| Type | Public, Private, Department, Project |
| Owner | Creator becomes Owner |
| Members | Role Owner or Member |
| Active | Inactive groups should not be used for new traffic |
Membership flow
- Create the group and set type.
- Add members (ManageGroup).
- Compose with the group selected — each member receives the message.
- Update or deactivate groups when membership changes.
6. Attachments
| Channel | Upload | Download |
|---|---|---|
| Internal | On compose (Attach) | On thread (DownloadAttach) |
| External email | On compose email | From email detail when permitted |
Files are stored by the Communication file storage service. Admins with Communication.Admin can follow elevated access paths where implemented.
Keep attachments within your organizational size and sensitivity policies even if email policy entities are not yet enforced in the UI.
7. External email
External mail is stored separately from internal messages (email message, recipients, attachments, folders).
7.1 Folders and statuses
| Folder | Typical use |
|---|---|
| Inbox | Received via IMAP sync |
| Sent | Outbound after queue processing |
| Drafts / Trash / Spam / Archive | Folder types exist; day-to-day UI focuses on inbox and sent |
| Message status | Meaning |
|---|---|
| Queued | Accepted for send, waiting on queue |
| Sent | Successfully handed to SMTP |
| Received | Synced from IMAP |
| Failed | Send failed after processing |
7.2 Send flow
- Open Compose email and choose From account, To/Cc/Bcc, subject, and body.
- Send — an email message is created as Queued and a queue item as Pending.
- Background worker processes the queue about every 30 seconds.
- Success → Sent; failure → Failed (retries up to the configured max, typically 3).
- Use Email queue to retry or cancel failed/pending items.
Reply and forward are supported by the email APIs and permissions (Email.Reply, Email.Forward). Prefer reply from the open message when the screen offers it.
7.3 Receive flow
IMAP must be configured (tenant settings and/or per-account API). The sync worker runs per tenant on a fixed interval.
8. Email accounts and server settings
8.1 Email accounts
Path: /communication/email-accounts
Permission: Email.ManageAccounts
Create mailbox identities (address, display name, optional linked user, default/active flags). These identities appear as From options when composing external mail and can be targets for sync.
The accounts screen focuses on identity fields. Per-account SMTP/IMAP can be saved via API; most deployments configure tenant-wide settings first.
8.2 Tenant SMTP / IMAP settings
Path: /communication/email-smtp-settings
Permission: Email.ManageSmtp (IMAP save also uses ManageImap on account APIs)
Configure:
- SMTP host, port, security, authentication
- Auth mode: Basic or Microsoft OAuth
- Default From address
- Optional IMAP for inbound sync
- App public URL when using Microsoft OAuth callback
Resolution order: per-account SMTP/IMAP if present, otherwise tenant settings.
8.3 Microsoft OAuth
When using Microsoft OAuth:
- Complete OAuth connect from the SMTP settings screen.
- Ensure the host public URL matches the OAuth callback registered for the app.
- Disconnect and reconnect if tokens expire or the tenant changes.
9. Email templates
Path: /communication/email-templates
Permission: Email.Templates
Maintain named HTML templates (create, update, delete). Templates are stored for reuse; automatic insertion into compose is not wired as a mandatory step — copy or apply manually until compose integration is extended.
10. Email queue and logs
Email queue
Path: /communication/email-queue
Permissions: Email.ViewLogs to list; Email.Retry to retry or cancel
| Status | Operator action |
|---|---|
| Pending | Wait for worker |
| Processing | In flight |
| Sent | Done |
| Failed | Retry or Cancel |
| Cancelled | Stopped |
Email logs
Path: /communication/email-logs
Permission: Email.ViewLogs
Operational history of email actions for troubleshooting (send, sync, failures). Use together with the queue when diagnosing delivery problems.
11. Unified search
Path: /communication/search
Permission: Communication.Search
Search accessible internal messages by subject and body (you are sender or recipient). An optional type filter may appear; System and Email message types are uncommon for internal records.
Despite “unified” naming in some UI copy, external email is not fully covered by this search today. Use External inbox/sent for mail lookup.
12. Audit log
Path: /communication/audit
Permission: Audit.View
Records module actions such as send, reply, forward, and mark-as-read, with success/failure/denied results. Filter by action, user, and date as offered on the screen.
Audit.Export exists as a permission but has no export UI yet.
13. ERP links
ERP-style links can associate a message with a document in another module (module name, entity type/id, optional URL).
| Layer | Status |
|---|---|
| Data model | Entity exists |
| API search/resolve | Placeholder / synthetic results |
| Compose UI | Links are not populated in normal compose |
Do not rely on ERP linking for production document trails until the search/resolve integration is completed for Sales, Finance, Manufacturing, HR, and related modules.
Email policies (attachment size, recipient limits, approval) exist as domain concepts and a permission (Email.Policies) but have no user-facing management screen yet.
14. Permissions summary
Permission group: Communication.
Messages and collaboration
| Permission | Ability |
|---|---|
| View | Groups/threads/ERP link access gates |
| Inbox | View internal inbox; archive API |
| Read | Open message; mark as read; thread |
| SendInternal | Compose, sent, reply/forward APIs |
| SendGroup | Required when sending to a group |
| CreateGroup | Create groups |
| ManageGroup | Update/delete groups; members |
| Attach / DownloadAttach | Upload / download internal files |
| Search | Unified internal search |
| Admin | Elevated access paths |
| DeleteOwn / DeleteAny / Export | Defined; not wired to UI workflows |
| Permission | Ability |
|---|---|
| Email.Send | Compose/send; external sent |
| Email.Receive | External inbox; email attachment download |
| Email.Reply / Forward | Reply and forward email |
| Email.ManageAccounts | Account CRUD |
| Email.ManageSmtp / ManageImap | Tenant and account server settings |
| Email.ViewLogs | Queue list and logs |
| Email.Retry | Retry / cancel queue items |
| Email.Templates | Template CRUD |
| Email.Policies | Defined only |
Other
| Permission | Ability |
|---|---|
| Dashboard | Communication dashboard |
| Audit.View | Audit list |
| Audit.Export | Defined only |
Parent menu opens with Dashboard, Inbox, or View.
Appendix A — Quick procedures
A.1 First internal message
- Grant SendInternal and Inbox to the roles involved.
- Optionally create a group and add members.
- Compose → select users or group → send.
- Recipient opens inbox → mark as read → reply from the thread.
A.2 Enable outbound email
- Turn off
Communication:UseMockEmailif real delivery is required. - Configure SMTP on
/communication/email-smtp-settings. - Create at least one email account.
- Compose email → send → confirm queue moves Pending → Sent.
- Check Email logs if the item fails.
A.3 Enable inbound email
- Configure IMAP on tenant settings (or per-account via API).
- Wait for the sync worker cycle.
- Confirm messages appear under External inbox.
A.4 Troubleshoot failed mail
- Open Email queue → locate Failed.
- Verify SMTP credentials, From address, and network access.
- Retry; if it fails again, review Email logs and cancel if obsolete.
Appendix B — Operating notes
| Topic | Guidance |
|---|---|
| Dual channel | Internal and email are separate stores; do not expect one search to cover both fully |
| Group send | Needs SendGroup in addition to SendInternal |
| Templates | Manage in UI; apply manually until compose auto-fill exists |
| Notifications | Do not depend on Communication push into HR notifications yet |
| Mock email | Host setting can silently “succeed” without real SMTP |
| Workers | Queue ~30s; IMAP sync ~120s; multi-tenant aware |
Appendix C — Document control
| Item | Value |
|---|---|
| Title | Communication Module User Guide |
| Source of truth | modules/communication and frontend/src/app/modules/communication |
| Format | Markdown + Mermaid (PDF edition embeds rendered figures) |
| Screenshots | Not included (by design) |
This guide describes functional capabilities of the Communication module as implemented in the Vertex ERP codebase. UI labels may appear in English or Arabic depending on language settings.