Account-Link Display Option


I’m trying to show “name” when the field is account-link but "display":"name" is not working. Is there a way to show name for account-link field in the list?


It’s a while ago, that you posted this thread, but I answered a similar question, I came across your question and I fiddled a bit.

I f you want to populate the name in an api request, have a look here:

If you want to display the name only in entries view /collections/entries/collection_name, this might work in /config/boostrap.php:


    // only on collections Admin controller
    $app->on('app.collections.controller.admin.init', function() {

        // only after collection "test2" was found
        $this->on('collections.find.after.test2', function($name, &$entries) {

            // ajax request in entries view
            // didn't test with all possible edge cases...
            if ($this['route'] == '/collections/find') {

                foreach ($entries as &$entry) {

                    if (isset($entry['account'])) {
                        $account = $this->storage->findOne('cockpit/accounts', ['_id' => $entry['account']]);
                        $entry['account'] = !empty($account['name']) ? $account['name'] : $account['user'];



Thanks for the answer, an interesting workaround :slight_smile: