Skip to content
Snippets Groups Projects
Commit e6da7c55 authored by aspangaro's avatar aspangaro
Browse files

Fix: Accountancy - Problem with empty accountancy acccount in create / modify mode

parent 4d862915
No related branches found
No related tags found
No related merge requests found
......@@ -89,7 +89,8 @@ if ($_POST["action"] == 'add')
$account->proprio = trim($_POST["proprio"]);
$account->owner_address = trim($_POST["owner_address"]);
$account->account_number = GETPOST('account_number');
$account_number = GETPOST('account_number','int');
if ($account_number <= 0) { $account->account_number = ''; } else { $account->account_number = $account_number; }
$account->accountancy_journal = trim($_POST["accountancy_journal"]);
$account->solde = $_POST["solde"];
......@@ -171,7 +172,8 @@ if ($_POST["action"] == 'update' && ! $_POST["cancel"])
$account->proprio = trim($_POST["proprio"]);
$account->owner_address = trim($_POST["owner_address"]);
$account->account_number = GETPOST('account_number');
$account_number = GETPOST('account_number', 'int');
if ($account_number <= 0) { $account->account_number = ''; } else { $account->account_number = $account_number; }
$account->accountancy_journal = trim($_POST["accountancy_journal"]);
$account->currency_code = trim($_POST["account_currency_code"]);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment