FacturX : PEPPOL ID not needed
This commit is contained in:
parent
4dacf83fb7
commit
a5d7ef6824
2 changed files with 23 additions and 4 deletions
|
|
@ -91,7 +91,6 @@ class FacturX extends XMLInvoice
|
|||
,ATTR_DEF_CITY=>'city'
|
||||
,ATTR_DEF_COUNTRY_CODE=>'country'
|
||||
,ATTR_DEF_NUMTVA=>'customer_vat_id'
|
||||
,ATTR_DEF_PEPPOLID=>'endpoint_id'
|
||||
];
|
||||
|
||||
foreach ($a_needed as $item=>$value) {
|
||||
|
|
@ -244,6 +243,25 @@ class FacturX extends XMLInvoice
|
|||
return $invoice->downloadString();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @brief check that all the data are correct
|
||||
* @returns empty arry : no errors, array with error code
|
||||
* @see get_message_error
|
||||
*/
|
||||
public function verify()
|
||||
{
|
||||
// verify all VAT
|
||||
///@var $a_error : array of error_code see check_company_error
|
||||
$a_error = array();
|
||||
$a_error['general'] = [];
|
||||
$a_error['operation']=[];
|
||||
|
||||
// verify that all needed data in PARAMETER are valid
|
||||
$a_error['company'] = $this->check_company_data();
|
||||
$a_error['customer'] = $this->check_customer_data();
|
||||
|
||||
return $a_error;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
@ -50,8 +50,9 @@ if ( isset($_REQUEST['p_jrn']) &&
|
|||
NoAccess();
|
||||
exit -1;
|
||||
}
|
||||
|
||||
//------------------------------------------------
|
||||
/* if a new invoice is encoded, we display a form for confirmation */
|
||||
//------------------------------------------------
|
||||
if ( isset ($_POST['view_invoice'] ) )
|
||||
{
|
||||
$p_jrn=$http->post("p_jrn","number");
|
||||
|
|
@ -115,10 +116,10 @@ if ( isset ($_POST['view_invoice'] ) )
|
|||
return;
|
||||
}
|
||||
}
|
||||
|
||||
//------------------------------
|
||||
/* Record the invoice */
|
||||
//------------------------------
|
||||
|
||||
if ( isset($_POST['record']) )
|
||||
{
|
||||
// Check privilege
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue