WIP: Feature/permissions for elastic search

use mapv instead