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>
name = models.CharField(max_length=255, unique=True)
listid = models.CharField(max_length=255, unique=True)
listemail = models.CharField(max_length=200)
+ web_url = models.CharField(max_length=2000, blank=True)
+ scm_url = models.CharField(max_length=2000, blank=True)
+ webscm_url = models.CharField(max_length=2000, blank=True)
send_notifications = models.BooleanField()
def __unicode__(self):
--- /dev/null
+BEGIN;
+ALTER TABLE "patchwork_project" ADD COLUMN "web_url" varchar(2000);
+ALTER TABLE "patchwork_project" ADD COLUMN "scm_url" varchar(2000);
+ALTER TABLE "patchwork_project" ADD COLUMN "webscm_url" varchar(2000);
+COMMIT;
<th>Patch count</th>
<td>{{n_patches}} (+ {{n_archived_patches}} archived)</td>
</tr>
+{% if project.web_url %}
+ <tr>
+ <th>Website</th>
+ <td><a href="{{project.web_url}}">{{project.web_url}}</a></td>
+ </tr>
+{% endif %}
+{% if project.webscm_url %}
+ <tr>
+ <th>Source Code Web Interface</th>
+ <td><a href="{{project.webscm_url}}">{{project.webscm_url}}</a></td>
+ </tr>
+{% endif %}
+{% if project.scm_url %}
+ <tr>
+ <th>Source Code Manager URL</th>
+ <td><a href="{{project.scm_url}}">{{project.scm_url}}</a></td>
+ </tr>
+{% endif %}
</table>
{% if settings.ENABLE_XMLRPC %}