Skip to content
This repository

Merging up from dev to stage #125

Merged
merged 2 commits into from over 1 year ago

1 participant

Ross Bruniges
Ross Bruniges
Collaborator

With fix for #123

Ross Bruniges rossbruniges merged commit 474d09e into from January 18, 2013
Ross Bruniges rossbruniges closed this January 18, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 2 unique commits by 1 author.

Jan 18, 2013
Ross Bruniges fix #123 - fixing edit entry url - returning a reference to the submi…
…ssion_parent opposed to the old submission URL
5886604
Ross Bruniges Merge pull request #124 from rossbruniges/dev
fix #123 - fixing edit entry url
b0dea3e
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 8 additions and 3 deletions. Show diff stats Hide diff stats

  1. 11  apps/challenges/models.py
11  apps/challenges/models.py
@@ -413,15 +413,20 @@ def phase_slug(self):
413 413
         return 'apps'
414 414
 
415 415
     def get_absolute_url(self):
416  
-        """Return this submission's URL."""
  416
+        """
  417
+        Return this submission's URL
  418
+        """
417 419
         if self.parent_slug and self.phase_slug:
418 420
             return self._lookup_url('entry_show', {'entry_id': self.parent_slug,
419 421
                                                    'phase': self.phase_slug})
420 422
         return u''
421 423
 
422 424
     def get_edit_url(self):
423  
-        """Return the URL to edit this submission."""
424  
-        return self._lookup_url('entry_edit', {'pk': self.id,
  425
+        """
  426
+        Return the URL to edit this submission, we need to use the submission
  427
+        parent as that is what holds the key of which submission to edit
  428
+        """
  429
+        return self._lookup_url('entry_edit', {'pk': self.parent_slug,
425 430
                                                'phase': self.phase_slug})
426 431
 
427 432
     def get_delete_url(self):
Commit_comment_tip

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.