forked from emaijala/MLInvoice
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinvoice_printer_email.php
More file actions
35 lines (28 loc) · 1.09 KB
/
invoice_printer_email.php
File metadata and controls
35 lines (28 loc) · 1.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php
/*******************************************************************************
MLInvoice: web-based invoicing application.
Copyright (C) 2010-2016 Ere Maijala
This program is free software. See attached LICENSE.
*******************************************************************************/
/*******************************************************************************
MLInvoice: web-pohjainen laskutusohjelma.
Copyright (C) 2010-2016 Ere Maijala
Tämä ohjelma on vapaa. Lue oheinen LICENSE.
*******************************************************************************/
require_once 'invoice_printer_base.php';
require_once 'invoice_printer_email_trait.php';
class InvoicePrinterEmail extends InvoicePrinterBase
{
use InvoicePrinterEmailTrait;
protected function emailPostProcess($success)
{
if ($success && $this->invoiceData['state_id'] == 1) {
// Mark invoice sent
mysqli_param_query('UPDATE {prefix}invoice SET state_id=2 WHERE id=?',
[
$this->invoiceId
]
);
}
}
}