Skip to content

REST API: Augmentation - shallowAugmentedArrayKeys not working #10774

Closed Answered by Kilsicles
Kilsicles asked this question in Troubleshooting
Discussion options

You must be logged in to vote

Additionaly extending the EntryRepository did the job @duncanmcclean:

<?php
namespace App\Repositories;

use Statamic\Stache\Repositories\EntryRepository;
use Statamic\Stache\Query\EntryQueryBuilder;
use Statamic\Contracts\Entries\QueryBuilder;
use Statamic\Contracts\Entries\Entry;
use App\Entries\ExtendedEntry;

class CustomEntryRepository extends EntryRepository
{
    public static function bindings(): array
    {
        return [
            Entry::class => ExtendedEntry::class,
            QueryBuilder::class => EntryQueryBuilder::class,
        ];
    }
}

class AppServiceProvider extends ServiceProvider
{
    /**
     * Register any application services.
     */
    public function…

Replies: 2 comments 4 replies

Comment options

You must be logged in to vote
4 replies
@Kilsicles
Comment options

@duncanmcclean
Comment options

@Kilsicles
Comment options

@Kilsicles
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by Kilsicles
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2 participants