2019-08-03 19:01:22 +02:00
# SendRecurringInvoiceByMail for <a href="https://www.dolibarr.org">DOLIBARR ERP CRM</a>
2018-12-01 22:40:16 +01:00
## Features
2021-02-19 02:48:14 +01:00
2024-03-13 18:49:51 +01:00
(en) This module sends by email the customer invoice generated with a recurring invoice template via scheduled jobs.
2018-12-01 22:40:16 +01:00
2024-03-13 18:49:51 +01:00
(fr) Ce module envoie par mail les factures clientes générées automatiquement par les travaux planifiés et les factures modèles.
2021-02-19 02:48:14 +01:00
2021-03-23 15:27:33 +01:00
You can customize the mail globally or by recurring invoice.
2021-02-20 00:32:15 +01:00
2021-03-23 15:27:33 +01:00
![Screenshot n° 1 ](img/screenshot1.png?raw=true )
2021-02-20 00:32:15 +01:00
2021-03-23 15:27:33 +01:00
To edit the default global mail template, go to Home > Setup > Emails > Email templates, and modify the `SendRecurringInvoiceByMail : original template` . If you don't want to attach the PDF of the invoice to the mails, set the `Attach file` input to 0 (default: 1, PDF attached).
2021-02-20 00:32:15 +01:00
2021-03-23 15:27:33 +01:00
To edit the default sender address, go to Home > Setup > Emails, and edit the `Sender email for automatic emails` field.
2021-02-20 00:32:15 +01:00
2022-01-11 18:11:12 +01:00
This module hooks himself on the end of the `Recurring invoices` job from the Scheduled jobs (aka. `cron` ) module. It will only be triggered via this Scheduled job and will not send mail when manually generating an invoice from a recurring invoice template.
2021-02-20 00:32:15 +01:00
## Requirements
2021-03-23 15:27:33 +01:00
It requires Dolibarr version 10.0 at least (first version with the `cron/afterCreationOfRecurringInvoice()` hook).
2018-12-02 01:30:02 +01:00
2021-03-23 15:27:33 +01:00
Don't forget to also activate the **Scheduled jobs** module.
2018-12-01 22:40:16 +01:00
Other modules are available on < a href = "https://www.dolistore.com" target = "_new" > Dolistore.com< / a > .
2021-03-23 15:27:33 +01:00
## Install
2018-12-01 22:40:16 +01:00
### From the ZIP file and GUI interface
2021-08-10 19:54:05 +02:00
Go to `Home` > `Setup` > `Modules/Applications` and finally the `Deploy/install external app/module` tab
and upload the module_sendrecurringinvoicebymail-x.y.z.zip file (you can get it from the
[original forge ](https://code.bugness.org/Dolibarr/sendrecurringinvoicebymail/releases )
or [Github ](https://github.com/bugness-chl/sendrecurringinvoicebymail/releases )).
2018-12-01 22:40:16 +01:00
2021-08-10 19:54:05 +02:00
Next, on the `Modules/Applications` page, activate the newly available sendrecurringinvoicebymail module,
and probably the Scheduled jobs (alias cron or modCron) integrated module too.
2018-12-01 22:40:16 +01:00
2021-08-10 19:54:05 +02:00
#### Troubleshooting
Note: If the module screen tells you there is no custom directory, check that your setup is correct:
2018-12-01 22:40:16 +01:00
- In your Dolibarr installation directory, edit the ```htdocs/conf/conf.php``` file and check that following lines are not commented:
```php
//$dolibarr_main_url_root_alt ...
//$dolibarr_main_document_root_alt ...
```
- Uncomment them if necessary (delete the leading ```//```) and assign a sensible value according to your Dolibarr installation
For example :
- UNIX:
```php
$dolibarr_main_url_root_alt = '/custom';
$dolibarr_main_document_root_alt = '/var/www/Dolibarr/htdocs/custom';
```
- Windows:
```php
$dolibarr_main_url_root_alt = '/custom';
$dolibarr_main_document_root_alt = 'C:/My Web Sites/Dolibarr/htdocs/custom';
```
### From a GIT repository
2019-08-03 19:01:22 +02:00
- Clone the repository in ```$dolibarr_main_document_root_alt/sendrecurringinvoicebymail```
2018-12-01 22:40:16 +01:00
```sh
cd ....../custom
2021-12-05 18:19:29 +01:00
git clone https://code.bugness.org/Dolibarr/sendrecurringinvoicebymail.git sendrecurringinvoicebymail
2018-12-01 22:40:16 +01:00
```
2021-08-10 19:54:05 +02:00
Then, from your browser:
2018-12-01 22:40:16 +01:00
- Log into Dolibarr as a super-administrator
- Go to "Setup" -> "Modules"
- You should now be able to find and enable the module
2021-03-23 15:27:33 +01:00
## Updating instructions
2018-12-01 22:40:16 +01:00
2021-03-23 15:27:33 +01:00
* Disable the module,
* Update the files (see Install),
* Re-enable the module.
2018-12-01 22:40:16 +01:00
2021-03-23 15:27:33 +01:00
## Licenses
2018-12-01 22:40:16 +01:00
### Main code
![GPLv3 logo ](img/gplv3.png )
GPLv3 or (at your option) any later version.
See file COPYING for more information.
2021-08-10 19:54:05 +02:00
### Documentation
2018-12-01 22:40:16 +01:00
All texts and readmes.
![GFDL logo ](img/gfdl.png )