GravityKit / GravityView

The best and easiest way to display Gravity Forms entries on your website.
https://www.gravitykit.com/products/gravityview/
245 stars 63 forks source link

Add a Merge Tag modifier to the Entry moderation Merge Tags to output the URL only #1986

Closed rafaehlers closed 1 day ago

rafaehlers commented 7 months ago

There's no way at this moment to just output the URL for the entry moderation merge tags.

This will be useful for so many use cases, including generating a QRCode, as requested by a user.

Related: https://github.com/GravityKit/GravityView/blob/develop/includes/class-gravityview-entry-approval-merge-tags.php#L227

floatytheastronaut commented 7 months ago

FreeScout #77233.
https://support.gravitykit.com/conversation/77233?folder_id=1

mrcasual commented 5 months ago

Implemented in fa45dce5f.

rafaehlers commented 1 month ago

@mrcasual This never worked:

On a form notification: image

image

Inside a custom content field: image

image

Tested on GV 2.27.1

mrcasual commented 1 month ago

@rafaehlers,the issue wasn't clear about adding a new (:url) merge tag modifier. Your "related" code link pointed to where the merge tag can be modified using a filter, and that's what was done here as well. It would have worked for the customer who asked for this. This is consistent with how we modify other links (e.g., gk/gravityview/widget/search/clear-button/params).

add_filter( 'gk/gravityview/entry/approval-link/params', function ( $params ) {
    $params['format'] = 'text';

    return $params;
} );

If a new merge tag modifier is needed, please update the issue with more details and I'll implement that.

mrcasual commented 1 month ago

@rafaehlers, implemented by 5565cca14. Please test.

rafaehlers commented 1 day ago

It works! Customer notified ✅