Changeset 126:c6dcf12e3807 in documentViewer


Ignore:
Timestamp:
Jun 8, 2010, 4:57:36 PM (14 years ago)
Author:
casties
Branch:
default
Message:

added method to get url of viewer instance
fixed bug with gettoc with mode=none

File:
1 edited

Legend:

Unmodified
Added
Removed
  • documentViewer.py

    r124 r126  
    222222        url = self.template.zogilib.getDLBaseUrl()
    223223        return url
     224
     225    def getDocumentViewerURL(self):
     226        """returns the URL of this instance"""
     227        return self.absolute_url()
    224228   
    225229    def getStyle(self, idx, selected, style=""):
     
    901905        """loads table of contents and stores in docinfo"""
    902906        logging.debug("documentViewer (gettoc) mode: %s"%(mode))
     907        if mode == "none":
     908            return docinfo
     909       
    903910        if 'tocSize_%s'%mode in docinfo:
    904911            # cached toc
    905             return docinfo
     912            return docinfo
     913       
    906914        docpath = docinfo['textURLPath']
    907915        # we need to set a result set size
Note: See TracChangeset for help on using the changeset viewer.