/loggerhead/trunk

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/loggerhead/trunk

« back to all changes in this revision

Viewing changes to loggerhead/controllers/revlog_ui.py

  • Committer: Robey Pointer
  • Date: 2006-12-11 06:44:19 UTC
  • Revision ID: robey@lag.net-20061211064419-8ssa7mlsiflpmy0c
initial checkin

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
import urllib
2
 
 
3
 
from breezy import osutils, urlutils
4
 
 
5
 
from ..controllers import TemplatedBranchView
6
 
 
7
 
 
8
 
class RevLogUI(TemplatedBranchView):
9
 
 
10
 
    template_name = 'revlog'
11
 
    supports_json = True
12
 
 
13
 
    def get_values(self, path, kwargs, headers):
14
 
        history = self._history
15
 
 
16
 
        revid = urlutils.unquote_to_bytes(osutils.safe_utf8(self.args[0]))
17
 
 
18
 
        change = history.get_changes([revid])[0]
19
 
        file_changes = history.get_file_changes(change)
20
 
        history.add_branch_nicks(change)
21
 
 
22
 
        return {
23
 
            'entry': change,
24
 
            'file_changes': file_changes,
25
 
            'revid': revid,
26
 
        }