diff --git a/htdocs/compta/facture/class/facture.class.php b/htdocs/compta/facture/class/facture.class.php index 85874a9c2a0..f3c8c4af323 100644 --- a/htdocs/compta/facture/class/facture.class.php +++ b/htdocs/compta/facture/class/facture.class.php @@ -129,10 +129,10 @@ class Facture extends CommonObject * Create invoice in database * Note: this->ref can be set or empty. If empty, we will use "(PROV)" * - * @param user Object user that create - * @param notrigger 1=Does not execute triggers, 0 otherwise - * @param forceduedate 1=Do not recalculate due date from payment condition but force it with value - * @return int <0 if KO, >0 if OK + * @param User $user Object user that create + * @param int $notrigger 1=Does not execute triggers, 0 otherwise + * @param int $forceduedate 1=Do not recalculate due date from payment condition but force it with value + * @return int <0 if KO, >0 if OK */ function create($user,$notrigger=0,$forceduedate=0) { @@ -1491,14 +1491,14 @@ class Facture extends CommonObject // Protection if (! $this->brouillon) { - dol_syslog("Facture::validate no draft status", LOG_WARNING); + dol_syslog(get_class($this)."::validate no draft status", LOG_WARNING); return 0; } if (! $user->rights->facture->valider) { $this->error='Permission denied'; - dol_syslog("Facture::validate ".$this->error, LOG_ERR); + dol_syslog(get_class($this)."::validate ".$this->error, LOG_ERR); return -1; } @@ -1581,11 +1581,11 @@ class Facture extends CommonObject } $sql.= ' WHERE rowid = '.$this->id; - dol_syslog("Facture::validate sql=".$sql); + dol_syslog(get_class($this)."::validate sql=".$sql); $resql=$this->db->query($sql); if (! $resql) { - dol_syslog("Facture::validate Echec update - 10 - sql=".$sql, LOG_ERR); + dol_syslog(get_class($this)."::validate Echec update - 10 - sql=".$sql, LOG_ERR); dol_print_error($this->db); $error++; } @@ -1637,7 +1637,7 @@ class Facture extends CommonObject $dirdest = $conf->facture->dir_output.'/'.$snumfa; if (file_exists($dirsource)) { - dol_syslog("Facture::validate rename dir ".$dirsource." into ".$dirdest); + dol_syslog(get_class($this)."::validate rename dir ".$dirsource." into ".$dirdest); if (@rename($dirsource, $dirdest)) { @@ -1689,11 +1689,13 @@ class Facture extends CommonObject } /** - * \brief Set draft status - * \param user Object user that modify - * \param int <0 if KO, >0 if OK + * Set draft status + * + * @param User $user Object user that modify + * @param int $idwarehouse Id warehouse to use for stock change + * @return int <0 if KO, >0 if OK */ - function set_draft($user) + function set_draft($user,$idwarehouse=0) { global $conf,$langs; @@ -1701,7 +1703,7 @@ class Facture extends CommonObject if ($this->statut == 0) { - dol_syslog("Facture::set_draft already draft status", LOG_WARNING); + dol_syslog(get_class($this)."::set_draft already draft status", LOG_WARNING); return 0; } @@ -1711,7 +1713,7 @@ class Facture extends CommonObject $sql.= " SET fk_statut = 0"; $sql.= " WHERE rowid = ".$this->id; - dol_syslog("Facture::set_draft sql=".$sql, LOG_DEBUG); + dol_syslog(get_class($this)."::set_draft sql=".$sql, LOG_DEBUG); if ($this->db->query($sql)) { // Si on decremente le produit principal et ses composants a la validation de facture, on réincrement diff --git a/htdocs/core/lib/ajax.lib.php b/htdocs/core/lib/ajax.lib.php index 9b4a18609dd..6549eb9dbbc 100644 --- a/htdocs/core/lib/ajax.lib.php +++ b/htdocs/core/lib/ajax.lib.php @@ -25,6 +25,7 @@ /** * Get value of an HTML field, do Ajax process and show result + * * @param selected Preselecte value * @param htmlname HTML name of input field * @param url Url for request: /chemin/fichier.php diff --git a/htdocs/fourn/class/fournisseur.commande.class.php b/htdocs/fourn/class/fournisseur.commande.class.php index 2666569a2a6..8ead0625328 100644 --- a/htdocs/fourn/class/fournisseur.commande.class.php +++ b/htdocs/fourn/class/fournisseur.commande.class.php @@ -94,9 +94,10 @@ class CommandeFournisseur extends Commande /** * Get object and lines from database - * @param id Id of order to load - * @param ref Ref of object - * @return int >0 if OK, <0 if KO + * + * @param int $id Id of order to load + * @param string $ref Ref of object + * @return int >0 if OK, <0 if KO */ function fetch($id,$ref='') { @@ -267,7 +268,9 @@ class CommandeFournisseur extends Commande /** * Validate an order - * @param user Utilisateur qui valide + * + * @param User $user Utilisateur qui valide + * @return int <0 if KO, >0 if OK */ function valid($user) { @@ -614,16 +617,17 @@ class CommandeFournisseur extends Commande /** * Accept an order * - * @param user Object user - * @return int <0 if KO, >0 if OK + * @param User $user Object user + * @param int $idwarehouse Id of warhouse for stock change + * @return int <0 if KO, >0 if OK */ - function approve($user) + function approve($user, $idwarehouse=0) { global $langs,$conf; $error=0; - dol_syslog("CommandeFournisseur::Approve"); + dol_syslog(get_class($this)."::Approve"); if ($user->rights->fournisseur->commande->approuver) { @@ -634,13 +638,13 @@ class CommandeFournisseur extends Commande if ($this->db->query($sql)) { - $result = 0; $this->log($user, 2, time()); // Statut 2 // If stock is incremented on validate order, we must increment it - if ($result >= 0 && $conf->stock->enabled && $conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER) + if (! $error && $conf->stock->enabled && $conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER) { require_once(DOL_DOCUMENT_ROOT."/product/stock/class/mouvementstock.class.php"); + $langs->load("agenda"); $cpt=count($this->lines); for ($i = 0; $i < $cpt; $i++) @@ -650,14 +654,13 @@ class CommandeFournisseur extends Commande { $mouvP = new MouvementStock($this->db); // We decrement stock of product (and sub-products) - $entrepot_id = "1"; // TODO ajouter possibilite de choisir l'entrepot - $result=$mouvP->reception($user, $this->lines[$i]->fk_product, $entrepot_id, $this->lines[$i]->qty, $this->lines[$i]->subprice, $langs->trans("OrderApprovedInDolibarr",$this->ref)); + $result=$mouvP->reception($user, $this->lines[$i]->fk_product, $idwarehouse, $this->lines[$i]->qty, $this->lines[$i]->subprice, $langs->trans("OrderApprovedInDolibarr",$this->ref)); if ($result < 0) { $error++; } } } } - if ($error == 0) + if (! $error) { // Appel des triggers include_once(DOL_DOCUMENT_ROOT . "/core/class/interfaces.class.php"); @@ -667,7 +670,7 @@ class CommandeFournisseur extends Commande // Fin appel triggers } - if ($error == 0) + if (! $error) { $this->db->commit(); return 1; @@ -1153,7 +1156,8 @@ class CommandeFournisseur extends Commande /** * Delete line - * @param idligne + * + * @param int $idligne Id of line to delete */ function deleteline($idligne) { @@ -1162,7 +1166,7 @@ class CommandeFournisseur extends Commande $sql = "DELETE FROM ".MAIN_DB_PREFIX."commande_fournisseurdet WHERE rowid = ".$idligne; $resql=$this->db->query($sql); - dol_syslog("Fournisseur.commande.class::deleteline sql=".$sql); + dol_syslog(get_class($this)."::deleteline sql=".$sql); if ($resql) { $result=$this->update_price(); @@ -1181,8 +1185,9 @@ class CommandeFournisseur extends Commande } /** - * Delete an order - * @return int <0 if KO, >0 if OK + * Delete an order + * + * @return int <0 if KO, >0 if OK */ function delete() { diff --git a/htdocs/fourn/class/fournisseur.facture.class.php b/htdocs/fourn/class/fournisseur.facture.class.php index 88e7f0a47ce..ed2100a03bd 100644 --- a/htdocs/fourn/class/fournisseur.facture.class.php +++ b/htdocs/fourn/class/fournisseur.facture.class.php @@ -735,11 +735,13 @@ class FactureFournisseur extends Facture /** * Tag invoice as validated + call trigger BILL_VALIDATE - * @param user Object user that validate - * @param force_number Reference to force on invoice - * @return int <0 if KO, =0 if nothing to do, >0 if OK + * + * @param User $user Object user that validate + * @param string $force_number Reference to force on invoice + * @param int $idwarehouse Id of warehouse for stock change + * @return int <0 if KO, =0 if nothing to do, >0 if OK */ - function validate($user, $force_number='') + function validate($user, $force_number='', $idwarehouse=0) { global $conf,$langs; @@ -748,7 +750,7 @@ class FactureFournisseur extends Facture // Protection if ($this->statut > 0) // This is to avoid to validate twice (avoid errors on logs and stock management) { - dol_syslog("FactureFournisseur::validate no draft status", LOG_WARNING); + dol_syslog(get_class($this)."::validate no draft status", LOG_WARNING); return 0; } @@ -779,12 +781,12 @@ class FactureFournisseur extends Facture $sql.= " SET fk_statut = 1, fk_user_valid = ".$user->id; $sql.= " WHERE rowid = ".$this->id; - dol_syslog("FactureFournisseur::validate sql=".$sql); + dol_syslog(get_class($this)."::validate sql=".$sql); $resql = $this->db->query($sql); if ($resql) { // Si on incrémente le produit principal et ses composants à la validation de facture fournisseur - if ($conf->stock->enabled && $conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL) + if (! $error && $conf->stock->enabled && $conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL) { require_once(DOL_DOCUMENT_ROOT."/product/stock/class/mouvementstock.class.php"); $langs->load("agenda"); @@ -796,14 +798,13 @@ class FactureFournisseur extends Facture { $mouvP = new MouvementStock($this->db); // We increase stock for product - $entrepot_id = "1"; // TODO ajouter possibilite de choisir l'entrepot - $result=$mouvP->reception($user, $this->lines[$i]->fk_product, $entrepot_id, $this->lines[$i]->qty, $this->lines[$i]->pu_ht, $langs->trans("InvoiceValidatedInDolibarr",$num)); + $result=$mouvP->reception($user, $this->lines[$i]->fk_product, $idwarehouse, $this->lines[$i]->qty, $this->lines[$i]->pu_ht, $langs->trans("InvoiceValidatedInDolibarr",$num)); if ($result < 0) { $error++; } } } } - if ($error == 0) + if (! $error) { // Appel des triggers include_once(DOL_DOCUMENT_ROOT . "/core/class/interfaces.class.php"); @@ -813,7 +814,7 @@ class FactureFournisseur extends Facture // Fin appel triggers } - if ($error == 0) + if (! $error) { $this->db->commit(); return 1; diff --git a/htdocs/fourn/commande/fiche.php b/htdocs/fourn/commande/fiche.php index 033c988fbc3..43f91978f91 100644 --- a/htdocs/fourn/commande/fiche.php +++ b/htdocs/fourn/commande/fiche.php @@ -274,17 +274,17 @@ if ($action == 'updateligne' && $user->rights->fournisseur->commande->creer && $ $localtax2_tx=get_localtax($_POST['tva_tx'],2,$societe); $result = $object->updateline( - $_POST['elrowid'], - $_POST['eldesc'], - $_POST['pu'], - $_POST['qty'], - $_POST['remise_percent'], - $_POST['tva_tx'], - $localtax1_tx, - $localtax2_tx, - 'HT', - 0, - isset($_POST["type"])?$_POST["type"]:$product->type + $_POST['elrowid'], + $_POST['eldesc'], + $_POST['pu'], + $_POST['qty'], + $_POST['remise_percent'], + $_POST['tva_tx'], + $localtax1_tx, + $localtax2_tx, + 'HT', + 0, + isset($_POST["type"])?$_POST["type"]:$product->type ); if ($result >= 0) @@ -304,13 +304,13 @@ if ($action == 'updateligne' && $user->rights->fournisseur->commande->creer && $ } } -if ($action == 'confirm_deleteproductline' && $confirm == 'yes') +if ($action == 'confirm_deleteproductline' && $confirm == 'yes' && $user->rights->fournisseur->commande->creer) { - if ($user->rights->fournisseur->commande->creer) - { - $object->fetch($id); - $result = $object->deleteline($_GET['lineid']); + $object->fetch($id); + $result = $object->deleteline(GETPOST('lineid')); + if ($result >= 0) + { $outputlangs = $langs; if (! empty($_REQUEST['lang_id'])) { @@ -319,6 +319,17 @@ if ($action == 'confirm_deleteproductline' && $confirm == 'yes') } if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE)) supplier_order_pdf_create($db, $object, $object->modelpdf, $outputlangs, GETPOST('hidedetails'), GETPOST('hidedesc'), GETPOST('hideref')); } + else + { + $error++; + $mesg=$object->error; + } + + if (! $error) + { + Header("Location: fiche.php?id=".$id); + exit; + } } if ($action == 'confirm_valid' && $confirm == 'yes' && $user->rights->fournisseur->commande->valider) @@ -342,8 +353,8 @@ if ($action == 'confirm_valid' && $confirm == 'yes' && $user->rights->fournisseu $mesg=$object->error; } - // If we have permission, we go directly on approved step - if ($user->rights->fournisseur->commande->approuver) + // If we have permission, and if we don't need to provide th idwarehouse, we go directly on approved step + if ($user->rights->fournisseur->commande->approuver && ! (! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER) && $object->hasProductsOrServices(1))) { $action='confirm_approve'; } @@ -351,16 +362,34 @@ if ($action == 'confirm_valid' && $confirm == 'yes' && $user->rights->fournisseu if ($action == 'confirm_approve' && $confirm == 'yes' && $user->rights->fournisseur->commande->approuver) { + $idwarehouse=GETPOST('idwarehouse'); + $object->fetch($id); - $result = $object->approve($user); - if ($result > 0) + $object->fetch_thirdparty(); + + // Check parameters + if (! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER) && $object->hasProductsOrServices(1)) { - Header("Location: fiche.php?id=".$id); - exit; + if (! $idwarehouse || $idwarehouse == -1) + { + $error++; + $errors[]=$langs->trans('ErrorFieldRequired',$langs->transnoentitiesnoconv("Warehouse")); + $action=''; + } } - else + + if (! $error) { - $mesg=$object->error; + $result = $object->approve($user, $idwarehouse); + if ($result > 0) + { + Header("Location: fiche.php?id=".$id); + exit; + } + else + { + $mesg=$object->error; + } } } @@ -832,7 +861,20 @@ if ($id > 0 || ! empty($ref)) */ if ($action == 'approve') { - $ret=$form->form_confirm("fiche.php?id=$object->id",$langs->trans("ApproveThisOrder"),$langs->trans("ConfirmApproveThisOrder",$object->ref),"confirm_approve", '', 1, 1); + $formquestion=array(); + if (! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER) && $object->hasProductsOrServices(1)) + { + $langs->load("stocks"); + require_once(DOL_DOCUMENT_ROOT."/product/class/html.formproduct.class.php"); + $formproduct=new FormProduct($db); + $formquestion=array( + //'text' => $langs->trans("ConfirmClone"), + //array('type' => 'checkbox', 'name' => 'clone_content', 'label' => $langs->trans("CloneMainAttributes"), 'value' => 1), + //array('type' => 'checkbox', 'name' => 'update_prices', 'label' => $langs->trans("PuttingPricesUpToDate"), 'value' => 1), + array('type' => 'other', 'name' => 'idwarehouse', 'label' => $langs->trans("SelectWarehouseForStockDecrease"), 'value' => $formproduct->selectWarehouses(GETPOST('idwarehouse'),'idwarehouse','',1))); + } + + $ret=$form->form_confirm("fiche.php?id=".$object->id,$langs->trans("ApproveThisOrder"),$langs->trans("ConfirmApproveThisOrder",$object->ref),"confirm_approve", $formquestion, 1, 1, 240); if ($ret == 'html') print '
'; } /* @@ -1023,10 +1065,10 @@ if ($id > 0 || ! empty($ref)) print ''.$langs->trans("AmountTTC").''.price($object->total_ttc).''; print ''.$langs->trans("Currency".$conf->monnaie).''; - print ""; + print "
"; - if ($mesg) print $mesg; - else print '
'; + dol_htmloutput_mesg($mesg); + dol_htmloutput_errors('',$errors); /* * Lines @@ -1264,6 +1306,7 @@ if ($id > 0 || ! empty($ref)) $var=!$var; print ''; print ''; + $form->select_produits_fournisseurs($object->fourn_id,'','idprodfournprice','',$filtre); if (! $conf->global->PRODUIT_USE_SEARCH_TO_SELECT) print '
'; diff --git a/htdocs/fourn/facture/fiche.php b/htdocs/fourn/facture/fiche.php index 14e0cb18e21..0a147a5c1d9 100644 --- a/htdocs/fourn/facture/fiche.php +++ b/htdocs/fourn/facture/fiche.php @@ -1,30 +1,30 @@ * Copyright (C) 2004-2011 Laurent Destailleur - * Copyright (C) 2004 Christophe Combelles - * Copyright (C) 2005 Marc Barilley / Ocebo - * Copyright (C) 2005-2011 Regis Houssin - * Copyright (C) 2010-2011 Juanjo Menent - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ +* Copyright (C) 2004 Christophe Combelles +* Copyright (C) 2005 Marc Barilley / Ocebo +* Copyright (C) 2005-2011 Regis Houssin +* Copyright (C) 2010-2011 Juanjo Menent +* +* This program is free software; you can redistribute it and/or modify +* it under the terms of the GNU General Public License as published by +* the Free Software Foundation; either version 2 of the License, or +* (at your option) any later version. +* +* This program is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU General Public License for more details. +* +* You should have received a copy of the GNU General Public License +* along with this program. If not, see . +*/ /** * \file htdocs/fourn/facture/fiche.php - * \ingroup facture, fournisseur - * \brief Page for supplier invoice card (view, edit, validate) - */ +* \ingroup facture, fournisseur +* \brief Page for supplier invoice card (view, edit, validate) +*/ require("../../main.inc.php"); require_once(DOL_DOCUMENT_ROOT."/core/class/html.formfile.class.php"); @@ -56,7 +56,7 @@ $object=new FactureFournisseur($db); /* * Actions - */ +*/ // Action clone object if ($action == 'confirm_clone' && $confirm == 'yes') @@ -84,32 +84,48 @@ if ($action == 'confirm_clone' && $confirm == 'yes') if ($action == 'confirm_valid' && $confirm == 'yes' && $user->rights->fournisseur->facture->valider) { - $object->fetch($id); - $result = $object->validate($user); - if ($result < 0) - { - $mesg='
'.$object->error.'
'; - } -} + $idwarehouse=GETPOST('idwarehouse'); -if ($action == 'confirm_delete' && $confirm == 'yes') -{ - if ($user->rights->fournisseur->facture->supprimer ) + $object->fetch($id); + $object->fetch_thirdparty(); + + // Check parameters + if (! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL) && $object->hasProductsOrServices(1)) { - $object->fetch($id); - $result=$object->delete($id); - if ($result > 0) + $langs->load("stocks"); + if (! $idwarehouse || $idwarehouse == -1) { - Header('Location: index.php'); - exit; + $error++; + $errors[]=$langs->trans('ErrorFieldRequired',$langs->transnoentitiesnoconv("Warehouse")); + $action=''; } - else + } + + if (! $error) + { + $result = $object->validate($user,'',$idwarehouse); + if ($result < 0) { $mesg='
'.$object->error.'
'; } } } +if ($action == 'confirm_delete' && $confirm == 'yes' && $user->rights->fournisseur->facture->supprimer) +{ + $object->fetch($id); + $result=$object->delete($id); + if ($result > 0) + { + Header('Location: index.php'); + exit; + } + else + { + $mesg='
'.$object->error.'
'; + } +} + if ($action == 'confirm_deleteproductline' && $confirm == 'yes') { if ($user->rights->fournisseur->facture->creer) @@ -190,7 +206,7 @@ if ($action == 'update' && ! $_POST['cancel']) if (! $error) { - // TODO move to DAO class + // TODO move to DAO class $sql = 'UPDATE '.MAIN_DB_PREFIX.'facture_fourn set '; $sql .= " facnumber='".$db->escape(trim($_POST['facnumber']))."'"; $sql .= ", libelle='".$db->escape(trim($_POST['libelle']))."'"; @@ -203,7 +219,7 @@ if ($action == 'update' && ! $_POST['cancel']) } /* * Action creation - */ +*/ if ($action == 'add' && $user->rights->fournisseur->facture->creer) { $error=0; @@ -245,15 +261,23 @@ if ($action == 'add' && $user->rights->fournisseur->facture->creer) $element = $subelement = $_POST['origin']; /*if (preg_match('/^([^_]+)_([^_]+)/i',$_POST['origin'],$regs)) { - $element = $regs[1]; - $subelement = $regs[2]; - }*/ + $element = $regs[1]; + $subelement = $regs[2]; + }*/ // For compatibility - if ($element == 'order') { $element = $subelement = 'commande'; } - if ($element == 'propal') { $element = 'comm/propal'; $subelement = 'propal'; } - if ($element == 'contract') { $element = $subelement = 'contrat'; } - if ($element == 'order_supplier') { $element = 'fourn'; $subelement = 'fournisseur.commande'; } + if ($element == 'order') { + $element = $subelement = 'commande'; + } + if ($element == 'propal') { + $element = 'comm/propal'; $subelement = 'propal'; + } + if ($element == 'contract') { + $element = $subelement = 'contrat'; + } + if ($element == 'order_supplier') { + $element = 'fourn'; $subelement = 'fournisseur.commande'; + } $object->origin = $_POST['origin']; $object->origin_id = $_POST['originid']; @@ -290,20 +314,20 @@ if ($action == 'add' && $user->rights->fournisseur->facture->creer) if ($lines[$i]->date_end) $date_end=$lines[$i]->date_end; $result = $object->addline( - $desc, - $lines[$i]->subprice, - $lines[$i]->tva_tx, - $lines[$i]->localtax1_tx, - $lines[$i]->localtax2_tx, - $lines[$i]->qty, - $lines[$i]->fk_product, - $lines[$i]->remise_percent, - $date_start, - $date_end, - 0, - $lines[$i]->info_bits, + $desc, + $lines[$i]->subprice, + $lines[$i]->tva_tx, + $lines[$i]->localtax1_tx, + $lines[$i]->localtax2_tx, + $lines[$i]->qty, + $lines[$i]->fk_product, + $lines[$i]->remise_percent, + $date_start, + $date_end, + 0, + $lines[$i]->info_bits, 'HT', - $product_type + $product_type ); if ($result < 0) @@ -618,7 +642,7 @@ if ($action == 'reopen' && $user->rights->fournisseur->facture->creer) /* * Add file in email form - */ +*/ if ($_POST['addfile']) { require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php"); @@ -634,7 +658,7 @@ if ($_POST['addfile']) /* * Remove file in email form - */ +*/ if (! empty($_POST['removedfile'])) { require_once(DOL_DOCUMENT_ROOT."/core/lib/files.lib.php"); @@ -650,7 +674,7 @@ if (! empty($_POST['removedfile'])) /* * Send mail - */ +*/ if ($action == 'send' && ! $_POST['addfile'] && ! $_POST['removedfile'] && ! $_POST['cancel']) { $langs->load('mails'); @@ -747,7 +771,9 @@ if ($action == 'send' && ! $_POST['addfile'] && ! $_POST['removedfile'] && ! $_P include_once(DOL_DOCUMENT_ROOT . "/core/class/interfaces.class.php"); $interface=new Interfaces($db); $result=$interface->run_triggers('BILL_SUPPLIER_SENTBYMAIL',$object,$user,$langs,$conf); - if ($result < 0) { $error++; $this->errors=$interface->errors; } + if ($result < 0) { + $error++; $this->errors=$interface->errors; + } // Fin appel triggers if ($error) @@ -806,7 +832,7 @@ if ($action == 'send' && ! $_POST['addfile'] && ! $_POST['removedfile'] && ! $_P /* * Build document - */ +*/ if ($action == 'builddoc') { @@ -853,7 +879,7 @@ if ($action == 'remove_file') /* * View - */ +*/ $form = new Form($db); $formfile = new FormFile($db); @@ -886,10 +912,19 @@ if ($action == 'create') else if (in_array($element,array('order_supplier'))) { // For compatibility - if ($element == 'order') { $element = $subelement = 'commande'; } - if ($element == 'propal') { $element = 'comm/propal'; $subelement = 'propal'; } - if ($element == 'contract') { $element = $subelement = 'contrat'; } - if ($element == 'order_supplier') { $element = 'fourn'; $subelement = 'fournisseur.commande'; } + if ($element == 'order') { + $element = $subelement = 'commande'; + } + if ($element == 'propal') { + dol_htmloutput_errors('',$errors); + $element = 'comm/propal'; $subelement = 'propal'; + } + if ($element == 'contract') { + $element = $subelement = 'contrat'; + } + if ($element == 'order_supplier') { + $element = 'fourn'; $subelement = 'fournisseur.commande'; + } require_once(DOL_DOCUMENT_ROOT.'/'.$element.'/class/'.$subelement.'.class.php'); $classname = ucfirst($subelement); @@ -964,74 +999,74 @@ if ($action == 'create') /* // Deposit - print ''; - print ''; - print ''; - $desc=$form->textwithpicto($langs->trans("InvoiceDeposit"),$langs->transnoentities("InvoiceDepositDesc"),1); - print $desc; - print ''."\n"; + print ''; + print ''; + print ''; + $desc=$form->textwithpicto($langs->trans("InvoiceDeposit"),$langs->transnoentities("InvoiceDepositDesc"),1); + print $desc; + print ''."\n"; - // Proforma - if ($conf->global->FACTURE_USE_PROFORMAT) - { - print ''; - print ''; - print ''; - $desc=$form->textwithpicto($langs->trans("InvoiceProForma"),$langs->transnoentities("InvoiceProFormaDesc"),1); - print $desc; - print ''."\n"; - } + // Proforma + if ($conf->global->FACTURE_USE_PROFORMAT) + { + print ''; + print ''; + print ''; + $desc=$form->textwithpicto($langs->trans("InvoiceProForma"),$langs->transnoentities("InvoiceProFormaDesc"),1); + print $desc; + print ''."\n"; + } - // Replacement - print ''; - print ''; - print ''; - $text=$langs->trans("InvoiceReplacementAsk").' '; - $text.=''; - $desc=$form->textwithpicto($text,$langs->transnoentities("InvoiceReplacementDesc"),1); - print $desc; - print ''; + // Replacement + print ''; + print ''; + print ''; + $text=$langs->trans("InvoiceReplacementAsk").' '; + $text.=''; + $desc=$form->textwithpicto($text,$langs->transnoentities("InvoiceReplacementDesc"),1); + print $desc; + print ''; - // Credit note - print ''; - print ''; - print ''; - $text=$langs->transnoentities("InvoiceAvoirAsk").' '; - // $text.=''; - $text.=''; - $desc=$form->textwithpicto($text,$langs->transnoentities("InvoiceAvoirDesc"),1); - //.' ('.$langs->trans("FeatureNotYetAvailable").')',$langs->transnoentities("InvoiceAvoirDesc"),1); - print $desc; - print ''."\n"; - */ + // Credit note + print ''; + print ''; + print ''; + $text=$langs->transnoentities("InvoiceAvoirAsk").' '; + // $text.=''; + $text.=''; + $desc=$form->textwithpicto($text,$langs->transnoentities("InvoiceAvoirDesc"),1); + //.' ('.$langs->trans("FeatureNotYetAvailable").')',$langs->transnoentities("InvoiceAvoirDesc"),1); + print $desc; + print ''."\n"; + */ print ''; print ''; @@ -1136,12 +1171,13 @@ else /* * View card - */ + */ $head = facturefourn_prepare_head($object); $titre=$langs->trans('SupplierInvoice'); dol_fiche_head($head, 'card', $titre, 0, 'bill'); dol_htmloutput_mesg($mesg); + dol_htmloutput_errors('',$errors); // Confirmation de la suppression d'une ligne produit if ($action == 'confirm_delete_line') @@ -1166,7 +1202,20 @@ else // Confirmation de la validation if ($action == 'valid') { - $ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('ValidateBill'), $langs->trans('ConfirmValidateBill', $object->ref), 'confirm_valid', '', 0, 1); + $formquestion=array(); + if (! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL) && $object->hasProductsOrServices(1)) + { + $langs->load("stocks"); + require_once(DOL_DOCUMENT_ROOT."/product/class/html.formproduct.class.php"); + $formproduct=new FormProduct($db); + $formquestion=array( + //'text' => $langs->trans("ConfirmClone"), + //array('type' => 'checkbox', 'name' => 'clone_content', 'label' => $langs->trans("CloneMainAttributes"), 'value' => 1), + //array('type' => 'checkbox', 'name' => 'update_prices', 'label' => $langs->trans("PuttingPricesUpToDate"), 'value' => 1), + array('type' => 'other', 'name' => 'idwarehouse', 'label' => $langs->trans("SelectWarehouseForStockDecrease"), 'value' => $formproduct->selectWarehouses(GETPOST('idwarehouse'),'idwarehouse','',1))); + } + + $ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('ValidateBill'), $langs->trans('ConfirmValidateBill', $object->ref), 'confirm_valid', $formquestion, 0, 1); if ($ret == 'html') print '
'; } @@ -1179,7 +1228,7 @@ else /* * Confirmation de la suppression de la facture fournisseur - */ + */ if ($action == 'delete') { $ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('DeleteBill'), $langs->trans('ConfirmDeleteBill'), 'confirm_delete', '', 0, 1); @@ -1189,7 +1238,7 @@ else /* * Facture - */ + */ print ''; // Ref @@ -1255,7 +1304,7 @@ else /* * List of payments - */ + */ $nbrows=7; if ($conf->projet->enabled) $nbrows++; @@ -1267,7 +1316,7 @@ else } print '
'; - + // TODO move to DAO class $sql = 'SELECT datep as dp, pf.amount,'; $sql .= ' c.libelle as paiement_type, p.num_paiement, p.rowid'; @@ -1404,7 +1453,7 @@ else /* * Lines - */ + */ print '
'; print ''; $var=1; @@ -1557,7 +1606,7 @@ else /* * Form to add new line - */ + */ if ($object->statut == 0 && $action != 'mod_ligne') { @@ -1662,7 +1711,7 @@ else /* * Boutons actions - */ + */ print '
'; @@ -1743,7 +1792,7 @@ else /* * Documents generes - */ + */ $ref=dol_sanitizeFileName($object->ref); $subdir = get_exdir($object->id,2).$ref; @@ -1755,8 +1804,6 @@ else print '
'; $somethingshown=$formfile->show_documents('facture_fournisseur',$subdir,$filedir,$urlsource,$genallowed,$delallowed,$object->modelpdf); - $object=$fac; - /* * Linked object block */ @@ -1775,7 +1822,7 @@ else } /* * Show mail form - */ + */ if ($action == 'presend') { $ref = dol_sanitizeFileName($object->ref); diff --git a/htdocs/langs/ca_ES/stocks.lang b/htdocs/langs/ca_ES/stocks.lang index 1c370dc4d61..42be80e3166 100644 --- a/htdocs/langs/ca_ES/stocks.lang +++ b/htdocs/langs/ca_ES/stocks.lang @@ -46,8 +46,8 @@ RuleForStockManagementIncrease=Regla de gestió d'increments d'estoc DeStockOnBill=Decrementar els estocs físics sobre les factures/abonaments a clients DeStockOnValidateOrder=Decrementar els estocs físics sobre les comandes de clients DeStockOnShipment=Decrementar els estocs físics sobre els enviaments -ReStockOnBill=Incrementar els estocs físics sobre les factures/abonaments de proveïdors (atenció, en aquesta versió, encara es fa l'ajustament sobre el magatzem número 1) -ReStockOnValidateOrder=Incrementar els estocs físics sobre les comandes a proveïdors (atenció, en aquesta versió, encara es fa l'ajustament sobre el magatzem número 1) +ReStockOnBill=Incrementar els estocs físics sobre les factures/abonaments de proveïdors +ReStockOnValidateOrder=Incrementar els estocs físics sobre les comandes a proveïdors ReStockOnDispatchOrder=Incrementa els estocs físics en el desglossament manual de la recepció de les comandes a proveïdors en els magatzems OrderStatusNotReadyToDispatch=La comanda encara no està o no té un estat que permeti un desglossament d'estoc. StockDiffPhysicTeoric=Motiu de la diferència entre valors físics i teòrics diff --git a/htdocs/langs/da_DK/stocks.lang b/htdocs/langs/da_DK/stocks.lang index 172f04f9b5e..d823993a7a4 100644 --- a/htdocs/langs/da_DK/stocks.lang +++ b/htdocs/langs/da_DK/stocks.lang @@ -55,8 +55,8 @@ RuleForStockManagementDecrease=Reglen for lagerstyring fald RuleForStockManagementIncrease=Reglen for lagerstyring stigning DeStockOnBill=Fraførsel reelle bestande på fakturaer / kreditnotaer DeStockOnValidateOrder=Fraførsel reelle bestande om ordrer noter -ReStockOnBill=Forhøjelse reelle bestande på fakturaer / kreditnotaer (advarsel, i denne version, er det kun i oplag nummer 1, at bestanden er ændret) -ReStockOnValidateOrder=Forhøjelse reelle bestande om ordrer noter (advarsel, i denne version, er det kun i oplag nummer 1, at bestanden er ændret) +ReStockOnBill=Forhøjelse reelle bestande på fakturaer / kreditnotaer +ReStockOnValidateOrder=Forhøjelse reelle bestande om ordrer noter StockLimitShort=Limit StockLimit=Stock grænse for indberetninger PhysicalStock=Fysiske lager diff --git a/htdocs/langs/de_AT/stocks.lang b/htdocs/langs/de_AT/stocks.lang index 1b2a09992c7..d72b70de79f 100644 --- a/htdocs/langs/de_AT/stocks.lang +++ b/htdocs/langs/de_AT/stocks.lang @@ -52,8 +52,8 @@ RuleForStockManagementIncrease=Regel für Lagerstandsanpassung (Erhöhung) DeStockOnBill=Verringere realen Bestände in den Rechnungen / Gutschriften DeStockOnValidateOrder=Decrease realen Bestände auf Bestellungen stellt fest DeStockOnShipment=Verringere Lagerstände nach erfolgtem Versand (empfohlen) -ReStockOnBill=Erhöhung der tatsächlichen Bestände in den Rechnungen / Gutschriften (Achtung: In dieser Version werden nur die Lagerstände des Lagers 1 aktualisiert) -ReStockOnValidateOrder=Erhöhung der realen Bestände auf Bestellungen stellt fest (Achtung: In dieser Version werden nur die Lagerstände des Lagers 1 aktualisiert) +ReStockOnBill=Erhöhung der tatsächlichen Bestände in den Rechnungen / Gutschriften +ReStockOnValidateOrder=Erhöhung der realen Bestände auf Bestellungen stellt fest StockDiffPhysicTeoric=Grund für die Differenz physisch. und theoret. Lagerbestand StockLimitShort=Mindestbestand StockLimit=Sicherungsbestand für autom. Benachrichtigung diff --git a/htdocs/langs/de_DE/stocks.lang b/htdocs/langs/de_DE/stocks.lang index 1b2a09992c7..d72b70de79f 100644 --- a/htdocs/langs/de_DE/stocks.lang +++ b/htdocs/langs/de_DE/stocks.lang @@ -52,8 +52,8 @@ RuleForStockManagementIncrease=Regel für Lagerstandsanpassung (Erhöhung) DeStockOnBill=Verringere realen Bestände in den Rechnungen / Gutschriften DeStockOnValidateOrder=Decrease realen Bestände auf Bestellungen stellt fest DeStockOnShipment=Verringere Lagerstände nach erfolgtem Versand (empfohlen) -ReStockOnBill=Erhöhung der tatsächlichen Bestände in den Rechnungen / Gutschriften (Achtung: In dieser Version werden nur die Lagerstände des Lagers 1 aktualisiert) -ReStockOnValidateOrder=Erhöhung der realen Bestände auf Bestellungen stellt fest (Achtung: In dieser Version werden nur die Lagerstände des Lagers 1 aktualisiert) +ReStockOnBill=Erhöhung der tatsächlichen Bestände in den Rechnungen / Gutschriften +ReStockOnValidateOrder=Erhöhung der realen Bestände auf Bestellungen stellt fest StockDiffPhysicTeoric=Grund für die Differenz physisch. und theoret. Lagerbestand StockLimitShort=Mindestbestand StockLimit=Sicherungsbestand für autom. Benachrichtigung diff --git a/htdocs/langs/el_GR/stocks.lang b/htdocs/langs/el_GR/stocks.lang index 8c85bd5a588..4fcc934283a 100644 --- a/htdocs/langs/el_GR/stocks.lang +++ b/htdocs/langs/el_GR/stocks.lang @@ -55,8 +55,8 @@ RuleForStockManagementIncrease=Κανόνας για την αύξηση της DeStockOnBill=Μείωση πραγματικών αποθεμάτων για τους πελάτες τιμολόγια / πιστωτικά επικύρωση σημειώσεις DeStockOnValidateOrder=Μείωση πραγματικών αποθεμάτων σχετικά με τις παραγγελίες των πελατών επικύρωσης DeStockOnShipment=Μείωση πραγματικών αποθεμάτων για την επικύρωση αποστολή -ReStockOnBill=Αύξηση πραγματικού αποθέματα για τους προμηθευτές τιμολόγια / πιστωτικά επικύρωση σημειώσεις (προειδοποίηση, σε αυτή την έκδοση, είναι μόνο σε αριθμό Αποθήκη 1 του εν λόγω αποθέματος είναι τροποποιημένο) -ReStockOnValidateOrder=Αύξηση πραγματικού αποθεμάτων σχετικά με τις παραγγελίες τους προμηθευτές επιδοκιμασίας (προειδοποίηση, σε αυτή την έκδοση, είναι μόνο σε αριθμό Αποθήκη 1 του εν λόγω αποθέματος έχει τροποποιηθεί) +ReStockOnBill=Αύξηση πραγματικού αποθέματα για τους προμηθευτές τιμολόγια / πιστωτικά επικύρωση σημειώσεις +ReStockOnValidateOrder=Αύξηση πραγματικού αποθεμάτων σχετικά με τις παραγγελίες τους προμηθευτές επιδοκιμασίας ReStockOnDispatchOrder=Αύξηση των αποθεμάτων σε πραγματικό εγχειρίδιο αποστολή σε αποθήκες, μετά από σειρά προμηθευτής που λαμβάνει OrderStatusNotReadyToDispatch=Παραγγελία δεν έχει ακόμη ή όχι περισσότερο μια κατάσταση που επιτρέπει την αποστολή των προϊόντων σε αποθήκες αποθεμάτων. StockDiffPhysicTeoric=Λόγος αποθεμάτων διαφορά φυσική και θεωρητική diff --git a/htdocs/langs/en_US/agenda.lang b/htdocs/langs/en_US/agenda.lang index 8fff67a3cfa..2acf601712d 100644 --- a/htdocs/langs/en_US/agenda.lang +++ b/htdocs/langs/en_US/agenda.lang @@ -37,6 +37,7 @@ PropalValidatedInDolibarr= Proposal %s validated InvoiceValidatedInDolibarr= Invoice %s validated InvoiceBackToDraftInDolibarr=Invoice %s go back to draft status OrderValidatedInDolibarr= Order %s validated +OrderApprovedInDolibarr=Order %s approved InterventionValidatedInDolibarr=Intervention %s validated ProposalSentByEMail=Commercial proposal %s sent by EMail OrderSentByEMail=Customer order %s sent by EMail diff --git a/htdocs/langs/en_US/stocks.lang b/htdocs/langs/en_US/stocks.lang index 70687e960a1..8688d51e7cc 100644 --- a/htdocs/langs/en_US/stocks.lang +++ b/htdocs/langs/en_US/stocks.lang @@ -47,8 +47,8 @@ RuleForStockManagementIncrease=Rule for stock management increase DeStockOnBill=Decrease real stocks on customers invoices/credit notes validation DeStockOnValidateOrder=Decrease real stocks on customers orders validation DeStockOnShipment=Decrease real stocks on shipment validation -ReStockOnBill=Increase real stocks on suppliers invoices/credit notes validation (warning, in this version, it's only in warehouse number 1 that stock is modified) -ReStockOnValidateOrder=Increase real stocks on suppliers orders approbation (warning, in this version, it's only in warehouse number 1 that stock is modified) +ReStockOnBill=Increase real stocks on suppliers invoices/credit notes validation +ReStockOnValidateOrder=Increase real stocks on suppliers orders approbation ReStockOnDispatchOrder=Increase real stocks on manual dispatching into warehouses, after supplier order receiving OrderStatusNotReadyToDispatch=Order has not yet or no more a status that allows dispatching of products in stock warehouses. StockDiffPhysicTeoric=Reason for difference stock physical and theoretical diff --git a/htdocs/langs/es_ES/stocks.lang b/htdocs/langs/es_ES/stocks.lang index 556e983efc6..27d6b57d100 100644 --- a/htdocs/langs/es_ES/stocks.lang +++ b/htdocs/langs/es_ES/stocks.lang @@ -46,8 +46,8 @@ RuleForStockManagementIncrease=Regla de gestión de incrementos de stock DeStockOnBill=Decrementar los stocks físicos sobre las facturas/abonos a clientes DeStockOnValidateOrder=Decrementar los stocks físicos sobre los pedidos de clientes DeStockOnShipment=Decrementar los stocks físicos sobre los envíos -ReStockOnBill=Incrementar los stocks físicos sobre las facturas/abonos de proveedores (atención, en esta versión, todavía se realiza el ajuste sobre el almacén número 1) -ReStockOnValidateOrder=Incrementar los stocks físicos sobre los pedidos a proveedores (atención, en esta versión, todavía se realiza el ajuste sobre el almacén número 1) +ReStockOnBill=Incrementar los stocks físicos sobre las facturas/abonos de proveedores +ReStockOnValidateOrder=Incrementar los stocks físicos sobre los pedidos a proveedores ReStockOnDispatchOrder=Incrementa los stocks físicos en el desglose manual de la recepción de los pedidos a proveedores en los almacenes OrderStatusNotReadyToDispatch=El pedido aún no está o no tiene un estado que permita un desglose de stock. StockDiffPhysicTeoric=Motivo de la diferencia entre valores físicos y teóricos diff --git a/htdocs/langs/fi_FI/stocks.lang b/htdocs/langs/fi_FI/stocks.lang index 4b64ba1d7fd..f056b1b0468 100644 --- a/htdocs/langs/fi_FI/stocks.lang +++ b/htdocs/langs/fi_FI/stocks.lang @@ -53,8 +53,8 @@ RuleForStockManagementDecrease=Sääntö varaston hallintaan lasku RuleForStockManagementIncrease=Sääntö varaston hallintaan lisätä DeStockOnBill=Decrease todellinen varastot laskuista / hyvityslaskuja DeStockOnValidateOrder=Decrease todellinen varastot tilaukset toteaa -ReStockOnBill=Lisäys todellinen varastot laskuista / hyvityslaskuja (varoitus, tässä versiossa, se on vain varasto numero 1, että varastossa on muutettu) -ReStockOnValidateOrder=Lisäys todellinen varastot tilaukset toteaa (varoitus, tässä versiossa, se on vain varasto numero 1, että varastossa on muutettu) +ReStockOnBill=Lisäys todellinen varastot laskuista / hyvityslaskuja +ReStockOnValidateOrder=Lisäys todellinen varastot tilaukset toteaa StockLimitShort=Limit StockLimit=Kanta raja hälytykset PhysicalStock=Varasto diff --git a/htdocs/langs/fr_FR/agenda.lang b/htdocs/langs/fr_FR/agenda.lang index 8ca6f98ad3b..f9dd2226d77 100644 --- a/htdocs/langs/fr_FR/agenda.lang +++ b/htdocs/langs/fr_FR/agenda.lang @@ -37,6 +37,7 @@ PropalValidatedInDolibarr=Proposition %s validée InvoiceValidatedInDolibarr=Facture %s validée InvoiceBackToDraftInDolibarr=Facture %s repassée en brouillon OrderValidatedInDolibarr=Commande %s validée +OrderApprovedInDolibarr=Commande %s approuvée InterventionValidatedInDolibarr=Intervention %s validée ProposalSentByEMail=Proposition commerciale %s envoyée par EMail OrderSentByEMail=Commande client %s envoyée par EMail diff --git a/htdocs/langs/fr_FR/stocks.lang b/htdocs/langs/fr_FR/stocks.lang index 1f393d63714..c89a25a4347 100644 --- a/htdocs/langs/fr_FR/stocks.lang +++ b/htdocs/langs/fr_FR/stocks.lang @@ -47,8 +47,8 @@ RuleForStockManagementIncrease=Règle de gestion des incrémentations de stock DeStockOnBill=Décrémente les stocks physiques sur validation des factures/avoirs clients DeStockOnValidateOrder=Décrémente les stocks physiques sur validation des commandes clients DeStockOnShipment=Décrémente les stocks physiques sur validation des expéditions -ReStockOnBill=Incrémente les stocks physiques sur validation des factures/avoirs fournisseurs (attention, dans cette version, c'est toujours dans le premier entrepôt que se fait l'ajustement) -ReStockOnValidateOrder=Incrémente les stocks physiques sur approbation des commandes fournisseurs (attention, dans cette version, c'est toujours dans le premier entrepôt que se fait l'ajustement) +ReStockOnBill=Incrémente les stocks physiques sur validation des factures/avoirs fournisseurs +ReStockOnValidateOrder=Incrémente les stocks physiques sur approbation des commandes fournisseurs ReStockOnDispatchOrder=Incrémente les stocks physiques sur ventilation manuelle de la réception des commandes fournisseurs dans les entrepôts OrderStatusNotReadyToDispatch=La commande n'a pas encore ou n'a plus un statut permettant une ventilation en stock. StockDiffPhysicTeoric=Raison écart stock physique-théorique diff --git a/htdocs/langs/hu_HU/stocks.lang b/htdocs/langs/hu_HU/stocks.lang index fa95fd5c3b8..d4d3b70891c 100644 --- a/htdocs/langs/hu_HU/stocks.lang +++ b/htdocs/langs/hu_HU/stocks.lang @@ -47,8 +47,8 @@ RuleForStockManagementIncrease=Készlet kerezelés szabály emelése DeStockOnBill=Tényleges készlet csökkentése számla/hitel jóváhagyásakor DeStockOnValidateOrder=Tényleges készlet csökkentése ügyfél rendelés jóváhagyásakor DeStockOnShipment=Tényleges készlet csökkentése szállítás jóváhagyásakor -ReStockOnBill=Tényleges készlet növelése számla/hitel jóváhagyásakor (Figyelem, ebben a verzióban, csak az 1-es számú raktár készlete módosúl) -ReStockOnValidateOrder=Tényleges készlet növelése beszállítótól való rendelés jóváhagyásakor (Figyelem, ebben a verzióban, csak az 1-es számú raktár készlete módosúl) +ReStockOnBill=Tényleges készlet növelése számla/hitel jóváhagyásakor +ReStockOnValidateOrder=Tényleges készlet növelése beszállítótól való rendelés jóváhagyásakor ReStockOnDispatchOrder=Tényleges készlet növelése manuális raktárba való feladáskor miután a beszállítói rendelés beérkezett OrderStatusNotReadyToDispatch=A rendelés még nincs olyan állapotban, hogy kiküldhető legyen a raktárba. StockDiffPhysicTeoric=Az eltérés oka a gyakorlati és az elméleti készlet diff --git a/htdocs/langs/is_IS/stocks.lang b/htdocs/langs/is_IS/stocks.lang index b08d2365286..f3eef8692c4 100644 --- a/htdocs/langs/is_IS/stocks.lang +++ b/htdocs/langs/is_IS/stocks.lang @@ -54,8 +54,8 @@ RuleForStockManagementIncrease=Regla fyrir lager stjórnun aukast DeStockOnBill=Minnka raunverulegur birgðir á viðskiptavini reikningum / kredit athugasemdir löggilding DeStockOnValidateOrder=Minnka raunverulegur birgðir á viðskiptavini pantanir löggilding DeStockOnShipment=Minnka alvöru stofnum á sendingunni löggilding -ReStockOnBill=Auka raunverulegur birgðir birgja reikningum / kredit athugasemdir löggilding (aðvörun í þessari útgáfu er það aðeins í fjölda vöruhús 1 sem birgðir er breytt) -ReStockOnValidateOrder=Auka raunverulegur birgðir birgja pantanir approbation (aðvörun í þessari útgáfu er það aðeins í fjölda vöruhús 1 sem birgðir er breytt) +ReStockOnBill=Auka raunverulegur birgðir birgja reikningum / kredit athugasemdir löggilding +ReStockOnValidateOrder=Auka raunverulegur birgðir birgja pantanir approbation ReStockOnDispatchOrder=Auka raunverulegur birgðir á handbók dispatching í vöruhús, eftir röð birgja sem fá OrderStatusNotReadyToDispatch=Panta hefur ekki enn eða ekki meira stöðu sem gerir dispatching af vörum í vöruhús lager. StockDiffPhysicTeoric=Ástæða fyrir lager munur líkamlega og fræðilegum diff --git a/htdocs/langs/it_IT/stocks.lang b/htdocs/langs/it_IT/stocks.lang index a5b5c581338..965316be732 100644 --- a/htdocs/langs/it_IT/stocks.lang +++ b/htdocs/langs/it_IT/stocks.lang @@ -43,8 +43,8 @@ RuleForStockManagement =Regola per la gestione delle scorte DeStockOnBill =Diminuzione delle scorte effettive all'emissione di fatture / note di credito DeStockOnValidateOrder =Diminuzione delle scorte effettive su convalida ordini DeStockOnShipment =Diminuzione delle scorte effettive con la spedizione (Raccomandato) -ReStockOnBill =Aumento delle scorte effettive con fatture / note di credito
(attenzione: con questa opzione vengono modificate solo le scorte del magazzino 1) -ReStockOnValidateOrder =Aumente delle scorte effettive su convalida ordini
(attenzione: con questa opzione vengono modificate solo le scorte del magazzino 1) +ReStockOnBill =Aumento delle scorte effettive con fatture / note di credito +ReStockOnValidateOrder =Aumente delle scorte effettive su convalida ordini StockDiffPhysicTeoric =Motivo della differenza tra scorta effettiva e teorica StockLimitShort =Limite StockLimit =Limite minimo scorta per segnalazioni diff --git a/htdocs/langs/nb_NO/stocks.lang b/htdocs/langs/nb_NO/stocks.lang index 4ad62aa8200..46cd58a1419 100644 --- a/htdocs/langs/nb_NO/stocks.lang +++ b/htdocs/langs/nb_NO/stocks.lang @@ -44,8 +44,8 @@ RuleForStockManagementIncrease=Regel for lagerøkning DeStockOnBill=Reduser virkelig beholdning ut fra faktura/kreditnota DeStockOnValidateOrder=Reduser virkelig beholdning ut fra ordre DeStockOnShipment=reduser virkelig beholdning ved forsendelse (anbefalt) -ReStockOnBill=Øk virkelig beholdning ut fra faktura/kreditnota (obs! i denne versjonen blir kun lager nummer 1 endret) -ReStockOnValidateOrder=Øk virkelig beholdning ut fra ordre (obs! i denne versjonen blir kun lager nummer 1 endret) +ReStockOnBill=Øk virkelig beholdning ut fra faktura/kreditnota +ReStockOnValidateOrder=Øk virkelig beholdning ut fra ordre StockDiffPhysicTeoric=Årsak til forskjell mellom fysisk og teoretisk beholdning StockLimitShort=Grense StockLimit=Minimumsbeholdning for varselmeldinger diff --git a/htdocs/langs/nl_BE/stocks.lang b/htdocs/langs/nl_BE/stocks.lang index e84ff98e2ed..2642f8b43f5 100644 --- a/htdocs/langs/nl_BE/stocks.lang +++ b/htdocs/langs/nl_BE/stocks.lang @@ -45,8 +45,8 @@ RuleForStockManagementIncrease=Regel voor voorraadbeheer verhogen DeStockOnBill=Daling van de reële voorraad op de facturen / creditnota's DeStockOnValidateOrder=Daling van de reële voorraad op bestellingen notities DeStockOnShipment=Daling van de reële voorraad op overbrenging (aanbevolen) -ReStockOnBill=Toename echte voorraden op facturen / creditnota's (waarschuwing, in deze versie, het is alleen in het magazijn nummer 1 dat bestand is gewijzigd) -ReStockOnValidateOrder=Toename voorraden echt op bestellingen notities (waarschuwing, in deze versie, het is alleen in het magazijn nummer 1 dat bestand is gewijzigd) +ReStockOnBill=Toename echte voorraden op facturen / creditnota's +ReStockOnValidateOrder=Toename voorraden echt op bestellingen notities StockDiffPhysicTeoric=Reden voor het verschil voorraad fysieke en theoretische StockLimitShort=Limiet StockLimit=Voorraad limiet voor signaleringen diff --git a/htdocs/langs/nl_NL/stocks.lang b/htdocs/langs/nl_NL/stocks.lang index cb4f85f5d45..8b8fc0a2178 100644 --- a/htdocs/langs/nl_NL/stocks.lang +++ b/htdocs/langs/nl_NL/stocks.lang @@ -46,9 +46,9 @@ RuleForStockManagementDecrease = Regel voor voorraadbeheerafname RuleForStockManagementIncrease = Regel voor voorraadbeheertoename DeStockOnBill = Verlaag de echte voorraad na het valideren van afnemersfacturen / creditnota's DeStockOnValidateOrder = Verlaag de echte voorraad na het valideren van opdrachten -DeStockOnShipment = Verlaag de echte voorraad na het valideren van verzendingen (waarschuwing, in deze versie, wordt de vooraad alleen in magazijn nummer 1 aangepast) -ReStockOnBill = Verhoog de echte voorraad na het valideren van leveranciersfacturen / -creditnota's (waarschuwing, in deze versie, wordt de vooraad alleen in magazijn nummer 1 aangepast) -ReStockOnValidateOrder = Verhoog de echte voorraad na het valideren van leveranciersopdrachten (waarschuwing, in deze versie, wordt de vooraad alleen in magazijn nummer 1 aangepast) +DeStockOnShipment = Verlaag de echte voorraad na het valideren van verzendingen +ReStockOnBill = Verhoog de echte voorraad na het valideren van leveranciersfacturen / creditnota's +ReStockOnValidateOrder = Verhoog de echte voorraad na het valideren van leveranciersopdrachten ReStockOnDispatchOrder = Verhoog de echte voorraad na het handmatig verzenden naar magazijnen, nadat de leveranciersopdracht ontvangst OrderStatusNotReadyToDispatch = Opdracht heeft nog geen, of niet langer, een status die het verzenden van producten naar een magazijn toestaat. StockDiffPhysicTeoric = Reden voor het verschil tussen de feitelijke en theoretische voorraad diff --git a/htdocs/langs/pl_PL/stocks.lang b/htdocs/langs/pl_PL/stocks.lang index 30493de4f87..afd82df2782 100644 --- a/htdocs/langs/pl_PL/stocks.lang +++ b/htdocs/langs/pl_PL/stocks.lang @@ -56,8 +56,8 @@ RuleForStockManagementIncrease=Artykuł na zarządzanie zapasami wzrost DeStockOnBill=Spadek realnych zasobów faktur / not kredytowych DeStockOnValidateOrder=Spadek realnych zasobów zamówień notatek DeStockOnShipment=Spadek realnych zasobów wysyłką (zaleciły) -ReStockOnBill=Wzrost realnego zasobów faktur / not kredytowych (uwaga, w tej wersji, to tylko w magazynie nr 1 tego zasobu zostanie zmodyfikowany) -ReStockOnValidateOrder=Wzrost realnego zasobów zamówień notatek (uwaga, w tej wersji, to tylko w magazynie nr 1 tego zasobu zostanie zmodyfikowany) +ReStockOnBill=Wzrost realnego zasobów faktur / not kredytowych +ReStockOnValidateOrder=Wzrost realnego zasobów zamówień notatek StockDiffPhysicTeoric=Powód różnica stanie fizycznym i teoretycznego StockLimitShort=Limit StockLimit=Stock limit wpisów diff --git a/htdocs/langs/pt_BR/stocks.lang b/htdocs/langs/pt_BR/stocks.lang index 4310897f3d5..54f05b9416c 100644 --- a/htdocs/langs/pt_BR/stocks.lang +++ b/htdocs/langs/pt_BR/stocks.lang @@ -46,8 +46,8 @@ RuleForStockManagementIncrease=Regra de Administração de incrementos de estoqu DeStockOnBill=Decrementar os estoques físicos sobre as faturas/recibos DeStockOnValidateOrder=Decrementar os estoques físicos sobre os pedidos DeStockOnShipment=Decrementar os estoques físicos sobre os envios (recomendado) -ReStockOnBill=Incrementar os estoques físicos sobre as faturas/recibos (Atenção, nesta Versão, todavía realiza-se o ajuste sobre o armazém número 1) -ReStockOnValidateOrder=Incrementar os estoques físicos sobre os pedidos (Atenção, nesta Versão, todavía se realiza o ajuste sobre o armazém número 1) +ReStockOnBill=Incrementar os estoques físicos sobre as faturas/recibos +ReStockOnValidateOrder=Incrementar os estoques físicos sobre os pedidos StockDiffPhysicTeoric=Motivo da diferença entre valores físicos e teóricos StockLimitShort=Límite máximo StockLimit=Límite máximo existencias diff --git a/htdocs/langs/pt_PT/stocks.lang b/htdocs/langs/pt_PT/stocks.lang index 57184a02b54..266175eaa7d 100644 --- a/htdocs/langs/pt_PT/stocks.lang +++ b/htdocs/langs/pt_PT/stocks.lang @@ -46,8 +46,8 @@ RuleForStockManagementIncrease=Regra de Gestão de incrementos de stock DeStockOnBill=Decrementar os stocks físicos sobre as facturas/recibos DeStockOnValidateOrder=Decrementar os stocks físicos sobre os pedidos DeStockOnShipment=Decrementar os stocks físicos sobre os envíos (recomendado) -ReStockOnBill=Incrementar os stocks físicos sobre as facturas/recibos (Atenção, em esta Versão, todavía realiza-se o ajuste sobre o armazem número 1) -ReStockOnValidateOrder=Incrementar os stocks físicos sobre os pedidos (Atenção, em esta Versão, todavía se realiza o ajuste sobre o armazem número 1) +ReStockOnBill=Incrementar os stocks físicos sobre as facturas/recibos +ReStockOnValidateOrder=Incrementar os stocks físicos sobre os pedidos StockDiffPhysicTeoric=Motivo da diferença entre valores físicos e teóricos StockLimitShort=Límite máximo StockLimit=Límite máximo existencias diff --git a/htdocs/langs/ro_RO/stocks.lang b/htdocs/langs/ro_RO/stocks.lang index 6e60df216ea..cb58b203121 100644 --- a/htdocs/langs/ro_RO/stocks.lang +++ b/htdocs/langs/ro_RO/stocks.lang @@ -53,8 +53,8 @@ RuleForStockManagementDecrease=Norma de management al stocurilor scădere RuleForStockManagementIncrease=Norma de management al stocurilor creştere DeStockOnBill=Reducerea real stocurile de pe facturi / note de credit DeStockOnValidateOrder=Reducerea real stocurile de pe ordinele de note -ReStockOnBill=Creşterea reală stocurile de pe facturi / note de credit (avertisment, în această versiune, este doar în depozit numărul 1, care stocul este modificat) -ReStockOnValidateOrder=Creşterea reală stocurile de pe ordinele de note (avertisment, în această versiune, este doar în depozit numărul 1, care stocul este modificat) +ReStockOnBill=Creşterea reală stocurile de pe facturi / note de credit +ReStockOnValidateOrder=Creşterea reală stocurile de pe ordinele de note StockLimitShort=Limita de StockLimit=Stoc limită pentru alerte PhysicalStock=Stocul fizic diff --git a/htdocs/langs/ru_RU/stocks.lang b/htdocs/langs/ru_RU/stocks.lang index 0a0a3cbe4a0..64660068afe 100644 --- a/htdocs/langs/ru_RU/stocks.lang +++ b/htdocs/langs/ru_RU/stocks.lang @@ -53,8 +53,8 @@ RuleForStockManagementDecrease=Правило для управления зап RuleForStockManagementIncrease=Правило для управления запасами увеличить DeStockOnBill=Снижение реальных запасов на счета / кредитных нот DeStockOnValidateOrder=Снижение реальных запасов по заказам записки -ReStockOnBill=Увеличение реальных запасов на счета / кредитных нот (предупреждение, в этой версии, это только на склад № 1, что запас изменяется) -ReStockOnValidateOrder=Увеличение реальных запасов по заказам записки (предупреждение, в этой версии, это только на склад № 1, что запас изменяется) +ReStockOnBill=Увеличение реальных запасов на счета / кредитных нот +ReStockOnValidateOrder=Увеличение реальных запасов по заказам записки StockDiffPhysicTeoric=Причина разницы запас физических и теоретических StockLimitShort=Предельные StockLimit=Фондовый предел для оповещения diff --git a/htdocs/langs/sl_SI/stocks.lang b/htdocs/langs/sl_SI/stocks.lang index 4370fbb6ac8..444b0aebf48 100644 --- a/htdocs/langs/sl_SI/stocks.lang +++ b/htdocs/langs/sl_SI/stocks.lang @@ -47,8 +47,8 @@ RuleForStockManagementIncrease= Pravilo za upravljanje povečanja zalog DeStockOnBill=Zmanjšanje dejanske zaloge po potrditvi fakture/dobropisa DeStockOnValidateOrder=Zmanjšanje dejanske zaloge po potrditvi naročila DeStockOnShipment= Zmanjšanje dejanske zaloge po potrditvi odpreme (priporočeno) -ReStockOnBill=Povečanje dejanske zaloge po potrditvi fakture/dobropisa (pozor, v tej verziji se zaloga spremeni samo v skladišču številka 1) -ReStockOnValidateOrder=Povečanje dejanske zaloge po potrditvi naročila (pozor, v tej verziji se zaloga spremeni samo v skladišču številka 1) +ReStockOnBill=Povečanje dejanske zaloge po potrditvi fakture/dobropisa +ReStockOnValidateOrder=Povečanje dejanske zaloge po potrditvi naročila ReStockOnDispatchOrder=Povečanje dejanske zaloge po ročnem vnosu v skladišče, po prejemu naročila od dobavitelja OrderStatusNotReadyToDispatch=Naročilo še nima ali nima več statusa, ki omogoča odpremo proizvoda iz skladišča. StockDiffPhysicTeoric=Razlog za razliko med knjižno in dejansko zalogo diff --git a/htdocs/langs/sv_SE/stocks.lang b/htdocs/langs/sv_SE/stocks.lang index 821eb8bfb33..bd2d9e044f0 100644 --- a/htdocs/langs/sv_SE/stocks.lang +++ b/htdocs/langs/sv_SE/stocks.lang @@ -55,8 +55,8 @@ RuleForStockManagementIncrease=Regel för lagerhantering öka DeStockOnBill=Minska riktiga lager kunder fakturor / kreditnotor validering DeStockOnValidateOrder=Minska riktiga lager på kunder order validering DeStockOnShipment=Minska riktiga lager på transporten validering -ReStockOnBill=Reell ökning av lager på leverantörer fakturor / kreditnotor validering (varning, i denna version, det är bara i lager nummer 1 att materielen är modifierad) -ReStockOnValidateOrder=Reell ökning av lagren av leverantörer order gillande (varning, i denna version, det är bara i lager nummer 1 att materielen är modifierad) +ReStockOnBill=Reell ökning av lager på leverantörer fakturor / kreditnotor validering +ReStockOnValidateOrder=Reell ökning av lagren av leverantörer order gillande ReStockOnDispatchOrder=Reell ökning av lagren på manuell distributionscentraler i lager, efter leverantör för mottagande OrderStatusNotReadyToDispatch=Beställ ännu inte eller inte mer en ställning som innebär sändningar av produkter i lager lager. StockDiffPhysicTeoric=Orsak till skillnad lager fysiska och teoretiska diff --git a/htdocs/langs/tr_TR/stocks.lang b/htdocs/langs/tr_TR/stocks.lang index 3cc7e95d414..5faef0e46f1 100644 --- a/htdocs/langs/tr_TR/stocks.lang +++ b/htdocs/langs/tr_TR/stocks.lang @@ -54,8 +54,8 @@ RuleForStockManagementIncrease=Stok yönetimi artış Kural DeStockOnBill=Faturaların gerçek stokları azaltın / kredi notları doğrulama DeStockOnValidateOrder=Emir notları doğrulama DeStockOnShipment=Gönderi doğrulama gerçek stokları azaltın (önerilir) -ReStockOnBill=Faturaların gerçek hisse arttır / kredi notları doğrulama (uyarı, bu sürümde, bu hisse senedi olarak bir depo sayısı 1 sadece) -ReStockOnValidateOrder=Emir notları doğrulama (uyarısı, bu sürüm gerçek stokları artış, bu hisse senedi olarak bir depo sayısı 1 sadece) +ReStockOnBill=Faturaların gerçek hisse arttır / kredi notları doğrulama +ReStockOnValidateOrder=Emir notları doğrulama StockDiffPhysicTeoric=Nedenle fark stok fiziksel ve teorik için StockLimitShort=Limit StockLimit=Için borsa sınırı uyarıları diff --git a/htdocs/langs/zh_CN/stocks.lang b/htdocs/langs/zh_CN/stocks.lang index 1ef5f628968..faf31fa9b53 100644 --- a/htdocs/langs/zh_CN/stocks.lang +++ b/htdocs/langs/zh_CN/stocks.lang @@ -54,8 +54,8 @@ RuleForStockManagementIncrease=增加的库存管理规则 DeStockOnBill=减少对客户的实际库存发票/信用票据验证 DeStockOnValidateOrder=减少对客户的订单确认 DeStockOnShipment=减少对实际装运验证股票(推荐) -ReStockOnBill=增加对供应商发票的实际库存/信用票据验证(警告在此版本中,它只有在仓库数1,股票被修改) -ReStockOnValidateOrder=对供应商的订单增加赞许(警告在此版本中,真正的股票,它只有在仓库数1,股票被修改) +ReStockOnBill=增加对供应商发票的实际库存/信用票据验证 +ReStockOnValidateOrder=对供应商的订单增加赞许 ReStockOnDispatchOrder=增加人工调度到仓库供应商接到订单后,实时股票 OrderStatusNotReadyToDispatch=命令还没有或根本没有更多的地位,使产品在仓库库存调度。 StockDiffPhysicTeoric=股票差异的原因和理论物理