Skip to content

Commit

Permalink
[rolodex] adds back method to populate contact edit form
Browse files Browse the repository at this point in the history
  • Loading branch information
prashant3863 committed Sep 26, 2023
1 parent c508c86 commit c365e53
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions apps/rolodex/views/partials/app/contact_list.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@
window.deleteContact = deleteContact;
window.renderTable = renderTable;
window.setContactEditForm = function (id, name){
document.getElementById("edit-contact-name").value = name
document.getElementById("edit-contact-id").value = id
}
getContacts().then((result) => {
document.querySelector("#contact-list-table > table").appendChild(renderTable(result))
})
Expand Down

0 comments on commit c365e53

Please sign in to comment.