Skip to content

Commit f122d7b

Browse files
Fix ACL rules
1 parent 67ecea4 commit f122d7b

File tree

5 files changed

+11
-6
lines changed

5 files changed

+11
-6
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,4 +88,4 @@ Magento attachments plugin with attachment type, multistore and visibility group
8888

8989
### 1.3.0
9090

91-
* Add composer file and visibility groups feature
91+
* Add composer file, visibility groups feature and minor fixes including proper ACL rules

app/code/community/LCB/Attachments/controllers/Adminhtml/AttachmentController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ protected function _initAction()
1717

1818
protected function _isAllowed()
1919
{
20-
return Mage::getSingleton('admin/session')->isAllowed('catalog/attachments');
20+
return Mage::getSingleton('admin/session')->isAllowed('catalog/attachments/attachment');
2121
}
2222

2323
public function indexAction()

app/code/community/LCB/Attachments/controllers/Adminhtml/CategoryController.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,11 @@
99
*/
1010
class LCB_Attachments_Adminhtml_CategoryController extends Mage_Adminhtml_Controller_Action {
1111

12+
protected function _isAllowed()
13+
{
14+
return Mage::getSingleton('admin/session')->isAllowed('catalog/attachments/category');
15+
}
16+
1217
protected function _initAction()
1318
{
1419
$this->loadLayout()->_setActiveMenu("lcb_attachments/category")->_addBreadcrumb(Mage::helper("adminhtml")->__("Category Manager"), Mage::helper("adminhtml")->__("Category Manager"));

app/code/community/LCB/Attachments/controllers/ImagesController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*/
1010
class LCB_Attachments_ImagesController extends Mage_Core_Controller_Front_Action {
1111

12-
public function GetAction()
12+
public function getAction()
1313
{
1414

1515
$imageData = $this->getRequest()->getParam('photos');

app/code/community/LCB/Attachments/controllers/IndexController.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*/
1010
class LCB_Attachments_IndexController extends Mage_Core_Controller_Front_Action {
1111

12-
public function IndexAction()
12+
public function indexAction()
1313
{
1414

1515
/**
@@ -71,7 +71,7 @@ public function IndexAction()
7171
*
7272
* @return void
7373
*/
74-
public function GetAction()
74+
public function getAction()
7575
{
7676

7777
$_isValidFormKey = $this->_validateFormKey();
@@ -214,7 +214,7 @@ public function GetAction()
214214
*
215215
* @return void
216216
*/
217-
public function DownloadAction()
217+
public function downloadAction()
218218
{
219219
$fileUrl = $this->getRequest()->getParam('url');
220220
$formKey = $this->getRequest()->getParam('form_key');

0 commit comments

Comments
 (0)