def publish(): """ Copy current draft xml file to the public location for document files. """ print 'edit::publish:' filename = session.filename return BookManager.publish(filename)
def index(): session.filename = request.args[0] filename = session.filename BookManager.copy_book(filename) # get parsed document info info, p = _get_bookinfo(filename) #get title of document title = info['book']['title'] buttons = {'renumber units': URL('edit', 'renumber', args=[filename]), 'publish': URL('edit', 'publish', args=[filename])} return {'filename': filename, 'buttons': buttons, 'title': title}
def index(): session.filename = request.args[0] filename = session.filename BookManager.copy_book(filename) # get parsed document info info, p = _get_bookinfo(filename) #get title of document title = info['book']['title'] buttons = { 'renumber units': URL('edit', 'renumber', args=[filename]), 'publish': URL('edit', 'publish', args=[filename]) } return {'filename': filename, 'buttons': buttons, 'title': title}
def renumber(): """ Renumber units and options throughout the current document. Units must be numbered consecutively and options must be numbered starting at 0 within each unit. """ print 'edit::renumber:' filename = session.filename return BookManager.renumber_units(filename)