Skip to content

[Feature Request] Automatically change active status sale for upcoming sale. #123

@andrewlimaza

Description

@andrewlimaza

It'd be neat to automatically set a sales 'active' status for upcoming sales, this helps site owners run their sales fully autonomously and won't need to login to turn their sale on or off.

This might be nice to opt-into to give flexibility and control over to sales as maybe the person doesn't want to automatically turn on a sale for whatever reason (i.e. incomplete sale settings).

An option as post meta could work, such as "Automatically activate sale?" and we can query this when figuring out which sale to automatically activate next.

It should only activate sales if:

  • Setting is enabled.
  • Sales start date is today or in the future AND sales end date is today or in the future.
  • Activate the next one based on the start date order.
  • Runs daily to check if a sale needs to be activated and then caches data to save some memory (although one query a day automatically isn't too heavy via a cron).

Ignore any currently active sales, just so we don't turn off an active sale.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions