开发者

Creating a new shipping provider for the store module. Where do I put it?

I want to create a new shipping module (FedEx) for the built-in Store module in DotNetNuke 6. I have created simple C# class project and can make reference to the Shipping namespace and can start implementing my own provider. But is this is best way to do this? Would I be better off creating a module? I think the latter because I will be creating a small control to configure the provider.

Once I am done, how do I get the Store to see the provider and use it in the store provider drop-down list? I have seen examples on the web about creating a brand-new module. I'm creating a new one too, but I am inheriting the Shipping class and want to essentially create a subclass (Shipping.FedEx开发者_StackOverflow中文版ShippingProvider) where is currently only Shipping.DefaultShippingProvider.

Thanks!


To answer your question - all DNN components should now be built as Extensions, packaged and installed using a DNN Manifest file.

A 'module' (really, extension) these days doesn't have to include any UI code. You can just bundle in the DLL and maybe some SQL scripts if that's what you need.

As for how to load the provider, you need to add in a provider entry and definition in your web.config file. This is the best way to do it. You can then use the in-built provider loading calls to load your provider when it is needed, although I've never worked with the store module so I don't know if this is easily achieved or not. There should be examples around that you can copy from.

As for creating the entries in your web.config, you can do this with your DNN manifest file as well.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜