added ajax to get tasks from server