django It seems the view func do not work
<p>I'm trying to write a FBV to delete a subject, but there are some problem I can't figure out. It's Django 1.7.1. Below are related codes.</p>

<p>The model Communication:</p>

<pre><code>...
@models.permalink
def get_delete_url(self):
    return 'comm_delete', [self.uuid]
</code></pre>

<p>the URLconf:</p>

<pre><code>url(r'^(?P&lt;uuid&gt;[\w-]+)/delete/$', views.comm_delete, name='comm_delete'),
</code></pre>

<p>the views:</p>

<pre><code>def comm_delete(request, uuid):
    obj = get_object_or_404(Communication, uuid=uuid)
    account = Account.objects.get(id=obj.account.id)
    if request.method == 'POST':
        obj.delete()
        return HttpResponseRedirect(reverse('crmapp.accounts.views.account_detail', args=(account.uuid,)))
    return render(request, 'subject_confirm_delete.html', {'object_name': 'Communication', 'object': obj})
</code></pre>

<p>when I click</p>

<pre><code>&lt;a class="cancel" href="{{ comm.get_delete_url }}"&gt;&lt;/a&gt;
</code></pre>

<p>the page move to uuid/delete/ url, the form display Communication object. If I still click the cancel button, just refresh the page and nothing changed.
So how can I fix it? Help me please!</p>

<p>The object_confirm_delete.html:
<img src="http://i.stack.imgur.com/vnpV5.png" alt="object_confirm_delete.html"></p>

<p>the page when clicked cancel button:
<img src="http://i.stack.imgur.com/7UWqS.png" alt="clicked_move_to_page"></p>

<p>the urls.py in app Communications like this:</p>

<pre><code>url(r'^(?P&lt;uuid&gt;[\w-]+)/', views.comm_detail, name='comm_detail'), 
url(r'^(?P&lt;uuid&gt;[\w-]+)/delete/$', views.comm_delete, name='comm_delete'),
</code></pre>

<p>as you can see, the first one has no '$' at the end, so when I link the url of second one, the first one's regex matched and perform the view comm_detail. After I modify it, It execute well.</p>

<p>the urls.py in app Communications like this:</p>

<pre><code>url(r'^(?P&lt;uuid&gt;[\w-]+)/', views.comm_detail, name='comm_detail'), 
url(r'^(?P&lt;uuid&gt;[\w-]+)/delete/$', views.comm_delete, name='comm_delete'),
</code></pre>

<p>as you can see, the first one has no '$' at the end, so when I link the url of second one, the first one's regex matched and perform the view comm_detail. After I modify it, It execute well. It means the FBV is correct.</p>

python django