Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add WPTV URL meta field #143

Merged
merged 11 commits into from Apr 26, 2023
Merged

Add WPTV URL meta field #143

merged 11 commits into from Apr 26, 2023

Conversation

renintw
Copy link
Collaborator

@renintw renintw commented Mar 22, 2023

Fixes #1003

This PR

  • Add a new meta field, the WPTV URL, with a text field form with URL validation.
  • Add View recording link to the modal. The URL would be to the wordpress.tv item entered in the meta field.

Screenshots

Edit Screen

image

Meeting List

Screen Shot 2023-03-23 at 4 16 16 AM

Modal

Screen Shot 2023-03-23 at 3 59 20 AM

List

List items would not show in Learn, but might show in other places. e.g., https://make.wordpress.org/meetings/

Screen Shot 2023-03-23 at 3 59 09 AM

ICS Import

ics

Testing instructions

  1. Add the plugin meeting-calendar and activate it.
  2. Go to /wp-admin/edit.php?post_type=meeting. There should be three default meetings.
  3. On the meeting list and edit screen, there should be a new field WPTV URL.
  4. If you're adding the plugin to Learn, then go to /online-workshops/. Otherwise, create a post and add a meeting block.
  5. Click on any of the meetings, then the modal would show up. View Recording should be there.
  6. Click List, in devTools -> Element, search wporg-meeting-calendar__list-event-copy, and unclick the display: none (in Learn, it was set invisible), View Recording should be there.
  7. Click iCal, and import to your calendar, should see all three meetings are added and show the corresponding info.

TODO

Fix PHPCS errors - WP PHPCS is updated to PHP8.0+. Some function usage standards have changed.

Update
PR to fix the issue is opened: #144

Update

Closed #144 (See reason there) and fixed in Fix PHPCS error.

@renintw renintw force-pushed the add/WPTV-URL-meta-field branch 7 times, most recently from e49681f to b56db01 Compare March 22, 2023 21:34
@renintw renintw changed the title Add/wptv url meta field Add wptv url meta field Mar 22, 2023
@renintw renintw changed the title Add wptv url meta field Add WPTV URL meta field Mar 22, 2023
@renintw renintw requested a review from adamwoodnz March 22, 2023 21:38
@renintw renintw self-assigned this Mar 22, 2023
@renintw renintw added the enhancement New feature or request label Mar 22, 2023
@renintw renintw force-pushed the add/WPTV-URL-meta-field branch 5 times, most recently from 9f5f754 to b56db01 Compare March 23, 2023 20:43
@adamwoodnz
Copy link

@renintw could you please add some testing instructions? 🙏

@renintw
Copy link
Collaborator Author

renintw commented Mar 23, 2023

@renintw could you please add some testing instructions? 🙏

@adamwoodnz I've updated it in the description.

Some more setting info in case you need it!
I was adding meeting-calendar to Learn by cloning it to the Learn project root folder and putting"plugins": ["./meeting-calendar"], in .wp-env.json. Then following the README instruction to set the plugin up, things should work out.

@renintw renintw force-pushed the add/WPTV-URL-meta-field branch 4 times, most recently from 0d3c5c3 to 98fa6f6 Compare March 30, 2023 00:09
@@ -569,6 +580,18 @@ public function render_meta_boxes( $post ) {
<input type="text" name="location" id="location" class="regular-text wide" value="<?php echo esc_attr( $location ); ?>">
</label>
</p>
<p>
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like an extra tag here

Suggested change
<p>

Copy link

@adamwoodnz adamwoodnz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏 Works for me, great work!

Just one comment inline

@renintw renintw merged commit 96a92e7 into master Apr 26, 2023
2 checks passed
@renintw renintw deleted the add/WPTV-URL-meta-field branch April 26, 2023 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New meta field for recorded video on online workshops
2 participants