wordcamp.org icon indicating copy to clipboard operation
wordcamp.org copied to clipboard

Pre-fill fields for wcdocs

Open ghost opened this issue 8 years ago • 21 comments

Imported from https://meta.trac.wordpress.org/ticket/3199 Created by @ePascalC:

Both the 'Attendee Visa letter' and 'Speaker Visa letter' are asking for information that is always the same for any request for the same WordCamp. Fields like 'WordCamp Name, WordCamp Location, WordCamp Date Start, WordCamp Date End, Organizer Name, Organizer Contacts' are the same for every Visa letter request so could be added on a 'settings' page or tab at the start of /wp-admin/admin.php?page=wcdocs

It would save time for bigger WordCamps like WCEU where several requests come in. It would also avoid spelling mistakes, decrease human errors and increase the overall consistency of the documents per WordCamp.

Using wcpt_get_wordcamp_location() to get the information might even be a better way, but for now just some fields to fill the info once would already be great.

ghost avatar Oct 16 '17 14:10 ghost

Comment by @coreymckrill:

  • Keywords set to Needs Patch Good First Bug

I agree, this would be a helpful addition. I think get_wordcamp_post(), located in mu-plugins/helper-functions.php would make it fairly easy to grab all the necessary values for pre-populating the fields.

ghost avatar Oct 16 '17 19:10 ghost

Comment by @ePascalC:

  • Keywords set to Good First Bug Has Patch

Both Speaker and Attendee Visa letter have been adapted. Data is taken using get_wordcamp_post().

This is my first .diff so please doublecheck that it's correct. Thanks.

ghost avatar Oct 18 '17 15:10 ghost

Comment by @ePascalC:

ghost avatar Oct 18 '17 15:10 ghost

Comment by @grapplerulrich:

After just reviewing the code I saw a few things.

  • name="attendee_last_name" should be changed too in speaker-visa.php
  • A small coding standard issue. I would add a space between ! and empty in !empty

Otherwise it looks good!

ghost avatar Oct 19 '17 06:10 ghost

Comment by @ePascalC:

Changed as requested

ghost avatar Oct 20 '17 19:10 ghost

Comment by @ePascalC:

Patch 3199.2 has the changes as requested.

ghost avatar Oct 20 '17 19:10 ghost

Comment by @grapplerulrich:

The changes look good. I have tested them locally too and was able to generate a PDF with the changes.

As we are adding changes we could add the WordCamp Location and WordCamp Date to the sponsor agreement too.

ghost avatar Oct 21 '17 16:10 ghost

Comment by slackbot:

This ticket was mentioned in Slack in #meta-wordcamp by iandunn. View the logs.

ghost avatar Oct 24 '17 19:10 ghost

Comment by @iandunn:

In [6053]:

WordCamp Docs: Rename speaker fields from "attendee" to "speaker".

This template was copied and pasted from the attendee template, and the fields were not updated at the time.

See https://meta.trac.wordpress.org/ticket/3199
Props casiepa, grapplerulrich

ghost avatar Oct 25 '17 14:10 ghost

Comment by @iandunn:

  • Status set to closed
  • Resolution set to fixed
  • Owner set to @iandunn

In [6054]:

WordCamp Docs: Pre-populate Speaker and Attendee visas.

Fixes https://meta.trac.wordpress.org/ticket/3199
Props casiepa, grapplerulrich

ghost avatar Oct 25 '17 14:10 ghost

Comment by @iandunn:

  • Keywords set to Good First Bug Needs Patch
  • Status set to reopened
  • Resolution cleared

Thanks @ePascalC and @grapplerulrich

I'm actually going to re-open this, since we can also populate the fields for the sponsorship agreement, and also pull in the organizer contact info for all the templates.

ghost avatar Oct 25 '17 14:10 ghost

Comment by @ePascalC:

So what is missing for the sponsorship agreement is:

  • The h2 title
  • The 'WordCamp Date' (which would be a combination of start and end date)
  • The 'WordCamp Location'

But @iandunn what do you mean by 'organizer contact info' ? I suppose you mean the last box of the Visa forms? What meta data should go in there, would that be the 'Contact Information' one (see screenshot)? [[Image()]]

ghost avatar Oct 25 '17 15:10 ghost

Comment by @ePascalC:

ghost avatar Oct 25 '17 15:10 ghost

Comment by @iandunn:

That's right. It'd be the E-mail Address field (not Email Address without the hyphen).

ghost avatar Oct 25 '17 16:10 ghost

Comment by slackbot:

This ticket was mentioned in Slack in #meta-wordcamp by iandunn. View the logs.

ghost avatar Apr 02 '20 17:04 ghost

This would be super cool for WordCamp Organizers to pre-fill fields for WC Docs. Just referring to the recent discussion in #meta-wordcamp channel in regards to WordCamp Asia 2023

chaion07 avatar Aug 16 '22 04:08 chaion07

@chaion07 I'm on it and the first prototype is ready! That said, I followed a slightly different approach. Instead of pre-filling for internal form, I hooked into the Jetpack form directly.

This is what I did so far:

  • I created a Jetpack form that enables attendees to request an Attendee Visa Letter.
  • I created an option section under WP Admin » Tools, to allow organisers to specify on which page the request form is located and how the field names are called.
  • When someone requests an Attendee Visa Letter, I check if the requester holds a valid ticket to the corresponding WordCamp.
  • If the requester holds a valid ticket, the Attendee Visa Letter including the name, country of origin and passport number gets sent to the requester.
  • If the requester does not hold a valid ticket, an email gets sent to the requester informing them that there's no valid ticket assigned to the email address they submitted, asking them to double-check their email address or to contact the corresponding WordCamp organiser team.

So, instead of pre-filling internal form fields, to lower the manual workload for organisers, I completely bypassed that, by enabling attendees to request and receive the wanted Attendee Visa Letter without any manual involvement of the WordCamp organising team.

nielslange avatar Aug 16 '22 23:08 nielslange

@nielslange did you get something ready for PR?

timiwahalahti avatar Jul 29 '23 03:07 timiwahalahti

@nielslange did you get something ready for PR?

I don't, @timiwahalahti. For WordCamp Asia, I created a custom WordPress plugin, which is not suitable for the general WordCamp multisite. Please don't hesitate to take over this issue.

nielslange avatar Jul 29 '23 14:07 nielslange

@nielslange, your solution will be a real time saver, but also it's important for each WordCamp to be able to personalize them and make them look professional, non-generic, and compliant with their national immigration authority's policies for visa letters. Particularly in Canada and the US, it has become harder to get visas, and the people requesting them are being advised and aware that they need a non-generic letter of support. There are specific recommendations for how tourist vs. business visa letters should be written that are likely to be somewhat different from country to country. I've addressed this in the Canadian context here: https://github.com/WordPress/wordcamp.org/issues/1510

dknauss avatar Oct 27 '25 16:10 dknauss

@dknauss Feel free to take over this issue.

nielslange avatar Oct 31 '25 07:10 nielslange