Giter VIP home page Giter VIP logo

Comments (6)

engram-design avatar engram-design commented on August 11, 2024

No, you don't have to if you don't want to. The option is there to control both ticket and event capacity, should you need that fine-grained level of control.

Say you have an event with 100 seats and Child + Adult tickets. You can just not set a quantity on those tickets so that there are no limits to how many tickets can be purchased (until all 100 are sold)

In another scenario, you might only allow 25 Child tickets, and 75 Adult tickets. Using the quantity allows you to control this.

The quantity for a ticket also acts like inventory, and is decremented whenever someone purchases a ticket of that type for the event. This may very well change in the future, as it's ambiguous, and can lead to deadlock issues (you edit the value while someone is purchasing that ticket - you get inconsistent results.

from events.

mihob avatar mihob commented on August 11, 2024

If the quantity field is left empty, 0 is saved as the value and the ticket is not available.

from events.

engram-design avatar engram-design commented on August 11, 2024

Ah, right you are - that's incorrect behaviour (see 5fa7893).

Fixed for the next release. To get this early, run composer require verbb/events:"dev-craft-4 as 2.0.2".

from events.

CaporalJuju avatar CaporalJuju commented on August 11, 2024

the bug is not fixed. the ticket quantity is automatically reset to 0 with release 2.0.2
a condition must be added to be functional

  $ticketModel->quantity = null;
        if ($ticket['quantity']) :
            $ticketModel->quantity = (int)$ticket['quantity'];
        endif;

you can't put an infinite total capacity on top of infinite tickets either

from events.

engram-design avatar engram-design commented on August 11, 2024

Right, that's why we added fba54ca which is unreleased. Is that not working for you?

from events.

engram-design avatar engram-design commented on August 11, 2024

Should be fixed in 2.0.3

from events.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.