refactored admin.js
Refactoring
Refactoring in progress
Refactoring
In looks like works
removed unused