Sorry for delay in responding.
What I found is that the drop-down is populated from employee_list which is effectively the Company_Representative column from the Company Info table.
You then search the clockinoutsystem table using the value from your dropdown, i.e. the company_representative.
At least at the time of cloning, the “company representatives” I selected from the drop-down had no data associated with them in the ClockInOutSystem, so the repeating panel had no data.
I just tried your app, and put myself in charge of “Garoot Marketing” (by adding my email to the Email column and making myself a user with that email), and leo@gmail.com data showed up as expected:
Firstly, kudos - this isn’t a trivial app you’ve built out here so well done. I’ll make a suggestion though: You store a lot of data as strings that can be stored either as a link or a simple object.
- You store Company_Representative as a comma-delimited string and parse that in your code. You can simply store it as a list of strings in a simple object column.
- You exclusively store refence to Users as their email in string format. You’re better off storing a reference to a user row. Similarly, if users are always part of a company, you can link to the company from their row.
If you implemented these recommendations, the following code:
employee = [(str(d['Company_Representatives']),d) for d in app_tables.company_info.search(Email=self.user_name.text)]
employee_list = []
for t in employee:
employee_list.extend(t[0].split(','))
self.drop_down_employees.items = employee_list
would be reduced to:
self.drop_down_employees.items = anvil.user.get_user()['company_link']['Company_Representatives']
Or, if Company_Representatives was a multiple reference to the users table:
reps = anvil.user.get_user()['company_link']['Company_Representatives']
self.drop_down_employees.items = [(rep['email'], rep) for rep in reps]
And the drop_down_employees.selected_item
would return a user row, which you could use for subsequent searching etc. I guarantee this would help with your debugging as well.