Im calling an endpoint in my template:
var postdata = { 'csrfmiddlewaretoken': '{{ csrf_token }}' }
$.post("reconcile/" + transaction_id, postdata);
Here is the view:
def reconcile_transaction(request, slug, id):
        society = get_object_or_404(Society, slug=slug)
        try:
            society.members.get(pk=request.user.id)
        except society.DoesNotExist:
            return HttpResponseRedirect('/')
        account = society.account
        transaction = Transaction.objects.filter(id=id)     
        print(transaction.get_stubbed_time)
I'm getting a 500 error at the print statement.
Any ideas?
 
     
     
    