Пример #1
0
def add():
    id = console.input_int("id: ")
    name = console.input_str("name: ")
    price = console.input_float("price: ")
    customer_ui.show_all()
    print("--Pick one--")
    customer_id = console.input_int("customer_id: ")
    asd = console.input_str("asd: ")
    item_object = item_model.Item( id, name, price, customer_id, asd)
    item_model.save(item_object)
Пример #2
0
def update():
    show_all()
    print("Enter id of product you want to update.")
    id = console.input_int("id: ")
    name = console.input_str("name: ")
    price = console.input_float("price: ")
    customer_id = console.input_int("customer_id: ")
    asd = console.input_str("asd: ")
    item_object = item_model.Item( id, name, price, customer_id, asd)
    item_model.update(item_object)
Пример #3
0
def update():
    show_all()
    print("Enter id of product you want to update.")
    id = console.input_int("id: ")
    name_pers = console.input_str("name_pers: ")
    AgesAll = console.input_int("ages_all: ")
    hobby = console.input_bool("hobby: ")
    heh = console.input_bool("heh: ")
    customer_object = customer_model.Customer(id, name_pers, AgesAll, hobby,
                                              heh)
    customer_model.update(customer_object)
Пример #4
0
def add():
    id = console.input_int("id: ")
    name_pers = console.input_str("name_pers: ")
    item_ui.show_all()
    print("--Pick one--")
    ages_all = console.input_int("ages_all: ")
    hobby = console.input_bool("hobby: ")
    heh = console.input_bool("heh: ")
    customer_object = customer_model.Customer(id, name_pers, ages_all, hobby,
                                              heh)
    customer_model.save(customer_object)
Пример #5
0
def add():
    id = console.input_int("id: ")
    price = console.input_float("price: ")
    asd = console.input_str("asd: ")
    uff = console.input_str("uff: ")
    hey_object = hey_model.Hey( id, price, asd, uff)
    hey_model.save(hey_object)
Пример #6
0
def update():
    show_all()
    print("Enter id of product you want to update.")
    id = console.input_int("id: ")
    price = console.input_float("price: ")
    asd = console.input_str("asd: ")
    uff = console.input_str("uff: ")
    hey_object = hey_model.Hey( id, price, asd, uff)
    hey_model.update(hey_object)
Пример #7
0
def remove():
    show_all()
    id = console.input_int("Enter id of item you want to remove: ")
    item_model.remove(id)
Пример #8
0
def remove():
    show_all()
    id = console.input_int("Enter id of customer you want to remove: ")
    customer_model.remove(id)
Пример #9
0
def remove():
    show_all()
    id = console.input_int("Enter id of hey you want to remove: ")
    hey_model.remove(id)