Hey @luxworx ,
Thank you for reaching out with your query! Yes, it is possible to display purchased eBooks within the Tutor LMS dashboard, but this would require a custom modification. Here’s a basic outline to achieve this:
- Add a Custom Filter: First, add a filter to your theme’s
functions.php
file. You can refer to this image as a guide: Sample Code.
- Create a Template File: Next, create a new PHP file under
tutor/templates/dashboard/
with the same name you’ve set for the custom menu.
- Display Data: Within the file, you can create a table to fetch and display the purchased eBooks. Here’s a sample snippet you can use to pull order history: Sample Table Code.
- Fetch Purchased Books: You can adapt a sample order history table to retrieve the relevant purchase data: Example.
Additionally, if you’re using any eCommerce plugin like WooCommerce, you can pull your order data directly from the respective order tables. You can refer to the WooCommerce documentation to use the wc_get_orders
function and fetch the orders: WooCommerce Documentation.
Once this customization is successfully implemented, users will be able to see their purchased eBooks directly from their dashboard.
For more details, you can refer to the Tutor LMS documentation: Editing Tutor Dashboard.
Let us know if you need further assistance!
Best regards,
Maizul Islam,
Tech Support, Themeum