Hi Exsonqu_Qu,
Quote:I'm wondering if this check is too strict?
yes, I agree this seems too strict for me too. But changing this needs huge effort because inside the code sometimes you are:
1. retrieving the customer and the branch from the DB
2. concatenating them using "-" as separator.
3. in another place in the code you explode them again using the separator which is "-".
This makes the branch name to be the same as the customer name.
This happens in
Contracts.php
Concatenating in line 668:
PHP Code:
$SelectedCustomer = $myrow['debtorno'] . '-' . $myrow['branchcode'];
exploding in line 695:
PHP Code:
$CustomerBranchArray = explode('-',$SelectedCustomer);
$_SESSION['Contract'.$identifier]->DebtorNo = trim($CustomerBranchArray[0]);
$_SESSION['Contract'.$identifier]->BranchCode = trim($CustomerBranchArray[1]);
And I do not know if this occurs elsewhere. This is why avoiding the "-" in branch name is the easiest way.
Best regards,
Ahmed