Hi Dennis
You should be able to get the edit link from active_scaffold_config:
active_scaffold_config.action_links[:edit]
And the record should be in @record variable.
Then you can add to your view:
<%= render_action_link(active_scaffold_config.action_links[:edit], @record,
authorized: true) %>
It will work if you opened the show action with JS, below the row on the table
list. If you opened the show action with the page: true setting in show
action_link, or clicking open in new path, I think the JS won't work to
display the row, as I think it looks for the row.
Other way would be mimic the html generated by the AS helper,
render_action_link:
<%= link_to "(Edit SubTDN)", edit_sub_tdn_path(adapter:
'_list_inline_adapter'), class: "button as_action", data: {position: :after},
remote: true %>
Regards
El domingo, 2 de abril de 2023 6:33:16 (CEST) Dennis Bulgatz escribió:
> HI Sergio,
>
> I was not able to understand what you meant below.
>
> In my view, I currently have this call to render a show HTML link:
> <%= link_to "(Edit SubTDN)", edit_sub_tdn_path(adapter:
> '_list_inline_adapter'), class: "button" %>
>
> Not sure what object I’d pass for a link in render_action_link(link, record,
> :authorized => true).
>
> I could not find the API call “display_link_in_show?” you mentioned. Could
> you possibly send a git link? I was looking
> here<
https://www.rubydoc.info/gems/active_scaffold_san/ActiveScaffold/Helpe
> rs/ViewHelpers#get_action_link_id-instance_method>.