Fix file attachment names in changedescs.

When file attachments are added with no captions, the change descriptions would
just say "Added ". This is pretty horrible. This change adds a new property
which will prefer the caption and fall back on the basename.

Testing done:
Added a file without a filename and published. Checked that the change description
text was the file basename. Gave the file a caption, and then removed it.
Checked that the change description text was the caption.
Release Review Board 1.7.2.
Strip whitespace from STMP server names.

The STMP server configuration would fail if there was trailing whitespace on the
server name. This was a problem when copy/pasting text into the form.

Testing done:
Produced the bug with an smtp server "smtp.gmail.com     " and triggered an
email event (registration for new user). Log produced an error: "Unknown host".
Added the changes on the diff and tried again, the email is sent and the value
that is saved is stripped of the redudant spaces.

Reviewed at http://reviews.reviewboard.org/r/3759/
Fixes bug 2620.
Fix static media URLs when running the devel server with a SITE_ROOT.

The way that static media URLs ('/static/' and '/media/') were mapped when a
SITE_ROOT was defined was problematic, in that it was appending the SITE_ROOT
twice in the urlspec. The problem is that all the URLs were created with the
root prepended, but the way that settings.py defined the urls didn't have the
right distinctions between the names of the directories and the URL paths.

Testing done:
Tested that loading the dashboard included all static media with a SITE_ROOT of
both '/' and '/example/'.
Add test: Expect 404 on invalid review access.

In particular, test if accessing the screenshots of a nonexistent review id
fails.

Testing done: Test passes with http://reviews.reviewboard.org/r/3767 applied.

Fixes bug 2551.
Reviewed at http://reviews.reviewboard.org/r/3761/
The "Posted Time" should be the time of publish.

Currently, the time_added of a review request is setup when a new record is
added. If there is a time difference between the creation time and the time of
actually publishing the review request, the field is not updated and it shows
the time of creation as the "Posted" time. This is fixed by updating the
"time_added" field to current time when a review request is published.

Testing done: Manual, Ran all tests to ensure no other breakage.

Reviewed at http://reviews.reviewboard.org/r/3753/
Fixes bug 1897.
Fix the settings import in the search index management command.

"import settings" should have been "from django.conf import settings".

Fixes bug 2872.
Clean up the name and spacing in the VersionOne code.

The VersionOne code had some spacing and trailing whitespace problems,
and also listed the service as "versionone" and not "VersionOne".
Don't show "Add comment" button if not logged in

This is for file upload reviews. Before, the button was there, but did nothing
for anonymous users. Also, fix some template tag indentation

Testing done: Checked if the button is gone for anonymous users and still there
for logged-in users. No failed tests.

Reviewed at http://reviews.reviewboard.org/r/3773/
Fixed bug allowing a request to be published with empty summary fields.

In the publish request page, if you filled the summary or description field then
deleted the contents, the fields would not be updated but the ReviewRequest
object would be updated.  This allowed a request to be published with empty
fields although the page showed they were not empty.

The fields are now emptied to then be filled with the new contents, avoiding
this issue.

Testing done: Checked in browser that the summary and description fields are
updated if you empty the field.  The Web UI does not allow the request to be
published after the field is emptied.

Reviewed at http://reviews.reviewboard.org/r/3760/
Fixes bug 2870.
Merge branch 'release-1.7.x' of https://github.com/reviewboard/reviewboard into bug2826