[support] Sending email when translation flagged as out of date

David Hart david.hart at gmail.com
Thu Mar 18 00:31:05 UTC 2010


Just as an update: I've installed Rules, and I have an unsatisfactory solution.

- On saving, Rules triggers a View Bulk Operation passing it the nid
as an argument
- The VBO view uses relationships (and distinct) to currently show a
single row for that node if it has child translations that are marked
out of date.
- If it has, the VBO then executes a Rule Set that sends an email to
all members of the translator role

This seems unsatisfactory to me as it seems weird to go Rules -> VBO
-> Rules but I can't work out otherwise in VBO how to send to members
of a role [presumably write a custom action] and I can't work out in
Rules how to test whether on saving the "mark as out of date" box is
ticked [presumably write a custom trigger].

My ideal solution would send an email to the translators with a link
to their version of the page (and the title in their language). It
would also be in either HTML email or turn www.example.com/node/17
(for example) into the www.example.com/foo/bar

The only thing I can currently think of is to write code that loops
through all the members of the role, gets their default language and
domain (as I'm using Domain Access as well), looks up the path  for
the translated version of the nid in their language and domain and
then fires out an email, but I still think I'm missing some obvious,
easy way to do what on the surface seems an easy action.

On Wed, Mar 17, 2010 at 11:52 AM, David Hart <david.hart at gmail.com> wrote:
> In Drupal 6, I want to send an email to all people with the
> "translator" role when a translation is flagged as out of date.
>
> I'd have thought this was a fairly common task, but I can't seem to
> work out how to do it as there's no trigger for translations. Do I
> need to create a trigger in my custom module? Is it easier to install
> Rules and use that to handle this or is that overkill for one feature?
> Is there anything I'm missing?
>


More information about the support mailing list