Announcements
This site is in read only until July 22 as we migrate to a new platform; refer to this community post for more details.

Scan barcode to edit specific row in a database

Hey guys,

So I'm building an app to track containers for a small logistics company.

I've set up a DB called Container Master Ledger with columns: ContainerID, Drop Time, Drop Location, Dropped by, Customer Name, Pickup Time, Picked Up By, Processed Time, Weight in Container, Image of Organics, and Image of Contamination.

When we drop empty containers to a customer I have set up an action to open a form prefilled with Drop Time, Drop Location, Dropped By and Customer Name then the ContainerID column is filled with the info from the barcode when it is scanned. When the form is submitted this writes the above data to those columns. 

Now, when we pick up containers from each venue, I would like to be able to scan the barcodes of the containers that were previously dropped (which are now full) and be taken to another form that can write to Pickup Time (with a timestamp) and Picked Up By (from useremail() for instance).

Then when we go to 'process' the container when we have finished collecting them all, I would like to be able to scan the barcode AGAIN and fill out a form to complete the row in the ledger  by writing to Processed Time, Weight in Container, Image of Organics and Image of Contamination.

I have tried to achieve this with combinations of linktoform, linktorow etc. but can't seem to work it out. I'm SURE there's a way to do it and I'm hoping someone might have an elegant solution or can help me write the appropriate expression/s to fill out a row of a ledger in three separate stages.

Any help would be much appreciated 😄

Solved Solved
0 4 616
1 ACCEPTED SOLUTION


@joshuacaddysnew wrote:

I would like to be able to scan the barcode AGAIN and fill out a form to complete the row in the ledger  by writing to Processed Time, Weight in Container, Image of Organics and Image of Contamination.


If understanding of your requirement is correct, I believe you essentially want to search an existing record again using the bar code and fill out some remaining fields in the record. If so, one of the easier options would be to use the Search bar at the top of the app screen to scan the bar code and load the record that you are looking for in the summary view. From the selected record through the search bar, you can then easily navigate to the form view to fill up the remaining fields of the record.

The image below shows search bar has scan option enabled because the record contains a bar code scannable field.

Suvrutt_Gurjar_0-1671890997014.png

 

 

View solution in original post

4 REPLIES 4


@joshuacaddysnew wrote:

I would like to be able to scan the barcode AGAIN and fill out a form to complete the row in the ledger  by writing to Processed Time, Weight in Container, Image of Organics and Image of Contamination.


If understanding of your requirement is correct, I believe you essentially want to search an existing record again using the bar code and fill out some remaining fields in the record. If so, one of the easier options would be to use the Search bar at the top of the app screen to scan the bar code and load the record that you are looking for in the summary view. From the selected record through the search bar, you can then easily navigate to the form view to fill up the remaining fields of the record.

The image below shows search bar has scan option enabled because the record contains a bar code scannable field.

Suvrutt_Gurjar_0-1671890997014.png

 

 

Hello @Suvrutt_Gurjar 

That works great but what if I only want the user to see and edit the one record from the scan and not have access to the entire list of records?

The details of your requirement are not clear. In general when restricting user to a certain set of records, either slices or security filters are used based on the use case. Slices are less secure and security filters are secure option.

Please take a look at the section "Security filters versus table slices" in the article below

Scale using security filters - AppSheet Help

Security filters: The Essentials - AppSheet Help

Slices: The Essentials - AppSheet Help

 

 

 

Thank you @Suvrutt_Gurjar ,

I have searched all over but couldn't find a proper guide for my requirements. 

Basically what I wanted to do was give a screen where a user can scan a QR code and get access to only that ONE record with the ability to edit some of its fields depending on the user's permissions. 

I finally figured out so I will create a new topic so I can share my findings and tag you

Top Labels in this Space