Age | Commit message (Collapse) | Author |
|
We need to do this in the models.py files, otherwise the post_save signal
might not be connected right away on launch of the application. Move them
over there, add a dispatch_uid so it only gets hooked up once, and do some
other function moving around so we don't have circular imports.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
When we moved some models from one app to another, we didn't do anything to
ensure the tables were created at all initially. Enforce this by adding the
minimal required dependencies- those migrations in the 'main' model that
last touched the involved models moving between apps.
Noticed-by: Angel Velasquez <angvp@archlinux.org>
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
And make sure it is unique through a few queries and some magic.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
These should get us all set to have more useful URLs for the news items.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Initially, this needs to allow null so that we can add in slugs for all of
our old news items.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
When moving the news model and updating the content type, I forgot to update
these strings to reflect the new permission name. Whoops.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Add last modified date as a column, and fix up some other small display,
sorting, and ordering issues.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This will come in handy when determining whether resources are out of date,
such as our news RSS feed. Also bump the Date fields to DateTime fields for
sake of sorting and if we have more than one news item on the same date.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
And be able to do filtering/sorting/etc. with it.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This view was getting huge with ~500 items on it, and most people are not
really interested in seeing every single news item. Use the drop in
pagination and add some controls that still allow browsing to any page of
the list.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Never would have guessed it should actually be in news/models.py.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Rather than the need to include RequestContext() calls directly, we can
just use direct_to_template to do all the work for us.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Implements FS#13741. A preview function is also added so working with news
items is easier to make sure you get the formatting right.
This will result in some older news items looking a bit weird if they didn't
put linebreaks in all the right places, we can fix a few of these as we
notice them.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
No need to pull back some 500 news articles when we just want the basics of
title, date, and author. Speaking of author, we might as well load that at
the same time too.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Now that we cache everything, we need to ensure anyone doing edits and
such gets the live data and not some cached version that was already
updated and is now stale. Add the never_cache decorator to any of the
CUD screens as well as a few others that might benefit from always being
regenerated.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
This was having some serious effects on caching as we would always have to
access the user in the session, marking every page with a "Vary: Cookie"
header. This is the start of stamping that out. The way we get the user for
news item creation is now more similar to that from the todo lists, but not
quite. That should be adjusted to be more like the news item creation.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Make both the title entry and the text area a lot larger so it is easier to
add and edit news items from the developer side.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
Unnecessary, and lets us standardize on not using it everywhere.
Signed-off-by: Dan McGee <dan@archlinux.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Also added vim command comment to the end of files.
|
|
archweb_pub conventions).
Moved pkgmaint_guide to a template.
|
|
|
|
Special Note
Prior to git import, approx 90% of the code was done by Judd Vinet. Thanks Judd!
|