Prestashop 1.5, How to copy a core module into my theme module folder? - module

I'de like to copy the [prestashop new theme]cart block (cartblock2 in the main module folder) into my theme/modules in order to customize it and keep the core module intact.
How do I do that ? I searched the documentation and it's not very clear...
What I did so far :
Copy cartblock2 from the main module folder into my theme/module folder, empty prestashop cache (it's turned off but just to be sure), I made my changes but nothing change it's only changing when I modify the module in the main module folder.
Thank you for your help

module folder name must same with root modules name
/modules/blockcart2
in themes
/themes/modules/blockcart2
and you can only edit blockcart2.tpl file in themes folder
and make sure blockcart2 installed in bacoffice

Related

How I can add new module to odoo 15

I am new to Odoo and I need to know what is the basic steps of adding a new module.
More specifically I need to know how to add custom modules to the addons-path.
In Odoo document they explain this step as this
$ ./odoo-bin --addons-path=../custom,../enterprise/,addons
but did not work for me.
For adding a new module you should do these steps:
Build your module with your written code or scaffold command.
Add the module path in your config file at addons-path = '',''
Change your URL like this: http://localhost:8091/web?debug=1
Go to apps and from up tabs
Select update app list and refresh your page.
Now you can see your module in the apps.
If you are not getting your custom module in Odoo after adding the path then you can try to add the full path of your folder into addons-path.
To get the full path of your custom folder just right-click on the folder and go to properties and find the path of your folder.
Also, you have to make sure to Apply the Update App list in your Odoo App Dashboard after restarting the server with custom addons.

PrestaShop Using Default Module Instead of Theme Module

Today I starting design theme for prestashop and i'm Beginner on that.
i have a Question about Theme Module
i have Some module for my new Theme Located here:
prestashop/theme/mytheme/Module
and i want customize that for my new theme.
but the prestashop not using My Module instead using default module Located here:
Prestashop/Module/
What's Wrong and how to Fix this?
From the PrestaShop documentation:
Overriding a module's behavior
The modules are usually in the following format:
/modules/my_module/my_module.tpl
/modules/my_module/my_module.css
/modules/my_module/my_module.js
Since PrestaShop 1.5, they can and should also be in the following format:
/modules/my_module/views/templates/front/my_module.tpl
/modules/my_module/views/templates/front/my_module.css
/modules/my_module/views/templates/front/my_module.js
PrestaShop allows you to override or replace certain front-office module files
with new ones within the same theme. The override is governed by the
theme: once it contains a /modules folder (or more!), PrestaShop will
browse its content for files which have the same name and path as
those of existing modules, and replace these with the new ones.
This means, for PrestaShop 1.4-compatible modules:
/themes/my_theme/modules/my_module/my_module.tpl
/themes/my_theme/css/modules/my_module/my_module.css
/themes/my_theme/js/modules/my_module/my_module.js
Since PrestaShop 1.5, the path is slightly longer
/themes/my_theme/modules/my_module/views/templates/front/my_module.tpl
/themes/my_theme/css/modules/my_module/views/templates/front/my_module.css
/themes/my_theme/js/modules/my_module/views/templates/front/my_module.js
In general, the proper path to override a .tpl, .js or .css file
depends on the module's own path. That is the reason why if PrestaShop
1.5 has to work with a module without a view folder, it will need the same override path.
In short, you can keep overriding code in 1.5 just
as you did in 1.4.
The new files will be used when the customer loads
your shop.
Contrary to the override code that is to be placed manually
in the /override folder, module overrides are enabled as soon as the
module is installed. During installation, overriding code is merge
with those already in place (if any), otherwise they are copied to the
/override folder at the root of the PrestaShop folder.

Cannot find/open Bing Maps module Orchard

When installing the "Bing Maps" module into Orchard 1.6 (source version) the module does not show up under modules in solution explorer.
Other modules are simply found in the root under Modules but for some reason this module is not.
It is located on the following location: C:\Orchard\src\Orchard.Web\Modules\Bing.Maps
How come its located here and not showing up in the Solution Explorer (The Orchard.web does not show modules in solution explorer)?
For installation i just went to admin dashboard --> gallery and install.
I need to edit this module because its having troubles with my regional settings, but i do not like editing files i cannot open in solution explorer (when opening through file/open file many lines are marked in red).
Thanks.
Modules are always physically located on the filesystem under the path e.g. C:\Orchard\src\Orchard.Web\Modules\SomeModule When you install a module, the files are copied to this folder.
The root Modules folder that you refer to is a solution folder used in visual studio to organise projects within the solution explorer. Projects can be moved to these virtual folders without affecting their location on the file system. To add your new module to this folder in Visual Studio solution explorer, right click the Modules solution folder and select Add => Existing project and select the project file for your new module.

File not found error in xcode

I have imported the folder containing SUPQueueConnection.h to the project and to the project root too. Still it is showing the same error SUPQueueConnection.h file not found.
And we imported all such needed .h and .m files to the project root.
Is there any other way for doing it?
Can anyone please help me in solving this problem?
In project navigation bar of your project check the folder you imported that it actually contains SUPQueueConnection.h file or not and if it is there try to import header file in the class in which you are using "SUPQueueConnection.h" file.Also if project is showing SUPQueueConnection.h file then right click on this file and click "Show IN Finder" option to see where actually the file is.Make sure it is copied in project folder.
If it does not solve the problem try deleting this file and drag and drop SUPQueueConnection.h again in project directly and make sure while copying on target your project is check marked.
Have you made sure that the files that aren't found are actually in your Xcode project? Make sure you can see the files somewhere in the sidebar. I've never actually tried it, but I don't think you can simply access files in the project directory root, they must be in your project. Xcode has changed since I used it last (been doing other things) but I think you can still add files by right clicking somewhere in your sidebar, also unless its changed you can add external files using a button in the file menu

How to add non-source folders to IntelliJ IDEA project

Recently set up a multi module project in IntelliJ with the following structure:
/module1
/module2
/web-module
/sql
/lib
/a few more folders
I set up module1+2 and web-module as modules in IntelliJ so those show up, but how do you make the sql and lib folder show up in the project panel? They should be included in VCS as well, but IntelliJ ignores them. How do you add folders outside modules to a project?
Screenshot of project and explorer view:
This is not a strict answer to the question, but it worked for me so I'm posting, perhaps someone will find this useful.
If you want to add an arbitrary folder to your project (even from some different location than your projects), just add it as a module. You needn't worry about the type so much e.g. I needed to add a folder with some SQL scripts, I added it as a Java module and it's nicely visible in IntelliJ even though it has no maven structure or Java sources.
This is how to do it:
File > Project Structure > Modules
Add > New Module > ... (e.g. Java Module)
In the new module settings mark the subfolders that you want to see as 'Sources'
VoilĂ ! :)
This is something that I typically see when creating a project from existing modules. All the modules will show in the project but not the other project related directories. These directories might be, configuration files, environment scripts or bundles of SQL scripts that don't fit neatly into an Intellij module type.
To show the rest of the project source files and directories, I create a parent module from the project root.
File->Project Structure->Modules
Create a new module using the + sign. The new module could be any type (I use java).
On the Next screen set the Content root and Module file location to the Project's root folder.
Select Finish
All of your other modules should now be submodules of the root, and your other project files should now show up.
Add and remove content roots
To add a new content root:
Go to File | Project Structure, or press Ctrl+Shift+Alt+S.
Select Modules under the Project Settings section.
Select the necessary module, and then open the Sources tab in the right-hand part of the dialog.
Click Add Content Root.
Specify the folder that you want to add as a new content root, and click OK.
source: https://www.jetbrains.com/help/idea/creating-and-managing-modules.html
I used File -> New -> Module from Existing Sources...
Then I simply select the folder and add it.
In Project view mode all directories (except the ignored ones from the settings) should show up. Of course the base folder for your multi-project has to be the folder above module1.
EDIT:
Your project should look like this (project view tree):
MY_PROJECT_ROOT (~/the/folder/to/your/project)
|- /module1
|- /module2
|- /web-module
And in this case, you should definitely see the other folders. I got a sample project set up where this is working.
EDIT 2:
From your screenshot, I assume you are missing the root directory (the project root is not as you expected). I added another screenshot. There should be a single root folder for your 3 modules. This one is missing at your screenshot. You have 3 separate folders with no common root folder. On MacOs, the project root is displayed in the window title. In my case it points to ~/devel/sandbox.
I guess you should try to create a new project in for that trunk folder. From the scratch. Then add the existing modules and you should be fine?!