Post by rgbrewer » Tue May 23, 2017 2:50 am

Hello,

I don't believe I am properly using the new architecture for version 2.3.0.2 ... Can you clarify?

I have a module that needs to be utilized specifically by the admins. These modules are being developed in the following folder

admin/controller/extension/module/mymodule_event.php
admin/controller/extension/module/mymodule_schedule.php
admin/controller/extension/module/mymodule_yellowbook.php

However, rather than doing this mymodule_ naming convention, I would prefer to group them together under one directory. However, have been unable to get any modules to work by placing them in their own directory within the extensions folder such as:

admin/controller/extension/mymodule/event.php

I have also been unable to get them to work like this either:

admin/controller/extension/module/mymodule/event.php

When I try to navigate to the proper route (extension/module/mymodule or extension/mymodule) I get an error stating I dont have permissions to access them. The permissions are set for my user group within OpenCart administration (which does see the folders.)

What am I doing wrong?
Thanks!
Last edited by rgbrewer on Tue May 23, 2017 3:00 am, edited 1 time in total.

New member

Posts

Joined
Sat Apr 22, 2017 9:30 am

Post by artcore » Tue May 23, 2017 2:58 am

It is very annoying indeed. It's because the permissions are not honored when there a more-than-2-part folder structure.
You can either ocmod the user_permissions.php in admin/controller/user/ or in admin/controller/startup/permission.php
It's easy to figure out. I have an example on my desktop, if you need help I'll post it tomorrow.

Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+ ;D

Thanks!


User avatar
Active Member

Posts

Joined
Tue Jul 09, 2013 4:13 am
Location - The Netherlands

Post by IP_CAM » Tue May 23, 2017 3:02 am

just a guess, but you may find some useful basic info on this matter by checking the links below.
Good Luck ;)
Ernie
---
Multi Module Joiner
https://www.opencart.com/index.php?rout ... n_id=23092
---
Xmod - Add Multiple modules into one
https://www.opencart.com/index.php?rout ... n_id=22187

I am no longer active at the Forum. Please do NOT send me Personal Mails,
they will no longer be replied to.
My Github OC Site: https://github.com/IP-CAM
4'300 + FREE OC Extensions, on the World's largest Github OC Repository Archive Site.


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland

Post by rgbrewer » Tue May 23, 2017 3:03 am

I would much appreciate that. I have no issue with modifying core files, but I'm looking through user_permission.php in the controller and not seeing the problem. Thank you, at least I'm not crazy.

Edit: permission.php in controller/startup seems much more promising, but I'm still not getting it to work. Thanks for the help.

New member

Posts

Joined
Sat Apr 22, 2017 9:30 am

Post by rgbrewer » Tue May 23, 2017 3:24 am

I believe I have it working:

In admin\controller\startup\permission.php

Code: Select all

$extension = array(
				'extension/dashboard',
				'extension/analytics',
				'extension/captcha',
				'extension/extension',
				'extension/feed',
				'extension/fraud',
				'extension/module',
				'extension/payment',
				'extension/shipping',
				'extension/theme',
				'extension/total'
			);
Add yours to the list.

Thanks everyone.

New member

Posts

Joined
Sat Apr 22, 2017 9:30 am

Post by artcore » Tue May 23, 2017 4:54 am

Great ;D

Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+ ;D

Thanks!


User avatar
Active Member

Posts

Joined
Tue Jul 09, 2013 4:13 am
Location - The Netherlands

Post by artcore » Tue May 23, 2017 4:56 am

IP_CAM wrote:
Tue May 23, 2017 3:02 am
just a guess, but you may find some useful basic info on this matter by checking the links below.
Good Luck ;)
Ernie
---
Multi Module Joiner
https://www.opencart.com/index.php?rout ... n_id=23092
---
Xmod - Add Multiple modules into one
https://www.opencart.com/index.php?rout ... n_id=22187
This is not related to the issue but thanks for thinking along :D

Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+ ;D

Thanks!


User avatar
Active Member

Posts

Joined
Tue Jul 09, 2013 4:13 am
Location - The Netherlands
Who is online

Users browsing this forum: No registered users and 24 guests