Changeset 611792 in indico


Ignore:
Timestamp:
05/30/11 18:09:48 (2 years ago)
Author:
Pedro Ferreira <jose.pedro.ferreira@…>
Branches:
master, burotel, hello-world-walkthrough, ipv6, v0.98-series, v0.98.2, v0.98.3, v0.98b1, v0.98b2, v0.99, b8c30da8ebdbdcbd675a873997cc3e95f567de49, 10eafd9ae230cbad5d99d5aaf22c24724fb6c98f
Children:
699502
Parents:
725fcf
git-author:
Pedro Ferreira <jose.pedro.ferreira@…> (05/30/11 18:08:03)
git-committer:
Pedro Ferreira <jose.pedro.ferreira@…> (05/30/11 18:09:48)
Message:

[FIX] Problem of empty link

  • No need for migration script;
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • bin/migration/migrate_0.97_0.98.py

    r725fcf r611792  
    3434from MaKaC.registration import RegistrantSession, RegistrationSession 
    3535from MaKaC.plugins.RoomBooking.default.dalManager import DALManager 
    36 from MaKaC.webinterface.displayMgr import ConfDisplayMgrRegistery, SystemLink 
    3736 
    3837from indico.ext import livesync 
     
    117116 
    118117 
    119 def _fixEmptyURLs(obj): 
    120     menu = ConfDisplayMgrRegistery().getDisplayMgr(obj).getMenu() 
    121     for l in menu.getLinkList(): 
    122         if type(l) == SystemLink and not hasattr(l, '_URL') and l.getCaption() == '' \ 
    123                and l.getName() == 'manageabstractreviewing': 
    124             menu._listLink.remove(l) 
    125  
    126  
    127118def runCategoryACMigration(dbi, withRBDB): 
    128119    """ 
     
    162153            # convert them to the new object classes. 
    163154            _convertAlarms(obj) 
    164  
    165             _fixEmptyURLs(obj) 
    166155 
    167156        _fixAccessController(obj, 
  • indico/MaKaC/webinterface/displayMgr.py

    r902aca r611792  
    288288                    elif link.getParent().getName() != linksData[link.getName()]["parent"]: 
    289289                        link.getParent().removeLink(link) 
     290                elif link.getName() not in linksData: 
     291                    # link was removed from the list 
     292                    self.removeLink(link) 
    290293 
    291294        #Now, update the system links 
Note: See TracChangeset for help on using the changeset viewer.