[Mailman-Developers] Reg: Postorius Issue 127

Stephen J. Turnbull turnbull.stephen.fw at u.tsukuba.ac.jp
Sat Jan 7 11:46:55 EST 2017


Siddhartha Gairola writes:

 > So this is what we have to implement for postorius -
 > "if the post is from a moderated member, the moderator has a checkbox to
 > clear the member's moderation when accepting the post."

Right.

 > But I am not too sure how to get this done. I guess it would require
 > modifying some controller.
 > If I could get some assistance on this, I would be grateful.

Postorius is implemented as a Django application, and Django uses a
modified MVC model.  So you should be prepared for all of model
(model), view (template), and controller (view) to be involved (in
parens Django terms, outside MVC terms, somewhat stretched as
necessary in Django).

Model: since the user's moderation bit is already set, it must be
present.  Since you're just asked to clear it, which is a normal
operation for bits, probably no change to model is needed.

Template: implements checkbox formatting.  Needs change.

View: implements checkbox toggling and communication with model.
Needs change.

To find template, go to template directory (use find(1) or GUI
equivalent on your platform), look through templates to find
moderation page(s) (there may be more than one).

To find code, grep through views for one which invokes that template.

Don't promise this will get you what you want, but that's the way I
would start.

Gotta do other work now, back tomorrow evening (> 06:00 UTC).

Steve



More information about the Mailman-Developers mailing list