Give alias and random suffix for whatsapp videos without created timestamp
This commit is contained in:
@@ -11,6 +11,7 @@ def show_video_row(
|
||||
preselected_labels,
|
||||
editable_labels=True,
|
||||
editable_difficulty=True,
|
||||
editable_alias=True,
|
||||
playlist=None,
|
||||
playlist_video_ids=None,
|
||||
video_playlists=None,
|
||||
@@ -19,7 +20,7 @@ def show_video_row(
|
||||
Affiche une ligne Streamlit pour une vidéo :
|
||||
- miniature + lecture conditionnelle
|
||||
- métadonnées et labels
|
||||
- édition des labels et difficulté
|
||||
- édition des labels, difficulté et alias
|
||||
- (optionnel) ajout/retrait d'une playlist
|
||||
"""
|
||||
|
||||
@@ -100,6 +101,11 @@ def show_video_row(
|
||||
if new_level != video.difficulty_display:
|
||||
db.update_video_difficulty(video.file_name, new_level)
|
||||
st.success(f"Niveau mis à jour pour {video.file_name}")
|
||||
if editable_alias:
|
||||
alias = st.text_input("Alias (optionnel)", value=video.alias, key=f'new_alias_{video.id}')
|
||||
if alias != video.alias:
|
||||
db.update_video_alias(video.file_name, alias.strip())
|
||||
st.success(f"Alias mis à jour pour {video.file_name}")
|
||||
|
||||
# --- Colonne 4 : action playlist ---
|
||||
if col4 and playlist:
|
||||
|
||||
Reference in New Issue
Block a user