~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to ivle/webapp/tutorial/media.py

  • Committer: William Grant
  • Date: 2010-02-11 05:27:24 UTC
  • Revision ID: grantw@unimelb.edu.au-20100211052724-171m0779yqzn1y1x
Add a setup.cfg with nose settings. You can now run the suite with 'IVLECONF=. nosetests'.

Show diffs side-by-side

added added

removed removed

Lines of Context:
45
45
        subjectdir = os.path.join(self.context.short_name, 'media')
46
46
        return os.path.join(subjectdir, self.path)
47
47
 
48
 
    def get_permissions(self, user, config):
49
 
        return self.context.get_permissions(user, config)
 
48
    def get_permissions(self, user):
 
49
        return self.context.get_permissions(user)
50
50
 
51
51
 
52
52
class SubjectMediaView(MediaFileView):
62
62
            req.config['paths']['data'],
63
63
            'content/subjects', self.context.filename)
64
64
 
65
 
    def get_permissions(self, user, config):
66
 
        return self.context.get_permissions(user, config)
 
65
    def get_permissions(self, user):
 
66
        return self.context.get_permissions(user)
67
67
 
68
68
 
69
69
@forward_route(Subject, '+media', argc=INF)