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

Ability to retrieve all Mailables used by the application and plugins #7425

Closed
Vitaliy-1 opened this issue Nov 2, 2021 · 3 comments
Closed
Assignees
Labels
Enhancement:1:Minor A new feature or improvement that can be implemented in less than 3 days.

Comments

@Vitaliy-1
Copy link
Collaborator

Describe the problem you would like to solve
The list of all available Mailables should be present in the UI for the configuration, including:

  • for automatic emails: associated email templates
  • for editable emails: default template and others that are available for the particular mailable
  • Mailable description

Describe the solution you'd like
Add a method for the Mailer class, which will scan Mailables used by the system. Make it possible for plugins to add their own Mailables.

Who is asking for this feature?
Part of the new email management workflow

Additional information
An example of Mailables list with their description
Manage Emails

@Vitaliy-1 Vitaliy-1 added the Enhancement:1:Minor A new feature or improvement that can be implemented in less than 3 days. label Nov 2, 2021
@Vitaliy-1 Vitaliy-1 added this to the 3.4 milestone Nov 2, 2021
@Vitaliy-1 Vitaliy-1 self-assigned this Nov 2, 2021
Vitaliy-1 added a commit to Vitaliy-1/pkp-lib that referenced this issue Nov 10, 2021
- move non-mailable classes from correspondent dir
- fix mailable's journal name variable retrieval
- cache events & mailables
- add name and description to mailables
Vitaliy-1 added a commit to Vitaliy-1/ojs that referenced this issue Nov 10, 2021
@Vitaliy-1
Copy link
Collaborator Author

Vitaliy-1 commented Nov 10, 2021

PRs
pkp-lib: #7444
OJS: pkp/ojs#3224
edit
OMP: pkp/omp#1030
OPS: pkp/ops#198

Vitaliy-1 added a commit to Vitaliy-1/pkp-lib that referenced this issue Nov 10, 2021
@Vitaliy-1
Copy link
Collaborator Author

Vitaliy-1 commented Nov 11, 2021

@NateWr, can you take a look at these PRs?
Alongside with Mailables, I've added file caching for core system events. Events, listeners and subscribers are cached in the form:

[
  'event' => [
    'listener@method'
  ]
]

Listeners and subscribers which were added without event discovery aren't cached

Vitaliy-1 added a commit to Vitaliy-1/pkp-lib that referenced this issue Nov 12, 2021
- move non-mailable classes from correspondent dir
- fix mailable's journal name variable retrieval
- cache events & mailables
- add name and description to mailables
Vitaliy-1 added a commit to Vitaliy-1/ojs that referenced this issue Nov 12, 2021
Vitaliy-1 added a commit to Vitaliy-1/omp that referenced this issue Nov 12, 2021
Vitaliy-1 added a commit to Vitaliy-1/ops that referenced this issue Nov 12, 2021
@Vitaliy-1
Copy link
Collaborator Author

Interesting, I didn't know that throw keyword cannot be used together with if...else ternary operator until PHP 8.0

Vitaliy-1 added a commit to Vitaliy-1/pkp-lib that referenced this issue Nov 14, 2021
- move non-mailable classes from correspondent dir
- fix mailable's journal name variable retrieval
- cache events & mailables
- add name and description to mailables
Vitaliy-1 added a commit to Vitaliy-1/pkp-lib that referenced this issue Nov 14, 2021
Vitaliy-1 added a commit to Vitaliy-1/omp that referenced this issue Nov 14, 2021
Vitaliy-1 added a commit to Vitaliy-1/ops that referenced this issue Nov 14, 2021
Vitaliy-1 added a commit that referenced this issue Nov 14, 2021
Vitaliy-1 added a commit to pkp/omp that referenced this issue Nov 14, 2021
pkp/pkp-lib#7425 Ability to retrieve mailables, add name and description
Vitaliy-1 added a commit to pkp/ops that referenced this issue Nov 14, 2021
pkp/pkp-lib#7425 Ability to retrieve mailables, add name and description
Vitaliy-1 added a commit to pkp/ojs that referenced this issue Nov 14, 2021
pkp/pkp-lib#7425 Ability to retrieve mailables, add name and description
Email: notifications, templates, drafting, sending automation moved this from To do to Done Nov 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement:1:Minor A new feature or improvement that can be implemented in less than 3 days.
Projects
No open projects
Development

No branches or pull requests

2 participants