correctly work gallery in admin  area