Category: Laravel 6
-
Post Views: 20 1. In Laravel 6.20.43, Lighthouse 5.45.0, the classClearSschemaCacheDeprecated. as shown in Figure 1 2. The reason should be caused by the change of the version of the lighthouse. genusClearSschemaCacheThe effect is to clear the pattern cache before running any tests. 3. Reference:https://lighthouse-php.com/5/testing/phpunit.html#setup, decide to replace with the classRefressschemaCache 4. Edit /modules/themestore/tests/functional/graphql/themeAssetGraphqlaptest.php. as shown in Figure 2 5.…
-
Post Views: 22 1. The structure when the request responds successfully. as shown in Figure 1 2. However, at this stage, there is no security verification for the request parameters. Reference:https://lighthouse-php.com/master/security/validation.html#single-arguments. Lighthouse allows you to use Laravel’s validation in queries and changes. 3. The change of this GraphQL API has only one request parameter, that is, themeID, and only need…
-
Post Views: 18 1. Error in Laravel 6: Target[Interface]Is not instantiable while building[Resolver]. as shown in Figure 1 2. View git logs, analyze /modules/themestore/providers/themestoreServiceProvider.php, send Now there is a shared binding registered in the container: ThemeConfigLoaderInterface::Class, but now it does not exist. as shown in Figure 2 3. Finally found this shared binding: ThemeConfigLoaderInterface::Class has been moved to /modules/themesetting/providers/themesettingServiceProvider.php 4.…
-
Post Views: 19 1. In \Vendor\Laravel\Telescope\Src\Watchers\EventWatcher.php:91, an error is reported: get_class() expects parameter 1 to be object, string give. as shown in Figure 1 2. Check \Vendor\Laravel\Telescope\SRC\Watchers\EventWatcher.php:91 3. View the EventServiceProvider 4. This looks like a bug, and I see a new commit that just solves this problem. Submit:https://github.com/laravel/telescope/commit/a69fc6f4f5fd5b0ac5a242981e162774cbb69e17. Support new listeners syntax. as shown in Figure 2 5. I…
-
Post Views: 18 1. There are now 2 projects, and their domain names are: Object.local, Object-master.local. The redis configuration of its .env file is as follows 2. However, the performance at this stage is that both projects still use Redis 1. The problem caused by sharing a Redis 1 database is that when Object.local is opened, and then Object-master.local is…
-
Post Views: 21 1. Run successfully in Altair GraphQL Client. as shown in Figure 1 2. Edit the test file, /modules/themestore/tests/functional/graphql/MutationThemeAssetGraphQLapTest.php. 3. Run the test case and report an error: Expected Type ThemeAssetCreateInput to be an object. as shown in Figure 2 4. Re-edit the test file 5. Run the test again and the test passes. 6. Run the test…
-
Post Views: 19 1. In PHPStorm and Laravel 6, the event log: Switch Laravel Idea Module System to Laravel-Modules? Switch or DonT show this again. as shown in Figure 1 2. Reference:https://laravel-idea.com/docs/modules. Laravel Idea uses module system concepts to understand the structure of the application. It helps with the correct view, configuration, routing and more convenient code generation. The module…
-
Post Views: 14 1. Error in Laravel 6: Target[Interface]Is not instantiable while building[Resolver]. as shown in Figure 1 2. Check /modules/themestore/providers/themestoreServiceProvider.php, prompting undefined classThemeschemaLoaderInterface. as shown in Figure 2 3. However, you can confirm the classThemeschemaLoaderInterfaceis there. In the end, I found that the path of use is wrong. Delete the theme\ from the path. IDE no longer prompts. as…
-
Post Views: 19 1. The structure when the request responds successfully. as shown in Figure 1 2. However, at this stage, there is no security verification for the request parameters. Reference:https://lighthouse-php.com/master/security/validation.html#single-arguments. Lighthouse allows you to use Laravel’s validation in queries and changes. as shown in Figure 2 3. Although the change of this GraphQL API has only 3 parameters in…
-
Post Views: 21 1. Add Template to create a template. as shown in Figure 1 2. Click the save button to view the network request. Request URL:https://xxx.myshopify.com/admin/themes/111/assets. Request method: POST. This is the REST implementation. as shown in Figure 2 Requested form data: Response data: 3. The API for creating template files is not implemented in GraphQL. Decided to refer…