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

Some issues on installation #56

Open
hoekie opened this issue Sep 14, 2023 · 5 comments
Open

Some issues on installation #56

hoekie opened this issue Sep 14, 2023 · 5 comments

Comments

@hoekie
Copy link

hoekie commented Sep 14, 2023

Hi!

After solving issue #55 I ran into the following:

After running dev/build I get this error:
Fatal error: Declaration of Sunnysideup\Ecommerce\Cms\CMSPageAddControllerProducts::doCancel($data, $form) must be compatible with SilverStripe\CMS\Controllers\CMSPageAddController::doCancel(array $data, SilverStripe\Forms\Form $form): SilverStripe\Control\HTTPResponse in C:\wamp64\www\mysite\vendor\sunnysideup\ecommerce\src\Cms\CMSPageAddControllerProducts.php on line 42

According to your docs, there should be an ecommerce.yml.example file in the _config folder to be copied into my own but it is nowhere to be found.
Or I'm looking on the wrong spot ;)

The demo site is not working (http://www.silverstripe-ecommerce.com/)

So far my findings regarding the installation.

Cheers!

Richard

@sunnysideup
Copy link
Owner

I will sort out the demo!

@sunnysideup
Copy link
Owner

sunnysideup commented Sep 17, 2023

I have solved some issues. I am sure there are more to solve! Please report.

@hoekie
Copy link
Author

hoekie commented Sep 17, 2023

Hi!

Thank you for your update!

After I unistalled and then installed the software again I ran into the following error after dev/build:

Sunnysideup\Ecommerce\Pages\CheckoutPage
[Emergency] Uncaught BadMethodCallException: Object->__call(): the method 'publishResursive' does not exist on 'Sunnysideup\Ecommerce\Pages\CheckoutPage'
GET /dev/build
Line 57 in C:\wamp64\www\mysite\vendor\silverstripe\framework\src\Core\CustomMethods.php

I notisted that you mispelled 'publishResursive' so I chanched that to 'publishRecursive' and ran dev/build again and all errors where gone!

Great!

In the environment builder list, I clicked on 'Please make sure to review your e-commerce settings (dev/ecommerce).
This gave me the following error:

[Emergency] Uncaught Error: Class "Sunnysideup\Ecommerce\Tasks\EcommerceTaskCheckConfiguration" not found
GET /dev/ecommerce/
Line 337 in C:\wamp64\www\mysite\vendor\sunnysideup\ecommerce\src\Cms\Dev\EcommerceDatabaseAdmin.php

In the backend, all items of the shop are visible in the left menu. I clicked on each link to see if they work and a click on each search link gave me the following error:

[Deprecated] strtotime(): Passing null to parameter #1 ($datetime) of type string is deprecated
GET /admin/sales-by-payment-type
Line 86 in C:\wamp64\www\mysite\vendor\sunnysideup\ecommerce\src\Api\EcommerceCache.php

In the next few days I will test the rest of the shop.

I will come back to this later this week.

Thanks so far for solving the issues!

Richard

@hoekie
Copy link
Author

hoekie commented Sep 18, 2023

Here is a thought of eliminating the 'Passing null to parameter' errors.

Adding a new product gave me:
[Deprecated] trim(): Passing null to parameter #1 ($string) of type string is deprecated
POST /admin/addproductorproductgroup/AddForm
Line 51 in C:\wamp64\www\rubenhoeke\vendor\sunnysideup\ecommerce\src\Dev\EcommerceCodeFilter.php

I'm using PHP 8.1 and this version has deprecated passing null as parameters to a lot of core functions such as trim() and strtotime() so I added ?? '' to $s = trim($obj->{$fieldName}); like so $s = trim($obj->{$fieldName} ?? ''); on line 51 of the EcommerceCodeFilter.php file and that seems to work fine.
I don't know if that's the right approach but it works...

Richard

@sunnysideup
Copy link
Owner

Hi,

I have gone through and made more changes. I am working on the demo site. I expect this to be up in around two months, but e-commerce should work mostly, already. Please keep reporting. I have fixed a lot of the string functions. You can always email me directly: [email protected] if you have more detailed questions.

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

No branches or pull requests

2 participants