Пример #1
0
def static_equal():
    indication = 0
    rs = Bus().get_all_bus_info()
    for rec in rs:
        indication = max(indication, rec.get('индикация', 1))
    result = {'индикация': indication, 'data': rs}
    return jsonify(result), 200, {'Access-Control-Allow-Origin': '*'}
Пример #2
0
def update_bus():
    return jsonify(Bus().update_bus(request.json))
Пример #3
0
def insert_trunc():
    return jsonify(Bus().insert_bus_transaction(request.json))
Пример #4
0
def insert_bus():
    return jsonify(Bus().insert_bus(request.json))
Пример #5
0
def bus_one(bus):
    return jsonify(Bus().get_one_bus_info(bus))
Пример #6
0
def bus_all():
    return jsonify(Bus().get_all_bus_info()), 200, {
        'Access-Control-Allow-Origin': '*'
    }