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 support for pmc_events post type. #13

Merged
merged 5 commits into from
May 21, 2024
Merged

Conversation

allan23
Copy link
Contributor

@allan23 allan23 commented May 21, 2024

No description provided.

@allan23 allan23 requested a review from ethitter May 21, 2024 15:58
Copy link
Member

@ethitter ethitter left a comment

Choose a reason for hiding this comment

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

Thank for contributing so quickly!

public static function get_query_args(): array {
return [
'post_type' => Plugin::SLUG,
'posts_per_page' => -1,
Copy link
Member

Choose a reason for hiding this comment

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

This needs either a date query or a limit. Artforum has 36k events 😄

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yikes. 😅

I've updated the query to fetch the last six months.

Copy link
Member

@ethitter ethitter left a comment

Choose a reason for hiding this comment

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

One last thing, the class needs to be instantiated in this array:

$query_args = [
new Query_Args\CoAuthors_Plus(),
new Query_Args\Nav_Menu_Item(),
new Query_Args\OEmbed_Cache(),
new Query_Args\Page(),
new Query_Args\PMC_Ads(),
new Query_Args\PMC_Amzn_Onsite(),
new Query_Args\PMC_Attachments(),
new Query_Args\PMC_Buy_Now_Block(),
new Query_Args\PMC_Buy_Now_Shortcode(),
new Query_Args\PMC_Carousel(),
new Query_Args\PMC_Custom_Feed(),
new Query_Args\PMC_Ecomm(),
new Query_Args\PMC_FAQ(),
new Query_Args\PMC_Gallery(),
new Query_Args\PMC_Hub(),
new Query_Args\PMC_List(),
new Query_Args\PMC_Not_For_Publication(),
new Query_Args\PMC_Nova_Homepage(),
new Query_Args\PMC_Profiles(),
new Query_Args\PMC_Profiles_Landing_Page(),
// new Query_Args\PMC_Publication_Issue(),
new Query_Args\PMC_Reviews(),
new Query_Args\PMC_Store_Products(),
new Query_Args\PMC_Term_Content(),
new Query_Args\PMC_TOC(),
new Query_Args\PMC_Top_Video(),
new Query_Args\PMC_Touts(),
new Query_Args\Post(),
new Query_Args\Safe_Redirect_Manager(),
new Query_Args\WPCOM_Legacy_Redirector(),
new Query_Args\Zoninator(),
];
.

@allan23 allan23 merged commit 2281987 into main May 21, 2024
3 checks passed
@allan23 allan23 deleted the feature/event-post-type branch May 21, 2024 17:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants