Exemplo n.º 1
0
def update(command, cursor, connection):
    col = commons.get_unset_fields(command, columns, table_name, cursor)
    args = cursor.callproc('CONTACTS_tapi.upd', (parameter_getters.get_parameter_col(command, "-c", col), parameter_getters.get_parameter_col(command, "-s", col),
           parameter_getters.get_parameter_col(command, "-i", col), command[1],
           parameter_getters.get_parameter_col(command, "-t", col)))
    res = int(args[3])
    connection.commit()
    notifiers.notify_update(res)
Exemplo n.º 2
0
def update(command, cursor, connection):
    col = commons.get_unset_fields(command, columns, table_name, cursor)
    res = cursor.callproc(
        'WORKERS_STATES_tapi.upd',
        (parameter_getters.get_parameter_col(command, "-d",
                                             col), int(command[1]),
         parameter_getters.get_parameter_col(command, "-n", col)))
    connection.commit()
    res = int(command[1])
    notifiers.notify_update(res)
Exemplo n.º 3
0
def update(command, cursor, connection):
    col = commons.get_unset_fields(command, columns, table_name, cursor)
    args = cursor.callproc('SERVICES_tapi.upd', (parameter_getters.get_parameter_col(command, "-p", col),
                                                 parameter_getters.get_parameter_col(command, "-d", col),
                                                 command[1],
                                                 parameter_getters.get_parameter_col(command, "-a", col),
                                                 parameter_getters.get_parameter_col(command, "-n", col)))
    res = int(args[2])
    connection.commit()
        
    notifiers.notify_update(res)
Exemplo n.º 4
0
def update(command, cursor, connection):
    col = commons.get_unset_fields(command, columns, table_name, cursor)
    if len(command) >= 2:
        args = cursor.callproc(
            'SALARIES_tapi.upd',
            (int(parameter_getters.get_parameter_col(command, "-w", col)),
             int(parameter_getters.get_parameter_col(command, "-v", col)),
             int(parameter_getters.get_parameter_col(command, "-s", col)),
             int(parameter_getters.get_parameter_col(command, "-c",
                                                     col)), int(command[1])))
        res = int(args[4])
        connection.commit()
    notifiers.notify_update(res)
Exemplo n.º 5
0
def update(command, cursor, connection):
    col = commons.get_unset_fields(command, columns, table_name, cursor)
    if len(command) >= 2:
        args = cursor.callproc(
            'PREMIUMS_SIZES_tapi.upd',
            (int(parameter_getters.get_parameter_col(command, "-min", col)),
             int(parameter_getters.get_parameter_col(command, "-max", col)),
             parameter_getters.get_parameter_col(command, "-d", col),
             command[1], parameter_getters.get_parameter_col(
                 command, "-n", col)))
        res = int(args[3])
        connection.commit()
    notifiers.notify_update(res)