add Wg.php and update repository
update controller and other view