示例#1
0
def itemXML(category_id, item_id):
    """
    ####Args####
        + category_id:  the id of the category of the book
        + item_id:  the id of the book

    ####Returns####
        + book:  XML object of the book
    """
    root = ET.Element('book')
    return app.response_class(
        ET.tostring(
            Item.getItemXML(session, item_id, root),
            encoding='us-ascii',
            method='xml'),
        mimetype='application/xml')