Separated to true MVC

Separated to true MVC and add authority management