add view and fix bug