Skip to content

Commit 9f3e006

Browse files
Merge branch 'cia-bugfix-ce-20240712' into cia-2.4.8-beta1-develop-bugfix-09022024
2 parents 7d4c1e2 + 3e63705 commit 9f3e006

File tree

9 files changed

+58
-8
lines changed

9 files changed

+58
-8
lines changed

app/code/Magento/Backend/Controller/Adminhtml/System/Design.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ abstract class Design extends Action
1414
*
1515
* @see _isAllowed()
1616
*/
17-
const ADMIN_RESOURCE = 'Magento_Backend::design';
17+
public const ADMIN_RESOURCE = 'Magento_Backend::schedule';
1818

1919
/**
20-
* Core registry
20+
* Core registry instance
2121
*
2222
* @var \Magento\Framework\Registry
2323
*/

app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/Cancel.php

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,18 @@
66
*/
77
namespace Magento\Sales\Controller\Adminhtml\Order\Invoice;
88

9-
class Cancel extends \Magento\Sales\Controller\Adminhtml\Invoice\AbstractInvoice\View
9+
use Magento\Framework\App\Action\HttpPostActionInterface;
10+
use Magento\Sales\Controller\Adminhtml\Invoice\AbstractInvoice\View;
11+
12+
class Cancel extends View implements HttpPostActionInterface
1013
{
14+
/**
15+
* Authorization level of a basic admin session
16+
*
17+
* @see _isAllowed()
18+
*/
19+
public const ADMIN_RESOURCE = 'Magento_Sales::invoice';
20+
1121
/**
1222
* Cancel invoice action
1323
*

app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/Capture.php

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,18 @@
66
*/
77
namespace Magento\Sales\Controller\Adminhtml\Order\Invoice;
88

9-
class Capture extends \Magento\Sales\Controller\Adminhtml\Invoice\AbstractInvoice\View
9+
use Magento\Framework\App\Action\HttpPostActionInterface;
10+
use Magento\Sales\Controller\Adminhtml\Invoice\AbstractInvoice\View;
11+
12+
class Capture extends View implements HttpPostActionInterface
1013
{
14+
/**
15+
* Authorization level of a basic admin session
16+
*
17+
* @see _isAllowed()
18+
*/
19+
public const ADMIN_RESOURCE = 'Magento_Sales::invoice';
20+
1121
/**
1222
* Capture invoice action
1323
*

app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/NewAction.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class NewAction extends \Magento\Backend\App\Action implements HttpGetActionInte
2323
*
2424
* @see _isAllowed()
2525
*/
26-
const ADMIN_RESOURCE = 'Magento_Sales::sales_invoice';
26+
public const ADMIN_RESOURCE = 'Magento_Sales::invoice';
2727

2828
/**
2929
* @var Registry

app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/Save.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ class Save extends \Magento\Backend\App\Action implements HttpPostActionInterfac
3030
*
3131
* @see _isAllowed()
3232
*/
33-
public const ADMIN_RESOURCE = 'Magento_Sales::sales_invoice';
33+
public const ADMIN_RESOURCE = 'Magento_Sales::invoice';
3434

3535
/**
3636
* @var InvoiceSender

app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/Start.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,13 @@
1010

1111
class Start extends \Magento\Sales\Controller\Adminhtml\Invoice\AbstractInvoice\View implements HttpGetActionInterface
1212
{
13+
/**
14+
* Authorization level of a basic admin session
15+
*
16+
* @see _isAllowed()
17+
*/
18+
public const ADMIN_RESOURCE = 'Magento_Sales::invoice';
19+
1320
/**
1421
* Start create invoice action
1522
*

app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/UpdateQty.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,19 @@
1818
use Magento\Sales\Controller\Adminhtml\Invoice\AbstractInvoice\View as AbstractView;
1919

2020
/**
21-
* Class UpdateQty
21+
* Class UpdateQty to update invoice items qty
22+
*
2223
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
2324
*/
2425
class UpdateQty extends AbstractView implements HttpPostActionInterface
2526
{
27+
/**
28+
* Authorization level of a basic admin session
29+
*
30+
* @see _isAllowed()
31+
*/
32+
public const ADMIN_RESOURCE = 'Magento_Sales::invoice';
33+
2634
/**
2735
* @var JsonFactory
2836
*/

app/code/Magento/Sales/Controller/Adminhtml/Order/Invoice/VoidAction.php

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,18 @@
66
*/
77
namespace Magento\Sales\Controller\Adminhtml\Order\Invoice;
88

9-
class VoidAction extends \Magento\Sales\Controller\Adminhtml\Invoice\AbstractInvoice\View
9+
use Magento\Framework\App\Action\HttpPostActionInterface;
10+
use Magento\Sales\Controller\Adminhtml\Invoice\AbstractInvoice\View;
11+
12+
class VoidAction extends View implements HttpPostActionInterface
1013
{
14+
/**
15+
* Authorization level of a basic admin session
16+
*
17+
* @see _isAllowed()
18+
*/
19+
public const ADMIN_RESOURCE = 'Magento_Sales::invoice';
20+
1121
/**
1222
* Void invoice action
1323
*

dev/tests/integration/testsuite/Magento/Sales/Controller/Adminhtml/Order/Invoice/SaveTest.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,11 @@ class SaveTest extends AbstractInvoiceControllerTest
3333
/** @var Item */
3434
private $orderItemResource;
3535

36+
/**
37+
* @var string
38+
*/
39+
protected $resource = "Magento_Sales::invoice";
40+
3641
/**
3742
* @inheritdoc
3843
*/

0 commit comments

Comments
 (0)