24/7 Support: 800.608.6482


Try our new AI assistant by clicking the chat icon in the lower right corner.

Developer Videos

Videos | Deleting a Module

ver. 9.0 and later

Video Transcript

In this video we’re going to talk about how to remove a module once it has been installed. There are a couple “gotchas” to this process which I’m going to go over. To delete a module the first thing we have to do is find it underneath the modules list. So I’ll go up here for modules and search for the module we want to delete. Here we can edit the module. Under the Information tab, there’s this “More” button on the far right. If we click this “More” button, there’s a sub menu for Delete Module. In Miva this is how we remove a module. However, it’s not that simple. If I click this button it will ask me, “Are you sure you want to delete this module?” It will give me the path to the module. I can hit delete and it will try to delete it, but it’s going to give me this error message that says “Emporium Plus Toolkit is being used by one or more stores and cannot be deleted.” So this is the first kinda of “gotcha” to delete the module. So before you delete the module, it has to be unassigned from every store you assigned it to. This assures that the modules properly cleaned up before it’s deleted. Now, let’s try this one more time.

Let’s go unassign it from the store. I know this is located under “Utilities” and I need to go to the “Add/Remove Modules” tab and scroll down to Emporium Plus Toolkit module and click the “Remove” button. This will unassign it from the store. Now that it’s been unassigned from the store, I should be able to go and delete it like we just did. So I’m going to go to “Modules” search for “Toolkit” and under the “More” menu click on “Delete Module.” Now that it was unassigned the delete worked, the Emporium Plus Toolkit module has been deleted. So now the module has been unassigned by all the stores and it’s been deleted.

There’s one other important step I want to show you when uninstalling a module and that’s located under Store Settings. If I scroll down under the Settings at the very bottom there is a checkbox that says, “Allow modules used by Storemorph items to be uninstalled, not recommended.” By default it should be unchecked in your store. What this is saying is that it will prevent any module which currently has an active item associated with it from being uninstalled. Now this is a good thing. If you have an item assigned to a page you potentially have item tags that are on that page and before you delete a module you first want to remove those item tags, you also want to delete the items associated with the module and then you want to delete the module itself and this setting will enforce that process. However in most cases you will want to leave this box unchecked to ensure that the module and items get removed properly.

One last thing I want to show you with modules is how to deactivate a module without unassigning it from the store. When you unassign or uninstall a module, it gets completely removed from the store, all its settings get erased and you have to install it from scratch in order to use it again. However, there may be cases where you want to temporarily turn off a module. Maybe for testing, or for some other purpose. This can be done safely under the module settings. Under the drop down menu click “Modules.” Here we’ll see a list of all the modules we’ve installed from the store. Say for example I want to deactivate the “Check payment module” without having to uninstall it from the store. I can do that from editing the module and unchecking this “Active” checkbox. Now it’s important to know that this can be done safely without breaking anything associated with the store. Making a module inactive will simply turn it off. When you turn it back on or make it active again, it will automatically retain any setting associated with that module that you had saved. I can come here and uncheck active, hit “Update” and this module is now deactivated. It’s still assigned to the store as you see here with the number of stores and is still assigned to my domain, it just can’t be used because it’s been deactivated. A common use case for this is it usually has to do with payment modules and shipping modules. Once an order has been placed with any particular payment module or a particular shipping module, that module cannot be deleted unless all orders that reference that module are also deleted. So this brings up a use case where you may want to switch payment gateways or change shipping carriers, but you can’t just unassign that module from the store. A common thing to do is to come and deactivate the module which will leave it available in the store, but not make it active for anyone to use.

Modules are an incredibly powerful part of the Miva Merchant ecosystem. As a developer you will use them quite a bit every day; installing, uninstalling and updating modules will become second nature as you work your way around the Miva Merchant Admin.

Looking for Developer Docs?

We have a whole section for that, including: Developer Training Series, Template Language docs, Module Development tutorials and much, much more.

Head to the Developer Section

This website uses cookies to identify visitors, track visitors to our website, store login session information and to remember your user preferences. By continuing to use this site you agree to our use of cookies. Learn More.

This website uses cookies. By continuing to use this site you agree to our use of cookies. Learn More.


Copyright © 1997 – 2024 Miva®, Miva Merchant®, MivaPay®, MivaCon®, Camp Miva®, Miva Connect®, Miva, Inc. All Rights Reserved.