Example #1
0
 def ser_item(self):
     """search for food item to order"""
     search = self.item_ser.get()
     self.item_tree.delete(*self.item_tree.get_children())
     item = Item()
     data = item.search_item(search)
     for i in data:
         self.item_tree.insert("",
                               "end",
                               text=i[0],
                               value=(i[0], i[2], i[1], i[3]))
Example #2
0
 def ser_item(self):
     """search for item in menu"""
     search = self.item_ser.get()
     self.item_tree.delete(*self.item_tree.get_children())
     item = Item()
     data = item.search_item(search)
     for i in data:
         self.item_tree.insert("",
                               "end",
                               text=i[0],
                               value=(i[2], i[1], i[3]))
     self.item_tree.bind("<Double-1>", self.select_item)