Added more logic to buttons, table for alerts and scripts to add in alerts dynamically.