fix bugs, add alert view