Fix: PHPCS
This commit is contained in:
parent
9b5a03fa82
commit
df066c3741
@ -104,7 +104,7 @@ script:
|
||||
- phpunit -d memory_limit=-1 --configuration test/phpunit/phpunittest.xml test/phpunit/AllTests.php
|
||||
- date
|
||||
# - phpcs -p --warning-severity=0 -s --report-summary --standard=dev/codesniffer/ruleset.xml --tab-width=4 --ignore=/build/html/,/dev/vagrant/,/documents/,/includes/,/test/report/ htdocs/core/class/dolgraph.class.php 2>&1
|
||||
- phpcs -p --warning-severity=0 -s --report-checkstyle --report-summary --standard=dev/codesniffer/ruleset.xml --tab-width=4 --ignore=/build/html/,/dev/vagrant/,/documents/,/includes/,/test/report/ . 2>&1
|
||||
- phpcs -p --warning-severity=0 -s --report-checkstyle --report-summary --standard=dev/codesniffer/ruleset.xml --tab-width=4 --ignore=/htdocs/conf/conf.php,/build/html/,/dev/vagrant/,/documents/,/includes/,/test/report/ . 2>&1
|
||||
- date
|
||||
|
||||
after_script:
|
||||
|
||||
@ -6,6 +6,7 @@
|
||||
<exclude-pattern>*/conf.php</exclude-pattern>
|
||||
<exclude-pattern>*/includes/*</exclude-pattern>
|
||||
<exclude-pattern>*/documents/*</exclude-pattern>
|
||||
<exclude-pattern>*/dev/vagrant/*</exclude-pattern>
|
||||
<exclude-pattern>*/custom/*</exclude-pattern>
|
||||
<exclude-pattern>*/nltechno*</exclude-pattern>
|
||||
|
||||
@ -260,7 +261,10 @@
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.Indent">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket">
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceBeforeOpenBracket">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceAfterOpenBracket">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.SpaceBeforeCloseBracket">
|
||||
@ -275,7 +279,6 @@
|
||||
<rule ref="PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket">
|
||||
<severity>0</severity>
|
||||
</rule>
|
||||
|
||||
|
||||
<rule ref="PEAR.Functions.ValidDefaultValue" />
|
||||
|
||||
|
||||
@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
// Instanciation et initialisation de l'objet xmlhttprequest
|
||||
function file (fichier) {
|
||||
function file(fichier) {
|
||||
|
||||
// Instanciation de l'objet pour Mozilla, Konqueror, Opera, Safari, etc ...
|
||||
if (window.XMLHttpRequest) {
|
||||
@ -51,7 +51,7 @@ function file (fichier) {
|
||||
|
||||
|
||||
// Affichage des donnees aTexte dans le bloc identifie par aId
|
||||
function afficheDonnees (aId, aTexte) {
|
||||
function afficheDonnees(aId, aTexte) {
|
||||
|
||||
document.getElementById(aId).innerHTML = aTexte;
|
||||
|
||||
@ -59,7 +59,7 @@ function afficheDonnees (aId, aTexte) {
|
||||
|
||||
|
||||
// aCible : id du bloc de destination; aCode : argument a passer a la page php chargee du traitement et de l'affichage
|
||||
function verifResultat (aCible, aCode) {
|
||||
function verifResultat(aCible, aCode) {
|
||||
if (aCode != '') {
|
||||
|
||||
if (texte = file ('facturation_dhtml.php?code='+escape(aCode))) {
|
||||
@ -76,21 +76,9 @@ function verifResultat (aCible, aCode) {
|
||||
|
||||
|
||||
// Change dynamiquement la classe de l'element ayant l'id aIdElement pour aClasse
|
||||
function setStyle (aIdElement, aClasse) {
|
||||
function setStyle(aIdElement, aClasse) {
|
||||
|
||||
aIdElement.className = aClasse;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
// Calcul et affichage en temps reel des informations sur le produit en cours
|
||||
function modif () {
|
||||
function modif() {
|
||||
|
||||
var prix_unit = parseFloat ( document.getElementById('frmQte').txtPrixUnit.value );
|
||||
var qte = parseFloat ( document.getElementById('frmQte').txtQte.value );
|
||||
@ -71,7 +71,7 @@ function modif () {
|
||||
}
|
||||
|
||||
// Affecte la source de la requete (liste deroulante ou champ texte 'ref') au champ cache
|
||||
function setSource (aSrc) {
|
||||
function setSource(aSrc) {
|
||||
|
||||
document.getElementById('frmFacturation').hdnSource.value = aSrc;
|
||||
document.getElementById('frmFacturation').submit();
|
||||
@ -79,7 +79,7 @@ function setSource (aSrc) {
|
||||
}
|
||||
|
||||
// Verification de la coherence des informations saisies dans le formulaire de choix du nombre d'articles
|
||||
function verifSaisie () {
|
||||
function verifSaisie() {
|
||||
|
||||
if ( document.getElementById('frmQte').txtQte.value ) {
|
||||
|
||||
@ -95,17 +95,17 @@ function verifSaisie () {
|
||||
}
|
||||
|
||||
// Verification de la coherence des informations saisies dans le formulaire de calcul de la difference
|
||||
function verifDifference () {
|
||||
function verifDifference() {
|
||||
|
||||
var du = parseFloat ( document.getElementById('frmDifference').txtDu.value );
|
||||
var encaisse = parseFloat ( document.getElementById('frmDifference').txtEncaisse.value );
|
||||
|
||||
if ( encaisse > du ) {
|
||||
if (encaisse > du) {
|
||||
|
||||
resultat = Math.round ( (encaisse - du) * 100 ) / 100;
|
||||
document.getElementById('frmDifference').txtRendu.value = resultat.toFixed(2);
|
||||
|
||||
} else if ( encaisse == du ) {
|
||||
} else if (encaisse == du) {
|
||||
|
||||
document.getElementById('frmDifference').txtRendu.value = '0';
|
||||
|
||||
@ -118,14 +118,14 @@ function verifDifference () {
|
||||
}
|
||||
|
||||
// Affecte le moyen de paiement (ESP, CB ou CHQ) au champ cache en fonction du bouton clique
|
||||
function verifClic (aChoix) {
|
||||
function verifClic(aChoix) {
|
||||
|
||||
document.getElementById('frmDifference').hdnChoix.value = aChoix;
|
||||
|
||||
}
|
||||
|
||||
// Determination du moyen de paiement, et validation du formulaire si les donnees sont coherentes
|
||||
function verifReglement () {
|
||||
function verifReglement() {
|
||||
|
||||
var choix = document.getElementById('frmDifference').hdnChoix.value;
|
||||
var du = parseFloat (document.getElementById('frmDifference').txtDu.value);
|
||||
@ -172,5 +172,4 @@ function verifReglement () {
|
||||
return false;
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -357,7 +357,6 @@ class DoliDBMysqli extends DoliDB
|
||||
* @return int Nombre de lignes
|
||||
* @see num_rows
|
||||
*/
|
||||
|
||||
function affected_rows($resultset)
|
||||
{
|
||||
// If resultset not provided, we take the last used by connexion
|
||||
|
||||
Loading…
Reference in New Issue
Block a user