Why the RegisterPluginDataContext method isn't exist in DependencyRegistrar ? [nop2.8]

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
9 years ago
i write a plugin, i can't build the project because that one is not exist. Maybe that method with mvc 5 or nop 3.x. Everybody know that problems, Please tell me if you fixed.

Thank you very much.
9 years ago
RegisterPluginDataContext is an extension method. Just ensure that "using Nop.Web.Framework.Mvc" is added to your DependencyRegistrar
9 years ago
a.m. wrote:
RegisterPluginDataContext is an extension method. Just ensure that "using Nop.Web.Framework.Mvc" is added to your DependencyRegistrar


Thank you for reply! What do you think when you see a image below ?

http://s18.postimg.org/bdvsk2xwp/Untitled.png
9 years ago
a.m. wrote:
RegisterPluginDataContext is an extension method. Just ensure that "using Nop.Web.Framework.Mvc" is added to your DependencyRegistrar


If i remove RegisterPluginDataContext method, my object_context doesn't work when i install the plugin. That mean, i can't access data with that object_context, the database don't generate table. I tried to apply normal code first, then POCO is generated in the database and i can get data from the way, only time. However, i uninstall plugin and delete the table by hand. After that, i re-install the plugin, The system notify that my object context have problems. I think the problem is mapping, when i uninstall plugin, i must remove mapping but i don't want to intervene available system .
8 years ago
the function "RegisterPluginDataContext" doesn't exist in NOPCommerce version 3.20
7 years ago
the same here with nop 3.20... Any solution?
6 years ago
I dont know about 2.8 or other versions but at 4.0 I got around this problem by checking the code at Shipping by Weight plugin.

Their using contains the following

using Autofac;
using Autofac.Core;
using Nop.Core.Configuration;
using Nop.Core.Data;
using Nop.Core.Infrastructure;
using Nop.Core.Infrastructure.DependencyManagement;
using Nop.Data;
using Nop.Plugin.Shipping.FixedOrByWeight.Data;
using Nop.Plugin.Shipping.FixedOrByWeight.Domain;
using Nop.Plugin.Shipping.FixedOrByWeight.Services;
using Nop.Web.Framework.Infrastructure;

The doc just cant catch up with the code updates.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.