modify usercontroller
add perm function