Lacking may record key on sub-record page

I have a main record page that looks like this and allows the user to either edit main (Clean Start) record or add/edit one of the sub-records:

Scott_Nesbitt_0-1644271531861.png

When I click on one of the icons it takes me to a sub page like this:

Scott_Nesbitt_1-1644271599813.png

However, when I click on the + to create a new record I do not have access to the main record key, Customer Id.  Any suggestions on the best way to resolve this?  Perhaps stuff the key in the UX somehow? (At least, that is what I would do if there were a real webpage.)

Thanks,

Scott

Solved Solved
0 15 147
1 ACCEPTED SOLUTION

HBT
Silver 4
Silver 4

LINKTOFILTEREDVIEW("Site Logistics_Form",[Customer ID]=[_THISROW]) if you write this formula in action, child records of related parent record are displayed. Afterwards, if you add a record with the add button, the parentID will appear in the form.

View solution in original post

15 REPLIES 15

A few questions..

When you say you do not have access to the main record key, what do you mean? I would assume the customer id of your sub table is a ref column to the main (customer) table. And if so, you should be able to get a list of customers to select from more or less automatically..

If you show you column definition (esp. of your cutomer id of the sub table)  it would probably make your issue more visible.

Yes, for my Site Logistics sub-table I have a Customer Id reference to the main table.  When I say I don't have access, I mean that in the create new Site Logistics action I don't have access to the parent key (have to hard-code this to work):  LINKTOFORM("Site Logistics_Form", "Customer Id", "f4d8447d")  Here is the top part of the sub record:

Scott_Nesbitt_0-1644328350806.png

Thanks

You may want to share what kind of expression you are using to navigate to the "inline_View" , in general you could use LINKTOFORM() or LINKTOFILTEREDVIEW() deep links in such a case instead of using system generated "Add" action that will open a fresh new form.

https://help.appsheet.com/en/articles/1023058-app-column-type-deep-link

This is how I get to the inline view: LINKTOFILTEREDVIEW(Site Logistics_Inline, [Customer Id] = [_THISROW].[Customer Id])

Are you saying I _do_ have access to the Customer Id here even when there are no sub-records?

You could have the add record action as an inline action with LINKTOFRORM() deep link on the Site_logistic record tables in the table view.

Yes, I do have the add record action as this:   LINKTOFORM("Site Logistics_Form", "Customer Id", "f4d8447d")

However, I have to hard-code the Customer Id as I don't have access to that in the sub-record view (unless you know of a way to get that).

Thanks

I am sorry that I am not getting your query.  If you build LINKTOFORM with 

LINKTOFORM( "Site Logistics_Form", "Customer ID", [Customer ID], .....) I believe you should get it. If you build this action as an inline action.

Just tried that, no luck.  The icon does not even show up, indicating that the Customer Id value is not valid.  This actually makes sense since there is no Site Logistics row yet.  😞

So the question becomes: Can table view of sub-records have access to the reference to the main record?  If not, I don't see how to create new sub-records with the correct link in this kind of view.

Could you please mention what table you are trying to set the action, what is the action goal and how you are trying to set it up? Relevant screenshots will help.

Actually, this issue is resolved.  I just had to use the LINKTOFILTEREDVIEW() the way HBT suggested and use the default add record icon.  Thanks for your help.

Yes, sorry I saw that the issue is resolved and @HBT  provided the solution after I posted the reply. In general I had also suggested using LINKTOFILTEREDVIEW() in the beginning. 

"You may want to share what kind of expression you are using to navigate to the "inline_View" , in general you could use LINKTOFORM() or LINKTOFILTEREDVIEW() deep links in such a case instead of using system generated "Add" action that will open a fresh new form."

Anyway nice to see you got the solution.

HBT
Silver 4
Silver 4

LINKTOFILTEREDVIEW("Site Logistics_Form",[Customer ID]=[_THISROW]) if you write this formula in action, child records of related parent record are displayed. Afterwards, if you add a record with the add button, the parentID will appear in the form.

Ah, that did it!  Thank you so much, HBT!  (For reference, I was trying to create a custom add icon and that does _not_work.  For some reason, only the system generated add action created the correct link.)  Thanks again, was stuck on that for three days.

I know that problems are difficult to solve, and I know that unless I can solve them, it becomes an obsession. Good luck with.

 

Top Labels in this Space