import product acl records

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
6 years ago
We import products directly into the NOP database.  During this import we need to create product acl records.  I've noticed that If I simply create a new record within the "AclRecord" table with a EntityName of "Product" that my desired changes show up under the Products admin page; however my changes don't reflect when using the webpage.  Clearing cache and restarting the application don't seem to help.  If I make no changes and save the product via the admin section the database changes then do reflect.

What am I missing to be able to get this to work via the import process?  I did look at that "InsertAclRecord" method inside of the Nop.Sevices.Security.AclService and see all it's doing is a database insert into that "AclRecord" table and then clearing the cache.  So I would think my import process would work as well.
6 years ago
After some debugging of the code while updating a product via the admin panel.  I was able to answer my own questions.  I didn't realize it but you also need to set SubjectToAcl to true as well within the Product table.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.