Protoqol / Prequel

Prequel for Laravel. Clear and concise database management. Unfortunately, not actively maintained due to time constraints.
https://packagist.org/packages/protoqol/prequel
MIT License
1.54k stars 96 forks source link

[Question] How to get this working with Sanctum #127

Closed ghost closed 3 years ago

ghost commented 3 years ago

Looking at the codebase, it seems this is basically a single page app, more or less, I have sanctum set up in my existing app and I'm getting errors:

Failed to load resource: the server responded with a status of 500 ()
/prequel-api/database/info/core_prequel/users:1 Failed to load resource: the server responded with a status of 500 ()
app.js:1 Error: Request failed with status code 500
    at e.exports (app.js:1)
    at e.exports (app.js:1)
    at XMLHttpRequest.h.onreadystatechange (app.js:1)

Perhaps, the error is something else ... when I try to generate any of the assets I get a 500 error in the Prequel console:

> START: Generating factory for users...
> ERROR: Class 'Protoqol\Prequel\App\FactoryAction' not found
> INFO: Getting updated data for core_prequel.users...
> START: Generating controller for users...
> ERROR: Class 'Protoqol\Prequel\App\ControllerAction' not found
> INFO: Getting updated data for core_prequel.users...

This happens for all generators ... I'm assuming it's due to Sanctum though I could be off.

Please advise asap.

Thanks ... GREAT PROJECT!

QuintenJustus commented 3 years ago

Hi there @19peaches! Thanks for reporting! I will look into this as soon as possible, I have not tested this with Sanctum to be honest. So there could be some incompatibility issues.

ghost commented 3 years ago

@QuintenJustus

Thanks so much ... I have time today so I'm going to reinstall today WITHOUT Sanctum and see if I get any different results.

I'm also going to try and make this a top level project as I'l like to use it for something a little bit different, as I look at the structure it seems that this is just a normal Laravel app running from the vendor dir ... I'll let you know how that goes.

ghost commented 3 years ago

I can now confirm that the errors I originally posted were indeed caused by Sanctum.

Installing without Sanctum enabled does indeed allow everything to route correctly, I can make Controllers, Models etc properly now.

Though I do have other issues I see, but these will be posted separately.