Ignore:
Timestamp:
09/19/11 14:31:48 (21 months ago)
Author:
Jose Benito <jose.benito.gonzalez@…>
Branches:
master, hello-world-walkthrough, ipv6, v0.98-series, v0.98.2, v0.98.3, v0.99, b8c30da8ebdbdcbd675a873997cc3e95f567de49, 4287315ec967a3da168d83963c14001db8487d53
Children:
a3fc2e
Parents:
f2ec56
git-author:
Adrian Moennich <jerome.ernst.monnich@…> (09/05/11 17:41:32)
git-committer:
Jose Benito <jose.benito.gonzalez@…> (09/19/11 14:31:48)
Message:

[FTR] Add API to create recording link

  • Allow other hooks but exporters in http api
  • Support POST API requests
  • Allow API hooks to require(&allow) POST
  • Log successful POST API requests
  • get rid of 'export' module name in http api
  • Allow non-array results, allow db committing
  • Closes #900
File:
1 edited

Legend:

Unmodified
Added
Removed
  • indico/MaKaC/plugins/Collaboration/RecordingManager/common.py

    rf9077c r03c6d2d  
    2424from MaKaC.conference import ConferenceHolder, Contribution 
    2525from MaKaC.common.logger import Logger 
    26 from MaKaC.errors import MaKaCError 
     26from MaKaC.errors import MaKaCError, NoReportError 
    2727try: 
    2828    import MySQLdb 
     
    833833#    Logger.get('RecMan').debug("in createIndicoLink()") 
    834834    # From IndicoID, get info 
    835     talkInfo = parseIndicoID(IndicoID) 
     835    try: 
     836        talkInfo = parseIndicoID(IndicoID) 
     837    except NoReportError: 
     838        return False 
    836839    obj = talkInfo["object"] 
    837840 
    838841    # Only one link per talk allowed. 
    839842    if doesExistIndicoLink(obj): 
    840         pass 
     843        return True # consider it a success anyway 
    841844    else: 
    842845#        Logger.get('RecMan').info("creating a new link in Indico for talk %s, CDS record %s" % (IndicoID, CDSID)) 
     
    855858        material.setMainResource(videoLink) 
    856859        obj.addMaterial(material) 
     860        return True 
    857861 
    858862def doesExistIndicoLink(obj): 
Note: See TracChangeset for help on using the changeset viewer.