def add_command(): backend.insert(title_text.get(), author_text.get(), year_text.get(), bookid_text.get()) list1.delete(0, END) #Clears the list box. list1.insert(END, (title_text.get(), author_text.get(), year_text.get(), bookid_text.get()))
def add_command(): backend.insert(title_text.get(), course_text.get(), due_text.get(), details_text.get()) list1.delete(0, END) list1.insert(END, (title_text.get(), course_text.get(), due_text.get(), details_text.get()))
def add_command(): backend.insert(client_text.get(), carrier_text.get(), status_text.get(), date_text) clear_command() view_command()
def add_command(): backend.insert(entry_title.get(), entry_author.get(), entry_year.get(), entry_id.get()) list1.delete(0, END) #limpia la lista list1.insert(END, entry_title.get(), entry_author.get(), entry_year.get(), entry_id.get())
def add_command(): backend.insert(name_text.get(), types_text.get(), quantity_text.get(), price_text.get()) list1.delete(0, END) list1.insert(END, (name_text.get(), types_text.get(), quantity_text.get(), price_text.get()))
def Add_entry(): backend.insert(Title_value.get(), Author_value.get(), Year_value.get(), ISBN_value.get()) lb1.delete(0, END) lb1.insert(END, (Title_value.get(), Author_value.get(), Year_value.get(), ISBN_value.get()))
def add_command(): backend.insert(title_text.get(), Author_text.get(), Year_text.get(), ISBN_text.get()) list1.delete(0, END) list1.insert(END, (title_text.get(), Author_text.get(), Year_text.get(), ISBN_text.get()) #delete entries def delete_command(): backend.delete(selected_tuple[0]) #update def update_command(): backend.update(selected_tuple[0],title_text.get(), Author_text.get(), Year_text.get(), ISBN_text.get() ) window=Tk() window.wm_title("Bookstore") l1=Label(window, text="Title") l1=Grid(row=0, column=0) l2=Label(window, text="Author") l2=Grid(row=0, column=0) l3=Label(window, text="Year") l3=Grid(row=0, column=0) l4=Label(window, text="ISBN") l4=Grid(row=0, column=0) Title_text=StringVar() e1=Entry(window, textvariable=Title_text) e1=Grid(row=0, column=1) Author_text=StringVar() e2=Entry(window, textvariable=Author_text) e2=Grid(row=0, column=3) Year_text=StringVar() e1=Entry(window, textvariable=Year_text) e1=Grid(row=1, column=1) ISBN_text=StringVar() e1=Entry(window, textvariable=ISBN_text) e1=Grid(row=1, column=3) list1=Listbox(window, height=6,width=35) list1.grid(row=2, column=0, rowspan=6,columnspan=2) sb1=Scrollbar(window) sb1.grid(row=1,column=3) list1.configure(yscrollcommand=sb1.set) sb1.configure(command=list1.yview) list1.bind('<<ListboxSelect>>', get_selected_row) b1=Button(window,text="View All", width=12, command=view_command) b1=Grid(row=2, column=3) b2=Button(window,text="Search entry", width=12, command=search_command) b2=Grid(row=3, column=3) b3=Button(window,text="Add Entry", width=12, command=add_command) b3=Grid(row=4, column=3) b4=Button(window,text="Update selected", width=12, command=update_command) b4=Grid(row=5, column=3) b5=Button(window,text="Delete selected", width=12, command=delete_command) b5=Grid(row=6, column=3) b6=Button(window,text="close", width=12) b6=Grid(row=7, column=3) window.mainloop()
def add(): backend.insert(titleText.get(), authorText.get(), yearText.get(), isbnText.get())
def add_command(): backend.insert(title_text.get(), publisher_text.get(), year_text.get(), upc_text.get()) list_box.delete(0, END) list_box.insert(END, (title_text.get(), publisher_text.get(), year_text.get(), upc_text.get()))
def addData(self, data): db = str(self.dbs[self.databaseDropdown.currentIndex()]) collection = str(self.collectionDropdown.currentText()) result = backend.insert(db, collection, data) self.findData()
def home(): forma=None iid=None res=backend.view() forma=request.args.get('form') # from datetime import datetime # import pandas as pd if forma not in [None, 'None']: import ast forma=ast.literal_eval(forma) # forma[3] = datetime.strptime(forma[3], '%Y-%m-%d') # forma[3] = pd.to_datetime(forma[3], '%Y-%m-%d', error='coerce') # if len(forma)>4: print('d', forma[3]) # print('f', forma) if request.form: if request.method == 'POST': i_name = request.form.get('name') i_surname = request.form.get('surname') i_id = request.form.get('id') i_mother = request.form.get('mother_id') i_father = request.form.get('father_id') i_spouse = request.form.get('spouse_id') i_gen = request.form.get('gen_id') if isnull(i_mother) or i_mother==0: i_mother=None if isnull(i_father) or i_father==0: i_father=None if isnull(i_spouse) or i_spouse==0: i_spouse=None if isnull(i_gen) or i_gen==0: i_gen=None i_dob = request.form.get('dob') i_dod = request.form.get('dod') i_pob = request.form.get('PoB') i_cob = request.form.get('CoB') i_col = request.form.get('CoL') i_gender = request.form.get('gender') i_cluster= request.form.get('cluster') i_com= request.form.get('com') if request.form['submit_button'] == 'insert': backend.insert(i_id, i_name, i_surname, i_dob, i_dod, i_mother, i_father, i_spouse, i_gen, i_cluster, i_gender, i_pob, i_cob, i_col, i_com) res=backend.view() elif request.form['submit_button'] == 'view': res=backend.view() # print (res) pass # do something else elif request.form['submit_button'] == 'draw': draw_tree() print(1) # print (res) pass elif request.form['submit_button'] == 'update': backend.update(i_id, i_name, i_surname, i_dob, i_dod, i_mother, i_father, i_spouse, i_gen, i_cluster, i_gender, i_pob, i_cob, i_col, i_com) res=backend.view() # print (res) pass # do something else else: pass # unknown return render_template("home.html", res=res, tbl='table.html', iid=iid, form=forma)
def add_command(): backend.insert(name.get(), roll.get(), section.get(), country.get()) list1.delete(0, END) list1.insert(END, (name.get(), roll.get(), section.get(), country.get()))
def add_command(self): backend.insert(self.contact_name.get(), self.contact_number.get()) self.list1.delete(0, END) self.list1.insert(END, (self.contact_name.get(), self.contact_number.get()))
def add_entry(): backend.insert(calc()[0], calc()[1]) view_all()
def insert(): backend.insert(title_e.get(), author_e.get(), year_e.get(), isbn_e.get()) view()
def to_add_task(): backend.insert(only_date,Task_Title.get(), Task_Detail.get(),Status.get()) print(backend.view())
def add_command(): backend.insert(name_text.get(), organization_text.get(), phone_text.get(), group_text.get()) list1.delete(0, END) list1.insert(END, (name_text.get(), organization_text.get(), phone_text.get(), group_text.get()))
def addBook(): (title, author, year, isbn) = getData() backend.insert(title, author, year, isbn) clearAllTextBox() viewBook() t1.focus()
def insert_command(): backend.insert(str(title_text.get()),author_text.get(),year_text.get(),isbn_text.get())
def add_command(): backend.insert(date_text.get(),earning_text.get(),exercise_text.get(),study_text.get(),diet_text.get(),coding_text.get()) list.delete(0,END) list.insert(END,(date_text.get(),earning_text.get(),exercise_text.get(),study_text.get(),diet_text.get(),coding_text.get()))
def add_command(): backend.insert(title= title_text.get(), author=author_text.get(), year=year_text.get(), isbn=isbn_text.get()) resultsBox.delete(0,END) resultsBox.insert(END, (title_text.get(),author_text.get(), year_text.get(), isbn_text.get()))
def add_command(): backend.insert(first_name_text.get(), last_name_text.get(), email_text.get(), age_text.get()) listbox_all_data.delete(0, END) listbox_all_data.insert(END, (first_name_text.get(), last_name_text.get(), email_text.get(), age_text.get()))
def insert_command(): backend.insert(title_text.get(), year_text.get(), author_text.get(), ISBN_text.get()) list1.delete(0, END) list1.insert(END, (title_text.get(), year_text.get(), author_text.get(), ISBN_text.get()))
def add_command(): backend.insert(e1.get(), e2.get(), e3.get(), e4.get()) l.delete(0, END) l.insert(END, (e1.get(), e2.get(), e3.get(), e4.get()))
def add_cmd(): backend.insert(e1_val.get(),e2_val.get(),e3_val.get(),e4_val.get()) list1.delete(0,END) list1.insert(END,(e1_val.get(),e2_val.get(),e3_val.get(),e4_val.get())) # to see the newly added entry
def insert_command(): #INSERT SOMETHING IN THE LIST backend.insert(title_text.get(), author_text.get(), year_text.get(), isbn_text.get()) list1.delete(0, END) list1.insert(END, (title_text.get(), author_text.get(), year_text.get(), isbn_text.get()))
def add_command(): c1.delete(0, END) backend.insert(a2_value.get(), a4_value.get(), b2_value.get(), b4_value.get()) c1.insert(END, (a2_value.get(), a4_value.get(), b2_value.get(), b4_value.get()))
def add_command(): backend.insert(title_text.get(), author_text.get(), year_text.get(), isbn_text.get()) list1.delete(0, END) list1.insert(END, (title_text.get(), author_text.get(), year_text.get(), isbn_text.get()))
def addFunction(): list1.delete(0, END) backend.insert(e1.get(), e3.get(), e2.get(), e4.get()) list1.insert(END, (e1.get(), e3.get(), e2.get(), e4.get()))
def add_command(): backend.insert(title_text.get(),author_text.get(),year_text.get(),isbn_text.get()) list1.delete(0,END) list1.insert(END,(title_text.get(),author_text.get(),year_text.get(),isbn_text.get()))
def add_entry_command(): list_box.delete(0,END) backend.insert(title_text_entry.get(),author_text_entry.get(),year_text_entry.get(),isbn_text_entry.get()) list_box.insert(END,(title_text_entry.get(),author_text_entry.get(),year_text_entry.get(),isbn_text_entry.get()))