Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • C CiviDiscount
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 36
    • Issues 36
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 9
    • Merge requests 9
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Extensions
  • CiviDiscount
  • Merge requests
  • !285

Fix broken 'any event' discount code

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged colemanw requested to merge colemanw/cividiscount:fixAnyEventCode into master Dec 04, 2022
  • Overview 0
  • Commits 1
  • Pipelines 0
  • Changes 1

@ayduns noticed this issue:

  1. Create a discount code for "Any event"
  2. Try to use it when registering a participant (backend "Register Event Participant" form)
  3. See error: "The discount code you entered is invalid."

It appears to have been caused by @eileen's commit in !242 (merged) which was according to her comment a fix for something I did. I wish I knew specifically what, because this has been quite a game of whack-a-mole and I think the resulting "solution" is more complex than necessary. I think switching this whole function over to using APIv4 would solve a lot of these serialization issues. But for now, this fixes the bug while staying faithful to @eileen's fix as well.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: fixAnyEventCode