[IMP] website_sale_aplicoop: automate non-weekly group order cycles

One-time, biweekly and monthly group orders now follow the same cron
confirmation flow as weekly ones (confirm sale orders + batch pickings
when the cycle cutoff passes):

- Biweekly/monthly keep the cutoff_day/pickup_day weekday scheme on a
  recurrence grid anchored at start_date (creation date as fallback):
  cutoffs advance +14 days / +1 month snapped to cutoff_day, with
  catch-up after cron downtime. Previously they behaved as weekly.
- One-time orders (specials/promotions) are driven by end_date
  (cutoff_date = end_date); once passed, the cron confirms, batches
  and closes the group order.
- end_date keeps its "empty = permanent" meaning for recurring orders.
- Website draft-cart lookup window is now period-aware instead of
  assuming a 6-day weekly cycle.
- New cron tests for once/biweekly/monthly cycles; i18n es/eu updated.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
GitHub Copilot 2026-07-15 14:14:03 +02:00
parent d8cd83bdaf
commit aba22fd230
8 changed files with 510 additions and 74 deletions

View file

@ -1,5 +1,28 @@
# Changelog - Website Sale Aplicoop
## [18.0.1.11.0] - 2026-07-15
### Added
- **Non-weekly cycle automation**: one-time (special/promotional), biweekly and
monthly group orders now follow the same cron confirmation flow as weekly orders
(confirm linked sale orders + batch their pickings once the cycle cutoff passes).
- **Biweekly/monthly recurrence**: these periods keep the weekday scheme
(`cutoff_day`/`pickup_day`) but on a recurrence grid anchored at `start_date`
(creation date as fallback): cutoffs advance every 14 days / 1 month (snapped to
`cutoff_day`), with automatic catch-up if the cron was down. Previously they
behaved as weekly.
- **One-time orders**: their single cycle is driven by `end_date`
(`cutoff_date = end_date`); once it passes, the cron confirms, batches and closes
the group order automatically.
### Changed
- `end_date` keeps its "permanent if empty" meaning for all recurring periods;
it only closes the cycle for one-time orders.
- Draft-cart lookup window on the website is now period-aware (7/14 days, 1 month,
or the full order lifetime for one-time orders) instead of always 6 days.
## [18.0.1.9.0] - 2026-05-20
### Added