trying to create a simple module for customer form

hi, im trying to create a simple form for customer to checkin while he visits the store.
trying to see if i can build a module which displays basic form data for customer to fill in
1)customer name
5)referall details etc?

can someone help me understand where to start to create a module (form) to collect the details and how to make the data available for later ERP actions like creating a ticket / orders for the same customer.?
any quick help would be much appreciated or advice details on where / how to start this .

Pièces jointes :


for such simple usage check the module builder,

for more complexe module I’d rather build the pages from database
and take only the folder structure from the module builder


Hello delcroip,

I’m new in Dolibarr and I find your module very interessing.

What’s the best pratice to use it?

Hi delcroip,

I’d like to use your code, but I’m lost.

Where can I find the best way to use it?

Thank’s for your good job.


First create the database table with any sql tool or simply by creating the sql file in the sql folder of the module and then activate the module it will run the sql file therefore create your new tables
then copy the “create fromtable” in the dev folder of dolibarr and execute the php from command with the table name as param.

finally change the php file generated :
- mymodule should be replace with your module name
- remove the out. prefix
- copy the files in your module folder (including the libs and ajax handler files)
- correct the error fo the generqted file (it will have some

I still need to improve the script to create the test class and to create business/visualation classes to have a cleaner code but current output helped me a lot

1 Like