summaryrefslogtreecommitdiffstats
path: root/templates
Commit message (Collapse)AuthorAgeFilesLines
* Move to a more recent django project structureJeremy Kerr2015-05-2738-1695/+0
| | | | | | | | | | This change updates patchwor to the newer project struture: we've moved the actual application out of the apps/ directory, and the patchwork-specific templates to under the patchwork application. This gives us the manage.py script in the top-level now. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Integrate 'django.contrib.staticfiles'Stephen Finucane2015-05-036-22/+43
| | | | | | | | | | Rather than providing a custom solution for serving static files, use the solution provided in the upstream Django source. This allows us to remove the top-level 'urls.py' file. Signed-off-by: Stephen Finucane <stephenfinucane@hotmail.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Resolve removed 'AUTH_PROFILE_MODULE' settingStephen Finucane2015-05-034-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'AUTH_PROFILE_MODULE' setting, and the 'get_profile()' method on the 'User' model are removed in Django 1.7. This causes errors when using Patchwork with Django 1.7+. There are three changes necessary: * Replace profile model's 'ForeignKey' with a 'OneToOneField' * Remove all 'get_profile()' calls * Delete 'AUTH_PROFILE_MODULE' settings from 'settings.py' These changes are discussed here: http://deathofagremmie.com/2014/05/24/retiring-get-profile-and-auth-profile-module/ Django 1.6 also introduces two other notable changes: * The 'XViewMiddleware' module has been moved * A new test runner has been introduced It is not possible to fix these issues without breaking compatibility with Django 1.5. As a result they have been ignored and must be resolved in a future release. Signed-off-by: Stephen Finucane <stephenfinucane@hotmail.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Make the submitter name link to a query for that submitterMichael Ellerman2015-05-032-3/+3
| | | | | | | | | | | | | | | | | | | | | | Currently the submitter name is rendered as a mailto: link. This is possibly useful in some circumstances, but in my experience is not usually what I want. Although it opens a mail to the submitter, it doesn't include any of the patch context, so is not very helpful. Instead the submitter link can be a link to a query for patches by that submitter. In my experience that is more useful, ie. when looking at a single patch for a submitter you can then quickly get the list of all patches by them. So do that conversion. In order to do it we need to know the current project, so that becomes a parameter to personify. I believe the url reversal is correct, though it's not pretty, and pulling SubmitterFilter.param out feels a little wrong, but is the best solution I could come up with. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: fixup HTML tagsBrian Norris2014-07-041-7/+6
| | | | | | | | | | These tags aren't matched appropriately. There may well be others, but I caught these by a mix of eyes and Firefox's source viewer. Signed-off-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* pwclient: accept more than one project in ~/.pwclientrcYann E. MORIN2014-07-041-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, given the format of ~/.pwclientrc, pwclient can only really act on a single project, as ~/pwclientrc can only contain the configuration for a single project. Although the -p options comes in handy to specify a project different from the one configured in ~/.pwclientrc, this only works if it is hosted on the same server. As soon as one needs to switch server, it is necessary to edit ~/pwclientrc. This can be quite inefficient when dealing with many projects, hosted on different servers. Change the format of ~/.pwclientrc so it is possible to define more than one project, and for each project, specify an URL and credentials. The new format is like: [options] default = project-A [project-A] url = http://my.patchwork.server/path/to/xmlrpc username = that-is-me password = secret [other-project] url = http://you.get/the/idea username = someone password = 1234 This has the advantage of not changing the options to pwclient, so the user experience is unmodified. If a ~/.pwclentrc exists in the old format, it is automatically converted over to the new format, and the previous one is saved as ~/.pwclientrc.orig. Upon conversion, no action is made, pwclient just exits (with return-code 1) to inform the user to review the conversion. Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: display projects as inline-block elementsJeremy Kerr2014-05-071-7/+8
| | | | | | ... rather than one long list. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Django 1.5 compatibility fixesRalf Baechle2013-10-1326-56/+56
| | | | | | | Django 1.5 wants plenty of quotes scattered over the templates. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* views/base: Implement limit for submitter autocompletionJeremy Kerr2013-10-131-1/+3
| | | | | | | Add a limit parameter to the completion view, and pass a limit of 20 results in the javascript. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* notifications: add project name to patch update notificationWolfram Sang2013-06-162-2/+3
| | | | | | | | | | Based on a feature request & patch from Wolfram Sang <wsa@the-dreams.de>. Notifications may span multiple projects, so include a summary in the subject line, and detail in the header. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* js: Add jquery and jquery tablednd pluginsJeremy Kerr2013-06-161-2/+2
| | | | | | | | | | | | Based on a change from Andreas Bießmann <andreas@biessmann.de>. Rather than requiring a download of the jquery library + tablednd plugin, commit these to the repository. In doing so, we upgrade to version 1.10.1 of jqeury, and the current stable tablednd. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* bundles: Remove separate public bundle viewsJeremy Kerr2013-04-204-29/+8
| | | | | | | | | | | | Having two views for bundles (public and non-public) can cause confusion when bundle owners want to share a URL; it's not obvious that the private URL isn't shareable. This change removes the private URLs, and puts all bundles under the /bundle/<username>/<bundlename>/ URL space. For non-public bundles, this will just 404 for non-owners. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates/bundle: Unify public bundle meta informationJeremy Kerr2012-12-301-2/+8
| | | | | | | | Currently, the public bundle meta information (the download link before the list of patches) differs from that of the private bundle view. This change unifies this information with the private view. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* views/bundle: Allow downloading public bundle as mboxSimo Sorce2012-12-301-0/+2
| | | | | | | | | | | Downloading single patches anonymously is allowed, we may as well allow downloading public bundles as mboxes. This patch also changes the file name to be bundle-<id>-<name>.mbox so that the file name is unique even if bundle names are reused. Signed-off-by: Simo Sorce <idra@samba.org> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: patchwork project URL fixesJeremy Kerr2012-11-292-2/+2
| | | | | | We need a trailing slash, and to update the URL in the about page too. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: Update patchwork project URLJeremy Kerr2012-11-151-1/+1
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: Add link to the projects website in the projects viewSimo Sorce2012-11-151-2/+7
| | | | | | | | Allows the casual visitor to check out what all these projects actually are. Signed-off-by: Simo Sorce <idra@samba.org> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Add URL and SCM data to projectsSimo Sorce2012-11-151-0/+18
| | | | | | | | | | | | | | | This allows us to display friendly links to the project website, web SCM UI and SCM URL. For example for the patchwork project these could be set to: web_url: http://jk.ozlabs.org/projects/patchwork/ scm_url: git://ozlabs.org/home/jk/git/patchwork webscm_url: http://git.ozlabs.org/?p=patchwork;a=tree Requires a DB schema upgrade Signed-off-by: Simo Sorce <idra@samba.org> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Add shortcut to admin panelSimo Sorce2012-11-051-0/+3
| | | | | | | | This patch adds a shortcut to the admin panel but only for users that are members of staff. Signed-off-by: Simo Sorce <idra@samba.org> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: Don't rely on bool(Page)Jeremy Kerr2012-06-171-1/+1
| | | | | | | | | The behaviour of bool(Page) changed in django 1.4 - it no longer evaluates to False when page has no objects. When checking for an empty patch list, use page.paginator.count. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* notifications: do not HTML-escape patch change notificationsStefan Hajnoczi2012-05-011-1/+1
| | | | | | | | | Patch change notifications are text/plain emails and should not HTML-escape patch names. This means quotes and ampersands in patch names should not be turned into &quot; and &amp; HTML entities. Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* notifications: Add code to send notificationsJeremy Kerr2011-04-142-0/+20
| | | | | | | | | Add a function (patchwork.utils.send_notifications) to process the PatchChangeNotification queue. We try to group mail to the same sender, by waiting settings.NOTIFICATION_DELAY_MINUTES to allow other notifications to arrive. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Add email opt-out systemJeremy Kerr2011-04-1410-10/+269
| | | | | | | | | | | We're going to start generating emails on patchwork updates, so firstly allow people to opt-out of all patchwork communications. We do this with a 'mail settings' interface, allowing non-registered users to set preferences on their email address. Logged-in users can do this through the user profile view. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* registration: use EmailConfimation rather than separate registration appJeremy Kerr2011-04-149-22/+4
| | | | | | | | | | Since we have infrastructure for email confirmations, we no longer need the separate registration app. Requires a migration script, which will delete all inactive users, including those newly added and pending confirmation. Use carefully. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Use generic email confirmation objectJeremy Kerr2011-04-142-1/+20
| | | | | | | | | | | | | Rather than having a UserPerson-specific confirmation, add an EmailConfirmation object to allow multiple types of confirmations (eg, opt-out requests in future). To do this, we use a view (patchwork.views.confirm) that will call the type-specific view with the confirmation object. Also, add tests to check that the User/Person linkage system works. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* views: Refactor generic_list() to make it less complicatedGuilherme Salgado2011-04-141-1/+1
| | | | | | | | | When a form is submitted it now delegates to separate processing functions according to the action. Apart from being more readable it's now a lot easier to add extra forms for processing lists of patches. Signed-off-by: Guilherme Salgado <guilherme.salgado@linaro.org> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: remove redundant 'about' link from main navJeremy Kerr2011-03-301-2/+0
| | | | | | We have a link to the about page right below. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Remove unused templates and some code for processing themGuilherme Salgado2011-03-084-170/+0
| | | | | | | | These seem to be what was used in the past to archive/unarchive and delete patches. Signed-off-by: Guilherme Salgado <guilherme.salgado@linaro.org> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: Spelling fixDirk Wallenstein2011-02-111-1/+1
| | | | | Signed-off-by: Dirk Wallenstein <halsmit@t-online.de> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: use custom templates for password changeJeremy Kerr2010-12-102-0/+55
| | | | | | | Add a couple of templates to keep the password change flow in the same look & feel as the rest of the site. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Add link to password change form on user profile pageSascha Silbe2010-12-101-0/+5
| | | | | Signed-off-by: Sascha Silbe <sascha-pgp@silbe.org> Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Add support for git-pull requestsJeremy Kerr2010-11-011-3/+11
| | | | | | | | | Add a a pull_url to the Patch object, and update the parser to look for git-pull style emails. Requires SQL migration script. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: remove "beta"Jeremy Kerr2010-08-101-2/+1
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: Add CSRF (cross-site request forgery) values to form postsJohn 'Warthog9' Hawley2010-08-1010-0/+20
| | | | | | | | This is a fairly simple patch, basically it does what the error message told me to do: "add In the template, there is a {% csrf_token %} template tag inside each POST form that targets an internal URL." Signed-off-by: John 'Warthog9' Hawley <warthog9@kernel.org>
* templates/patch-list: add default text for patches with no nameJeremy Kerr2010-08-101-1/+1
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* views: Use request scheme in sample pwclientrc file.Jeremy Kerr2010-03-191-1/+1
| | | | | | Adapt the pwclientrc file to suit the current scheme in use. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* templates: close table cell in project maintainer listJeremy Kerr2009-04-051-0/+1
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* views: separate project views into separate fileJeremy Kerr2009-04-051-1/+1
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Bundle reordering supportJeremy Kerr2009-02-082-1/+34
| | | | | | | | Bundles can now be reordered and saved. Add dependency on jquery in INSTALL. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Initial bundle reordering supportJeremy Kerr2009-01-292-74/+89
| | | | | | | | | todo: * implement ajax reorder api * finish migration script * order patches in bundle view Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* [html] Fix apparently-unclosed script tagJeremy Kerr2008-09-241-3/+3
| | | | | | Firefox doesn't seem to grok the <script/> notation. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* [html] Add select-all checkbox for patch listsJeremy Kerr2008-09-241-1/+3
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* [html] Reference common.js in base templateJeremy Kerr2008-09-242-5/+1
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* [html] Consolidate js filesJeremy Kerr2008-09-241-1/+1
| | | | | | | We don't need most of the stuff in htdocs/js/. Put the only function required into a common.js, which we can add other stuff to. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* [html] Reinstate 'about' linkJeremy Kerr2008-09-231-16/+22
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* [views] Restructure profile view, simplify bundle accessJeremy Kerr2008-09-233-36/+106
| | | | | | | Make bundles more like todo lists - the list itself has its own page, accessible from the top user links. Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Add 404 templateJeremy Kerr2008-09-161-0/+10
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Fix 'activate' mispellingJeremy Kerr2008-09-121-1/+1
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Add commit_ref field to patch pageJeremy Kerr2008-09-091-0/+6
| | | | Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
* Fix user/username mismatch on pwclientrc templateJeremy Kerr2008-09-091-2/+3
| | | | | | ... and add a comment to the auth section Signed-off-by: Jeremy Kerr <jk@ozlabs.org>