Commit 93da61ff authored by Mat's avatar Mat

hop

parent 7406447a
......@@ -103,9 +103,10 @@
*/
let editBtn = document.createElement('button');
editBtn.innerHTML = '<i class="fas fa-edit fa-fw"></i> Editer';
editBtn.classList.add('btn', 'btn-primary');
editBtn.dataset.imageId = json[i].id;
editBtn.innerHTML = '<i class="fas fa-edit fa-fw"></i> Editer';
editBtn.addEventListener('click', function(e)
{
let imageId = this.dataset.imageId;
......@@ -130,9 +131,10 @@
*/
let deleteBtn = document.createElement('button');
deleteBtn.innerHTML = '<i class="fas fa-trash fa-fw"></i> Supprimer';
deleteBtn.classList.add('btn', 'btn-danger');
deleteBtn.dataset.imageId = json[i].id;
deleteBtn.innerHTML = '<i class="fas fa-trash fa-fw"></i> Supprimer';
deleteBtn.addEventListener('click', function(e)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment