How to generate tickets again after the check in (function)?

Home Forums Ticket Products Event Tickets Plus How to generate tickets again after the check in (function)?

Viewing 15 posts - 1 through 15 (of 16 total)
  • Author
    Posts
  • #1464105
    Ilkka
    Participant

    Hi,

    We have a situation that we would like to generate the tickets again after the check in is made. This is because we have customised the tickets that they will get a checked in label. This will lead to a situation that we would like to resend the newly generated tickets to the customer. For example: You have checked in here is your new tickets.

    So best option would be to know if there is a function to generate the tickets again. I am talking also about the PDF ticket.

    Or is there a hook, action or function to resend it as fresh tickets. Like they never existed before…

    thanks

    #1465551
    Cliff
    Member

    Hi. Are you saying that a new email with the PDF ticket is attached, but the PDF ticket does not have the “Checked In” label on it because the ticket.pdf file already existed but it was the old one without the “Checked In” label?

    #1465568
    Ilkka
    Participant

    Hi,

    Thanks for your answer. I am mainly looking for a function that i could resend the tickets. Because we have a solution for generating the tickets again after they have been checked in and received our custom label. So our pdf ticket has the checked in label. We just do not know how to send the tickets for the customer.

    So if we really simplify this. What is the function to send the tickets to the customer, or action or hook? How can we trigger the action of sending the tickets to the customer.

    Thanks

    #1465574
    Ilkka
    Participant

    Hi,

    And totally another thing. We previously had another discussion of styling the pdf. I have 100% perfect now. I wanted to let you know that if there is a space in the styling (inline) it will cause many problems to the styling of the pdf.

    For example:
    CORRECT

    <

    h6 style=”margin:0 0 10px 0″>

    THIS WILL cause almost all styling to break in the pdf.

    <

    h6 style=”margin:0 0 10px 0″>

    Notice the break after first ”

    Out of the topic, but wanted you to know.

    thanks.

    #1465578
    Ilkka
    Participant

    Hi,

    I noticed that it will not display html in this board correctly, maybe blocked. Here is an image for you.

    Thanks.

    #1466710
    Cliff
    Member

    1)

    If using WooCommerce tickets, you can resend a ticket email by going to the order and choosing that order action. Here’s a quick video (no audio): https://cl.ly/0x0K3j2F1U2m

    2)

    Thanks for the heads up here. Where are you adding such CSS?

    You could report this issue to https://github.com/mpdf/mpdf/issues if it’s reproducible.

    #1466716
    Ilkka
    Participant

    Hi,

    Thanks for your answer. Yes i know that this actions exists in the orders in woocommerce and it has proven to be very useful also. But we are looking the exact same function, but we need to rigger this automatically. So what is the function to trigger this action (of sending the tickets to the customer email)?

    As we have loads of tickets send daily to the customer we can not go through all the events and look for the order and make it manually, we need to have it automatically. I know you have this function as it is working fine, but the problem is we do not know it. 🙂

    Thanks.

    #1466747
    Cliff
    Member

    This all happens by extending WooCommerce’s email class and then this class gets added via the woocommerce_email_classes filter.

    For more details, you can search /wp-content/plugins/event-tickets-plus/src/Tribe/Commerce/WooCommerce/Main.php for “add_email_class_to_woocommerce” and also review /wp-content/plugins/event-tickets-plus/src/Tribe/Commerce/WooCommerce/Email.php

    I’m unsure how/where you could add all this as a button to loop through all attendees, though.

    #1466748
    Ilkka
    Participant

    Hi,

    I try to make it as clear as possible:

    https://github.com/moderntribe/products-extensions/blob/master/tribe-ext-pdf-tickets/index.php#L537-L545

    How to call this from a hook or from our own plugin.

    Thanks.

    #1467656
    Cliff
    Member

    Although untested, one or both of these might work:

    • Tribe__Extension::instance( ‘Tribe__Extension__PDF_Tickets’ )->do_upload_pdf( /*…args…*/ );
    • Tribe__Tickets_Plus__Commerce__WooCommerce__Main::get_instance()->send_tickets_email( /*…args…*/ );

    That being said, if you successfully send a new email, I believe it would send the existing PDF file and not generate a new one with your added customized styling/watermark image.

    Therefore, I’ve logged a feature request for the PDF Tickets extension to be able to force-overwriting the existing PDF.

    #1467882
    Ilkka
    Participant

    Hi,

    I will try it. And let you know.

    Thanks.

    #1468520
    Cliff
    Member

    Thanks for checking in. I’ll wait to hear from you.

    Please note that threads get Closed automatically after a couple weeks of inactivity. If it does get Closed, please open a new thread, adding your current problem description and also linking back to this thread.

    Thank you!

    #1469175
    Ilkka
    Participant

    Hi,

    Thanks for your answer. It was showing us the right way.

    We are doing some stuff before, but this will do the trick for us.

    Tribe__Extension::instance( ‘Tribe__Extension__PDF_Tickets’ )->do_upload_pdf( $attendee_id );
    $order_ref = get_post_meta($attendee_id,‘_tribe_wooticket_order’,true);
    Tribe__Tickets_Plus__Commerce__WooCommerce__Main::get_instance()->send_tickets_email( $order_ref );

    Thanks.

    #1469176
    Ilkka
    Participant

    So, this case is solved. Great work.

    ilkka

    #1473716
    Cliff
    Member

    Glad to hear and thanks for letting us know.

Viewing 15 posts - 1 through 15 (of 16 total)
  • The topic ‘How to generate tickets again after the check in (function)?’ is closed to new replies.