PinPointSlider Plugin can't install Nopcommerce 4.2 version

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
3 years ago
Hello I want to install new PinPointSlider Plugin but it shows in admin panel Install button when I click installation and restart application plugin is not installed.

This is repository with plugin please help:
https://github.com/piotrsz772/PinPointSliderNopcommerce/tree/master/Nop.Plugin.Widgets.PinPointSlider
3 years ago
Please check in System>>Log

Is there any error in log?
3 years ago
This is an error:

Nop.Core.NopException: No constructor was found that had all the dependencies satisfied. ---> Nop.Core.NopException: Unknown dependency
   at Nop.Core.Infrastructure.NopEngine.<ResolveUnregistered>b__14_0(ParameterInfo parameter) in E:\Repository\Protor\src\Libraries\Nop.Core\Infrastructure\NopEngine.cs:line 253
   at System.Linq.Enumerable.SelectArrayIterator`2.ToArray()
   at System.Linq.Enumerable.ToArray[TSource](IEnumerable`1 source)
   at Nop.Core.Infrastructure.NopEngine.ResolveUnregistered(Type type) in E:\Repository\Protor\src\Libraries\Nop.Core\Infrastructure\NopEngine.cs:line 257
   --- End of inner exception stack trace ---
   at Nop.Core.Infrastructure.NopEngine.ResolveUnregistered(Type type) in E:\Repository\Protor\src\Libraries\Nop.Core\Infrastructure\NopEngine.cs:line 266
   at Nop.Services.Plugins.PluginDescriptor.Instance[TPlugin]() in E:\Repository\Protor\src\Libraries\Nop.Services\Plugins\PluginDescriptor.cs:line 46
   at Nop.Services.Plugins.PluginService.InstallPlugins() in E:\Repository\Protor\src\Libraries\Nop.Services\Plugins\PluginService.cs:line 419
3 years ago
That is the source code. But does not look like a standard plugin setup
Did you build it in Visual Studio to make a plugin ?
It needs a Plugin.json file to install
3 years ago
I took code from here

https://github.com/nopSolutions/nopCommerce-plugin-template-VS/tree/nopCommerce-4.20
3 years ago
Ok that is a temple for building a plugin.
So you combined the bits of both and made a PinPointSlider plugin.
Are you debuging it in Visual Studio ?
3 years ago
you are missing plugin.json.

Please add and try to build your project and then run.
3 years ago
I have updated git version still same error with plugin.json
3 years ago
piotr772 wrote:
I have updated git version still same error with plugin.json



Just uncomment below code in  PluginNopStartup.cs

   services.AddDbContext<PinPointSliderObjectContext>(optionsBuilder =>
            {
                optionsBuilder.UseSqlServerWithLazyLoading(services);
            });


below is working....

public class PluginNopStartup : INopStartup
    {
        public void ConfigureServices(IServiceCollection services, IConfiguration configuration)
        {
            services.AddDbContext<PinPointSliderObjectContext>(optionsBuilder =>
            {
                optionsBuilder.UseSqlServerWithLazyLoading(services);
            });

            services.Configure<RazorViewEngineOptions>(options =>
            {
                options.ViewLocationExpanders.Add(new ViewLocationExpander());
            });
        }

        public void Configure(IApplicationBuilder application)
        {
        }

        public int Order => 11;
    }
3 years ago
Yes, it works now, thank you :)
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.