Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dolibarr
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Software_Artifact_Infrastructure_Repository
dolibarr
Commits
d8001a8e
Commit
d8001a8e
authored
9 years ago
by
Laurent Destailleur
Browse files
Options
Downloads
Plain Diff
Merge pull request #4379 from aspangaro/3.9-p3
Fix: SQL error on user bank tab
parents
ffe80a36
87f1e55b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
htdocs/user/class/userbankaccount.class.php
+3
-4
3 additions, 4 deletions
htdocs/user/class/userbankaccount.class.php
with
3 additions
and
4 deletions
htdocs/user/class/userbankaccount.class.php
+
3
−
4
View file @
d8001a8e
...
...
@@ -133,15 +133,14 @@ class UserBankAccount extends Account
* Load record from database
*
* @param int $id Id of record
* @param int $socid Id of company. If this is filled, function will return the default RIB of company
* @return int <0 if KO, >0 if OK
*/
function
fetch
(
$id
,
$socid
=
0
)
function
fetch
(
$id
)
{
if
(
empty
(
$id
)
&&
empty
(
$socid
)
)
return
-
1
;
if
(
empty
(
$id
))
return
-
1
;
$sql
=
"SELECT rowid, fk_user, entity, bank, number, code_banque, code_guichet, cle_rib, bic, iban_prefix as iban, domiciliation, proprio,"
;
$sql
.
=
" owner_address,
default_rib,
label, datec, tms as datem"
;
$sql
.
=
" owner_address, label, datec, tms as datem"
;
$sql
.
=
" FROM "
.
MAIN_DB_PREFIX
.
"user_rib"
;
if
(
$id
)
$sql
.
=
" WHERE rowid = "
.
$id
;
if
(
$socid
)
$sql
.
=
" WHERE fk_user = "
.
$userid
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment