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
fc01bfe0
Commit
fc01bfe0
authored
17 years ago
by
Laurent Destailleur
Browse files
Options
Downloads
Patches
Plain Diff
Fix: Save of conciliate account option
parent
aeef986c
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
htdocs/compta/bank/account.class.php
+25
-25
25 additions, 25 deletions
htdocs/compta/bank/account.class.php
htdocs/compta/bank/fiche.php
+7
-9
7 additions, 9 deletions
htdocs/compta/bank/fiche.php
with
32 additions
and
34 deletions
htdocs/compta/bank/account.class.php
+
25
−
25
View file @
fc01bfe0
...
...
@@ -103,7 +103,7 @@ class Account extends CommonObject
* \param line_id Id ecriture bancaire
* \param url_id Id parametre url
* \param url Url
* \param label Libell
du lien
* \param label Libell
� d
u lien
* \param type Type de lien (payment, company, member, ...)
* \return int <0 si ko, id line si ok
*/
...
...
@@ -127,7 +127,7 @@ class Account extends CommonObject
/**
* \brief Renvoi tableau des liens
* \param line_id Id ligne
c
riture
* \param line_id Id ligne
�cr
iture
* \retuen array Tableau des liens
*/
function
get_url
(
$line_id
)
...
...
@@ -146,7 +146,7 @@ class Account extends CommonObject
while
(
$i
<
$num
)
{
$obj
=
$this
->
db
->
fetch_object
(
$result
);
// Anciens liens (pour compatibilit
)
// Anciens liens (pour compatibilit
�)
$lines
[
$i
][
0
]
=
$obj
->
url
;
$lines
[
$i
][
1
]
=
$obj
->
url_id
;
$lines
[
$i
][
2
]
=
$obj
->
label
;
...
...
@@ -164,16 +164,16 @@ class Account extends CommonObject
/**
\brief Ajoute une entree dans la table ".MAIN_DB_PREFIX."bank
\param $date Date TMS op
r
ation
\param $date Date TMS op
�ra
tion
\param $oper 1,2,3,4...
\param $label Descripton
\param $amount Montant
\param $num_chq Numero cheque ou virement
\param $categorie Categorie optionnelle
\param $user Utilisateur qui cr
e
\param $user Utilisateur qui cr
�e
\param $emetteur Nom emetteur
\param $banque Banque emettrice
\return int Rowid de l'entr
e
ajoute
,
<0 si erreur
\return int Rowid de l'entr
�e
ajout�e
, <
0 si erreur
*/
function
addline
(
$date
,
$oper
,
$label
,
$amount
,
$num_chq
=
''
,
$categorie
=
''
,
$user
,
$emetteur
=
''
,
$banque
=
''
)
{
...
...
@@ -279,7 +279,7 @@ class Account extends CommonObject
require_once
DOL_DOCUMENT_ROOT
.
'/lib/bank.lib.php'
;
if
(
!
verif_rib
(
$this
->
code_banque
,
$this
->
code_guichet
,
$this
->
number
,
$this
->
cle_rib
,
$this
->
iban_prefix
))
{
$this
->
error
=
"Le contr
l
e de la cl
i
ndique que les informations de votre compte bancaire sont incorrectes."
;
$this
->
error
=
"Le contr
o
le de la cl
e
indique que les informations de votre compte bancaire sont incorrectes."
;
return
0
;
}
...
...
@@ -290,14 +290,14 @@ class Account extends CommonObject
}
$sql
=
"INSERT INTO "
.
MAIN_DB_PREFIX
.
"bank_account ("
;
$sql
.
=
"datec, ref, label, account_number, currency_code,"
;
$sql
.
=
"min_allowed, min_desired,"
;
$sql
.
=
"datec, ref, label, account_number, currency_code,
"
;
$sql
.
=
"
rappro,
min_allowed, min_desired,
"
;
$sql
.
=
"comment"
;
$sql
.
=
") values ("
;
$sql
.
=
"now(),'"
.
addslashes
(
$this
->
ref
)
.
"', '"
.
addslashes
(
$this
->
label
)
.
"',"
;
$sql
.
=
"'"
.
addslashes
(
$this
->
account_number
)
.
"','"
.
$this
->
currency_code
.
"',"
;
$sql
.
=
"min_allowed=
"
.
price2num
(
$this
->
min_allowed
)
.
",
min_desired=
"
.
price2num
(
$this
->
min_desired
)
.
","
;
$sql
.
=
"
comment=
'"
.
addslashes
(
$this
->
comment
)
.
"'"
;
$sql
.
=
"now(),'"
.
addslashes
(
$this
->
ref
)
.
"', '"
.
addslashes
(
$this
->
label
)
.
"',
"
;
$sql
.
=
"'"
.
addslashes
(
$this
->
account_number
)
.
"',
'"
.
$this
->
currency_code
.
"',
"
;
$sql
.
=
$this
->
rappro
.
",
"
.
price2num
(
$this
->
min_allowed
)
.
",
"
.
price2num
(
$this
->
min_desired
)
.
",
"
;
$sql
.
=
"'"
.
addslashes
(
$this
->
comment
)
.
"'"
;
$sql
.
=
")"
;
dolibarr_syslog
(
"Account::create sql="
.
$sql
);
...
...
@@ -400,7 +400,7 @@ class Account extends CommonObject
// Verification parametres
if
(
!
verif_rib
(
$this
->
code_banque
,
$this
->
code_guichet
,
$this
->
number
,
$this
->
cle_rib
,
$this
->
iban_prefix
))
{
$this
->
error
=
"Le contr
l
e de la cl
i
ndique que les informations de votre compte bancaire sont incorrectes."
;
$this
->
error
=
"Le contr
�le
de la cl�
ind
ique que les informations de votre compte bancaire sont incorrectes."
;
return
0
;
}
...
...
@@ -441,8 +441,8 @@ class Account extends CommonObject
/*
* \brief Charge un compte en memoire depuis la base
* \param id Id du compte
rcuprer
* \param ref Ref du compte
rcuprer
* \param id Id du compte
� r�cup�rer
* \param ref Ref du compte
� r�cup�rer
*/
function
fetch
(
$id
,
$ref
=
''
)
{
...
...
@@ -527,8 +527,8 @@ class Account extends CommonObject
/**
* \brief Retourne le libell
du statut d'une facture (brouillon, valide
,
abandonne,
paye)
* \param mode 0=libell
long, 1=libell
c
ourt, 2=Picto + Libell c
o
urt, 3=Picto, 4=Picto + Libell lo
n
g
* \param mode 0=libell
� l
ong, 1=libell�
cou
rt, 2=Picto + Libell� co
urt
, 3=Picto, 4=Picto + Libell� long
* \return string Libelle
*/
function
getLibStatut
(
$mode
=
0
)
...
...
@@ -537,10 +537,10 @@ class Account extends CommonObject
}
/**
* \brief Renvoi le libell
d'un statut donn
* \brief Renvoi le libell
� d
'un statut donn�
* \param statut Id statut
* \param mode 0=libell
long, 1=libell
c
ourt, 2=Picto + Libell c
o
urt, 3=Picto, 4=Picto + Libell lo
n
g, 5=Libell cou
r
t + Picto
* \return string Libell
du statut
* \param mode 0=libell
� l
ong, 1=libell�
cou
rt, 2=Picto + Libell� co
urt
, 3=Picto, 4=Picto + Libell� long
, 5
=Libell� court
+ P
icto
* \return string Libell
� d
u statut
*/
function
LibStatut
(
$statut
,
$mode
=
0
)
{
...
...
@@ -582,7 +582,7 @@ class Account extends CommonObject
/*
* \brief Renvoi si un compte peut etre supprimer ou non (sans mouvements)
* \return boolean vrai si peut etre supprim
,
faux sinon
* \return boolean vrai si peut etre supprim
�,
faux sinon
*/
function
can_be_deleted
()
{
...
...
@@ -779,7 +779,7 @@ class AccountLine
/**
* \brief Charge en memoire depuis la base, une ecriture sur le compte
* \param id Id de la ligne
c
riture
rcuprer
* \param id Id de la ligne
�cr
iture �
r�cup�rer
* \return int <0 if KO, >0 if OK
*/
function
fetch
(
$rowid
)
...
...
@@ -839,7 +839,7 @@ class AccountLine
if
(
$this
->
rappro
)
{
// Protection pour eviter tout suppression d'une ligne consolid
e
// Protection pour eviter tout suppression d'une ligne consolid
�e
$this
->
error
=
"DeleteNotPossibleLineIsConsolidated"
;
return
-
1
;
}
...
...
@@ -940,7 +940,7 @@ class AccountLine
}
$this
->
date_creation
=
$obj
->
datec
;
//$this->date_rappro = $obj->daterappro; // \todo pas encore g
re
//$this->date_rappro = $obj->daterappro; // \todo pas encore g
�r�e
}
$this
->
db
->
free
(
$result
);
}
...
...
This diff is collapsed.
Click to expand it.
htdocs/compta/bank/fiche.php
+
7
−
9
View file @
fc01bfe0
...
...
@@ -16,15 +16,13 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
* $Id$
*/
/**
\file htdocs/compta/bank/fiche.php
\ingroup banque
\brief Fiche cration compte bancaire
\version $
Revision
$
\brief Fiche cr
e
ation compte bancaire
\version $
Id
$
*/
require
(
"./pre.inc.php"
);
...
...
@@ -48,7 +46,7 @@ if ($_POST["action"] == 'add')
$account
->
label
=
trim
(
$_POST
[
"label"
]);
$account
->
courant
=
$_POST
[
"type"
];
$account
->
clos
=
$_POST
[
"clos"
];
$account
->
rappro
=
$_POST
[
"norappro"
]
?
1
:
0
;
$account
->
rappro
=
(
isset
(
$_POST
[
"norappro"
]
)
&&
$_POST
[
"norappro"
])
?
0
:
1
;
$account
->
url
=
$_POST
[
"url"
];
$account
->
account_number
=
trim
(
$_POST
[
"account_number"
]);
...
...
@@ -90,7 +88,7 @@ if ($_POST["action"] == 'update' && ! $_POST["cancel"])
$account
->
label
=
trim
(
$_POST
[
"label"
]);
$account
->
courant
=
$_POST
[
"type"
];
$account
->
clos
=
$_POST
[
"clos"
];
$account
->
rappro
=
(
isset
(
$_POST
[
"norappro"
])
&&
$_POST
[
"norappro"
]
==
'on'
)
?
0
:
1
;
$account
->
rappro
=
(
isset
(
$_POST
[
"norappro"
])
&&
$_POST
[
"norappro"
])
?
0
:
1
;
$account
->
url
=
trim
(
$_POST
[
"url"
]);
$account
->
bank
=
trim
(
$_POST
[
"bank"
]);
...
...
@@ -150,7 +148,7 @@ $form = new Form($db);
/* ************************************************************************** */
/* */
/* Affichage page en mode cration */
/* Affichage page en mode cr
�
ation */
/* */
/* ************************************************************************** */
...
...
@@ -217,7 +215,7 @@ if ($_GET["action"] == 'create')
// Comment
print
'<tr><td valign="top">'
.
$langs
->
trans
(
"Comment"
)
.
'</td>'
;
print
'<td colspan="3">'
;
// diteur wysiwyg
//
�
diteur wysiwyg
if
(
$conf
->
fckeditor
->
enabled
&&
$conf
->
global
->
FCKEDITOR_ENABLE_MAILING
)
{
require_once
(
DOL_DOCUMENT_ROOT
.
"/lib/doleditor.class.php"
);
...
...
@@ -456,7 +454,7 @@ else
// Comment
print
'<tr><td valign="top">'
.
$langs
->
trans
(
"Comment"
)
.
'</td>'
;
print
'<td colspan="3">'
;
// diteur wysiwyg
//
�
diteur wysiwyg
if
(
$conf
->
fckeditor
->
enabled
&&
$conf
->
global
->
FCKEDITOR_ENABLE_MAILING
)
{
require_once
(
DOL_DOCUMENT_ROOT
.
"/lib/doleditor.class.php"
);
...
...
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