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

Success message is not showing when creating invoice & shipment simultaniously #19942 #20391

Merged

Conversation

XxXgeoXxX
Copy link
Member

Description (*)

Preconditions (*)

Magento 2.3
PHP 7.1.3

Steps to reproduce (*)

Create order from admin panel.
View order at admin panel and Click "create invoice".
Check the checkbox "create shipment" and "Email copy of invoice" while generating invoice. and click submit invoice button.

Expected result (*)

Success message should show as "You created the invoice and shipment."

Actual result (*)

Invoice has been created but no success message is appearing.

Manual testing scenarios (*)

Create order from admin panel.
View order at admin panel and Click "create invoice".
Check the checkbox "create shipment" and "Email copy of invoice" while generating invoice. and click submit invoice button.

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds on Travis CI are green)

@magento-engcom-team
Copy link
Contributor

Hi @XxXgeoXxX. Thank you for your contribution
Here is some useful tips how you can test your changes using Magento test environment.
Add the comment under your pull request to deploy test or vanilla Magento instance:

  • @magento-engcom-team give me test instance - deploy test instance based on PR changes
  • @magento-engcom-team give me 2.3-develop instance - deploy vanilla Magento instance

For more details, please, review the Magento Contributor Assistant documentation

@sdzhepa
Copy link
Contributor

sdzhepa commented Jan 30, 2019

@magento-engcom-team give me test instance

@magento-engcom-team
Copy link
Contributor

Hi @sdzhepa. Thank you for your request. I'm working on Magento instance for you

@magento-engcom-team
Copy link
Contributor

Hi @sdzhepa, here is your new Magento instance.
Admin access: https://pr-20391.instances.magento-community.engineering/admin
Login: admin Password: 123123q

@sdzhepa
Copy link
Contributor

sdzhepa commented Jan 30, 2019

@magento-engcom-team give me 2.3-develop instance

@magento-engcom-team
Copy link
Contributor

Hi @sdzhepa. Thank you for your request. I'm working on Magento 2.3-develop instance for you

@magento-engcom-team
Copy link
Contributor

Hi @sdzhepa, here is your Magento instance.
Admin access: https://i-20391-2-3-develop.instances.magento-community.engineering/admin
Login: admin Password: 123123q
Instance will be terminated in up to 3 hours.

@sdzhepa sdzhepa self-assigned this Jan 30, 2019
@sdzhepa
Copy link
Contributor

sdzhepa commented Jan 30, 2019

Hello @XxXgeoXxX

I cannot reproduce the described issue on lates 2.3-develop by provided steps (Steps to reproduce/Manual testing scenarios)

Could you confirm and close PR or provide additional details?

Used scenario:

  1. Request new vanilla Magento instance give me 2.3-develop instance

  2. Go to Admin Panel and create new Simple Product for test

  3. Go to Sales > Orders and created a new order with the test product

  4. Create new test Customer

  5. Add Simple product, fill all required fields and click Submit Order (Flat Rate + Check / Money order)

  6. Click Invoice button

  7. Check "Create Shipment"

  8. Check "Email Copy of Invoice"
    123123123123123

  9. Click Submit Invoice button

Actual Result: Sucess message "You created the invoice and shipment." is shown
3333333333333

Thank you for contribution and collaboration!

@XxXgeoXxX
Copy link
Member Author

XxXgeoXxX commented Jan 30, 2019

Hi @sdzhepa
I think you couldn't reproduce issue because PR #20142 was merged to 2-3-develop branch
Issue #19942

Messages are removed after call method app/code/Magento/Email/Model/Template/Filter.php:blockDirective because all/only shipment email template used construction '{{block}}'. When shipment and invoice created together with send email functionality mesages were added and after that Magento creates block(according templates app/code/Magento/Sales/view/frontend/email/shipment_new.html) by layout functionality(\Magento\Framework\View\LayoutInterface) and it call method initMessages which remove all of them.

This does not happen when we only ship order because method add messages called after send email.
Or after moving method after sending emails.

@sdzhepa
Copy link
Contributor

sdzhepa commented Feb 14, 2019

Hi @XxXgeoXxX

Thank you for the details!

Just one thing, during testing I found new records in the system/debug log files.
Could you please have a look nad fix?

Steps to reproduce

Actual result: (on branch with fix)

[2019-02-01 22:07:42] main.INFO: Broken reference: the 'sales.email.order.shipme
nt.renderers.default' element cannot be added as child to 'sales.email.order.shi
pment.renderers', because the latter doesn't exist [] []
[2019-02-01 22:07:42] main.INFO: Broken reference: the 'sales.email.order.shipme
nt.renderers.bundle' element cannot be added as child to 'sales.email.order.ship
ment.renderers', because the latter doesn't exist [] []

Expected result: (on 2.3-develop branch )

  • there are no records about "Broken reference" as on branch with fix (edited)

@XxXgeoXxX
Copy link
Member Author

Hi, @sdzhepa. I could not reproduce your records in log files.

@sdzhepa
Copy link
Contributor

sdzhepa commented Mar 1, 2019

Hello @XxXgeoXxX

We have rechecked it one more time on the clean clone and install and no errors.
It seems was some local env issue.

Sorry for delays, I put the PR into the delivery queue

Thank you for contribution and collaboration!

@sdzhepa sdzhepa removed their assignment Mar 1, 2019
@magento-engcom-team
Copy link
Contributor

Hi @sdzhepa, thank you for the review.
ENGCOM-4419 has been created to process this Pull Request

@sdzhepa sdzhepa removed their assignment Mar 1, 2019
@p-bystritsky p-bystritsky self-assigned this Mar 6, 2019
@magento-engcom-team magento-engcom-team merged commit 32f0eb7 into magento:2.3-develop Mar 11, 2019
@ghost
Copy link

ghost commented Mar 11, 2019

Hi @XxXgeoXxX, thank you for your contribution!
Please, complete Contribution Survey, it will take less than a minute.
Your feedback will help us to improve contribution process.

magento-engcom-team pushed a commit that referenced this pull request Mar 11, 2019
@magento-engcom-team magento-engcom-team added this to the Release: 2.3.2 milestone Mar 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants