示例#1
0
def add_image_to_show(album, filename):
    """Add an image to the show"""
    show = Show(album, current_app.config, session)
    try:
        show.add_image(filename).save()
    except:
        return jsonify(result="Failed")

    return jsonify(result="OK")
示例#2
0
def add_image_to_show(album, filename):
    """Add an image to the show"""
    show = Show(album, current_app.config, session)
    try:
        show.add_image(filename).save()
    except:
        return jsonify(result='Failed')

    return jsonify(result='OK')
示例#3
0
def add_image_to_show(album, filename):
    """Add an image to the show"""
    show = Show(album)
    if show.add_image(filename):
        return jsonify(result='OK')
    return jsonify(result='Failed')