Skip to content

Conversation

@Benjamin-etu-lille
Copy link
Collaborator

This PR introduce the ability to schedule the publication of a video at a specific date and time.

In the video edit form, a new checkbox "Schedule the post" allows you to enable scheduling.
If checked, a "Scheduled publish date" field appears, allowing you to select the date and time when the video should be published.

A periodic Celery task will automatically publish videos at their scheduled date and time.

Celery setup:

To enable scheduled publishing, you must run both a Celery worker and a Celery beat scheduler in your terminal:
Worker:
celery -A pod.main worker -l info

Beat:
celery -A pod.main beat -l info

Before sending your pull request, make sure the following are done

  • You have read our contribution guidelines.
  • Your PR targets the dev_v4 branch.
  • Your PR status is in draft if it’s still a work in progress.

@Badatos Badatos added this to the 4.x milestone Oct 28, 2025
change_transcript();
}

document.addEventListener("DOMContentLoaded", function() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ajouter un petit jsdoc

self.fields = add_describedby_attr(self.fields)
self.fields['scheduled_publish_date'].widget.input_type = 'datetime-local'
self.fields['scheduled_publish_date'].widget.attrs['placeholder'] = 'AAAA-MM-JJTHH:MM'
self.fields['scheduled_publish_date'].help_text = _('Format attendu : AAAA-MM-JJTHH:MM (ex : 2025-06-11T14:30)')
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

à mettre en anglais par défaut.

)
scheduled_publish_date = models.DateTimeField(
null=True, blank=True,
help_text="Date and hour of the scheduled publication."
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

à traduire

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

est-ce que ce fichier binaire peut être créé automatiquement s'il est manquant ?
Si oui, ne pas l'inclure dans le git

@Badatos Badatos deleted the branch EsupPortail:dev_v4 November 10, 2025 11:03
@Badatos Badatos closed this Nov 10, 2025
@Badatos Badatos reopened this Nov 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants