eo_get_remaining_tickets_count() for individual tickets

WordPress Event Management, Calendars & Registration Forums General Question eo_get_remaining_tickets_count() for individual tickets

This topic contains 4 replies, has 2 voices, and was last updated by  Stephen Harris 9 years, 7 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #18018

    Hi Stephen,

    Me again!

    In a back-end report, I’m trying to report on sales by individual ticket on an occurrence. I need to show the ticket name, price, quantity and quantity remaining (unsold).

    I can get the first three numbers without a problem using eo_get_event_tickets(), but I can’t figure out how to get the quantity remaining for an individual ticket.

    I can use eo_get_remaining_tickets_count() to return the quantity left for all tickets on an occurrence, but not an individual ticket.

    Any ideas?

    I’ll start having a dig in the plugin internals in parallel…

    Cheers,

    Andrew

    Andrew Shankie
    #18019

    Hi Stephen,

    I answered my own question – I managed to do it using eo_get_the_occurrences_tickets().

    It’s worth mentioning that the codex doesn’t have this function documented completely:

    http://codex.wp-event-organiser.com/function-eo_get_the_occurrences_tickets.html

    All the best,

    Andrew

    Andrew Shankie
    #18021

    Thanks Andrew,

    It seems the script for creating the documentation was parsing the development and build directions, hence the ‘already declared’ error. I’ll update that shortly.

    Stephen Harris
    #18028

    Super. Nice one! Thanks Stephen.

    Hope I’m not being a pain, but I feel I’m up against the coal face with some of the functionality I’m building, so I hope this stuff is useful. Probably not for your tendonitis, but there we are.

    Andrew Shankie
    #18049

    No worries, and happy to answer any questions if documentation is lacking.

    Stephen Harris
Viewing 5 posts - 1 through 5 (of 5 total)
To enable me to focus on Pro customers, only users who have a valid license for the Pro add-on may post new topics or replies in this forum. If you have a valid license, please log-in or register an account using the e-mail address you purchased the license with. If you don't you can purchase one here. Or there's always the WordPress repository forum.