Skip to content
GitLab
Explorer
Connexion
S'inscrire
Navigation principale
Rechercher ou aller à…
Projet
P
parlote-facil
Gestion
Activité
Membres
Labels
Programmation
Tickets
Tableaux des tickets
Jalons
Wiki
Code
Requêtes de fusion
Dépôt
Branches
Validations
Étiquettes
Graphe du dépôt
Comparer les révisions
Extraits de code
Compilation
Pipelines
Jobs
Planifications de pipeline
Artéfacts
Déploiement
Releases
Registre de paquets
Registre de conteneur
Registre de modèles
Opération
Environnements
Modules Terraform
Surveillance
Incidents
Analyse
Données d'analyse des chaînes de valeur
Analyse des contributeurs
Données d'analyse CI/CD
Données d'analyse du dépôt
Expériences du modèle
Aide
Aide
Support
Documentation de GitLab
Comparer les forfaits GitLab
Forum de la communauté
Contribuer à GitLab
Donner votre avis
Raccourcis clavier
?
Extraits de code
Groupes
Projets
Afficher davantage de fils d'Ariane
facil
parlote-facil
Validations
81438678
Valider
81438678
rédigé
il y a 14 ans
par
danielvincent
Parcourir les fichiers
Options
Téléchargements
Correctifs
Plain Diff
Refactored more photo js out to photos.js. That should be it for that refactor
parent
81edef9b
Aucune branche associée trouvée
Branches contenant la validation
Aucune étiquette associée trouvée
Étiquettes contenant la validation
Aucune requête de fusion associée trouvée
Modifications
2
Masquer les modifications d'espaces
En ligne
Côte à côte
Affichage de
2 fichiers modifiés
app/views/photos/_new_photo.haml
+0
-30
0 ajout, 30 suppressions
app/views/photos/_new_photo.haml
public/javascripts/photos.js
+27
-0
27 ajouts, 0 suppression
public/javascripts/photos.js
avec
27 ajouts
et
30 suppressions
app/views/photos/_new_photo.haml
+
0
−
30
Voir le fichier @
81438678
:javascript
$
(
function
()
{
$
(
"
#photo_image
"
).
html5_upload
({
// WE INSERT ALBUM_ID PARAM HERE
url
:
"
/photos?album_id=
#{
@album
.
id
}
"
,
sendBoundary
:
window
.
FormData
||
$
.
browser
.
mozilla
,
setName
:
function
(
text
)
{
$
(
"
#progress_report_name
"
).
text
(
text
);
},
onFinish
:
function
(
event
,
total
){
$
(
"
#add_photo_button
"
).
html
(
"
Add Photos
"
);
$
(
"
#add_photo_loader
"
).
fadeOut
(
400
);
$
(
"
#photo_title_status
"
).
text
(
"
Done!
"
);
$
(
"
#progress_report
"
).
html
(
"
Good job me!
"
);
$
(
"
#add_photo_button
"
).
addClass
(
"
uploading_complete
"
);
},
onStart
:
function
(
event
,
total
){
$
(
"
#add_photo_button
"
).
html
(
"
Uploading Photos
"
);
$
(
"
#add_photo_loader
"
).
fadeIn
(
400
);
$
(
"
form.new_photo
"
).
fadeOut
(
0
);
$
(
"
#progress_report
"
).
fadeIn
(
0
);
$
(
"
#photo_title_status
"
).
text
(
"
Uploading...
"
);
return
true
;
}
});
});
%h1
%span
{
:id
=>
"photo_title_status"
}
Add photos to
...
...
Ce diff est replié.
Cliquez pour l'agrandir.
public/javascripts/photos.js
+
27
−
0
Voir le fichier @
81438678
...
...
@@ -22,3 +22,30 @@ function reset_photo_fancybox(){
$
(
"
#new_photo_pane
"
).
html
(
ajax
.
responseText
)
});
}
$
(
"
#photo_image
"
).
html5_upload
({
// WE INSERT ALBUM_ID PARAM HERE
url
:
"
/photos?album_id=
"
+
$
(
"
.album_id
"
)[
0
].
id
,
sendBoundary
:
window
.
FormData
||
$
.
browser
.
mozilla
,
setName
:
function
(
text
)
{
$
(
"
#progress_report_name
"
).
text
(
text
);
},
onFinish
:
function
(
event
,
total
){
$
(
"
#add_photo_button
"
).
html
(
"
Add Photos
"
);
$
(
"
#add_photo_loader
"
).
fadeOut
(
400
);
$
(
"
#photo_title_status
"
).
text
(
"
Done!
"
);
$
(
"
#progress_report
"
).
html
(
"
Good job me!
"
);
$
(
"
#add_photo_button
"
).
addClass
(
"
uploading_complete
"
);
},
onStart
:
function
(
event
,
total
){
$
(
"
#add_photo_button
"
).
html
(
"
Uploading Photos
"
);
$
(
"
#add_photo_loader
"
).
fadeIn
(
400
);
$
(
"
form.new_photo
"
).
fadeOut
(
0
);
$
(
"
#progress_report
"
).
fadeIn
(
0
);
$
(
"
#photo_title_status
"
).
text
(
"
Uploading...
"
);
return
true
;
}
});
Ce diff est replié.
Cliquez pour l'agrandir.
Aperçu
0%
Chargement en cours
Veuillez réessayer
ou
joindre un nouveau fichier
.
Annuler
You are about to add
0
people
to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Enregistrer le commentaire
Annuler
Veuillez vous
inscrire
ou vous
se connecter
pour commenter