diff --git a/dockerfile-dev-with-volumes/README.adoc b/dockerfile-dev-with-volumes/README.adoc index e3f2a89a5c..4ecf9aeccd 100755 --- a/dockerfile-dev-with-volumes/README.adoc +++ b/dockerfile-dev-with-volumes/README.adoc @@ -76,12 +76,16 @@ ES_VERSION = 7 ES_URL = ['http://elasticsearch:9200/'] + CACHES = { - # … default cache config and others "default": { - "BACKEND": "django.core.cache.backends.locmem.LocMemCache", + "BACKEND": "django_redis.cache.RedisCache", + "LOCATION": "redis://redis:6379/3", + "OPTIONS": { + "CLIENT_CLASS": "django_redis.client.DefaultClient", + }, + "KEY_PREFIX": "pod" }, - # Persistent cache setup for select2 (NOT DummyCache or LocMemCache). "select2": { "BACKEND": "django_redis.cache.RedisCache", "LOCATION": "redis://redis:6379/2", @@ -90,6 +94,15 @@ CACHES = { }, }, } +SESSION_ENGINE = "redis_sessions.session" +SESSION_REDIS = { + "host": "redis", + "port": 6379, + "db": 4, + "prefix": "session", + "socket_timeout": 1, + "retry_on_timeout": False, +} # Uniquement lors d’environnement conteneurisé MIGRATION_MODULES = {'flatpages': 'pod.db_migrations'} diff --git a/dockerfile-dev-with-volumes/pod/Dockerfile b/dockerfile-dev-with-volumes/pod/Dockerfile index e1a08e348c..755e9ad3b2 100755 --- a/dockerfile-dev-with-volumes/pod/Dockerfile +++ b/dockerfile-dev-with-volumes/pod/Dockerfile @@ -29,12 +29,13 @@ WORKDIR /usr/src/app COPY ./requirements.txt . COPY ./requirements-conteneur.txt . +COPY ./requirements-dev.txt . RUN mkdir /tmp/node_modules/ COPY --from=source-build-js /tmp/pod/node_modules/ /tmp/node_modules/ -RUN pip3 install --no-cache-dir -r requirements.txt \ - && pip3 install --no-cache-dir -r requirements-conteneur.txt +RUN pip3 install --no-cache-dir -r requirements-conteneur.txt \ + && pip3 install elasticsearch==7.17.7 # ENTRYPOINT : COPY ./dockerfile-dev-with-volumes/pod/my-entrypoint.sh /tmp/my-entrypoint.sh diff --git a/pod/import_video/templates/import_video/list.html b/pod/import_video/templates/import_video/list.html index 9086c65cc4..e3792dd50b 100644 --- a/pod/import_video/templates/import_video/list.html +++ b/pod/import_video/templates/import_video/list.html @@ -47,20 +47,9 @@ {% for record in recordings %} {{ record.name }} - - {% if not record.uploadedToPodBy %} - {% trans "Video file not uploaded to Pod" %} - {% else %} - {% trans "Video file already uploaded to Pod" %} - {% if request.user != record.uploadedToPodBy %} - {% trans "by"%} {{ record.uploadedToPodBy.first_name }} {{ record.uploadedToPodBy.last_name }} - {% endif %} - {% endif %} - - {{ record.startTime }} - - {{ record.type }} - + {{ record.state }} + {{ record.startTime }} + {{ record.type }} {% if record.presentationUrl != "" %} diff --git a/pod/import_video/utils.py b/pod/import_video/utils.py index 12b67965be..422afa71ea 100644 --- a/pod/import_video/utils.py +++ b/pod/import_video/utils.py @@ -195,6 +195,22 @@ def save_video(request, dest_file, recording_name, description, date_evt=None): raise ValueError(msg) +def check_file_exists(source_url): + """Check that the URL exists. + + Args: + source_url (String): Source URL + + Returns: + Boolean: file exists (True) or not (False) + """ + response = requests.head(source_url) + if response.status_code < 400: + return True + else: + return False + + class video_parser(HTMLParser): """Useful to parse the BBB Web page and search for video file. diff --git a/pod/import_video/views.py b/pod/import_video/views.py index 57935fa400..7ebd0794bd 100644 --- a/pod/import_video/views.py +++ b/pod/import_video/views.py @@ -7,9 +7,8 @@ from .models import ExternalRecording from .forms import ExternalRecordingForm -from .utils import download_video_file, save_video -from .utils import secure_request_for_upload, parse_remote_file -from .utils import StatelessRecording +from .utils import StatelessRecording, download_video_file, check_file_exists +from .utils import save_video, secure_request_for_upload, parse_remote_file from datetime import datetime from django.conf import settings from django.contrib.sites.shortcuts import get_current_site @@ -163,8 +162,6 @@ def external_recordings(request): Returns: HTTPResponse: external recordings list """ - # print(timezone.localtime().strftime("%y%m%d-%H%M%S")) - if RESTRICT_EDIT_IMPORT_VIDEO_ACCESS_TO_STAFF_ONLY and request.user.is_staff is False: return render(request, "import_video/list.html", {"access_not_allowed": True}) @@ -179,38 +176,7 @@ def external_recordings(request): recordings = [] for data in external_recordings: - # Management of the stateless recording - recording = StatelessRecording(data.id, data.name, "published") - # Upload to Pod is always possible in such a case - recording.canUpload = True - # Only owner can delete this external recording - recording.canDelete = get_can_delete_external_recording(request, data.owner) - - recording.startTime = data.start_at - - # Management of the external recording type - if data.type == "bigbluebutton": - # For BBB, external URL can be the video or presentation playback - if data.source_url.find("playback/video") != -1: - # Management for standards video URLs with BBB or Scalelite server - recording.videoUrl = data.source_url - elif data.source_url.find("playback/presentation/2.3") != -1: - # Management for standards presentation URLs with BBB or Scalelite server - # Add computed video playback - recording.videoUrl = data.source_url.replace( - "playback/presentation/2.3", "playback/video" - ) - else: - # Management of other situations, non standards URLs - recording.videoUrl = data.source_url - else: - # For PeerTube, Video file, Youtube - recording.videoUrl = data.source_url - - # Display type label - recording.type = data.get_type_display - - recording.uploadedToPodBy = data.uploaded_to_pod_by + recording = get_stateless_recording(request, data) recordings.append(recording) @@ -589,9 +555,9 @@ def upload_youtube_recording_to_pod(request, record_id): "Try changing the access rights to the video directly in Youtube." ) raise ValueError(msg) - except PytubeError: + except PytubeError as pterror: msg = {} - msg["error"] = _("YouTube error") + msg["error"] = _("YouTube error '%s'" % (mark_safe(pterror))) msg["message"] = _( "YouTube content is inaccessible. " "This content does not appear to be publicly available." @@ -738,3 +704,63 @@ def upload_peertube_recording_to_pod(request, record_id): # noqa: C901 "Try changing the record type or address for this recording." ) raise ValueError(msg) + + +def get_stateless_recording(request, data): + """Return a stateless recording from an external recording. + + Args: + request (Request): HTTP request + data (ExternalRecording): external recording + + Returns: + StatelessRecording: stateless recording + """ + recording = StatelessRecording(data.id, data.name, "published") + # By default, upload to Pod is possible + recording.canUpload = True + # Only owner can delete this external recording + recording.canDelete = get_can_delete_external_recording(request, data.owner) + + recording.startTime = data.start_at + + recording.uploadedToPodBy = data.uploaded_to_pod_by + + # State management + if recording.uploadedToPodBy is None: + recording.state = _("Video file not uploaded to Pod") + else: + recording.state = _("Video file already uploaded to Pod") + + # Management of the external recording type + if data.type == "bigbluebutton": + # For BBB, external URL can be the video or presentation playback + if data.source_url.find("playback/video") != -1: + # Management for standards video URLs with BBB or Scalelite server + recording.videoUrl = data.source_url + elif data.source_url.find("playback/presentation/2.3") != -1: + # Management for standards presentation URLs with BBB or Scalelite server + # Add computed video playback + recording.videoUrl = data.source_url.replace( + "playback/presentation/2.3", "playback/video" + ) + recording.presentationUrl = data.source_url + else: + # Management of other situations, non standards URLs + recording.videoUrl = data.source_url + + # For old BBB or BBB 2.6+ without video playback + if check_file_exists(recording.videoUrl) is False: + recording.state = _( + "No video file found. " "Upload to Pod as a video is not possible." + ) + recording.canUpload = False + recording.videoUrl = "" + else: + # For PeerTube, Video file, Youtube + recording.videoUrl = data.source_url + + # Display type label + recording.type = data.get_type_display + + return recording diff --git a/pod/locale/fr/LC_MESSAGES/django.mo b/pod/locale/fr/LC_MESSAGES/django.mo index 13c7efefda..5cd2a15bf8 100644 Binary files a/pod/locale/fr/LC_MESSAGES/django.mo and b/pod/locale/fr/LC_MESSAGES/django.mo differ diff --git a/pod/locale/fr/LC_MESSAGES/django.po b/pod/locale/fr/LC_MESSAGES/django.po index 97116f7848..020096deb2 100644 --- a/pod/locale/fr/LC_MESSAGES/django.po +++ b/pod/locale/fr/LC_MESSAGES/django.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Pod\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2023-06-19 09:33+0200\n" +"POT-Creation-Date: 2023-06-27 09:34+0200\n" "PO-Revision-Date: \n" "Last-Translator: obado \n" "Language-Team: Pod Team pod@esup-portail.org\n" @@ -205,7 +205,6 @@ msgstr "Fermer" #: pod/completion/templates/video_caption_maker.html #: pod/enrichment/templates/enrichment/group_enrichment.html #: pod/import_video/templates/import_video/add_or_edit.html -#: pod/import_video/templates/import_video/delete.html #: pod/import_video/views.py pod/live/templates/live/event-form.html #: pod/live/templates/live/event_delete.html #: pod/live/templates/live/event_edit.html @@ -234,7 +233,6 @@ msgstr "Une ou plusieurs erreurs ont été trouvées dans le formulaire." #: pod/completion/templates/video_caption_maker.html #: pod/enrichment/templates/enrichment/group_enrichment.html #: pod/import_video/templates/import_video/add_or_edit.html -#: pod/import_video/templates/import_video/delete.html #: pod/live/templates/live/event-form.html #: pod/live/templates/live/event_delete.html #: pod/live/templates/live/event_edit.html @@ -568,7 +566,6 @@ msgid "Publish this presentation" msgstr "Publier cette présentation" #: pod/bbb/templates/bbb/card.html -#: pod/import_video/templates/import_video/list.html #: pod/meeting/templates/meeting/internal_recordings.html msgid "by" msgstr "par" @@ -978,7 +975,6 @@ msgstr "Supprimer le chapitre" #: pod/completion/templates/document/list_document.html #: pod/completion/templates/overlay/list_overlay.html #: pod/enrichment/templates/enrichment/list_enrichment.html -#: pod/import_video/templates/import_video/delete.html #: pod/live/templates/live/event_delete.html #: pod/meeting/templates/meeting/delete.html #: pod/playlist/templates/playlist.html @@ -2446,42 +2442,6 @@ msgstr "" msgid "YouTube's Terms of Service" msgstr "Conditions d’utilisation de YouTube" -#: pod/import_video/templates/import_video/delete.html -#: pod/main/templates/navbar.html -#: pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/delete.html -#: pod/meeting/templates/meeting/internal_recordings.html -#: pod/meeting/templates/meeting/invite.html -#: pod/meeting/templates/meeting/join.html -#: pod/meeting/templates/meeting/my_meetings.html pod/meeting/views.py -msgid "My meetings" -msgstr "Mes réunions" - -#: pod/import_video/templates/import_video/delete.html -#: pod/meeting/templates/meeting/delete.html -#, python-format -msgid "Delete the meeting %(name)s" -msgstr "Supprimer la réunion %(name)s" - -#: pod/import_video/templates/import_video/delete.html -#: pod/meeting/templates/meeting/delete.html -msgid "Back to my meetings" -msgstr "Retour à mes réunions" - -#: pod/import_video/templates/import_video/delete.html -#: pod/meeting/templates/meeting/delete.html -msgid "To delete the meeting, please check the box in and click delete." -msgstr "" -"Pour supprimer la réunion, veuillez cocher la case et cliquer sur supprimer." - -#: pod/import_video/templates/import_video/delete.html -#: pod/live/templates/live/event_delete.html -#: pod/meeting/templates/meeting/delete.html -#: pod/recorder/templates/recorder/record_delete.html -#: pod/video/templates/videos/video_delete.html -msgid "Agree required" -msgstr "Accord requis" - #: pod/import_video/templates/import_video/filter_aside.html #: pod/live/templates/live/filter_aside.html #: pod/meeting/templates/meeting/filter_aside.html @@ -2534,7 +2494,7 @@ msgstr "Vous devez créer une vidéo externe avant de pouvoir l'importer." #: pod/meeting/templates/meeting/internal_recordings.html msgid "Do not leave the page until the video upload to Pod is complete." msgstr "" -"Ne quittez pas la page tant que le téléchargement de la vidéo sur Pod n’est " +"Ne quittez pas la page tant que le téléversement de la vidéo sur Pod n’est " "pas terminé." #: pod/import_video/templates/import_video/list.html pod/main/forms.py @@ -2567,16 +2527,6 @@ msgstr "Importer" msgid "Manage" msgstr "Gérer" -#: pod/import_video/templates/import_video/list.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Video file not uploaded to Pod" -msgstr "Le fichier vidéo n’a pas été téléversé sur Pod" - -#: pod/import_video/templates/import_video/list.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Video file already uploaded to Pod" -msgstr "Fichier vidéo déjà téléversé sur Pod" - #: pod/import_video/templates/import_video/list.html #: pod/meeting/templates/meeting/internal_recordings.html msgid "Display the recording in presentation format" @@ -2588,7 +2538,6 @@ msgid "Display the recording in video format" msgstr "Afficher l’enregistrement au format vidéo" #: pod/import_video/templates/import_video/list.html -#: pod/meeting/templates/meeting/internal_recordings.html msgid "Please confirm you want to upload the recording to Pod" msgstr "" "Veuillez confirmer que vous souhaitez téléverser l’enregistrement sur Pod" @@ -2723,6 +2672,11 @@ msgid "Try changing the access rights to the video directly in Youtube." msgstr "" "Essayez de modifier les droits d’accès à la vidéo directement dans Youtube." +#: pod/import_video/views.py +#, python-format +msgid "YouTube error '%s'" +msgstr "Erreur en lien avec Youtube '%s'" + #: pod/import_video/views.py msgid "" "YouTube content is inaccessible. This content does not appear to be publicly " @@ -2773,6 +2727,22 @@ msgstr "" msgid "Impossible to upload to Pod the PeerTube video" msgstr "Impossible de téléverser la vidéo PeerTube sur Pod" +#: pod/import_video/views.py +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Video file not uploaded to Pod" +msgstr "Le fichier vidéo n’a pas été téléversé sur Pod" + +#: pod/import_video/views.py +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Video file already uploaded to Pod" +msgstr "Fichier vidéo déjà téléversé sur Pod" + +#: pod/import_video/views.py +msgid "No video file found. Upload to Pod as a video is not possible." +msgstr "" +"Aucun fichier vidéo trouvé. Le téléversement sur Pod en tant que vidéo n’est " +"pas possible." + #: pod/live/admin.py pod/live/models.py msgid "QR code to record immediately an event" msgstr "QR code pour la programmation d’un évènement immédiat" @@ -3473,6 +3443,13 @@ msgstr "L’évènement est actuellement en cours. La supression est impossible. msgid "To delete the event, please checked in and click send." msgstr "Pour supprimer l’évènement, veuillez cocher et cliquer sur envoyer." +#: pod/live/templates/live/event_delete.html +#: pod/meeting/templates/meeting/delete.html +#: pod/recorder/templates/recorder/record_delete.html +#: pod/video/templates/videos/video_delete.html +msgid "Agree required" +msgstr "Accord requis" + #: pod/live/templates/live/event_edit.html #: pod/live/templates/live/event_immediate_edit.html msgid "" @@ -4588,6 +4565,16 @@ msgstr "Certaines fonctionnalités sont indisponibles" msgid "Add a video" msgstr "Ajouter une vidéo" +#: pod/main/templates/navbar.html +#: pod/meeting/templates/meeting/add_or_edit.html +#: pod/meeting/templates/meeting/delete.html +#: pod/meeting/templates/meeting/internal_recordings.html +#: pod/meeting/templates/meeting/invite.html +#: pod/meeting/templates/meeting/join.html +#: pod/meeting/templates/meeting/my_meetings.html pod/meeting/views.py +msgid "My meetings" +msgstr "Mes réunions" + #: pod/main/templates/navbar.html msgid "Toggle configuration panel" msgstr "Basculer le panneau de configuration" @@ -5113,6 +5100,20 @@ msgstr "" "L’accès à l’ajout d’une réunion a été limité. Si vous souhaitez ajouter des " "réunions sur la plateforme, veuillez" +#: pod/meeting/templates/meeting/delete.html +#, python-format +msgid "Delete the meeting %(name)s" +msgstr "Supprimer la réunion %(name)s" + +#: pod/meeting/templates/meeting/delete.html +msgid "Back to my meetings" +msgstr "Retour à mes réunions" + +#: pod/meeting/templates/meeting/delete.html +msgid "To delete the meeting, please check the box in and click delete." +msgstr "" +"Pour supprimer la réunion, veuillez cocher la case et cliquer sur supprimer." + #: pod/meeting/templates/meeting/filter_aside.html pod/video/views.py msgid "Status" msgstr "Statut" @@ -5133,6 +5134,11 @@ msgstr "Enregistrements de réunion" msgid "Toolbar" msgstr "Barre d’outils" +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Please confirm you want to upload the recording To Pod" +msgstr "" +"Veuillez confirmer que vous souhaitez téléverser l’enregistrement sur Pod" + #: pod/meeting/templates/meeting/internal_recordings.html msgid "Please confirm you want to delete the recording" msgstr "Veuillez confirmer que vous souhaitez supprimer l’enregistrement" diff --git a/pod/locale/fr/LC_MESSAGES/djangojs.mo b/pod/locale/fr/LC_MESSAGES/djangojs.mo index ccf0a8e687..9a76085bb5 100644 Binary files a/pod/locale/fr/LC_MESSAGES/djangojs.mo and b/pod/locale/fr/LC_MESSAGES/djangojs.mo differ diff --git a/pod/locale/fr/LC_MESSAGES/djangojs.po b/pod/locale/fr/LC_MESSAGES/djangojs.po index 920999070e..3142de6008 100644 --- a/pod/locale/fr/LC_MESSAGES/djangojs.po +++ b/pod/locale/fr/LC_MESSAGES/djangojs.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Esup-Pod\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2023-06-12 13:57+0200\n" +"POT-Creation-Date: 2023-06-27 09:35+0200\n" "PO-Revision-Date: \n" "Last-Translator: obado \n" "Language-Team: \n" @@ -26,12 +26,12 @@ msgid "Close" msgstr "Fermer" #: pod/chapter/static/js/chapters.js pod/completion/static/js/completion.js -#: pod/enrichment/static/js/enrichment.js +#: pod/enrichment/static/js/enrichment.js pod/playlist/static/js/playlist.js msgid "Error getting form." msgstr "Erreur lors de la récupération du formulaire." #: pod/chapter/static/js/chapters.js pod/completion/static/js/completion.js -#: pod/enrichment/static/js/enrichment.js +#: pod/enrichment/static/js/enrichment.js pod/playlist/static/js/playlist.js msgid "The form could not be recovered." msgstr "Le formulaire ne peut pas être récupéré." @@ -176,6 +176,16 @@ msgstr "Veuillez entrer un texte pour le segment compris entre %s et %s :" msgid "Pause to enter caption for segment from %s to %s." msgstr "Mettez en pause pour entrer le texte du segment entre %s et %s." +#: pod/completion/static/js/caption_maker.js +#: pod/podfile/static/podfile/js/filewidget.js +msgid "Add" +msgstr "Ajouter" + +#: pod/completion/static/js/caption_maker.js +#: pod/video/static/js/comment-script.js +msgid "Delete" +msgstr "Supprimer" + #: pod/completion/static/js/caption_maker.js msgid "Caption" msgstr "Légende / Sous-titre" @@ -484,6 +494,21 @@ msgstr "" "Cette extension de fichier n’est pas présente dans les extensions " "autorisées :" +#: pod/playlist/static/js/playlist.js +msgid "Position saved" +msgstr "Position enregistrée" + +#: pod/playlist/static/js/playlist.js +msgid "Error deleting video from playlist. The video could not be deleted." +msgstr "" +"Erreur lors de la suppression de la vidéo de la liste de lecture. La vidéo " +"n’a pas pu être retirée." + +#: pod/playlist/static/js/playlist.js +msgid "Error deleting playlist. The playlist could not be deleted." +msgstr "" +"Erreur lors de la suppression. La liste de lecture n’a pas pu être supprimée." + #: pod/playlist/static/js/playlist.js msgid "The video can not be added from this page." msgstr "La vidéo ne peut être ajoutée depuis cette page." @@ -528,10 +553,6 @@ msgstr "Retirer" msgid "Server error" msgstr "Erreur du serveur" -#: pod/podfile/static/podfile/js/filewidget.js -msgid "Add" -msgstr "Ajouter" - #: pod/podfile/static/podfile/js/filewidget.js msgid "Are you sure you want to delete this folder?" msgstr "Êtes-vous sûr(e) de vouloir supprimer ce dossier ?" @@ -568,22 +589,41 @@ msgstr "Réponse" msgid "Answers" msgstr "Réponses" -#: pod/video/static/js/comment-script.js -msgid "Delete" -msgstr "Supprimer" - #: pod/video/static/js/comment-script.js msgid "Cancel" msgstr "Annuler" +#: pod/video/static/js/comment-script.js +#, javascript-format +msgid "%s vote" +msgid_plural "%s votes" +msgstr[0] "%s vote" +msgstr[1] "%s votes" + #: pod/video/static/js/comment-script.js msgid "Agree with the comment" msgstr "D’accord avec ce commentaire" +#: pod/video/static/js/comment-script.js +msgid "Reply to comment" +msgstr "Répondre au commentaire" + +#: pod/video/static/js/comment-script.js +msgid "Reply" +msgstr "Répondre" + #: pod/video/static/js/comment-script.js msgid "Remove this comment" msgstr "Supprimer ce commentaire" +#: pod/video/static/js/comment-script.js +msgid "Add a public comment" +msgstr "Ajouter un commentaire public" + +#: pod/video/static/js/comment-script.js +msgid "Send" +msgstr "Envoyer" + #: pod/video/static/js/comment-script.js msgid "Show answers" msgstr "Afficher les réponses" @@ -596,13 +636,6 @@ msgstr "Mauvaise réponse du serveur." msgid "Sorry, you're not allowed to vote by now." msgstr "Désolé, vous n’êtes pas autorisé à voter maintenant." -#: pod/video/static/js/comment-script.js -#, javascript-format -msgid "%s vote" -msgid_plural "%s votes" -msgstr[0] "%s vote" -msgstr[1] "%s votes" - #: pod/video/static/js/comment-script.js msgid "Sorry, you can't comment this video by now." msgstr "Désolé, vous ne pouvez pas commenter cette vidéo maintenant." @@ -635,38 +668,47 @@ msgid "An Error occurred while processing." msgstr "Une erreur est survenue durant l’exécution du processus." #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "This content is password protected." msgstr "Ce contenu est protégé par mot de passe." #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "This content is chaptered." msgstr "Ce contenu est chapitré." #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "This content is in draft." msgstr "Ce contenu est en brouillon." #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Video content." msgstr "Contenu vidéo." #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Audio content." msgstr "Contenu audio." #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Edit the video" msgstr "Éditer la vidéo" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Complete the video" msgstr "Compléter la vidéo" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Chapter the video" msgstr "Chapitrer la vidéo" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Delete the video" msgstr "Supprimer la vidéo" @@ -727,6 +769,18 @@ msgstr "Désolé, aucune vidéo trouvée" msgid "Edit the category" msgstr "Éditer la catégorie" +#: pod/video/static/js/video_category.js +msgid "Delete the category" +msgstr "Supprimer la catégorie" + +#: pod/video/static/js/video_category.js +msgid "Success!" +msgstr "Succès !" + +#: pod/video/static/js/video_category.js +msgid "Error…" +msgstr "Erreur…" + #: pod/video/static/js/video_category.js msgid "Category created successfully" msgstr "Catégorie créée avec succès" @@ -783,40 +837,6 @@ msgstr "Ajouts en favoris total depuis la création" msgid "Slug" msgstr "Titre court" -#~ msgid "Position saved" -#~ msgstr "Position enregistrée" - -#~ msgid "Error deleting video from playlist. The video could not be deleted." -#~ msgstr "" -#~ "Erreur lors de la suppression de la vidéo de la liste de lecture. La " -#~ "vidéo n’a pas pu être retirée." - -#~ msgid "Error deleting playlist. The playlist could not be deleted." -#~ msgstr "" -#~ "Erreur lors de la suppression. La liste de lecture n’a pas pu être " -#~ "supprimée." - -#~ msgid "Reply to comment" -#~ msgstr "Répondre au commentaire" - -#~ msgid "Reply" -#~ msgstr "Répondre" - -#~ msgid "Add a public comment" -#~ msgstr "Ajouter un commentaire public" - -#~ msgid "Send" -#~ msgstr "Envoyer" - -#~ msgid "Delete the category" -#~ msgstr "Supprimer la catégorie" - -#~ msgid "Success!" -#~ msgstr "Succès !" - -#~ msgid "Error…" -#~ msgstr "Erreur…" - #~ msgid "Are you sure you want to delete this element?" #~ msgstr "Êtes-vous sûr(e) de vouloir supprimer cet élément ?" diff --git a/pod/locale/nl/LC_MESSAGES/django.po b/pod/locale/nl/LC_MESSAGES/django.po index 45739e3cb6..50d2413f7c 100644 --- a/pod/locale/nl/LC_MESSAGES/django.po +++ b/pod/locale/nl/LC_MESSAGES/django.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Pod\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2023-06-12 13:57+0200\n" +"POT-Creation-Date: 2023-06-27 09:34+0200\n" "PO-Revision-Date: 2023-06-08 14:37+0200\n" "Last-Translator: obado \n" "Language-Team: \n" @@ -173,12 +173,12 @@ msgstr "" #: pod/authentication/templates/userpicture/userpicture.html #: pod/bbb/templates/bbb/list_meeting.html #: pod/completion/templates/video_caption_maker.html +#: pod/import_video/templates/import_video/add_or_edit.html #: pod/live/templates/live/direct.html #: pod/live/templates/live/event-iframe.html #: pod/live/templates/live/event-info.html pod/main/templates/base.html #: pod/main/templates/navbar.html pod/main/templates/navbar_collapse.html #: pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html #: pod/meeting/templates/meeting/my_meetings.html #: pod/playlist/templates/playlist/playlist_video_list.html #: pod/playlist/templates/playlist_player-iframe.html @@ -200,13 +200,13 @@ msgstr "" #: pod/bbb/templates/bbb/publish_meeting.html pod/bbb/views.py #: pod/completion/templates/video_caption_maker.html #: pod/enrichment/templates/enrichment/group_enrichment.html -#: pod/live/templates/live/event-form.html +#: pod/import_video/templates/import_video/add_or_edit.html +#: pod/import_video/views.py pod/live/templates/live/event-form.html #: pod/live/templates/live/event_delete.html #: pod/live/templates/live/event_edit.html #: pod/live/templates/live/event_immediate_edit.html pod/live/views.py #: pod/main/templates/contact_us.html pod/main/tests/test_views.py #: pod/main/views.py pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html #: pod/meeting/templates/meeting/delete.html #: pod/meeting/templates/meeting/invite.html #: pod/meeting/templates/meeting/join.html pod/meeting/views.py @@ -228,13 +228,13 @@ msgstr "" #: pod/bbb/templates/bbb/publish_meeting.html #: pod/completion/templates/video_caption_maker.html #: pod/enrichment/templates/enrichment/group_enrichment.html +#: pod/import_video/templates/import_video/add_or_edit.html #: pod/live/templates/live/event-form.html #: pod/live/templates/live/event_delete.html #: pod/live/templates/live/event_edit.html #: pod/live/templates/live/event_immediate_edit.html #: pod/main/templates/contact_us.html #: pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html #: pod/meeting/templates/meeting/delete.html #: pod/meeting/templates/meeting/invite.html #: pod/meeting/templates/meeting/join.html @@ -350,8 +350,8 @@ msgstr "" msgid "URL of the recording thumbnail of the BBB presentation." msgstr "" -#: pod/bbb/models.py pod/favorite/models.py pod/meeting/models.py -#: pod/recorder/models.py +#: pod/bbb/models.py pod/favorite/models.py pod/import_video/models.py +#: pod/meeting/models.py pod/recorder/models.py msgid "User" msgstr "" @@ -411,8 +411,9 @@ msgstr "" msgid "Attendees" msgstr "" -#: pod/bbb/models.py pod/live/forms.py pod/live/models.py pod/meeting/forms.py -#: pod/meeting/models.py pod/video_search/forms.py +#: pod/bbb/models.py pod/import_video/models.py pod/live/forms.py +#: pod/live/models.py pod/meeting/forms.py pod/meeting/models.py +#: pod/video_search/forms.py msgid "Start date" msgstr "" @@ -548,7 +549,6 @@ msgid "Publish this presentation" msgstr "" #: pod/bbb/templates/bbb/card.html -#: pod/meeting/templates/meeting/external_recordings.html #: pod/meeting/templates/meeting/internal_recordings.html msgid "by" msgstr "" @@ -833,8 +833,8 @@ msgstr "" #: pod/completion/templates/video_caption_maker.html #: pod/enrichment/templates/enrichment/form_enrichment.html #: pod/enrichment/templates/enrichment/group_enrichment.html +#: pod/import_video/templates/import_video/add_or_edit.html #: pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html #: pod/playlist/templates/playlist.html #: pod/recorder/templates/recorder/add_recording.html #: pod/video/templates/channel/channel_edit.html @@ -1842,9 +1842,9 @@ msgid "End of enrichment display in seconds." msgstr "" #: pod/enrichment/models.py -#: pod/enrichment/templates/enrichment/list_enrichment.html pod/live/models.py -#: pod/meeting/templates/meeting/external_recordings.html pod/video/forms.py -#: pod/video/models.py pod/video/views.py +#: pod/enrichment/templates/enrichment/list_enrichment.html +#: pod/import_video/templates/import_video/list.html pod/live/models.py +#: pod/video/forms.py pod/video/models.py pod/video/views.py #: pod/video_search/templates/search/search.html msgid "Type" msgstr "" @@ -2113,260 +2113,711 @@ msgstr "Déposez la vidéo sur une autre pour échanger leur position." msgid "Number of favorites" msgstr "" -#: pod/live/admin.py pod/live/models.py -msgid "QR code to record immediately an event" +#: pod/import_video/apps.py +msgid "Import External Video" msgstr "" -#: pod/live/admin.py -msgid "QR Code" +#: pod/import_video/forms.py pod/meeting/forms.py +msgid "Please enter a valid address" +msgstr "Vul alstublieft een geldig adres in" + +#: pod/import_video/models.py pod/meeting/models.py +msgid "Recording name" msgstr "" -#: pod/live/admin.py pod/live/models.py pod/recorder/models.py -#: pod/video/models.py -msgid "password" +#: pod/import_video/models.py pod/meeting/models.py +msgid "Please enter a name that will allow you to easily find this recording." msgstr "" -#: pod/live/admin.py pod/meeting/admin.py pod/video/admin.py -msgid "Yes" +#: pod/import_video/models.py pod/meeting/models.py +msgid "User who create this recording" msgstr "" -#: pod/live/admin.py pod/meeting/admin.py pod/video/admin.py -msgid "No" +#: pod/import_video/models.py pod/meeting/models.py pod/video/models.py +msgid "Site" msgstr "" -#: pod/live/admin.py -msgid "Auto start admin" +#: pod/import_video/models.py +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "Big Blue Button" msgstr "" -#: pod/live/admin.py pod/live/models.py pod/video/models.py -msgid "Thumbnails" +#: pod/import_video/models.py +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "PeerTube" msgstr "" -#: pod/live/apps.py pod/live/templates/live/direct.html -#: pod/live/templates/live/directs.html -#: pod/live/templates/live/directs_all.html pod/main/templates/navbar.html -msgid "Lives" +#: pod/import_video/models.py +msgid "Video file" msgstr "" -#: pod/live/forms.py pod/live/models.py -msgid "Piloting implementation" +#: pod/import_video/models.py +msgid "Youtube" msgstr "" -#: pod/live/forms.py pod/live/models.py -msgid "Select the piloting implementation for to this broadcaster." +#: pod/import_video/models.py +msgid "External record type" msgstr "" -#: pod/live/forms.py -msgid "End should not be in the past" +#: pod/import_video/models.py +msgid "" +"It is possible to manage recordings from Big Blue Button or another source " +"delivering video files." msgstr "" -#: pod/live/forms.py pod/live/models.py -msgid "An event cannot be planned in the past" +#: pod/import_video/models.py pod/meeting/models.py +msgid "Address of the recording to download" msgstr "" -#: pod/live/forms.py -msgid "Start should not be after end" +#: pod/import_video/models.py pod/meeting/models.py +msgid "" +"Please enter the address of the recording to download. This address must " +"match the record type selected." msgstr "" -#: pod/live/forms.py -msgid "Planification error." +#: pod/import_video/models.py pod/meeting/models.py +msgid "User who uploaded to Pod the video file" msgstr "" -#: pod/live/forms.py -msgid "An event is already planned at these dates" +#: pod/import_video/models.py +msgid "External recordings" msgstr "" -#: pod/live/forms.py pod/meeting/forms.py pod/video/forms.py -msgid "Password" +#: pod/import_video/templates/import_video/add_or_edit.html +#: pod/import_video/templates/import_video/list.html pod/import_video/views.py +msgid "My external videos" msgstr "" -#: pod/live/forms.py pod/live/templates/live/event_edit.html -msgid "Display advanced options" +#: pod/import_video/templates/import_video/add_or_edit.html +#: pod/import_video/views.py +msgid "Edit the external video" msgstr "" -#: pod/live/forms.py pod/live/models.py -msgid "Building" +#: pod/import_video/templates/import_video/add_or_edit.html +#: pod/import_video/templates/import_video/list.html pod/import_video/views.py +msgid "Create an external video" msgstr "" -#: pod/live/forms.py -msgid "Broadcaster device" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "" +"Access to adding external recording has been restricted. If you want to add " +"external recordings on the platform, please" msgstr "" -#: pod/live/forms.py pod/meeting/forms.py pod/recorder/forms.py -#: pod/video/forms.py -msgid "I agree" +#: pod/import_video/templates/import_video/add_or_edit.html +#: pod/live/templates/live/event_edit.html +#: pod/live/templates/live/event_immediate_edit.html +#: pod/meeting/templates/meeting/add_or_edit.html +#: pod/meeting/templates/meeting/my_meetings.html +#: pod/video/templates/videos/add_video.html +#: pod/video/templates/videos/video_edit.html +msgid "contact us" msgstr "" -#: pod/live/forms.py -msgid "Delete event cannot be undo" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "" +"To centralize Big Blue Button, PeerTube, video file, Youtube recordings on " +"this platform, first, please enter the information below." msgstr "" -#: pod/live/forms.py -#, python-format -msgid "Recording of %(user)s the %(date)s" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "Then you can import this video to Pod." msgstr "" -#: pod/live/models.py pod/recorder/models.py -msgid "name" +#: pod/import_video/templates/import_video/add_or_edit.html +#: pod/video/templates/videos/add_video.html +#: pod/video/templates/videos/video_edit.html +msgid "Uploading" msgstr "" -#: pod/live/models.py pod/live/templates/live/direct.html pod/video/models.py -#: pod/video/templates/channel/channel.html -#: pod/video/templates/channel/channel_edit.html -#: pod/video/templates/channel/list_theme.html -#: pod/video/templates/videos/video.html -msgid "Headband" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "" +"To retrieve recordings from other interfaces, just copy the link to the Big " +"Blue Button, PeerTube, Youtube or other video from the app." msgstr "" -#: pod/live/models.py -msgid "Buildings" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "" +"All you have to do is paste this link in the 'Address of the recording to " +"download' field, and enter the additional information." msgstr "" -#: pod/live/models.py pod/recorder/models.py -msgid "description" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "" +"Once the entry is made, you will be able - if the original application " +"allows it and if the video is publicly available - to upload the video to " +"this platform." msgstr "" -#: pod/live/models.py -msgid "Poster" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "To do this, please use the 'Upload to Pod as video' button in the list." msgstr "" -#: pod/live/models.py -msgid "URL" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "" +"You will then be able to find the encoded video directly in the My videos " +"tab after a while." msgstr "" -#: pod/live/models.py -msgid "Url of the stream" +#: pod/import_video/templates/import_video/add_or_edit.html +#: pod/video/templates/videos/add_video.html +#: pod/video/templates/videos/video_edit.html +msgid "An email will be sent to you when all encoding tasks are completed." msgstr "" -#: pod/live/models.py -msgid "Check if the broadcaster is currently sending stream." +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "Terms of Service" msgstr "" -#: pod/live/models.py -msgid "Enable add event" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "" +"It is necessary to respect the terms of use of the various services before " +"being able to upload a video from their site to this platform." msgstr "" -#: pod/live/models.py -msgid "If checked, it will allow to create an event to this broadcaster." +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "More infomations on Big Blue Button" msgstr "" -#: pod/live/models.py -msgid "Enable viewers count" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "More infomations on PeerTube" msgstr "" -#: pod/live/models.py -msgid "Enable viewers count on live." +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "YouTube" msgstr "" -#: pod/live/models.py -msgid "Live is accessible only to authenticated users." +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "" +"Their terms of service state that you are not allowed to download any " +"content unless permitted by YouTube or the person who owns the copyright to " +"the content." msgstr "" -#: pod/live/models.py -msgid "Show in live tab" +#: pod/import_video/templates/import_video/add_or_edit.html +msgid "YouTube's Terms of Service" msgstr "" -#: pod/live/models.py -msgid "Live is accessible from the Live tab" +#: pod/import_video/templates/import_video/filter_aside.html +#: pod/live/templates/live/filter_aside.html +#: pod/meeting/templates/meeting/filter_aside.html +#: pod/meeting/templates/meeting/filter_aside_recording.html +#: pod/video/templates/videos/filter_aside.html +msgid "Filters" msgstr "" -#: pod/live/models.py -msgid "Select one or more groups who can manage event to this broadcaster." +#: pod/import_video/templates/import_video/filter_aside.html +#: pod/main/templates/aside.html +#: pod/meeting/templates/meeting/filter_aside_recording.html +#: pod/recorder/models.py pod/video/forms.py pod/video/models.py +#: pod/video/templates/videos/filter_aside.html +#: pod/video_search/templates/search/search.html +msgid "Tags" msgstr "" -#: pod/live/models.py -msgid "Piloting configuration parameters" +#: pod/import_video/templates/import_video/filter_aside.html +#: pod/main/templates/navbar.html pod/main/templates/navbar_collapse.html +#: pod/meeting/templates/meeting/filter_aside_recording.html +#: pod/video/templates/videos/filter_aside.html +#: pod/video/templates/videos/filter_aside_category.html +#: pod/video_search/forms.py pod/video_search/templates/search/search.html +msgid "Search" msgstr "" -#: pod/live/models.py -msgid "Add piloting configuration parameters in Json format." +#: pod/import_video/templates/import_video/filter_aside.html +#: pod/meeting/templates/meeting/filter_aside_recording.html +msgid "Type at least 3 chars to filter" msgstr "" -#: pod/live/models.py pod/recorder/models.py pod/video/forms.py -#: pod/video/models.py pod/video_search/templates/search/search.html -msgid "Main language" +#: pod/import_video/templates/import_video/list.html +msgid "" +"If you have achieved Big Blue Button meetings via another interface " +"(typically via Moodle), or if you wish to centralize PeerTube, Youtube or " +"other videos on Pod, it is possible to retrieve these recordings and be able " +"to convert them into video in this platform (under certain conditions)." msgstr "" -#: pod/live/models.py pod/recorder/models.py pod/video/forms.py -#: pod/video/models.py -msgid "Select the main language used in the content." +#: pod/import_video/templates/import_video/list.html +msgid "You need to create an external video before you can import it." msgstr "" -#: pod/live/models.py -msgid "Broadcasters" +#: pod/import_video/templates/import_video/list.html +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Do not leave the page until the video upload to Pod is complete." msgstr "" -#: pod/live/models.py -msgid "Is recording?" +#: pod/import_video/templates/import_video/list.html pod/main/forms.py +#: pod/meeting/forms.py pod/meeting/templates/meeting/internal_recordings.html +#: pod/podfile/models.py pod/podfile/templates/podfile/home_content.html +#: pod/video_encode_transcript/models.py +msgid "Name" msgstr "" -#: pod/live/models.py pod/video/models.py -msgid "" -"Please choose a title as short and accurate as possible, reflecting the main " -"subject / context of the content. (max length: 250 characters)" +#: pod/import_video/templates/import_video/list.html +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "State" msgstr "" -#: pod/live/models.py pod/main/forms.py pod/main/models.py -#: pod/playlist/models.py pod/video/forms.py pod/video/models.py -#: pod/video/templates/channel/list_theme.html -msgid "Description" +#: pod/import_video/templates/import_video/list.html pod/meeting/admin.py +#: pod/meeting/templates/meeting/internal_recordings.html pod/video/models.py +msgid "Date" msgstr "" -#: pod/live/models.py pod/video/forms.py pod/video/models.py -msgid "" -"In this field you can describe your content, add all needed related " -"information, and format the result using the toolbar." +#: pod/import_video/templates/import_video/list.html +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Playback" msgstr "" -#: pod/live/models.py pod/meeting/models.py pod/video/forms.py -#: pod/video/models.py -msgid "Additional owners" +#: pod/import_video/templates/import_video/list.html +msgid "Import" msgstr "" -#: pod/live/models.py -msgid "" -"You can add additional owners to the event. They will have the same rights " -"as you except that they can't delete this event." +#: pod/import_video/templates/import_video/list.html +msgid "Manage" msgstr "" -#: pod/live/models.py -msgid "Start of the live event." +#: pod/import_video/templates/import_video/list.html +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Display the recording in presentation format" msgstr "" -#: pod/live/models.py -msgid "End of the live event." +#: pod/import_video/templates/import_video/list.html +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Display the recording in video format" msgstr "" -#: pod/live/models.py -msgid "Broadcaster name." +#: pod/import_video/templates/import_video/list.html +msgid "Please confirm you want to upload the recording to Pod" msgstr "" -#: pod/live/models.py -msgid "Embedded Site URL" +#: pod/import_video/templates/import_video/list.html +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Upload to Pod as a video" msgstr "" -#: pod/live/models.py -msgid "Url of the embedded site to display" +#: pod/import_video/templates/import_video/list.html +msgid "Please confirm you want to delete the external recording" msgstr "" -#: pod/live/models.py -msgid "Embedded Site Height" +#: pod/import_video/templates/import_video/list.html +msgid "Edit the external recording" msgstr "" -#: pod/live/models.py -msgid "Height of the embedded site (in pixels)" +#: pod/import_video/templates/import_video/list.html +msgid "Delete the external recording" msgstr "" -#: pod/live/models.py -msgid "Embedded aside Site URL" +#: pod/import_video/utils.py pod/import_video/views.py pod/meeting/views.py +msgid "Impossible to upload to Pod the video" msgstr "" -#: pod/live/models.py -msgid "Url of the embedded site to display on aside" +#: pod/import_video/utils.py +msgid "No URL found / No recording name" msgstr "" -#: pod/live/models.py pod/recorder/models.py pod/video/forms.py -#: pod/video/models.py +#: pod/import_video/utils.py +msgid "Try changing the record type or address for this recording" +msgstr "" + +#: pod/import_video/utils.py +msgid "The HTML file for this recording was not found on the BBB server." +msgstr "" + +#: pod/import_video/utils.py +msgid "The video file for this recording was not found in the HTML file." +msgstr "" + +#: pod/import_video/utils.py +msgid "The found file is not a valid video." +msgstr "" + +#: pod/import_video/utils.py +msgid "No video file found" +msgstr "" + +#: pod/import_video/utils.py +msgid "The video file for this recording was not found on the BBB server." +msgstr "" + +#: pod/import_video/utils.py +msgid "Impossible to download the video file from the server." +msgstr "" + +#: pod/import_video/utils.py +msgid "Impossible to create the Pod video" +msgstr "" + +#: pod/import_video/views.py +msgid "You cannot view this recording." +msgstr "" + +#: pod/import_video/views.py pod/meeting/views.py +msgid "" +"The recording has been uploaded to Pod. You can see the generated video in " +"My videos." +msgstr "" + +#: pod/import_video/views.py pod/live/views.py pod/meeting/views.py +#: pod/video/views.py +msgid "The changes have been saved." +msgstr "" + +#: pod/import_video/views.py +msgid "The external recording has been deleted." +msgstr "" + +#: pod/import_video/views.py +msgid "Impossible to create the external recording" +msgstr "" + +#: pod/import_video/views.py pod/meeting/views.py +#, python-format +msgid "" +"This video was uploaded to Pod; its origin is %(type)s : %(url)s" +msgstr "" + +#: pod/import_video/views.py pod/meeting/views.py +msgid "Try changing the record type or address for this recording." +msgstr "" + +#: pod/import_video/views.py +#, python-format +msgid "" +"This video '%(name)s' was uploaded to Pod; its origin is Youtube : %(url)s" +msgstr "" + +#: pod/import_video/views.py +msgid "YouTube error" +msgstr "" + +#: pod/import_video/views.py +msgid "" +"YouTube content is unavailable. This content does not appear to be publicly " +"available." +msgstr "" + +#: pod/import_video/views.py +msgid "Try changing the access rights to the video directly in Youtube." +msgstr "" + +#: pod/import_video/views.py +#, python-format +msgid "YouTube error '%s'" +msgstr "" + +#: pod/import_video/views.py +msgid "" +"YouTube content is inaccessible. This content does not appear to be publicly " +"available." +msgstr "" + +#: pod/import_video/views.py +msgid "Try changing the address of this recording." +msgstr "" + +#: pod/import_video/views.py +msgid "PeerTube error" +msgstr "" + +#: pod/import_video/views.py +msgid "The address entered does not appear to be a valid PeerTube address." +msgstr "" + +#: pod/import_video/views.py +msgid "Try changing the address of the recording." +msgstr "" + +#: pod/import_video/views.py +msgid "" +"The address entered does not appear to be a valid PeerTube address or the " +"PeerTube server is not responding as expected." +msgstr "" + +#: pod/import_video/views.py +msgid "Try changing the address of the recording or retry later." +msgstr "" + +#: pod/import_video/views.py +#, python-format +msgid "" +"This video '%(name)s' was uploaded to Pod; its origin is PeerTube : %(url)s." +msgstr "" + +#: pod/import_video/views.py +msgid "Impossible to upload to Pod the PeerTube video" +msgstr "" + +#: pod/import_video/views.py +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Video file not uploaded to Pod" +msgstr "" + +#: pod/import_video/views.py +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Video file already uploaded to Pod" +msgstr "" + +#: pod/import_video/views.py +msgid "No video file found. Upload to Pod as a video is not possible." +msgstr "" + +#: pod/live/admin.py pod/live/models.py +msgid "QR code to record immediately an event" +msgstr "" + +#: pod/live/admin.py +msgid "QR Code" +msgstr "" + +#: pod/live/admin.py pod/live/models.py pod/recorder/models.py +#: pod/video/models.py +msgid "password" +msgstr "" + +#: pod/live/admin.py pod/meeting/admin.py pod/video/admin.py +msgid "Yes" +msgstr "" + +#: pod/live/admin.py pod/meeting/admin.py pod/video/admin.py +msgid "No" +msgstr "" + +#: pod/live/admin.py +msgid "Auto start admin" +msgstr "" + +#: pod/live/admin.py pod/live/models.py pod/video/models.py +msgid "Thumbnails" +msgstr "" + +#: pod/live/apps.py pod/live/templates/live/direct.html +#: pod/live/templates/live/directs.html +#: pod/live/templates/live/directs_all.html pod/main/templates/navbar.html +msgid "Lives" +msgstr "" + +#: pod/live/forms.py pod/live/models.py +msgid "Piloting implementation" +msgstr "" + +#: pod/live/forms.py pod/live/models.py +msgid "Select the piloting implementation for to this broadcaster." +msgstr "" + +#: pod/live/forms.py +msgid "End should not be in the past" +msgstr "" + +#: pod/live/forms.py pod/live/models.py +msgid "An event cannot be planned in the past" +msgstr "" + +#: pod/live/forms.py +msgid "Start should not be after end" +msgstr "" + +#: pod/live/forms.py +msgid "Planification error." +msgstr "" + +#: pod/live/forms.py +msgid "An event is already planned at these dates" +msgstr "" + +#: pod/live/forms.py pod/meeting/forms.py pod/video/forms.py +msgid "Password" +msgstr "" + +#: pod/live/forms.py pod/live/templates/live/event_edit.html +msgid "Display advanced options" +msgstr "" + +#: pod/live/forms.py pod/live/models.py +msgid "Building" +msgstr "" + +#: pod/live/forms.py +msgid "Broadcaster device" +msgstr "" + +#: pod/live/forms.py pod/meeting/forms.py pod/recorder/forms.py +#: pod/video/forms.py +msgid "I agree" +msgstr "" + +#: pod/live/forms.py +msgid "Delete event cannot be undo" +msgstr "" + +#: pod/live/forms.py +#, python-format +msgid "Recording of %(user)s the %(date)s" +msgstr "" + +#: pod/live/models.py pod/recorder/models.py +msgid "name" +msgstr "" + +#: pod/live/models.py pod/live/templates/live/direct.html pod/video/models.py +#: pod/video/templates/channel/channel.html +#: pod/video/templates/channel/channel_edit.html +#: pod/video/templates/channel/list_theme.html +#: pod/video/templates/videos/video.html +msgid "Headband" +msgstr "" + +#: pod/live/models.py +msgid "Buildings" +msgstr "" + +#: pod/live/models.py pod/recorder/models.py +msgid "description" +msgstr "" + +#: pod/live/models.py +msgid "Poster" +msgstr "" + +#: pod/live/models.py +msgid "URL" +msgstr "" + +#: pod/live/models.py +msgid "Url of the stream" +msgstr "" + +#: pod/live/models.py +msgid "Check if the broadcaster is currently sending stream." +msgstr "" + +#: pod/live/models.py +msgid "Enable add event" +msgstr "" + +#: pod/live/models.py +msgid "If checked, it will allow to create an event to this broadcaster." +msgstr "" + +#: pod/live/models.py +msgid "Enable viewers count" +msgstr "" + +#: pod/live/models.py +msgid "Enable viewers count on live." +msgstr "" + +#: pod/live/models.py +msgid "Live is accessible only to authenticated users." +msgstr "" + +#: pod/live/models.py +msgid "Show in live tab" +msgstr "" + +#: pod/live/models.py +msgid "Live is accessible from the Live tab" +msgstr "" + +#: pod/live/models.py +msgid "Select one or more groups who can manage event to this broadcaster." +msgstr "" + +#: pod/live/models.py +msgid "Piloting configuration parameters" +msgstr "" + +#: pod/live/models.py +msgid "Add piloting configuration parameters in Json format." +msgstr "" + +#: pod/live/models.py pod/recorder/models.py pod/video/forms.py +#: pod/video/models.py pod/video_search/templates/search/search.html +msgid "Main language" +msgstr "" + +#: pod/live/models.py pod/recorder/models.py pod/video/forms.py +#: pod/video/models.py +msgid "Select the main language used in the content." +msgstr "" + +#: pod/live/models.py +msgid "Broadcasters" +msgstr "" + +#: pod/live/models.py +msgid "Is recording?" +msgstr "" + +#: pod/live/models.py pod/video/models.py +msgid "" +"Please choose a title as short and accurate as possible, reflecting the main " +"subject / context of the content. (max length: 250 characters)" +msgstr "" + +#: pod/live/models.py pod/main/forms.py pod/main/models.py +#: pod/playlist/models.py pod/video/forms.py pod/video/models.py +#: pod/video/templates/channel/list_theme.html +msgid "Description" +msgstr "" + +#: pod/live/models.py pod/video/forms.py pod/video/models.py +msgid "" +"In this field you can describe your content, add all needed related " +"information, and format the result using the toolbar." +msgstr "" + +#: pod/live/models.py pod/meeting/models.py pod/video/forms.py +#: pod/video/models.py +msgid "Additional owners" +msgstr "" + +#: pod/live/models.py +msgid "" +"You can add additional owners to the event. They will have the same rights " +"as you except that they can't delete this event." +msgstr "" + +#: pod/live/models.py +msgid "Start of the live event." +msgstr "" + +#: pod/live/models.py +msgid "End of the live event." +msgstr "" + +#: pod/live/models.py +msgid "Broadcaster name." +msgstr "" + +#: pod/live/models.py +msgid "Embedded Site URL" +msgstr "" + +#: pod/live/models.py +msgid "Url of the embedded site to display" +msgstr "" + +#: pod/live/models.py +msgid "Embedded Site Height" +msgstr "" + +#: pod/live/models.py +msgid "Height of the embedded site (in pixels)" +msgstr "" + +#: pod/live/models.py +msgid "Embedded aside Site URL" +msgstr "" + +#: pod/live/models.py +msgid "Url of the embedded site to display on aside" +msgstr "" + +#: pod/live/models.py pod/recorder/models.py pod/video/forms.py +#: pod/video/models.py msgid "Draft" msgstr "" @@ -2786,16 +3237,6 @@ msgid "" "platform, please" msgstr "" -#: pod/live/templates/live/event_edit.html -#: pod/live/templates/live/event_immediate_edit.html -#: pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -#: pod/meeting/templates/meeting/my_meetings.html -#: pod/video/templates/videos/add_video.html -#: pod/video/templates/videos/video_edit.html -msgid "contact us" -msgstr "" - #: pod/live/templates/live/event_edit.html msgid "The event is currently in progress. Editing options are limited." msgstr "" @@ -2889,14 +3330,6 @@ msgstr "" msgid "Show all events" msgstr "" -#: pod/live/templates/live/filter_aside.html -#: pod/meeting/templates/meeting/filter_aside.html -#: pod/meeting/templates/meeting/filter_aside_external_recording.html -#: pod/meeting/templates/meeting/filter_aside_recording.html -#: pod/video/templates/videos/filter_aside.html -msgid "Filters" -msgstr "" - #: pod/live/templates/live/filter_aside.html pod/main/templates/aside.html #: pod/main/templates/navbar.html pod/video/models.py #: pod/video/templates/videos/filter_aside.html @@ -2960,12 +3393,8 @@ msgstr "" msgid "The password is incorrect." msgstr "" -#: pod/live/views.py -msgid "Editing the event" -msgstr "" - -#: pod/live/views.py pod/meeting/views.py pod/video/views.py -msgid "The changes have been saved." +#: pod/live/views.py +msgid "Editing the event" msgstr "" #: pod/live/views.py @@ -3037,14 +3466,6 @@ msgstr "" msgid "Other (please specify)" msgstr "" -#: pod/main/forms.py pod/meeting/forms.py -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html pod/podfile/models.py -#: pod/podfile/templates/podfile/home_content.html pod/video/models.py -#: pod/video_encode_transcript/models.py -msgid "Name" -msgstr "" - #: pod/main/forms.py msgid "Subject" msgstr "" @@ -3776,15 +4197,6 @@ msgstr "" msgid "Disciplines" msgstr "" -#: pod/main/templates/aside.html -#: pod/meeting/templates/meeting/filter_aside_external_recording.html -#: pod/meeting/templates/meeting/filter_aside_recording.html -#: pod/recorder/models.py pod/video/forms.py pod/video/models.py -#: pod/video/templates/videos/filter_aside.html -#: pod/video_search/templates/search/search.html -msgid "Tags" -msgstr "" - #: pod/main/templates/base.html msgid "Toggle side Menu" msgstr "" @@ -3901,15 +4313,6 @@ msgstr "" msgid "Channels" msgstr "" -#: pod/main/templates/navbar.html pod/main/templates/navbar_collapse.html -#: pod/meeting/templates/meeting/filter_aside_external_recording.html -#: pod/meeting/templates/meeting/filter_aside_recording.html -#: pod/video/templates/videos/filter_aside.html -#: pod/video/templates/videos/filter_aside_category.html -#: pod/video_search/forms.py pod/video_search/templates/search/search.html -msgid "Search" -msgstr "" - #: pod/main/templates/navbar.html msgid "Some features are unavailable" msgstr "" @@ -3920,9 +4323,7 @@ msgstr "" #: pod/main/templates/navbar.html #: pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html #: pod/meeting/templates/meeting/delete.html -#: pod/meeting/templates/meeting/external_recordings.html #: pod/meeting/templates/meeting/internal_recordings.html #: pod/meeting/templates/meeting/invite.html #: pod/meeting/templates/meeting/join.html @@ -3966,6 +4367,10 @@ msgstr "" msgid "Video Record" msgstr "" +#: pod/main/templates/navbar.html +msgid "Import an external video" +msgstr "" + #: pod/main/templates/navbar.html pod/video/templates/channel/channel_edit.html #: pod/video/templates/channel/my_channels.html #: pod/video/templates/channel/theme_edit.html pod/video/views.py @@ -4032,6 +4437,10 @@ msgstr "" msgid "Your message has been sent." msgstr "" +#: pod/main/utils.py +msgid "This view cannot be accessed directly." +msgstr "" + #: pod/main/views.py msgid "Link" msgstr "" @@ -4044,11 +4453,6 @@ msgstr "" msgid "join" msgstr "" -#: pod/meeting/admin.py pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html pod/video/models.py -msgid "Date" -msgstr "" - #: pod/meeting/admin.py msgid "Recurring" msgstr "" @@ -4141,14 +4545,6 @@ msgstr "" msgid "Send invite to owner and additional owners" msgstr "" -#: pod/meeting/forms.py -msgid "Owner of the recording cannot be an additional owner too" -msgstr "" - -#: pod/meeting/forms.py -msgid "Please enter a valid address" -msgstr "Vul alstublieft een geldig adres in" - #: pod/meeting/models.py msgid "Daily" msgstr "" @@ -4281,10 +4677,6 @@ msgid "" " " msgstr "" -#: pod/meeting/models.py pod/video/models.py -msgid "Site" -msgstr "" - #: pod/meeting/models.py msgid "Max Participants" msgstr "" @@ -4384,314 +4776,70 @@ msgid "Parent Meeting ID" msgstr "" #: pod/meeting/models.py -msgid "Internal Meeting ID" -msgstr "" - -#: pod/meeting/models.py -msgid "Voice Bridge" -msgstr "" - -#: pod/meeting/models.py -msgid "BBB Create Time" -msgstr "" - -#: pod/meeting/models.py -msgid "" -"The day of the start date of the meeting must be included in the recurrence " -"weekdays." -msgstr "" - -#: pod/meeting/models.py -msgid "Unable to end meeting!" -msgstr "" - -#: pod/meeting/models.py -msgid "Unable to get meeting recordings!" -msgstr "" - -#: pod/meeting/models.py -msgid "Unable to delete recording!" -msgstr "" - -#: pod/meeting/models.py -msgid "Recording name" -msgstr "" - -#: pod/meeting/models.py -msgid "Please enter a name that will allow you to easily find this recording." -msgstr "" - -#: pod/meeting/models.py -msgid "Is this an internal recording ?" -msgstr "" - -#: pod/meeting/models.py -msgid "User who create this recording" -msgstr "" - -#: pod/meeting/models.py -msgid "" -"You can add additional owners to this recording. They will have the same " -"rights as you except that they cannot delete this recording." -msgstr "" - -#: pod/meeting/models.py -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "Big Blue Button" -msgstr "" - -#: pod/meeting/models.py -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "PeerTube" -msgstr "" - -#: pod/meeting/models.py -msgid "Video file" -msgstr "" - -#: pod/meeting/models.py -msgid "Youtube" -msgstr "" - -#: pod/meeting/models.py -msgid "External record type" -msgstr "" - -#: pod/meeting/models.py -msgid "" -"It is possible to manage recordings from Big Blue Button or another source " -"delivering video files." -msgstr "" - -#: pod/meeting/models.py -msgid "Address of the recording to download" -msgstr "" - -#: pod/meeting/models.py -msgid "" -"Please enter the address of the recording to download. This address must " -"match the record type selected." -msgstr "" - -#: pod/meeting/models.py -msgid "User who uploaded to Pod the video file" -msgstr "" - -#: pod/meeting/models.py -msgid "Recording ID" -msgstr "" - -#: pod/meeting/models.py -msgid "Duration of recording" -msgstr "" - -#: pod/meeting/models.py pod/recorder/models.py -msgid "Recordings" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/link_meeting.html pod/meeting/views.py -msgid "Edit the meeting" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit.html pod/meeting/views.py -msgid "Add a new meeting" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit.html -#: pod/meeting/templates/meeting/my_meetings.html -msgid "" -"Access to adding meeting has been restricted. If you want to add meetings on " -"the platform, please" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/my_meetings.html pod/meeting/views.py -msgid "External recordings" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -#: pod/meeting/templates/meeting/external_recordings.html pod/meeting/views.py -msgid "Edit the external recording" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -#: pod/meeting/templates/meeting/external_recordings.html -msgid "Add an external recording" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "" -"Access to adding external recording has been restricted. If you want to add " -"external recordings on the platform, please" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "" -"To centralize Big Blue Button, PeerTube, video file, Youtube recordings on " -"this platform, first, please enter the information below." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "Then, you will be able to upload this recording to Pod." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -#: pod/video/templates/videos/add_video.html -#: pod/video/templates/videos/video_edit.html -msgid "Uploading" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "" -"To retrieve recordings from other interfaces, just copy the link to the Big " -"Blue Button, PeerTube, Youtube or other video from the app." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "" -"All you have to do is paste this link in the 'Address of the recording to " -"download' field, and enter the additional information." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "" -"Once the entry is made, you will be able - if the original application " -"allows it and if the video is publicly available - to upload the video to " -"this platform." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "To do this, please use the 'Upload to Pod as video' button in the list." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "" -"You will then be able to find the encoded video directly in the My videos " -"tab after a while." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -#: pod/video/templates/videos/add_video.html -#: pod/video/templates/videos/video_edit.html -msgid "An email will be sent to you when all encoding tasks are completed." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "Terms of Service" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "" -"It is necessary to respect the terms of use of the various services before " -"being able to upload a video from their site to this platform." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "More infomations on Big Blue Button" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "More infomations on PeerTube" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "YouTube" -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "" -"Their terms of service state that you are not allowed to download any " -"content unless permitted by YouTube or the person who owns the copyright to " -"the content." -msgstr "" - -#: pod/meeting/templates/meeting/add_or_edit_external_recording.html -msgid "YouTube's Terms of Service" -msgstr "" - -#: pod/meeting/templates/meeting/delete.html -#, python-format -msgid "Delete the meeting %(name)s" -msgstr "" - -#: pod/meeting/templates/meeting/delete.html -msgid "Back to my meetings" -msgstr "" - -#: pod/meeting/templates/meeting/delete.html -msgid "To delete the meeting, please check the box in and click delete." -msgstr "" - -#: pod/meeting/templates/meeting/external_recordings.html -msgid "" -"If you have achieved Big Blue Button meetings via another interface " -"(typically via Moodle), or if you wish to centralize PeerTube, Youtube or " -"other videos on Pod, it is possible to retrieve these recordings and be able " -"to convert them into video in this platform (under certain conditions)." +msgid "Internal Meeting ID" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -msgid "Please use the button below to add such a recording." +#: pod/meeting/models.py +msgid "Voice Bridge" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Do not leave the page until the video upload to Pod is complete." +#: pod/meeting/models.py +msgid "BBB Create Time" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "State" +#: pod/meeting/models.py +msgid "" +"The day of the start date of the meeting must be included in the recurrence " +"weekdays." msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Playback" +#: pod/meeting/models.py +msgid "Unable to end meeting!" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Toolbar" +#: pod/meeting/models.py +msgid "Unable to get meeting recordings!" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Video file not uploaded to Pod" +#: pod/meeting/models.py +msgid "Unable to delete recording!" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Video file already uploaded to Pod" +#: pod/meeting/models.py +msgid "Recording ID" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Display the recording in presentation format" +#: pod/meeting/models.py pod/recorder/models.py +msgid "Recordings" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Display the recording in video format" +#: pod/meeting/templates/meeting/add_or_edit.html +#: pod/meeting/templates/meeting/link_meeting.html pod/meeting/views.py +msgid "Edit the meeting" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Please confirm you want to upload the recording To Pod" +#: pod/meeting/templates/meeting/add_or_edit.html pod/meeting/views.py +msgid "Add a new meeting" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -#: pod/meeting/templates/meeting/internal_recordings.html -msgid "Upload to Pod as a video" +#: pod/meeting/templates/meeting/add_or_edit.html +#: pod/meeting/templates/meeting/my_meetings.html +msgid "" +"Access to adding meeting has been restricted. If you want to add meetings on " +"the platform, please" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -msgid "Please confirm you want to delete the external recording" +#: pod/meeting/templates/meeting/delete.html +#, python-format +msgid "Delete the meeting %(name)s" msgstr "" -#: pod/meeting/templates/meeting/external_recordings.html -msgid "Delete the external recording" +#: pod/meeting/templates/meeting/delete.html +msgid "Back to my meetings" +msgstr "" + +#: pod/meeting/templates/meeting/delete.html +msgid "To delete the meeting, please check the box in and click delete." msgstr "" #: pod/meeting/templates/meeting/filter_aside.html pod/video/views.py @@ -4706,15 +4854,18 @@ msgstr "" msgid "See all my meetings" msgstr "" -#: pod/meeting/templates/meeting/filter_aside_external_recording.html -#: pod/meeting/templates/meeting/filter_aside_recording.html -msgid "Type at least 3 chars to filter" -msgstr "" - #: pod/meeting/templates/meeting/internal_recordings.html pod/meeting/views.py msgid "Meeting recordings" msgstr "" +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Toolbar" +msgstr "" + +#: pod/meeting/templates/meeting/internal_recordings.html +msgid "Please confirm you want to upload the recording To Pod" +msgstr "" + #: pod/meeting/templates/meeting/internal_recordings.html msgid "Please confirm you want to delete the recording" msgstr "" @@ -4921,30 +5072,10 @@ msgstr "" msgid "Password given is not correct." msgstr "" -#: pod/meeting/views.py -msgid "This view cannot be accessed directly." -msgstr "" - #: pod/meeting/views.py msgid "You cannot view the recordings of this meeting." msgstr "" -#: pod/meeting/views.py -msgid "You cannot view this recording." -msgstr "" - -#: pod/meeting/views.py -msgid "Impossible to upload to Pod the video" -msgstr "" - -#: pod/meeting/views.py -msgid "No URL found / No recording name" -msgstr "" - -#: pod/meeting/views.py -msgid "Try changing the record type or address for this recording" -msgstr "" - #: pod/meeting/views.py msgid "The recording has been deleted." msgstr "" @@ -5004,131 +5135,10 @@ msgid "" " " msgstr "" -#: pod/meeting/views.py -msgid "" -"The recording has been uploaded to Pod. You can see the generated video in " -"My videos." -msgstr "" - -#: pod/meeting/views.py -msgid "Add a new external recording" -msgstr "" - -#: pod/meeting/views.py -msgid "The external recording has been deleted." -msgstr "" - -#: pod/meeting/views.py -msgid "The HTML file for this recording was not found on the BBB server." -msgstr "" - -#: pod/meeting/views.py -msgid "The video file for this recording was not found in the HTML file." -msgstr "" - -#: pod/meeting/views.py -msgid "The found file is not a valid video." -msgstr "" - -#: pod/meeting/views.py -msgid "No video file found" -msgstr "" - -#: pod/meeting/views.py -msgid "The video file for this recording was not found on the BBB server." -msgstr "" - -#: pod/meeting/views.py -msgid "Impossible to download the video file from the server." -msgstr "" - -#: pod/meeting/views.py -msgid "Impossible to create the Pod video" -msgstr "" - #: pod/meeting/views.py msgid "Impossible to create the internal recording" msgstr "" -#: pod/meeting/views.py -msgid "Impossible to create the external recording" -msgstr "" - -#: pod/meeting/views.py -#, python-format -msgid "" -"This video was uploaded to Pod; its origin is %(type)s : %(url)s" -msgstr "" - -#: pod/meeting/views.py -msgid "Try changing the record type or address for this recording." -msgstr "" - -#: pod/meeting/views.py -#, python-format -msgid "" -"This video '%(name)s' was uploaded to Pod; its origin is Youtube : %(url)s" -msgstr "" - -#: pod/meeting/views.py -msgid "YouTube error" -msgstr "" - -#: pod/meeting/views.py -msgid "" -"YouTube content is unavailable. This content does not appear to be publicly " -"available." -msgstr "" - -#: pod/meeting/views.py -msgid "Try changing the access rights to the video directly in Youtube." -msgstr "" - -#: pod/meeting/views.py -msgid "" -"YouTube content is inaccessible. This content does not appear to be publicly " -"available." -msgstr "" - -#: pod/meeting/views.py -msgid "Try changing the address of this recording." -msgstr "" - -#: pod/meeting/views.py -msgid "PeerTube error" -msgstr "" - -#: pod/meeting/views.py -msgid "The address entered does not appear to be a valid PeerTube address." -msgstr "" - -#: pod/meeting/views.py -msgid "Try changing the address of the recording." -msgstr "" - -#: pod/meeting/views.py -msgid "" -"The address entered does not appear to be a valid PeerTube address or the " -"PeerTube server is not responding as expected." -msgstr "" - -#: pod/meeting/views.py -msgid "Try changing the address of the recording or retry later." -msgstr "" - -#: pod/meeting/views.py -#, python-format -msgid "" -"This video '%(name)s' was uploaded to Pod; its origin is PeerTube : %(url)s." -msgstr "" - -#: pod/meeting/views.py -msgid "Impossible to upload to Pod the PeerTube video" -msgstr "" - #: pod/playlist/apps.py pod/playlist/models.py msgid "Playlists" msgstr "" @@ -6374,30 +6384,6 @@ msgstr "" msgid "View counts" msgstr "" -#: pod/video/models.py pod/video_encode_transcript/models.py -msgid "Please use the only format in encoding choices:" -msgstr "" - -#: pod/video/models.py pod/video_encode_transcript/models.py -msgid "Format" -msgstr "" - -#: pod/video/models.py pod/video_encode_transcript/models.py -msgid "Please use the only format in format choices:" -msgstr "" - -#: pod/video/models.py pod/video_encode_transcript/models.py -msgid "encoding source file" -msgstr "" - -#: pod/video/models.py -msgid "Video Playlist" -msgstr "" - -#: pod/video/models.py -msgid "Video Playlists" -msgstr "" - #: pod/video/models.py msgid "Video version" msgstr "" @@ -7517,6 +7503,22 @@ msgstr "" msgid "renditions" msgstr "" +#: pod/video_encode_transcript/models.py +msgid "Please use the only format in encoding choices:" +msgstr "" + +#: pod/video_encode_transcript/models.py +msgid "Format" +msgstr "" + +#: pod/video_encode_transcript/models.py +msgid "Please use the only format in format choices:" +msgstr "" + +#: pod/video_encode_transcript/models.py +msgid "encoding source file" +msgstr "" + #: pod/video_encode_transcript/models.py msgid "Encoding video" msgstr "" @@ -7545,6 +7547,14 @@ msgstr "" msgid "Encoding steps" msgstr "" +#: pod/video_encode_transcript/models.py +msgid "Video Playlist" +msgstr "" + +#: pod/video_encode_transcript/models.py +msgid "Video Playlists" +msgstr "" + #: pod/video_encode_transcript/utils.py msgid "Encoding" msgstr "Videocodering" diff --git a/pod/locale/nl/LC_MESSAGES/djangojs.po b/pod/locale/nl/LC_MESSAGES/djangojs.po index 7a00217b05..f0d5395c3b 100644 --- a/pod/locale/nl/LC_MESSAGES/djangojs.po +++ b/pod/locale/nl/LC_MESSAGES/djangojs.po @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: Esup-Pod\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2023-06-12 13:57+0200\n" +"POT-Creation-Date: 2023-06-27 09:35+0200\n" "PO-Revision-Date: 2023-02-08 15:22+0100\n" "Last-Translator: obado \n" "Language-Team: \n" @@ -26,12 +26,12 @@ msgid "Close" msgstr "" #: pod/chapter/static/js/chapters.js pod/completion/static/js/completion.js -#: pod/enrichment/static/js/enrichment.js +#: pod/enrichment/static/js/enrichment.js pod/playlist/static/js/playlist.js msgid "Error getting form." msgstr "" #: pod/chapter/static/js/chapters.js pod/completion/static/js/completion.js -#: pod/enrichment/static/js/enrichment.js +#: pod/enrichment/static/js/enrichment.js pod/playlist/static/js/playlist.js msgid "The form could not be recovered." msgstr "" @@ -161,6 +161,16 @@ msgstr "" msgid "Pause to enter caption for segment from %s to %s." msgstr "" +#: pod/completion/static/js/caption_maker.js +#: pod/podfile/static/podfile/js/filewidget.js +msgid "Add" +msgstr "" + +#: pod/completion/static/js/caption_maker.js +#: pod/video/static/js/comment-script.js +msgid "Delete" +msgstr "" + #: pod/completion/static/js/caption_maker.js msgid "Caption" msgstr "" @@ -461,6 +471,18 @@ msgstr "" msgid "The file extension not in the allowed extension:" msgstr "" +#: pod/playlist/static/js/playlist.js +msgid "Position saved" +msgstr "" + +#: pod/playlist/static/js/playlist.js +msgid "Error deleting video from playlist. The video could not be deleted." +msgstr "" + +#: pod/playlist/static/js/playlist.js +msgid "Error deleting playlist. The playlist could not be deleted." +msgstr "" + #: pod/playlist/static/js/playlist.js msgid "The video can not be added from this page." msgstr "" @@ -503,10 +525,6 @@ msgstr "" msgid "Server error" msgstr "" -#: pod/podfile/static/podfile/js/filewidget.js -msgid "Add" -msgstr "" - #: pod/podfile/static/podfile/js/filewidget.js msgid "Are you sure you want to delete this folder?" msgstr "" @@ -544,21 +562,40 @@ msgid "Answers" msgstr "" #: pod/video/static/js/comment-script.js -msgid "Delete" +msgid "Cancel" msgstr "" #: pod/video/static/js/comment-script.js -msgid "Cancel" -msgstr "" +#, javascript-format +msgid "%s vote" +msgid_plural "%s votes" +msgstr[0] "" +msgstr[1] "" #: pod/video/static/js/comment-script.js msgid "Agree with the comment" msgstr "" +#: pod/video/static/js/comment-script.js +msgid "Reply to comment" +msgstr "" + +#: pod/video/static/js/comment-script.js +msgid "Reply" +msgstr "" + #: pod/video/static/js/comment-script.js msgid "Remove this comment" msgstr "" +#: pod/video/static/js/comment-script.js +msgid "Add a public comment" +msgstr "" + +#: pod/video/static/js/comment-script.js +msgid "Send" +msgstr "" + #: pod/video/static/js/comment-script.js msgid "Show answers" msgstr "" @@ -571,13 +608,6 @@ msgstr "" msgid "Sorry, you're not allowed to vote by now." msgstr "" -#: pod/video/static/js/comment-script.js -#, javascript-format -msgid "%s vote" -msgid_plural "%s votes" -msgstr[0] "" -msgstr[1] "" - #: pod/video/static/js/comment-script.js msgid "Sorry, you can't comment this video by now." msgstr "" @@ -610,38 +640,47 @@ msgid "An Error occurred while processing." msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "This content is password protected." msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "This content is chaptered." msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "This content is in draft." msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Video content." msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Audio content." msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Edit the video" msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Complete the video" msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Chapter the video" msgstr "" #: pod/video/static/js/regroup_videos_by_theme.js +#: pod/video/static/js/video_category.js msgid "Delete the video" msgstr "" @@ -701,6 +740,18 @@ msgstr "" msgid "Edit the category" msgstr "" +#: pod/video/static/js/video_category.js +msgid "Delete the category" +msgstr "" + +#: pod/video/static/js/video_category.js +msgid "Success!" +msgstr "" + +#: pod/video/static/js/video_category.js +msgid "Error…" +msgstr "" + #: pod/video/static/js/video_category.js msgid "Category created successfully" msgstr "" diff --git a/pod/main/context_processors.py b/pod/main/context_processors.py index 59f427a115..950418b4d9 100644 --- a/pod/main/context_processors.py +++ b/pod/main/context_processors.py @@ -1,19 +1,11 @@ from django.conf import settings as django_settings from django.core.exceptions import ImproperlyConfigured -from django.db.models import Count, Sum -from django.db.models import Prefetch -from datetime import timedelta from pod.main.models import LinkFooter from django.core.exceptions import ObjectDoesNotExist -from pod.video.models import Channel -from pod.video.models import Theme -from pod.video.models import Type -from pod.video.models import Discipline -from pod.video.models import Video + from pod.main.models import Configuration from django.contrib.sites.shortcuts import get_current_site -from pod.main.models import AdditionalChannelTab MENUBAR_HIDE_INACTIVE_OWNERS = getattr( django_settings, "MENUBAR_HIDE_INACTIVE_OWNERS", False @@ -103,7 +95,7 @@ def context_settings(request): ).value maintenance_sheduled = Configuration.objects.get(key="maintenance_sheduled") - maintenance_sheduled = True if maintenance_sheduled.value == "1" else False + maintenance_sheduled = True if (maintenance_sheduled.value == "1") else False maintenance_text_sheduled = Configuration.objects.get( key="maintenance_text_sheduled" ).value @@ -150,93 +142,8 @@ def context_settings(request): return new_settings -def context_navbar(request): - channels = ( - Channel.objects.filter( - visible=True, - video__is_draft=False, - add_channels_tab=None, - site=get_current_site(request), - ) - .distinct() - .annotate(video_count=Count("video", distinct=True)) - .prefetch_related( - Prefetch( - "themes", - queryset=Theme.objects.filter( - parentId=None, channel__site=get_current_site(request) - ) - .distinct() - .annotate(video_count=Count("video", distinct=True)), - ) - ) - ) - - add_channels_tab = AdditionalChannelTab.objects.all().prefetch_related( - Prefetch( - "channel_set", - queryset=Channel.objects.filter(site=get_current_site(request)) - .distinct() - .annotate(video_count=Count("video", distinct=True)), - ) - ) - - all_channels = ( - Channel.objects.all() - .filter(site=get_current_site(request)) - .distinct() - .annotate(video_count=Count("video", distinct=True)) - .prefetch_related( - Prefetch( - "themes", - queryset=Theme.objects.filter(channel__site=get_current_site(request)) - .distinct() - .annotate(video_count=Count("video", distinct=True)), - ) - ) - ) - - types = ( - Type.objects.filter( - sites=get_current_site(request), - video__is_draft=False, - video__sites=get_current_site(request), - ) - .distinct() - .annotate(video_count=Count("video", distinct=True)) - ) - - disciplines = ( - Discipline.objects.filter( - site=get_current_site(request), - video__is_draft=False, - video__sites=get_current_site(request), - ) - .distinct() - .annotate(video_count=Count("video", distinct=True)) - ) - +def context_footer(request): linkFooter = LinkFooter.objects.all().filter(sites=get_current_site(request)) - - list_videos = Video.objects.filter( - encoding_in_progress=False, - is_draft=False, - sites=get_current_site(request), - ) - VIDEOS_COUNT = list_videos.count() - VIDEOS_DURATION = ( - str(timedelta(seconds=list_videos.aggregate(Sum("duration"))["duration__sum"])) - if list_videos.aggregate(Sum("duration"))["duration__sum"] - else 0 - ) - return { - "ALL_CHANNELS": all_channels, - "ADD_CHANNELS_TAB": add_channels_tab, - "CHANNELS": channels, - "TYPES": types, - "DISCIPLINES": disciplines, "LINK_FOOTER": linkFooter, - "VIDEOS_COUNT": VIDEOS_COUNT, - "VIDEOS_DURATION": VIDEOS_DURATION, } diff --git a/pod/main/static/js/infinite.js b/pod/main/static/js/infinite.js index d5604eb655..09e5bfa767 100644 --- a/pod/main/static/js/infinite.js +++ b/pod/main/static/js/infinite.js @@ -87,22 +87,22 @@ class InfiniteLoader { window.addEventListener("scroll", this.scroller_init); } async initMore() { - let url = this.url; this.callBackBeforeLoad(); + let url = this.url; + this.getData(url, this.next_page_number, this.nextPage).then((data) => { + if (data !== null && data !== undefined) { + const html = new DOMParser().parseFromString(data, "text/html"); + /*if (html.getElementById("videos_list").dataset.nextpage !== "True") { + this.nextPage = false; + }*/ + // data-nextpage="{{ videos.has_next|yesno:'true,false' }}" + this.nextPage = html.getElementById("videos_list").dataset.nextpage; + let element = this.videos_list; - // UPDATE DOM - this.getData(url, this.next_page_number).then((data) => { - const html = new DOMParser().parseFromString(data, "text/html"); - - if (html.getElementById("videos_list").dataset.nextPage !== "True") { - this.nextPage = false; + element.innerHTML += html.getElementById("videos_list").innerHTML; + this.next_page_number += 1; } - - let element = this.videos_list; - - element.innerHTML += html.getElementById("videos_list").innerHTML; this.callBackAfterLoad(); - this.next_page_number += 1; }); } @@ -110,8 +110,9 @@ class InfiniteLoader { window.removeEventListener("scroll", this.scroller_init); } - async getData(url, page) { + async getData(url, page, nextPage) { if (!url) return; + if (nextPage == "false") return; url = url + page; const response = await fetch(url, { method: "GET", diff --git a/pod/main/test_settings.py b/pod/main/test_settings.py index 5532b99536..0f29fbdfe3 100644 --- a/pod/main/test_settings.py +++ b/pod/main/test_settings.py @@ -73,7 +73,7 @@ def get_shared_secret(): api_mate_url = "https://bigbluebutton.org/api-mate/" response = requests.get(api_mate_url) - soup = BeautifulSoup(response.text) + soup = BeautifulSoup(response.text, features="html.parser") input_val = soup.body.find("input", attrs={"id": "input-custom-server-salt"}) return input_val.get("value") diff --git a/pod/settings.py b/pod/settings.py index f6f97207a2..ff0e18c7bc 100644 --- a/pod/settings.py +++ b/pod/settings.py @@ -4,6 +4,7 @@ Django version: 3.2. """ import os +import importlib.util import django.conf.global_settings BASE_DIR = os.path.dirname(os.path.dirname(__file__)) @@ -12,7 +13,7 @@ ## # Version of the project # -VERSION = "3.3.0" +VERSION = "3.3.1" ## # Installed applications list @@ -114,7 +115,8 @@ "django.contrib.messages.context_processors.messages", # Local contexts "pod.main.context_processors.context_settings", - "pod.main.context_processors.context_navbar", + "pod.main.context_processors.context_footer", + "pod.video.context_processors.context_navbar", "pod.video.context_processors.context_video_settings", "pod.authentication.context_processors.context_authentication_settings", "pod.recorder.context_processors.context_recorder_settings", @@ -352,6 +354,7 @@ "OPTIONS": { "CLIENT_CLASS": "django_redis.client.DefaultClient", }, + "KEY_PREFIX": "pod", }, "select2": { "BACKEND": "django_redis.cache.RedisCache", @@ -455,3 +458,13 @@ def update_settings(local_settings): locals()[variable] = the_update_settings[variable] TIME_INPUT_FORMATS = ["%H:%M", *django.conf.global_settings.TIME_INPUT_FORMATS] + +if locals()["DEBUG"] is True and importlib.util.find_spec("debug_toolbar") is not None: + INSTALLED_APPS.append("debug_toolbar") + MIDDLEWARE = [ + "debug_toolbar.middleware.DebugToolbarMiddleware", + ] + MIDDLEWARE + DEBUG_TOOLBAR_CONFIG = {"SHOW_TOOLBAR_CALLBACK": "pod.settings.show_toolbar"} + + def show_toolbar(request): + return True diff --git a/pod/urls.py b/pod/urls.py index 587319cd74..c39d60191e 100644 --- a/pod/urls.py +++ b/pod/urls.py @@ -10,6 +10,8 @@ from django.views.i18n import JavaScriptCatalog from django.utils.translation import ugettext_lazy as _ +import importlib.util + from pod.main.views import ( contact_us, download_file, @@ -140,14 +142,18 @@ ), ] +if settings.DEBUG: + urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) + if importlib.util.find_spec("debug_toolbar") is not None: + urlpatterns += [ + path("__debug__/", include("debug_toolbar.urls")), + ] + # CHANNELS urlpatterns += [ url(r"^", include("pod.video.urls-channels-video")), ] -if settings.DEBUG: - urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) - # Change admin site title admin.site.site_header = _("Pod Administration") admin.site.site_title = _("Pod Administration") diff --git a/pod/video/context_processors.py b/pod/video/context_processors.py index 26ecccfca6..6c3240822d 100644 --- a/pod/video/context_processors.py +++ b/pod/video/context_processors.py @@ -1,10 +1,71 @@ from django.conf import settings as django_settings +from pod.video.models import Channel +from pod.video.models import Theme +from pod.video.models import Type +from pod.video.models import Discipline +from pod.video.models import Video + +from django.db.models import Count, Sum +from django.db.models import Prefetch +from django.db.models import Q +from django.db.models import Exists +from django.db.models import OuterRef + +from datetime import timedelta +from django.contrib.sites.shortcuts import get_current_site +from pod.main.models import AdditionalChannelTab +from pod.video_encode_transcript.models import EncodingVideo +from pod.video_encode_transcript.models import PlaylistVideo +from pod.video_encode_transcript.models import EncodingAudio + CHUNK_SIZE = getattr(django_settings, "CHUNK_SIZE", 100000) HIDE_USER_FILTER = getattr(django_settings, "HIDE_USER_FILTER", False) OEMBED = getattr(django_settings, "OEMBED", False) USE_STATS_VIEW = getattr(django_settings, "USE_STATS_VIEW", False) +__AVAILABLE_VIDEO_FILTER__ = { + "encoding_in_progress": False, + "is_draft": False, + "sites": 1, +} + + +def get_available_videos(request=None): + """Get all videos available.""" + __AVAILABLE_VIDEO_FILTER__["sites"] = get_current_site(request) + vids = ( + Video.objects.filter(**__AVAILABLE_VIDEO_FILTER__) + .defer("video", "slug", "owner", "additional_owners", "description") + .filter( + Q( + Exists( + EncodingVideo.objects.filter( + video=OuterRef("pk"), encoding_format="video/mp4" + ) + ) + ) + | Q( + Exists( + PlaylistVideo.objects.filter( + video=OuterRef("pk"), + name="playlist", + encoding_format="application/x-mpegURL", + ) + ) + ) + | Q( + Exists( + EncodingAudio.objects.filter( + video=OuterRef("pk"), name="audio", encoding_format="video/mp4" + ) + ) + ) + ) + .distinct() + ) + return vids + def context_video_settings(request): new_settings = {} @@ -13,3 +74,88 @@ def context_video_settings(request): new_settings["OEMBED"] = OEMBED new_settings["USE_STATS_VIEW"] = USE_STATS_VIEW return new_settings + + +def context_navbar(request): + channels = ( + Channel.objects.filter( + visible=True, + video__is_draft=False, + add_channels_tab=None, + site=get_current_site(request), + ) + .distinct() + .annotate(video_count=Count("video", distinct=True)) + .prefetch_related( + Prefetch( + "themes", + queryset=Theme.objects.filter( + parentId=None, channel__site=get_current_site(request) + ) + .distinct() + .annotate(video_count=Count("video", distinct=True)), + ) + ) + ) + + add_channels_tab = AdditionalChannelTab.objects.all().prefetch_related( + Prefetch( + "channel_set", + queryset=Channel.objects.filter(site=get_current_site(request)) + .distinct() + .annotate(video_count=Count("video", distinct=True)), + ) + ) + + all_channels = ( + Channel.objects.all() + .filter(site=get_current_site(request)) + .distinct() + .annotate(video_count=Count("video", distinct=True)) + .prefetch_related( + Prefetch( + "themes", + queryset=Theme.objects.filter(channel__site=get_current_site(request)) + .distinct() + .annotate(video_count=Count("video", distinct=True)), + ) + ) + ) + + types = ( + Type.objects.filter( + sites=get_current_site(request), + video__is_draft=False, + video__sites=get_current_site(request), + ) + .distinct() + .annotate(video_count=Count("video", distinct=True)) + ) + + disciplines = ( + Discipline.objects.filter( + site=get_current_site(request), + video__is_draft=False, + video__sites=get_current_site(request), + ) + .distinct() + .annotate(video_count=Count("video", distinct=True)) + ) + + list_videos = get_available_videos(request) + VIDEOS_COUNT = list_videos.count() + VIDEOS_DURATION = ( + str(timedelta(seconds=list_videos.aggregate(Sum("duration"))["duration__sum"])) + if list_videos.aggregate(Sum("duration"))["duration__sum"] + else 0 + ) + + return { + "ALL_CHANNELS": all_channels, + "ADD_CHANNELS_TAB": add_channels_tab, + "CHANNELS": channels, + "TYPES": types, + "DISCIPLINES": disciplines, + "VIDEOS_COUNT": VIDEOS_COUNT, + "VIDEOS_DURATION": VIDEOS_DURATION, + } diff --git a/pod/video/feeds.py b/pod/video/feeds.py index 6f645203c1..ac0caac7e4 100644 --- a/pod/video/feeds.py +++ b/pod/video/feeds.py @@ -9,7 +9,7 @@ from django.shortcuts import get_object_or_404 from django.utils.html import format_html -from pod.video.views import get_videos_list +from .context_processors import get_available_videos from pod.video_encode_transcript.models import EncodingAudio from pod.video.models import Channel @@ -153,7 +153,7 @@ def get_object(self, request, slug_c=None, slug_t=None): ) self.feed_url = request.build_absolute_uri() - videos_list = get_videos_list() + videos_list = get_available_videos() if slug_c: channel = get_object_or_404( diff --git a/pod/video/rest_views.py b/pod/video/rest_views.py index 9671134ca1..af0beb0539 100644 --- a/pod/video/rest_views.py +++ b/pod/video/rest_views.py @@ -11,15 +11,13 @@ from .models import Channel, Theme from .models import Type, Discipline, Video from .models import ViewCount -from .utils import get_available_videos +from .context_processors import get_available_videos # commented for v3 # from .remote_encode import start_store_remote_encoding_video import json -__VIDEOS__ = get_available_videos() - # Serializers define the API representation. @@ -218,7 +216,7 @@ def user_videos(self, request): ) if request.GET.get("encoded") and request.GET.get("encoded") == "true": user_videos = user_videos.exclude( - pk__in=[vid.id for vid in __VIDEOS__ if not vid.encoded] + pk__in=[vid.id for vid in user_videos if not vid.encoded] ) if request.GET.get("search_title") and request.GET.get("search_title") != "": user_videos = user_videos.filter( @@ -267,9 +265,9 @@ class DublinCoreView(APIView): max_page_size = 1000 def get(self, request, format=None): - list_videos = __VIDEOS__ + list_videos = get_available_videos(request) if request.GET: - list_videos = __VIDEOS__.filter(**request.GET.dict()) + list_videos = list_videos.filter(**request.GET.dict()) xmlcontent = '\n' xmlcontent += ( " { + setListenerChangeInputs(el); + }); +//initiate checkedInputs +document + .querySelectorAll("input[type=checkbox]:checked[class=form-check-input]") + .forEach((e) => { + checkedInputs.push(e); + }); + // First launch of the infinite scroll infinite = new InfiniteLoader( getUrlForRefresh(), @@ -257,10 +270,3 @@ infinite = new InfiniteLoader( nextPage, (page = 2) ); - -// Add event listener on inputs on launch -document - .querySelectorAll(".form-check-input,#sort,#sort_direction") - .forEach((el) => { - setListenerChangeInputs(el); - }); diff --git a/pod/video/templates/videos/video_list.html b/pod/video/templates/videos/video_list.html index 9e1a5a1e81..0410ba9b3e 100644 --- a/pod/video/templates/videos/video_list.html +++ b/pod/video/templates/videos/video_list.html @@ -1,7 +1,7 @@ {% load i18n %} {% load static %} {% spaceless %} -
+
{% for video in videos %}
{% include "videos/card.html" %} @@ -13,17 +13,18 @@ {% endfor %}
{% if videos.has_next %} -{% trans "More" %} - + {% endif %} {% endspaceless %} + {% block more_script %} {% endblock %} diff --git a/pod/video/templatetags/video_tags.py b/pod/video/templatetags/video_tags.py index 476b542a7d..7f725696cb 100644 --- a/pod/video/templatetags/video_tags.py +++ b/pod/video/templatetags/video_tags.py @@ -14,7 +14,7 @@ from tagging.utils import LOGARITHMIC from ..forms import VideoVersionForm -from ..utils import get_available_videos +from ..context_processors import get_available_videos from pod.video_encode_transcript.utils import check_file import importlib diff --git a/pod/video/tests/test_get_available_videos.py b/pod/video/tests/test_get_available_videos.py new file mode 100644 index 0000000000..b9f3cb6f4d --- /dev/null +++ b/pod/video/tests/test_get_available_videos.py @@ -0,0 +1,121 @@ +"""Video Models test cases.""" +from django.test import TestCase +from django.contrib.auth.models import User +from ..models import Video, Type + +from ..context_processors import __AVAILABLE_VIDEO_FILTER__ +from ..context_processors import get_available_videos + +from pod.video_encode_transcript.models import EncodingVideo +from pod.video_encode_transcript.models import PlaylistVideo +from pod.video_encode_transcript.models import EncodingAudio +from pod.video_encode_transcript.models import VideoRendition + + +class VideoAvailableTestCase(TestCase): + """Test the video available.""" + + fixtures = [ + "initial_data.json", + ] + + def setUp(self): + """Create videos to be tested.""" + user = User.objects.create(username="pod", password="pod1234pod") + + # Video 1 with minimum attributes + Video.objects.create( + title="Video1", + owner=user, + video="test.mp4", + type=Type.objects.get(id=1), + ) + Video.objects.create( + title="Video2", + owner=user, + video="test.mp4", + type=Type.objects.get(id=1), + ) + Video.objects.create( + title="Video3", + owner=user, + video="test.mp4", + type=Type.objects.get(id=1), + ) + + def test_available_video_filter(self): + """ + Test available filter for videos. + """ + self.assertEqual(Video.objects.all().count(), 3) + vids = Video.objects.filter(**__AVAILABLE_VIDEO_FILTER__) + self.assertEqual(vids.count(), 0) + vid1 = Video.objects.get(id=1) + vid1.is_draft = False + vid1.save() + vids = Video.objects.filter(**__AVAILABLE_VIDEO_FILTER__) + self.assertEqual(vids.count(), 1) + vid1.encoding_in_progress = True + vid1.save() + vids = Video.objects.filter(**__AVAILABLE_VIDEO_FILTER__) + self.assertEqual(vids.count(), 0) + + def test_video_filter_encoding(self): + """ + Test available videos for encoding. + """ + vid1 = Video.objects.get(id=1) + vid2 = Video.objects.get(id=2) + vid3 = Video.objects.get(id=3) + + vid1.is_draft = False + vid1.save() + vids = Video.objects.filter(**__AVAILABLE_VIDEO_FILTER__) + self.assertEqual(vids.count(), 1) + EncodingVideo.objects.create( + video=vid1, + encoding_format="video/mp4", + rendition=VideoRendition.objects.get(id=1), + ) + vids = get_available_videos() + self.assertEqual(vids.count(), 1) + vid1.is_draft = True + vid1.save() + vids = get_available_videos() + self.assertEqual(vids.count(), 0) + plvid2 = PlaylistVideo.objects.create( + video=vid2, name="playlist", encoding_format="application/x-mpegURL" + ) + vids = get_available_videos() + self.assertEqual(vids.count(), 0) + vid2.is_draft = False + vid2.save() + vids = get_available_videos() + self.assertEqual(vids.count(), 1) + vid1.is_draft = False + vid1.save() + vids = get_available_videos() + self.assertEqual(vids.count(), 2) + eavid3 = EncodingAudio.objects.create( + video=vid3, name="audio", encoding_format="video/mp4" + ) + vids = get_available_videos() + self.assertEqual(vids.count(), 2) + vid3.is_draft = False + vid3.save() + vids = get_available_videos() + self.assertEqual(vids.count(), 3) + plvid1 = PlaylistVideo.objects.create( + video=vid1, name="playlist", encoding_format="application/x-mpegURL" + ) + vids = get_available_videos() + self.assertEqual(vids.count(), 3) + plvid2.delete() + vids = get_available_videos() + self.assertEqual(vids.count(), 2) + eavid3.delete() + vids = get_available_videos() + self.assertEqual(vids.count(), 1) + plvid1.delete() + vids = get_available_videos() + self.assertEqual(vids.count(), 1) diff --git a/pod/video/tests/test_stats_view.py b/pod/video/tests/test_stats_view.py index 4d1c82ec21..eb52ddc231 100644 --- a/pod/video/tests/test_stats_view.py +++ b/pod/video/tests/test_stats_view.py @@ -10,6 +10,9 @@ from django.contrib.sites.models import Site from pod.authentication.models import AccessGroup +from pod.video_encode_transcript.models import EncodingVideo +from pod.video_encode_transcript.models import VideoRendition + import json import logging @@ -75,6 +78,22 @@ def setUp(self): video="teststatsviewthird.mp4", type=self.t1, ) + # add encoding to video + EncodingVideo.objects.create( + video=self.video, + encoding_format="video/mp4", + rendition=VideoRendition.objects.get(id=1), + ) + EncodingVideo.objects.create( + video=self.video2, + encoding_format="video/mp4", + rendition=VideoRendition.objects.get(id=1), + ) + EncodingVideo.objects.create( + video=self.video3, + encoding_format="video/mp4", + rendition=VideoRendition.objects.get(id=1), + ) self.video.channel.set([self.channel]) self.video.theme.set([self.theme]) self.video2.channel.set([self.channel]) diff --git a/pod/video/utils.py b/pod/video/utils.py index f08b9595f4..4204be7775 100644 --- a/pod/video/utils.py +++ b/pod/video/utils.py @@ -8,7 +8,6 @@ from django.conf import settings from django.http import JsonResponse from django.db.models import Q -from django.contrib.sites.shortcuts import get_current_site from django.template.defaultfilters import slugify from .models import Video @@ -50,22 +49,6 @@ SECURE_SSL_REDIRECT = getattr(settings, "SECURE_SSL_REDIRECT", False) VIDEOS_DIR = getattr(settings, "VIDEOS_DIR", "videos") - -def get_available_videos(): - """Get all videos available.""" - videos = Video.objects.filter(encoding_in_progress=False, is_draft=False).defer( - "video", "slug", "owner", "additional_owners", "description" - ) - # for clean install, produces errors - try: - videos = videos.exclude( - pk__in=[vid.id for vid in videos if not vid.encoded] - ).filter(sites=get_current_site(None)) - except Exception: - pass - return videos - - ############################################################### # EMAIL ############################################################### diff --git a/pod/video/views.py b/pod/video/views.py index 0244bdb866..2076789e82 100644 --- a/pod/video/views.py +++ b/pod/video/views.py @@ -54,10 +54,10 @@ pagination_data, get_headband, change_owner, - get_available_videos, get_video_data, get_id_from_request, ) +from .context_processors import get_available_videos from .utils import sort_videos_list from django.views.decorators.csrf import ensure_csrf_cookie @@ -165,7 +165,6 @@ TRANSCRIPT_VIDEO = getattr(settings, "TRANSCRIPT_VIDEO", "start_transcript") -__VIDEOS__ = get_available_videos() # ############################################################################ # CHANNEL @@ -285,7 +284,7 @@ def paginator(videos_list, page): def channel(request, slug_c, slug_t=None): channel = get_object_or_404(Channel, slug=slug_c, site=get_current_site(request)) - videos_list = __VIDEOS__.filter(channel=channel) + videos_list = get_available_videos().filter(channel=channel) channel.video_count = videos_list.count() theme = None @@ -566,12 +565,6 @@ def my_videos(request): return render(request, "videos/my_videos.html", data_context) -def get_videos_list(): - """Render the main list of videos.""" - videos_list = __VIDEOS__ - return videos_list.distinct() - - def get_paginated_videos(paginator, page): """Return paginated videos in paginator object.""" try: @@ -618,8 +611,7 @@ def get_owners_has_instances(owners): def videos(request): """Render the main list of videos.""" - videos_list = get_videos_list() - videos_list = get_filtered_videos_list(request, videos_list) + videos_list = get_filtered_videos_list(request, get_available_videos()) sort_field = request.GET.get("sort") sort_direction = request.GET.get("sort_direction") @@ -631,6 +623,8 @@ def videos(request): count_videos = len(videos_list) page = request.GET.get("page", 1) + if page == "" or page is None: + page = 1 full_path = "" if page: full_path = ( @@ -649,7 +643,6 @@ def videos(request): "videos/video_list.html", {"videos": videos, "full_path": full_path, "count_videos": count_videos}, ) - return render( request, "videos/videos.html", @@ -1984,7 +1977,7 @@ def get_videos(p_slug, target, p_slug_t=None): """ videos = [] title = _("Pod video viewing statistics") - + available_videos = get_available_videos() if target.lower() == "video": video_founded = Video.objects.filter(slug=p_slug).first() # In case that the slug is a bad one @@ -1996,14 +1989,14 @@ def get_videos(p_slug, target, p_slug_t=None): elif target.lower() == "channel": title = _("Video viewing statistics for the channel %s") % p_slug - videos = __VIDEOS__.filter(channel__slug__istartswith=p_slug) + videos = available_videos.filter(channel__slug__istartswith=p_slug) elif target.lower() == "theme" and p_slug_t: title = _("Video viewing statistics for the theme %s") % p_slug_t - videos = __VIDEOS__.filter(theme__slug__istartswith=p_slug_t) + videos = available_videos.filter(theme__slug__istartswith=p_slug_t) elif target == "videos": - return (__VIDEOS__, title) + return (available_videos, title) return (videos, title) @@ -2096,7 +2089,9 @@ def stats_view(request, slug=None, slug_t=None): ) ) - min_date = __VIDEOS__.aggregate(Min("date_added"))["date_added__min"].date() + min_date = ( + get_available_videos().aggregate(Min("date_added"))["date_added__min"].date() + ) data.append({"min_date": min_date}) return JsonResponse(data, safe=False) diff --git a/pod/xapi/views.py b/pod/xapi/views.py index 62a4f5474f..df810e5aba 100644 --- a/pod/xapi/views.py +++ b/pod/xapi/views.py @@ -23,7 +23,8 @@ }, ) To test with celery : -(django_pod3) pod@pod:/.../podv3$ python -m celery -A pod.main worker +(django_pod3) pod@pod:/.../podv3$ + python -m celery -A pod.xapi.xapi_tasks worker -l INFO -Q xapi """ XAPI_ANONYMIZE_ACTOR = getattr(settings, "XAPI_ANONYMIZE_ACTOR", True) XAPI_LRS_URL = getattr(settings, "XAPI_LRS_URL", "") diff --git a/requirements-conteneur.txt b/requirements-conteneur.txt index 49d5af378b..adbe220545 100644 --- a/requirements-conteneur.txt +++ b/requirements-conteneur.txt @@ -1,2 +1,2 @@ +-r ./requirements-dev.txt importlib-metadata==4.13.0 -elasticsearch==7.17.7 \ No newline at end of file diff --git a/requirements-dev.txt b/requirements-dev.txt index bd719d7331..983c4f23fd 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -1,4 +1,6 @@ +-r ./requirements.txt flake8 coveralls httmock beautifulsoup4 +django-debug-toolbar