Skip Navigation

[Resolved] Integrate WooCommerce Subscriptions into Toolset Views

This support ticket is created 5 years, 3 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

This topic contains 4 replies, has 2 voices.

Last updated by richardG-4 5 years, 2 months ago.

Assisted by: Christian Cox.

Author
Posts
#1184460
Screenshot_1.jpg

Tell us what you are trying to do?
I opened and closed a similar ticket, I got some help making the shortcode needed so I'm opening a new ticket. I have the coding for a shortcode that will make it so we can display a subscription's status, I need help displaying it in the view specific to individuals that own the subscription.

Currently the only way I can display the status is by putting in a specific post ID, such as a test subscription I made with the ID 215. I'd like the view to be able to pull the subscription post ID from the user so it knows which post ID to use. I may need to use a different shortcode, but I don't know if I can do that, so I'm hoping Views can make that determination.

Is there any documentation that you are following?
Here is the code created from WooCommerce to display the subscription status:

function get_subscription_status($postid) {
$subscription = wc_get_order( $postid['postid'] );
return $subscription->get_status();

}
add_shortcode( 'subscription_status', 'get_subscription_status' );

Here is the shortcode: [subscription_status postid="postID"]

Is there a similar example that we can see?
I will share an image.

What is the link to your site?
hidden link

#1184510

I'd like the view to be able to pull the subscription post ID from the user so it knows which post ID to use.
There's no direct integration between Views and Subscriptions, so I'm not sure how to access the subscription post ID. How does one get a subscription post ID given a known User ID, outside of Views? Is there a shortcode?

#1188380

I found the option to display the content type Orders on a tutorial from Toolset,, but I don't see it as a content type for Orders on the View selection as it says in Step 1:

https://toolset.com/learn/create-an-ecommerce-wordpress-site/displaying-more-information-from-woocommerce/how-to-display-woocommerce-orders-on-the-front-end/

Is that not a default content, do I need to add it myself and create a relationship or something?

#1189140

You must have Toolset WooCommerce Views active to create a View of Orders. If you have the WCV plugin active but still cannot see Orders in the Content Selection area, there must be something else going on. I'll be glad to take a closer look.

#1200754

I'll see if I can hire someone to help with integration, thank you for giving me direction on what needs to be done!

This ticket is now closed. If you're a WPML client and need related help, please open a new support ticket.