GravityPDF / gravity-pdf

Gravity PDF is a GPLv2-licensed WordPress plugin that allows you to automatically generate, email and download PDF documents using Gravity Forms.
https://gravitypdf.com
88 stars 21 forks source link

Give Nested Forms Entries a Unique ID #1409

Closed jakejackson1 closed 2 years ago

jakejackson1 commented 2 years ago

Description

The HTML markup generated for fields includes the standard ID "field-#". Inside the Nested Forms field, there could be multiples of the same ID. This PR ensures that all IDs are unique for Nested Form fields.

Testing instructions

  1. Setup a Parent / Child form with the Nested Forms add-on
  2. Create PDF on the Parent form
  3. Submit test entry with multiple child entries
  4. View source code of generated PDF and ensure no ID conflicts for the Nested Form fields output

Follow above steps for the native Repeater field and check no conflicts.

Screenshots

Checklist:

Additional Comments

codecov[bot] commented 2 years ago

Codecov Report

Merging #1409 (144f5d6) into development (493b8d5) will increase coverage by 15.96%. The diff coverage is n/a.

:exclamation: Current head 144f5d6 differs from pull request most recent head ae1432a. Consider uploading reports for the commit ae1432a to get more accurate results

@@                Coverage Diff                 @@
##             development    #1409       +/-   ##
==================================================
+ Coverage          77.34%   93.30%   +15.96%     
==================================================
  Files                243       57      -186     
  Lines              10107     1464     -8643     
  Branches             370      370               
==================================================
- Hits                7817     1366     -6451     
+ Misses              2282       90     -2192     
  Partials               8        8               
Impacted Files Coverage Δ
src/Helper/Fields/Field_Form.php
src/Helper/Fields/Field_Repeater.php
src/View/html/FormSettings/add_edit.php
src/Helper/Helper_Notices.php
src/Helper/Fields/Field_Post_Content.php
src/Helper/Fields/Field_Slim_Post.php
src/Helper/Fields/Field_V3_Products.php
src/Helper/Helper_Interface_Setup_TearDown.php
src/Model/Model_Actions.php
src/View/html/PDF/page_title.php
... and 176 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

jakejackson1 commented 2 years ago

Notify HS with tags nested-forms-blank

jestonihpi commented 2 years ago

I will review this now @jakejackson1.