Revision 13 as of 2010-06-01 05:57:33

Clear message

Web UI - Status

This page should serve as a place to update everyone on the current state of development, but also to discuss the progress and/or decisions being made while developing.

Components

The Mailman Web UI consists of three components:

  1. a REST client module that handles all communication with Mailman

  2. "mailman-django": a reusable Django app that makes use of the client module and delivers the web front-end

  3. a django project/site that includes mailman-django

Why not just ship one thing? Because this way we cover a number of different scenarios, i.e.:

  • Use 1., 2. & 3. if you have Mailman installed but are not running an existing Django site.

  • Use 1. & 2. if you already have an existing Django web site and would like to extend it with a Mailman interface.

  • Use 1. if you are developing a completely different Python application that needs to communicate with Mailman.

The REST client module

A current draft contains two classes:

MailmanRESTClient: Methods names CRUD-like: create_list(), read_list(), update_list(), delete_list(), get_lists(), subscribe_list(), leave_list() etc.

MailmanRESTClientError: Exception Class

It currently uses urllib and urllib2 to talk to Mailman but this has to be changed to use httlib to make use of the DELETE and PUT request methods (since Mailman's REST server now uses Restish).

Note: The client module should be part of the Mailman core source to integrate it into Mailman's testing routine. But it should also be distributed as a stand-alone Python module.

mailman-django

A reusable Django app. Lives outside the Django project folder, somewhere on the Python path. Directory structure so far:

mailman-django/
    media/
        mailman-django/
            css/
            img/
            js/
    templates/
        mailman-django/
            lists/
            members/

The "mailman-django" folders inside "media" and "templates" may seem redundant but help maintain clarity and prevent conflicts when integrating the app into an existing environment.

The Django website/project

Contains the standard set of files when doing:

django-admin.py startproject mailmanweb

Could further be reduced to keep only settings.py and urls.py.

mailman-django is included by adding it to INSTALLED_APPS in the project's settings.py:

INSTALLED_APPS = (
    'mailman-django'
)

.... and by adding it to urls.py:

urlpatterns = patterns('',
    (r'^mailman/', include('mailman-django.urls'))
)

Applications in Django

The current plan is to have one standard django apps for the UI but discussions have been made to make it two: one for the admin site and one for the user sites. This will make the project more lucid. It is also possible to add more apps for organizations that wish to customize their views or add additional fields.

The UI DB

The plan is that there will be one "normal"/standard UI which only uses the core DB and access this via the rest client. However, with the help of Django one can add databases which can be used for alternative UI's, such as the one from Systers. The extra DB could, for instance, include the following tables and content:

Table "user"

  • id integer not null (to connect to core db), PK
  • URL text (specific "link_id" for each user)
  • required_id integer (connects to the "required" table)
  • web_url text (if someone, for instance, wish to add a link to a blog or similar)

Table mailing list

  • id integer not null (to connect to core db), PK
  • URL text (specific "link_id")
  • picture base64-encoded (if, for instance, the organization using the mailing list wants to add a logo)
  • dlist_enabled boolean (Systers specific)
  • questions_essay text (Systers specific)
  • required_id integer (connects to the "required" table)

Table required

  • id integer not null, PK
  • fullname_req boolean (Systers specific, possibly for core as well)
  • essay_req boolean (Systers specific)
  • picture_req boolean (although we'll probably want to make this optionally)

Of these, the mailing list and the user tables are already present in core and would be extended with this information.

Test Server

A test server with a basic setup of the web UI is currently being set up.

Features to be implemented first

  1. Ability for users to subscribe, manage subscriptions, unsubscribe, change emails
  2. Admin ability to create/delete lists via pre-defined styles
  3. Users ability to customize their subscirptions
  4. Moderation
  5. Aite admin ability to create domains, add and modify styles
  6. List admin ability to customize lists