No description
Find a file
Ali Asadi a643fee027 FIX(notifications): action_code accepts dots, PushMessage.stats actually updates
Found by an end-to-end run against a live Gotify container:

- action_code / NotificationLink.action_code were SlugField, which rejects
  dots. Every documented action_code (billboard.approved, escrow.timeout,
  ...) is dotted, so any real request using the catalog got a 400 before
  this fix -- only click_url ever worked. Switched both to CharField with
  a validator that keeps slug's charset but allows ".".
- send_push_notification set push_message.state instead of .stats after a
  successful send, so PushMessage.stats stayed stuck at INIT forever
  regardless of delivery outcome. Fixed the attribute name and scoped the
  save with update_fields.

Verified live: POST with a dotted action_code now resolves through
NotificationLink and lands in Gotify with the correct click.url, and the
PushMessage row flips to DONE.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-01 15:55:17 +03:30
.forgejo/workflows init 2025-06-29 17:09:37 +03:30
apps FIX(notifications): action_code accepts dots, PushMessage.stats actually updates 2026-09-01 15:55:17 +03:30
docs REFACTOR(notifications): rename code/click_object_id to action_code/click_object_id_value 2026-08-23 12:13:29 +03:30
gotify_rest_api_client init 2025-06-29 22:15:11 +03:30
main add winsoo in trusted origins 2026-09-01 12:06:27 +03:30
static add static files 2025-07-01 15:15:21 +03:30
templates bulk push 2025-09-02 20:12:20 +03:30
utils FIX(notifications): configuration for GOTIFY_BASE_PUBLIC_URL 2026-05-09 14:12:13 +03:30
.gitignore chore: ignore __pycache__ and compiled Python files 2026-08-22 09:35:53 +03:30
celery.sh celery beat 2025-09-06 17:26:10 +03:30
Dockerfile modify Dockerfile 2025-07-01 12:47:51 +03:30
manage.py init 2025-06-29 17:09:37 +03:30
README.srt FIX(notifications): configuration for GOTIFY_BASE_PUBLIC_URL 2026-05-09 14:12:13 +03:30
requirements.in celery beat 2025-09-06 17:00:21 +03:30
requirements.txt celery beat 2025-09-06 17:00:21 +03:30
run.sh init 2025-06-29 17:09:37 +03:30

openapi-python-client
https://push.gooyal.ir/swagger?base=push.gooyal.ir

npm install -g swagger2openapi