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

Dosen't send email on state change using WS since 1.7.6 #14842

Closed
thbl opened this issue Jul 24, 2019 · 4 comments · Fixed by #14899
Closed

Dosen't send email on state change using WS since 1.7.6 #14842

thbl opened this issue Jul 24, 2019 · 4 comments · Fixed by #14899
Assignees
Labels
1.7.6.0 Affects versions Bug Type: Bug Email Label: Which BO under menu is concerned Fixed Resolution: issue closed because fixed Minor Severity: minor bug > https://build.prestashop.com/news/severity-classification Order Component: Which BO section is concerned Regression Type: regression WS Category: Web Service
Milestone

Comments

@thbl
Copy link

thbl commented Jul 24, 2019

After updating to 1.7.6...
When changing ordre "current_state" using webservice, emails is not sent tho ordre state changes.

@khouloudbelguith
Copy link
Contributor

khouloudbelguith commented Jul 24, 2019

Hi @thbl,

Thanks for your report.

I manage to reproduce the issue with PS1.7.6.0.
I used this script

<?php
/**
 * Created by PhpStorm.
 * User: khouloud.belguith
 * Date: 24/07/19
 * Time: 12:01
 */
define('DEBUG', true);
ini_set('display_errors','on');
define('PS_SHOP_PATH', 'http://shop.com');
define('PS_WS_AUTH_KEY', 'key');
require_once('PSWebServiceLibrary.php');
$ws = new PrestaShopWebservice(
    'http://shop.com',
    'Key',
    false);
$id = 11; //ID order Here
$xml = $ws->get(array('resource' => 'orders', 'id' => $id));
echo "BEFORE\n";
echo $xml->asXML();
unset($xml->order->current_state);
$xml->order->shipping_number = 10;
$xml->order->current_state = 4;
$opt['putXml'] = $xml->asXML();
$opt['id'] = $id;
$opt['resource'] = 'orders';

$xml = $ws->edit($opt);


$xml = $ws->get(array('resource' => 'orders', 'id' => $id));

echo $xml->asXML();

It is OK with PS1.7.5.2, Email is received.
I’ll add this to the debug roadmap so that it’s fixed. If you have already fixed it on your end or if you think you can do it, please do send us a pull request!
Thanks!

@khouloudbelguith khouloudbelguith added 1.7.6.0 Affects versions Bug Type: Bug Email Label: Which BO under menu is concerned Minor Severity: minor bug > https://build.prestashop.com/news/severity-classification Order Component: Which BO section is concerned WS Category: Web Service Regression Type: regression labels Jul 24, 2019
@colinegin colinegin added this to Backlog in PrestaShop 1.7.6 via automation Jul 24, 2019
@thbl
Copy link
Author

thbl commented Jul 24, 2019

@khouloudbelguith sadly i can't seam to find the bug yet

@thbl
Copy link
Author

thbl commented Jul 25, 2019

If new state has "send email to customer" enable, webservice will return with a error 500
(500 Internal Server Error)
Tho the order state has been changed, without sending a email.

@Progi1984 Progi1984 added the WIP Status: Work In Progress label Jul 26, 2019
@Progi1984 Progi1984 added this to the 1.7.6.1 milestone Jul 26, 2019
@marionf marionf moved this from Backlog to In progress in PrestaShop 1.7.6 Jul 29, 2019
@Progi1984 Progi1984 moved this from In progress to To be reviewed in PrestaShop 1.7.6 Jul 29, 2019
@eternoendless eternoendless moved this from To be reviewed to To be tested in PrestaShop 1.7.6 Jul 31, 2019
@khouloudbelguith khouloudbelguith added Fixed Resolution: issue closed because fixed and removed WIP Status: Work In Progress labels Aug 1, 2019
@khouloudbelguith khouloudbelguith moved this from To be tested to To be merged in PrestaShop 1.7.6 Aug 1, 2019
PrestaShop 1.7.6 automation moved this from To be merged to Done Aug 1, 2019
@marionf marionf moved this from Done to In progress in PrestaShop 1.7.6 Aug 1, 2019
@marionf marionf moved this from In progress to To do in PrestaShop 1.7.6 Aug 1, 2019
@marionf marionf reopened this Aug 1, 2019
PrestaShop 1.7.6 automation moved this from To do to In progress Aug 1, 2019
@marionf marionf removed the Fixed Resolution: issue closed because fixed label Aug 1, 2019
@marionf marionf added the Ready Status: Issue is ready to be worked on label Aug 1, 2019
@marionf
Copy link
Contributor

marionf commented Aug 1, 2019

Reopened, the PR should be on 1.7.6.x branch

@khouloudbelguith khouloudbelguith added Fixed Resolution: issue closed because fixed and removed Ready Status: Issue is ready to be worked on labels Aug 1, 2019
@khouloudbelguith khouloudbelguith moved this from In progress to To be tested in PrestaShop 1.7.6 Aug 1, 2019
@khouloudbelguith khouloudbelguith moved this from To be tested to To be merged in PrestaShop 1.7.6 Aug 1, 2019
PrestaShop 1.7.6 automation moved this from To be merged to Done Aug 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1.7.6.0 Affects versions Bug Type: Bug Email Label: Which BO under menu is concerned Fixed Resolution: issue closed because fixed Minor Severity: minor bug > https://build.prestashop.com/news/severity-classification Order Component: Which BO section is concerned Regression Type: regression WS Category: Web Service
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

4 participants