Comments

geek-merlin’s picture

damienmckenna’s picture

Subscribe.

pluess’s picture

Assigned: Unassigned » pluess
StatusFileSize
new13.65 KB

Hi

This is an initial port to D7. Logging and showing the mail via devel module are working. The view at admin/reports/maillog is partially working. I didn't find any up to date information about views for D7 to migrate this code.

The Mimemail and SMTP support does not work yet. How am I supposed to achieve this in D7. The D6 code is based on the hooks supported by mimemail. In D7 we have http://api.drupal.org/api/drupal/includes--mail.inc/function/drupal_mail... but as far as I understand, this does not fully support our needs, since we cannot have a cascade of system wide mail handlers like mimemail -> maillog -> smtp.

Another approach would be to extend http://drupal.org/project/mailsystem with this functionality.
How should I proceed with this?

And of course any other issues about the D7 port are very welcome!

miro_dietiker’s picture

Great to find some help for an initial D7 version.

There's not that much special about D7 views port.

Note your patch contains tabs and thus is not following the drupal coding standard. Please resubmit without tabs.
BTW: you can replace the tabs e.g. in vi with this command:
:%s/\t/ /g

We'll need to work more on details to provide an implementation that works for almost all development / debug cases.

pluess’s picture

StatusFileSize
new14.32 KB

Thanks for the vi command :-) ! Removed the tabs and reformatted the new code with 2 spaces.

About views: I simply increased the version number in maillog_views_api to 3. Guess there are more small changes necessary to get everything working again. I think it's the custom handlers which are not working.

I do agree 100% with your last point. It would be great if all major mail modules could agree an common API.
I think mail_system is a good starting point but does not provide enough. If it could take a list of default mail systems and attach a weight for everyone in order to tell in which order to call them, that would be great.
It would be easy to write a module for this, but it only works if mimemail and phpmailer would be based on this module as well. In D6 mimemail did something similar (and still does in the 7.x-1.x-dev code) with hook_mailengine.

Maybe we can discus this next Wednesday when we meet in Zürich anyway.

miro_dietiker’s picture

Version: 6.x-1.x-dev » 7.x-1.x-dev
Status: Active » Needs work

Committed this to repo as an initial start.

Further more work needed.

Michael Zetterberg fd. Lopez’s picture

StatusFileSize
new6.12 KB

The /maillog/details/# did not load for me.

Tracked it down to D7 changes to hook_theme and theme implementations.

Patch attached.

miro_dietiker’s picture

Status: Needs work » Needs review

Looks pretty right to me, thank you Michael. I'll review in detail and commit later.

james.williams’s picture

subscribe. I'm working with this today, and it looks fine so far to me.

james.williams’s picture

Permissions were not working due to a typo. Attached patch builds on the one in comment #7 and fixes this. I include a Drush-compatible patch too.

james.williams’s picture

Other than the permissions sorted in the above comment, everything else seems to be fine.

miro_dietiker’s picture

Status: Needs review » Needs work

Fixed, james / michael

Still needs work to make maillog transparent and cleanup D7 interfaces.

Letting this on needs-work.
However please add separate D7 issues and provide separate patches there.
This issue should not be a general collection of further D7 issues.

miro_dietiker’s picture

Status: Needs work » Fixed

Marking this fixed for now. The basic port is available and works.

Please create individual issues to add bug reports and fixes.

tenken’s picture

Hi. I was reading this thread and read that a 7x version exsisted. But, I could not find it on the project page. There is a "7.x-1.x-dev" version choice in the Issue form. So via Drush I was able to grab maillog-7.x-1.x-dev, but it would be helpful to show 7x-dev as a row in available versions at the bottom of the project page.

miro_dietiker’s picture

The 7.x-1.x-dev version is being shown on public website.
http://drupal.org/project/simplenews

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.