magento / magento2

Prior to making any Submission(s), you must sign an Adobe Contributor License Agreement, available here at: https://opensource.adobe.com/cla.html. All Submissions you make to Adobe Inc. and its affiliates, assigns and subsidiaries (collectively “Adobe”) are subject to the terms of the Adobe Contributor License Agreement.
http://www.magento.com
Open Software License 3.0
11.49k stars 9.31k forks source link

Unable to to add items when creating an order in M2.3.1 admin (error 500) #23186

Closed mrlerch closed 5 years ago

mrlerch commented 5 years ago

Preconditions (*)

CentOS Linux release 7.6.1810, PHP 7.2.17 php-fpm, nginx/1.15.12, 5.7.24-27 Percona M2.3.1

Steps to reproduce (*)

  1. Log in to Magento Admin
  2. Go to Sales -> Orders
  3. Create New Order
  4. Select Customer
  5. Click on "Add Products"
  6. Select a Product, or products. I just selected one product with qty 1
  7. Click on "Add selected products to order"

Expected result (*)

  1. I would expect to see the product in the specified quantity to be listed under the "Items Ordered" section or to be listed how it is supposed to be listed
  2. I would expect that there should still be a button labeled "Add Products", but it's not there.
  3. I would expect that at the bottom at Sub Totals I would see the price subtotal of the added products, but it shows $0

Actual result (*)

  1. Please see screen shot
  2. Failed to load resource: https://dev.proproductssales.com/admin_17bb64/sales/order_create/loadBlock/key/85e684c462766728b38d3d47b40d908c0776d968c03919668805295c40650988/block/search,items,shipping_method,totals,giftmessage,billing_method?isAjax=true the server responded with a status of 500 ()
  3. When I proceed to fill in the shipping address etc. and then get a shipping quote, I can select the method
  4. When I click on Available Payment method I get ---- nothing
  5. when I click on "Submit order" I get:

1 exception(s): Exception #0 (Magento\Framework\Exception\ValidatorException): Invalid template file: 'Magento_Paypal::payment/mark.phtml' in module: '' block's name: 'magento\framework\view\element\template_0'

Please help image

image image
m2-assistant[bot] commented 5 years ago

Hi @mrlerch. Thank you for your report. To help us process this issue please make sure that you provided the following information:

Please make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, please, add a comment to the issue:

@magento give me 2.3-develop instance - upcoming 2.3.x release

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

@mrlerch do you confirm that you were able to reproduce the issue on vanilla Magento instance following steps to reproduce?


m2-assistant[bot] commented 5 years ago

Hi @krishprakash. Thank you for working on this issue. In order to make sure that issue has enough information and ready for development, please read and check the following instruction: :point_down:

mrlerch commented 5 years ago

So I have more information. When I disable the PayPal payment method that is included and shipped with M2.3.1 then it is kind of working. At least I can add and modify items in the order.

Still if the customer has items in the cart, and I check one or all and the click update in the left column at the bottom the simply seems to remove the items from the customer cart, but does t add it to the current order. So that’s another bug.

I am also seeing several error messages displayed. I will take some screen shots and send them over.

So all in all I believe that first and foremost the PayPal payment method is the problem here.

Does anyone know when M2.3.3 is going to be released? I read other posts where people had PayPal method issues in the front end. Just asking....

mrlerch commented 5 years ago

More info. In the system log I see this: main.ERROR: Invalid template file: 'Magento_Paypal::payment/mark.phtml' in module: '' block's name: 'magento\framework\view\element\template_0' [] []

mark.phtml which apparently does not exist in the file tree, is called here: vendor/magento/module-paypal/Block/Express/Form.php

CompactCodeEU commented 5 years ago

We have resolved this issue for @mrlerch . The problem it is referring to a frontend template. The 2 templates should be moved to the base directory. So vendor/magento/module-paypal/view/frontend/templates/payment/mark.phtml vendor/magento/module-paypal/view/frontend/templates/payment/redirect.phtml needs to be moved to vendor/magento/module-paypal/view/base/templates/payment/mark.phtml vendor/magento/module-paypal/view/base/templates/payment/redirect.phtml

Making the template available for frontend and adminhtml area's

@magento-engcom-team Do i need to push a request?

m2-assistant[bot] commented 5 years ago

Hi @engcom-Charlie. Thank you for working on this issue. In order to make sure that issue has enough information and ready for development, please read and check the following instruction: :point_down:

engcom-Charlie commented 5 years ago

Hello @mrlerch I have to close this issue because i can't reproduce this bug on fresh Magento 2.3-develop. Thank for your report!

CompactCodeEU commented 4 years ago

This should not be closed. Just move the templates to the base directory instead of the frontend directory. Its an easy fix that does not have any backwards compatibility issues

mrlerch commented 4 years ago

Issue is back after recent upgrade to M 2.3.3. Please fix .... again.

mrlerch commented 4 years ago

I ended up moving the 2 files as mentioned in Rob's post and it is working again. Why can't someone update this???????

vendor/magento/module-paypal/view/frontend/templates/payment/mark.phtml vendor/magento/module-paypal/view/frontend/templates/payment/redirect.phtml needs to be moved to vendor/magento/module-paypal/view/base/templates/payment/mark.phtml vendor/magento/module-paypal/view/base/templates/payment/redirect.phtml

JoostWan commented 4 years ago

This is still a issue in 2.3.5-p2