bethlakshmi / gbe-divio-djangocms-python2.7

3rd try is the charm - Divio Cloud, Django CMS, Python 3.x, Django 3.x
Apache License 2.0
6 stars 1 forks source link

Integrate with Humanitix #536

Closed bethlakshmi closed 7 months ago

bethlakshmi commented 10 months ago

This would be a 4th payment system - I would not remove any of the others, though I might spend a bit of time looking at on/off switching for them.

Humanitix (and how we want to use it) has a different ticket structure than we've had for the others, so this is a morph of the data model and also a fairly different API structure.

Data Design:

Here's how I plan to map Humanitix data concepts to GBE:

CHALLENGES: 1 - there is no ticket type ID. I have a question pending to Humantix on this. This is a problem, since with no unique ID, I have to rely on something mutable to recognize already synced tickets on a repeat sync. So if a title changes, I make a NEW ticket type, because I can't tell if it's the same as a previously named type. It also makes deducing the package/ticket type relationship impossible from the API.

Limitations:

Requirements to meet on the GBE side.

Right now we have:

This is definitely a draft and not a done deal.

bethlakshmi commented 9 months ago

OK, I'll turn this into real docs in the Wiki later, but here in the comments is going to be notes with highlights Scratch may want to weigh in on.

1 - I decided that TicketTypes (Humantix tickets) and TicketPackages are going to both be "TicketItems" in our models - as they are both sellable things and so will be represented in Transactions. I made two subclasses for them so that:

bethlakshmi commented 9 months ago

@burlexpo - OK, question. There are 3 ways to set ticket costs in Humantix:

CHALLENGE: There is a set of cost options, which looks like this:

Screenshot 2023-12-02 at 3 35 56 PM

I don't have a place to store multiple costs. Of note - there's no way to control the quantity of each option. You can't sell 100 tickets at $10, then 10 VIPs at $50 - it's a straight list for people to choose and there's no verbiage you can attach to the prices saying anything at all.

Options on my end: 1 - super easy - skip it, we're never gonna use this. If this option is used, the cost on our end will be $0, which will unfortunately display in some views. 2 - not that much work - just save the lowest cost and label it as a minimum (same as the min/max range) 3 - really a PITA - add multiple costs to ticket items so that I can store all costs. Then figure out where/how to display this.

Any preference? Skipping it until I hear otherwise.

bethlakshmi commented 9 months ago

@burlexpo - QUESTION 2:

start and end date on ticket sales

These are settable in the ticket type section of Humanitix. But they don't show up in the API anywhere that I can find (I really think I looked everywhere).

What I've done in the past was to sync the date and then stop displaying tickets when the date has passed. It can also be overwritten by the user - so it CAN be set manually.

The options here:

This IS a new feature if we're asking them to add it to the API. I can see why they may not see value in exposing it.

Not a blocker for me... will continue with basic stuff while we talk.

burlexpo commented 9 months ago

@bethlakshmi

Q1: Skip it Q2: I'm pretty sure that a ticket that has expired or is not yet on sale is "disabled". So try testing that

bethlakshmi commented 9 months ago

Q2: Playing with it yields no change in disabled/enabled status. I mailed to Humanitix with the mystery.

bethlakshmi commented 9 months ago

FYI - chugging along (as can be seen by commit emails).

Done so far:

TODO:

Going to another ticket for:

bethlakshmi commented 9 months ago

OK, got another question for @burlexpo - working on "make the display for the new ticket types & packages look good for ticket buyers, ie, this page: https://www.burlesque-expo.com/ticketing/"

Situation - we are likely to have more than 1 ticket type per event. For example, the Main Event and Rhinestone Review often sell VIP tickets at a higher price. So we have, for example:

Now with Humanitix, the Event level is the whole conference. So when I've been showing ticket options in previous years I did something like this:

Screenshot 2023-12-09 at 10 10 18 AM

So that for the given event, we show:

Previously, the first 3 items came from the Ticket Event - which is now the whole conference - so that's a no-go. I figured out I can reshuffle the ticket type to GBE scheduled Event link so that I can get the event name from the GBE scheduled event, and then calculate the min/max ticket prices by comparing all the ticket types associated with that event.

So that leave the problem of the pretty icon and the enticing bullets.

I can do 1 of two things:

So question - @burlexpo - do you have a preference of those 3 options?

And if I do what I think is easiest - pick an arbitrary ticket type and display it's icon/bullets - what algorithm would you prefer? I could do things like - always pick the highest price, most recently edited, alphabetically first title... I lean towards highest price - because we usually have cheaper tickets that expire, or sell out as time goes on. But the highest price tickets are always the most available, so work as a good long term container for other settings.

bethlakshmi commented 9 months ago

OK, another open question - packages. Very similar problem, slightly different issues. We could very well have 2 packages of, say, Whole Shebang. We often have done:

With Humantix, I can't think of a way (unless I fake it with extra work for me and @burlexpo) to aggregate those 3 Whole Shebangs into 1 package on our Buy Tickets display. They don't have the same name, they won't have the same ID.

Right now I'm stuck with having those 3 Whole Shebangs show up as separate packages that don't have anything do with one another. Which means that any extra description has to be done by Scratch on all of them. Alternately, I could develop some sort of thingy that collects them and provides the place where the icon and bullet points can be provided.

Because this has gotten intense, I'm also going to post what I have so far so we can look at it on the test site. You can preview it here:

https://burlesque-expo-stage.us.aldryn.io/ticketing/

burlexpo commented 9 months ago

A couple of thoughts -- mostly, "are we reinventing the wheel?". I understand that when the only tool you have is a Pyhon Developer than all problems look like a nail... but it seems like Humanitix has some features we may want to use instead of writing our own.

1) Buy Ticket Widget -- shows a list of available tickets but can be imbedded in our website 2) Multiple prices for the same ticket -- https://humanitix.atlassian.net/servicedesk/customer/portal/2/article/1236992683 3) I can't find the Quick Start page for Discounts (I can find it but it's 404), but I'm pretty sure there's a way to offer prices for a limited time to do what we want to do in that department

bethlakshmi commented 9 months ago
  1. Yep, if you like what's shown here: https://humanitix.atlassian.net/wiki/spaces/CS/pages/1228538204/Sell+tickets+and+showcase+events+on+your+website+with+widgets?parentProduct=JSM-Portal&parentProductContentContainerId=10114&initialAllowedFeatures=disable-login-flow.disable-share&locale=en-US#[hardBreak]%F0%9F%8E%AB-Buy-tickets-widget

I can definitely set you up with a page for that - can probably even do it w/out code using Django CMS and the embedded code. Can't change the look and feel though, so it will look a bit transplanted.

  1. on the page you linked, do you mean "flexible pricing" - that is different from multiple pricing. It's stuff like ranges or lists - but for each ticket type there is 1 price (however flexible) and 1 date range.
  2. Discounts - is it this? https://humanitix.atlassian.net/servicedesk/customer/portal/2/article/1276674650 - this seems to be all about codes.
burlexpo commented 9 months ago
  1. I went to look and see if the L&F of the widget was CSS controllable. Can't tell if it is.
  2. (3) Allows us to set a PWYW for specific ticket type and date. So, we could create a ticket for "Rhinestone Revue" and someone could select from a list of prices we set; one VIP price, one standard price.
  3. Yes, but item 8 on their list is "set a time when codes are valid" and since you can create an automatic discount on certain tickets, I think you could set things up to say

When you purchase ticket WHOLE SHEBANG automatically apply DISCOUNT "2024"

and then DISCOUNT 2024 says

1/1/2024-1/31/2024 Discount =50% 2/1/2024-2/29/2024 Discount=40% 3/1/2024-3/31/2024 Discount=30%

etc

bethlakshmi commented 9 months ago

1 - usually messing around with CSS on an embed like this is asking for trouble. They definitely don't expect us to do that, so when/if they ever change the HTML, the results will be unpredictable and we'll never know when that happens. What they give us is a script which loads both the content and the HTML around it. What we paste into our site, looks like this:

`

` 2 - so that list of prices what I was asking about a few days ago. The list gives no context, so they won't really know that by purchasing the most expensive ticket they are getting priority seating - it's just a list of costs. Also - I don't have a way to store that data right now - I can build it, but not sure if it's worth it. 3 - OK. That seems really complicated for the user? And it also means if I'm doing anything about it on our side, I'm writing a whole other aspect of the code to work with discount codes. I think we're at a point where we need to chat IRL. I'm starting to wonder what the requirements of the GBE site should be here, and how much of their ticketing system I should sync.
bethlakshmi commented 9 months ago

FYI - I put up a test page with the ticket list widget from Humanitix - here: https://burlesque-expo-stage.us.aldryn.io/humantix-embedded-widget/?edit_off=true

The "Example of list" is what the price list of option 2 gives you - the list is just a list of costs, no other text available.

The look of it is pretty good - IMO - neutral enough that it's not too jarring, and the fact that they can walk all the way through payment w/out leaving our site is neat. The only odd thing is that the login/payment here is separate from anything related to our login - and that's just how it will have to be.

If we go with this... I'm wondering what part of ticket integration needs custom code? We show ticket stuff on the event pages, and on the user's home page...but that's a lot simpler... do I want to even try to do a purchase tickets page?

burlexpo commented 9 months ago

Hmm... yeah, the "Example of List" isn't great, but we might be able to put the text elsewhere. It's a diferent way than we've done things historically. It saves some work and creates others.

I'm around tomorrow during the day if you want to get together to discuss

burlexpo commented 9 months ago

3 - OK. That seems really complicated for the user? And it also means if I'm doing anything about it on our side, I'm writing a whole other aspect of the code to work with discount codes.

No, it's complicated for me -- it's invisible to the user. The prices just change automatically.

bethlakshmi commented 9 months ago

Sounds good. I have meetings 12-2 intermittently but otherwise free. Will probably book some sort of morning workout.

bethlakshmi commented 8 months ago

First round done - follow on tickets created. On the live site, I turned on Humanitix, turned off Eventbrite and I'm just waiting to make sure the timed sync pulls in the event the way it should. The Buy Tickets page has been created and is live.

bethlakshmi commented 8 months ago

Turns out I needed to integrate the ticket sync. They can be synced manually with the button, but i forgot to implement the cron job way of doing it! (D'oh). so I manually synced the tickets and set them up. And will do the automated version on the #563 ticket

bethlakshmi commented 7 months ago

Fixed with #567 - and I just configured Divio with the new scripts. It bears monitoring for a bit - we have no transactions yet. Would love to see some syncing up after we well them. :)