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
85ce1f04
Commit
85ce1f04
authored
15 years ago
by
Laurent Destailleur
Browse files
Options
Downloads
Patches
Plain Diff
Fix: Postgresql compatibility
parent
a9f31603
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/compta/index.php
+7
-7
7 additions, 7 deletions
htdocs/compta/index.php
with
7 additions
and
7 deletions
htdocs/compta/index.php
+
7
−
7
View file @
85ce1f04
...
...
@@ -527,14 +527,14 @@ if ($conf->fournisseur->enabled && $user->rights->societe->lire)
{
$langs
->
load
(
"boxes"
);
$sql
=
"SELECT s.nom, s.rowid,
"
.
$db
->
pdate
(
"
s.datec
"
)
.
"
as dc"
;
$sql
=
"SELECT s.nom, s.rowid, s.datec as dc"
;
$sql
.
=
" FROM "
.
MAIN_DB_PREFIX
.
"societe as s"
;
if
(
!
$user
->
rights
->
societe
->
client
->
voir
&&
!
$user
->
societe_id
)
$sql
.
=
", "
.
MAIN_DB_PREFIX
.
"societe_commerciaux as sc"
;
$sql
.
=
" WHERE s.fournisseur = 1"
;
$sql
.
=
" AND s.entity = "
.
$conf
->
entity
;
if
(
!
$user
->
rights
->
societe
->
client
->
voir
&&
!
$user
->
societe_id
)
$sql
.
=
" AND s.rowid = sc.fk_soc AND sc.fk_user = "
.
$user
->
id
;
if
(
$socid
)
$sql
.
=
" AND s.rowid = "
.
$socid
;
$sql
.
=
" ORDER BY
s.datec
DESC"
;
$sql
.
=
$db
->
order
(
"
s.datec
"
,
"
DESC"
)
;
$sql
.
=
$db
->
plimit
(
$max
,
0
);
$result
=
$db
->
query
(
$sql
);
...
...
@@ -561,7 +561,7 @@ if ($conf->fournisseur->enabled && $user->rights->societe->lire)
$customerstatic
->
nom
=
$objp
->
nom
;
print
'<tr '
.
$bc
[
$var
]
.
'>'
;
print
'<td>'
.
$customerstatic
->
getNomUrl
(
1
)
.
'</td>'
;
print
'<td align="right">'
.
dol_print_date
(
$objp
->
dc
,
'day'
)
.
'</td>'
;
print
'<td align="right">'
.
dol_print_date
(
$
db
->
jdate
(
$
objp
->
dc
)
,
'day'
)
.
'</td>'
;
print
'</tr>'
;
$var
=!
$var
;
$i
++
;
...
...
@@ -589,8 +589,8 @@ if ($conf->tax->enabled && $user->rights->tax->charges->lire)
$sql
=
"SELECT c.rowid, c.amount, c.date_ech, c.paye,"
;
$sql
.
=
" cc.libelle,"
;
$sql
.
=
" SUM(pc.amount) as sumpaid"
;
$sql
.
=
" FROM ("
.
MAIN_DB_PREFIX
.
"chargesociales as c, "
.
MAIN_DB_PREFIX
.
"
c_
chargesociales as
c
c)"
;
$sql
.
=
" LEFT JOIN "
.
MAIN_DB_PREFIX
.
"paiementcharge as pc ON
c.rowid =
pc.fk_charge"
;
$sql
.
=
" FROM ("
.
MAIN_DB_PREFIX
.
"
c_
chargesociales as
c
c, "
.
MAIN_DB_PREFIX
.
"chargesociales as c)"
;
$sql
.
=
" LEFT JOIN "
.
MAIN_DB_PREFIX
.
"paiementcharge as pc ON pc.fk_charge
= c.rowid
"
;
$sql
.
=
" WHERE c.fk_type = cc.id"
;
$sql
.
=
" AND c.entity = "
.
$conf
->
entity
;
$sql
.
=
" AND c.paye = 0"
;
...
...
@@ -751,7 +751,7 @@ if ($conf->facture->enabled && $conf->commande->enabled && $user->rights->comman
}
/*
* Unpaid customers
bill
s
* Unpaid customers
invoice
s
*/
if
(
$conf
->
facture
->
enabled
&&
$user
->
rights
->
facture
->
lire
)
{
...
...
@@ -850,7 +850,7 @@ if ($conf->facture->enabled && $user->rights->facture->lire)
}
/*
*
Factures fournisseurs impaye
es
*
Unpayed supplier invoic
es
*/
if
(
$conf
->
fournisseur
->
enabled
&&
$user
->
rights
->
fournisseur
->
facture
->
lire
)
{
...
...
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