Added javascript code to handle delete record buttons.