Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] php artisan backpack:crud sth -> Grammar::compileColumnListing does not exist #4000

Closed
MeerKatDev opened this issue Dec 9, 2021 · 2 comments
Assignees
Labels

Comments

@MeerKatDev
Copy link

Bug report

What I did

php artisan backpack:crud sth

What I expected to happen

To generate a CRUD controller as usual

What happened

xxx@MacBook lookinglass-backend % php artisan backpack:crud something                                                                                               
Model created successfully.

   BadMethodCallException 

  Method Jenssegers\Mongodb\Schema\Grammar::compileColumnListing does not exist.

  at vendor/laravel/framework/src/Illuminate/Macroable/Traits/Macroable.php:113
    109▕      */
    110▕     public function __call($method, $parameters)
    111▕     {
    112▕         if (! static::hasMacro($method)) {
  ➜ 113▕             throw new BadMethodCallException(sprintf(
    114▕                 'Method %s::%s does not exist.', static::class, $method
    115▕             ));
    116▕         }
    117▕ 

  • Bad Method Call: Did you mean Jenssegers\Mongodb\Schema\Grammar::compileRenameColumn() ? 

      +30 vendor frames 
  31  artisan:37
      Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

What I've already tried to fix it

Searched the function and tried to implement a stub, but other errors come up.
That class inherits directly from Illuminate\Database\Schema\Grammars\Grammar, so there should't be any missing functions.

Is it a bug in the latest version of Backpack?

After I run composer update backpack/crud the bug... is it still there?

Backpack, Laravel, PHP, DB version

When I run php artisan backpack:version the output is:

### PHP VERSION:
PHP 7.4.26 (cli) (built: Nov 28 2021 17:11:17) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
    with Zend OPcache v7.4.26, Copyright (c), by Zend Technologies

### LARAVEL VERSION:
v8.74.0@004ea195012d5132eca07a176a6e587c6a74815e

### BACKPACK VERSION:
4.1.61@4400187391eb5b73672c2b166a990cd737277409
@promatik
Copy link
Contributor

Hi @MeerKatDev!

This was an issue with MongoDB support. This will be fixed with Laravel-Backpack/Generators#123.
Let's move the conversation there 🙌

@tabacitu
Copy link
Member

Thanks for the report @MeerKatDev & for the PR @promatik .

@MeerKatDev - can you please confirm Antonio's PR fixes this for you?

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants