Age | Commit message (Collapse) | Author |
|
This is way too much text to duplicate across many places..
|
|
This includes a number of new features:
* Move some moderation functionality into shared places, so we don't
keep re-inventing the wheel.
* Implement three-state moderation, where the submitter can edit their
item and then explicitly say "i'm done, please moderate this now".
This is currently only implemented for News, but done in a reusable
way.
* Move moderation workflow to it's own set of URLs instead of
overloading it on the general admin interface. Admin interface remains
for editing things, but these are now separated out into separate
things.
* Do proper stylesheet clearing for moderation of markdown fields, using
a dynamic sandboxed iframe, so it's not ruined by the /admin/ css.
* Move moderation email notification into dedicated moderation code,
thereby simplifying the admin subclassing we did which was in some
places quite fragile.
* Reset date of news postings to the date of their approval, when
approved. This avoids some annoying ordering issues.
|
|
This is the bardware compatible value that will be needed once we
upgrade django later.
|
|
|
|
|
|
In a quest to reach pep8, use spaces to indent rather than tabs.
|
|
|
|
Clean up the whitespace in the primary Python / HTML files in
order to make it easier to apply changes going forward.
|
|
1. ForeignKey with unique -> OneToOneField
2. IPAddressField -> GenericIPAddressField
3. Fix fields with default=datetime.now() which gives server start time,
not the insert time (clearly this default was never used, and the
field was always explicitly set, but it should still not be incorrectly
defined)
|
|
We were already using signals for everything except delete, and even
in our old version of django the delete signal exists (it didn't exist
when this code was first written).
Django doesn't really like models to be OOP like this, so keeping PgModel
would cause issues with upcoming changes in django 1.8. Using simple functions
is easier, and the actual functionality is replicated straight off.
|
|
Remove unused imports and some other completely unused code.
|
|
|
|
This is requied to support notifications, and good for consistency
in general.
|
|
organisation field
For those who don't read the introduction page under my account, per request
from Dave.
|
|
The rest of the code already dealt with profservs attached to organisations,
but the existance of tihs field causded the validation to reject any
updates since this field is wrong. Instead, create a verify_submitter()
function that checks the permissions on the organisation.
This fixes #98
|
|
|
|
|
|
|
|
This allows all models inherited from PgModel to specify which
URLs to purge by either setting a field or defining a function
called purge_urls, at which point they will be purged whenever
the save signal is fired.
Also implements a form under /admin/purge/ that allows for manual
purging. This should probably be extended in the future to show
the status of the pgq slaves, but that will come later.
Includes a SQL function that posts the expires to a pgq queue. For
a local deployment, this can be replaced with a simple void function
to turn off varnish purging.
|
|
|
|
Contains basic functionality, and an import of most of the static content
from the old site.
There is still plenty more to do...
|