Fixed index error

This commit is contained in:
Josh Biltonen 2022-11-10 17:41:27 -08:00
parent 3af683acf5
commit 319566ab0f
2 changed files with 2 additions and 2 deletions

View File

@ -1 +1 @@
{"_default": {"1": {"Serial Number": "123", "Brand": "d", "Grade": "7", "Name": "jb"}, "2": {"Serial Number": "1", "Brand": "2", "Grade": "3", "Name": "4"}}} {"_default": {}}

View File

@ -122,7 +122,7 @@ def main():
) )
window["table"].update(format_table(result)) window["table"].update(format_table(result))
elif event == "table": elif event == "table" and values["table"]:
row=window["table"].get()[values["table"][0]] row=window["table"].get()[values["table"][0]]
window["Serial Number"].update(row[0]) window["Serial Number"].update(row[0])
window["Brand"].update(row[1]) window["Brand"].update(row[1])