~loggerhead-team/loggerhead/trunk-rich

« back to all changes in this revision

Viewing changes to loggerhead/controllers/revision_ui.py

  • Committer: Robey Pointer
  • Date: 2007-01-16 03:53:02 UTC
  • Revision ID: robey@lag.net-20070116035302-wzxy5sig3lugvpib
make index_freq a config

Show diffs side-by-side

added added

removed removed

Lines of Context:
35
35
        # BranchView object
36
36
        self._branch = branch
37
37
        self.log = branch.log
38
 
        
 
38
 
39
39
    @util.strip_whitespace
40
40
    @turbogears.expose(html='loggerhead.templates.revision')
41
41
    def default(self, *args, **kw):
42
42
        z = time.time()
43
43
        h = self._branch.get_history()
44
 
        util.set_context(kw)
45
44
        
46
45
        if len(args) > 0:
47
46
            revid = h.fix_revid(args[0])
51
50
        file_id = kw.get('file_id', None)
52
51
        start_revid = h.fix_revid(kw.get('start_revid', None))
53
52
        query = kw.get('q', None)
54
 
        remember = kw.get('remember', None)
55
 
        compare_revid = kw.get('compare_revid', None)
56
53
        
57
54
        try:
58
55
            revid, start_revid, revid_list = h.get_view(revid, start_revid, file_id, query)
67
64
            navigation.query = query
68
65
        util.fill_in_navigation(h, navigation)
69
66
 
70
 
        if compare_revid is not None:
71
 
            change = h.get_diff(compare_revid, revid)
72
 
        else:
73
 
            change = h.get_changes([ revid ], get_diffs=True)[0]
 
67
        change = h.get_changes([ revid ], get_diffs=True)[0]
74
68
        # add parent & merge-point branch-nick info, in case it's useful
75
69
        h.get_branch_nicks([ change ])
76
70
 
89
83
            'history': h,
90
84
            'navigation': navigation,
91
85
            'query': query,
92
 
            'remember': remember,
93
 
            'compare_revid': compare_revid,
94
86
            'side_by_side': side_by_side,
95
87
        }
96
88
        h.flush_cache()