Post by ValeraBahley » Thu Sep 05, 2024 11:27 pm

I need to make a script that periodically fetches a JSON and adds some products/categories to the catalog.

I made a controller in admin/ with no view. It can successfully modify the catalog using the built in models, but, from what I understand, since it's an admin extension, even if I don't have any

Code: Select all

$this->user->hasPermission
checks in the class code I must be logged in browser in to call it. Therefore using Cron to periodically call this module with a cURL is suboptimal, if even possible.

Question: should I just make a separate script that connects and modifies the database by itself, or is there a way to utilize built in models?

Thanks in advance.

Newbie

Posts

Joined
Sat Aug 08, 2020 5:41 am

Post by paulfeakins » Fri Sep 06, 2024 6:40 pm

ValeraBahley wrote:
Thu Sep 05, 2024 11:27 pm
Question: should I just make a separate script that connects and modifies the database by itself, or is there a way to utilize built in models?
This question has been asked and answered many times, please always search the forum before posting.

Locking topic.

UK OpenCart Hosting | OpenCart Audits | OpenCart Support - please email info@antropy.co.uk


User avatar
Guru Member
Online

Posts

Joined
Mon Aug 22, 2011 11:01 pm
Location - London Gatwick, United Kingdom
Who is online

Users browsing this forum: Amazon [Bot] and 25 guests