Allows organizers to test their shop as if it were a different date and time.
Implemented using a time_machine_now() function which is used instead of regular now(), which can overlay the real date time with a value from a ContextVar, assigned from a session value in EventMiddleware.
For more information, see doc/development/implementation/timemachine.rst
---------
Co-authored-by: Richard Schreiber <schreiber@rami.io>
Co-authored-by: Raphael Michel <michel@rami.io>
* Prevent transferring files from priv/ to pub/ on event clone
* Also detect file names with node prefix
* Only transfer files in explicitly declared file fields
* Update django-hierarkey
* Add note to documentation about the new behaviour
* Generalize import process from orders to more models
* Add voucher import
* Model import: Guess assignments of based on column headers
* Fix lock_seats being pointless
* Update docs
* Update doc/development/api/import.rst
Co-authored-by: Richard Schreiber <schreiber@rami.io>
* Update src/pretix/base/modelimport_vouchers.py
Co-authored-by: Richard Schreiber <schreiber@rami.io>
---------
Co-authored-by: Richard Schreiber <schreiber@rami.io>
On systems that follow the FHS it may be desirable to separate logs and
cache files into dedicated base directories (e.g. /var/log/pretix or
/var/cache/pretix).
* start impl of unavailability modes ui
* add db migration
* use new widget for more fields
* improve contrast
* use new widget for hide_without_voucher field
* improved wording
* rebase migration
* undo changes to require_membership_hidden
* code formatting
* move unavail_reason logic around
* enforce consistent state of hide_without_voucher / require_voucher
* annotate unavailability info in get_grouped_items
* remove MSIE6 compat
* add unavailability reasons to widget
* remove test output
* Apply suggestions from code review
text improvements
Co-authored-by: Richard Schreiber <schreiber@rami.io>
* add css fix for jumping items due to tooltip
* dynamically retrieve unavailability reason message
* widget: simplify logic conditions
* add available_{from,until}_mode to api and api docs
* rebase migration
* rebase migration
* add unavailable_*_mode to ItemVariation
* add available_*_mode to API docs for items
* fix wrong reference
* fix test cases
* add available_*_mode to item variation form
* apply unavailability modes to subevents and variations (presale)
* /o\
* apply unavailability modes to subevents and variations (widget)
* display unavailability mode in subevent product settings
* fix widget test
* fix api item tests
* copy available_*_mode when copying an item
* Apply suggestions from code review
Co-authored-by: Raphael Michel <michel@rami.io>
* Add unavail mode indicator to bulk create and edit forms
---------
Co-authored-by: Richard Schreiber <schreiber@rami.io>
Co-authored-by: Raphael Michel <michel@rami.io>
* remove duplicate context generation
* allow text templates in frontpage_text
* refactor: move placeholder functionality to separate file
* fix wrong class name, code style
* update year in license header
* undo license header update
* use new function name
* render only the placeholders that are actually used in the message
* refactoring
* add str(...) call
* Update doc/development/api/placeholder.rst
Co-authored-by: Raphael Michel <michel@rami.io>
* rename register_mail_placeholders to register_template_placeholders
(deprecate old name)
* isort
* add signals to docs
---------
Co-authored-by: Raphael Michel <michel@rami.io>
* Check-in: Show more information
* Add change notes
* Rebase migration
* Add "expand" option to checkinrpc
* REmove accidental file
* Docs fixes
* REbase migration
* Rebase migration
* Fix typo
* REbase migration
* Make web-checkin look more like new android checkin
* Add public filters based on meta data
* Fix licenseheaders
* ignore empty values
* Fix tests
* Full non-widget implementation
* Widget support
* Add a few tests
* Allow to reorder properties
* Fix isort
* Allow to opt-out for specific events
* Fix name clash between new and old field to make migration feasible
* draft
* Implementation that is closer to old one
* Fix tests
* Add tests
* Update src/pretix/control/forms/item.py
Co-authored-by: Richard Schreiber <schreiber@rami.io>
* Review notes
---------
Co-authored-by: Richard Schreiber <schreiber@rami.io>