mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
All methods set_draft() were renamed into setDraft()
This commit is contained in:
parent
6ecd37ea8f
commit
c0b6699b25
|
|
@ -18,6 +18,7 @@ Following changes may create regressions for some external modules, but were nec
|
|||
* Deprecated function img_phone as been removed. You can use img_picto(..., 'call|call_out') instead.;
|
||||
* Files for variables of themes were renamed from graph-color.php into theme_vars.inc.php to match naming
|
||||
convention of extension .inc.php for files to be included.
|
||||
* All methods set_draft() were renamed into setDraft().
|
||||
|
||||
|
||||
***** ChangeLog for 9.0.1 compared to 9.0.0 *****
|
||||
|
|
|
|||
|
|
@ -595,7 +595,6 @@ class BOM extends CommonObject
|
|||
}
|
||||
}
|
||||
|
||||
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||
/**
|
||||
* Set draft status
|
||||
*
|
||||
|
|
@ -604,7 +603,6 @@ class BOM extends CommonObject
|
|||
*/
|
||||
public function setDraft($user)
|
||||
{
|
||||
//phpcs:enable
|
||||
global $conf,$langs;
|
||||
|
||||
$error=0;
|
||||
|
|
|
|||
|
|
@ -790,7 +790,7 @@ if (empty($reshook))
|
|||
// Go back to draft
|
||||
if ($action == 'modif' && $usercancreate)
|
||||
{
|
||||
$object->set_draft($user);
|
||||
$object->setDraft($user);
|
||||
|
||||
if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -593,7 +593,7 @@ class Proposals extends DolibarrApi
|
|||
throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login);
|
||||
}
|
||||
|
||||
$result = $this->propal->set_draft(DolibarrApiAccess::$user);
|
||||
$result = $this->propal->setDraftDolibarrApiAccess::$user);
|
||||
if ($result == 0) {
|
||||
throw new RestException(304, 'Nothing done. May be object is already draft');
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2605,7 +2605,7 @@ class Propal extends CommonObject
|
|||
* @param int $notrigger 1=Does not execute triggers, 0= execute triggers
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function set_draft($user, $notrigger = 0)
|
||||
public function setDraft($user, $notrigger = 0)
|
||||
{
|
||||
// phpcs:enable
|
||||
$error=0;
|
||||
|
|
|
|||
|
|
@ -1219,7 +1219,7 @@ if (empty($reshook))
|
|||
}
|
||||
|
||||
if (! $error) {
|
||||
$result = $object->set_draft($user, $idwarehouse);
|
||||
$result = $object->setDraft($user, $idwarehouse);
|
||||
if ($result >= 0)
|
||||
{
|
||||
// Define output language
|
||||
|
|
|
|||
|
|
@ -770,7 +770,7 @@ class Orders extends DolibarrApi
|
|||
throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login);
|
||||
}
|
||||
|
||||
$result = $this->commande->set_draft(DolibarrApiAccess::$user, $idwarehouse);
|
||||
$result = $this->commande->setDraftDolibarrApiAccess::$user, $idwarehouse);
|
||||
if ($result == 0) {
|
||||
throw new RestException(304, 'Nothing done. May be object is already closed');
|
||||
}
|
||||
|
|
|
|||
|
|
@ -479,7 +479,7 @@ class Commande extends CommonOrder
|
|||
* @param int $idwarehouse Warehouse ID to use for stock change (Used only if option STOCK_CALCULATE_ON_VALIDATE_ORDER is on)
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function set_draft($user, $idwarehouse = -1)
|
||||
public function setDraft($user, $idwarehouse = -1)
|
||||
{
|
||||
//phpcs:enable
|
||||
global $conf,$langs;
|
||||
|
|
|
|||
|
|
@ -621,7 +621,7 @@ if (empty($reshook))
|
|||
{
|
||||
if (! empty($conf->global->INVOICE_CAN_ALWAYS_BE_EDITED) || ($resteapayer == $object->total_ttc && empty($object->paye)))
|
||||
{
|
||||
$result=$object->set_draft($user, $idwarehouse);
|
||||
$result=$object->setDraft($user, $idwarehouse);
|
||||
if ($result<0) setEventMessages($object->error, $object->errors, 'errors');
|
||||
|
||||
// Define output language
|
||||
|
|
|
|||
|
|
@ -745,7 +745,7 @@ class Invoices extends DolibarrApi
|
|||
throw new RestException(401, 'Access not allowed for login '.DolibarrApiAccess::$user->login);
|
||||
}
|
||||
|
||||
$result = $this->invoice->set_draft(DolibarrApiAccess::$user, $idwarehouse);
|
||||
$result = $this->invoice->setDraftDolibarrApiAccess::$user, $idwarehouse);
|
||||
if ($result == 0) {
|
||||
throw new RestException(304, 'Nothing done.');
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2537,7 +2537,7 @@ class Facture extends CommonInvoice
|
|||
* @param int $idwarehouse Id warehouse to use for stock change.
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function set_draft($user, $idwarehouse = -1)
|
||||
public function setDraft($user, $idwarehouse = -1)
|
||||
{
|
||||
// phpcs:enable
|
||||
global $conf,$langs;
|
||||
|
|
|
|||
|
|
@ -1458,7 +1458,7 @@ class FactureFournisseur extends CommonInvoice
|
|||
* @param int $idwarehouse Id warehouse to use for stock change.
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function set_draft($user, $idwarehouse = -1)
|
||||
public function setDraft($user, $idwarehouse = -1)
|
||||
{
|
||||
// phpcs:enable
|
||||
global $conf,$langs;
|
||||
|
|
|
|||
|
|
@ -1446,7 +1446,7 @@ if (empty($reshook))
|
|||
}
|
||||
}
|
||||
|
||||
$object->set_draft($user, $idwarehouse);
|
||||
$object->setDraft($user, $idwarehouse);
|
||||
|
||||
// Define output language
|
||||
if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE))
|
||||
|
|
|
|||
|
|
@ -144,7 +144,7 @@ if (empty($reshook))
|
|||
// Confirm back to draft status
|
||||
if ($action == 'modif' && $user->rights->reception->creer)
|
||||
{
|
||||
$result = $object->set_draft($user);
|
||||
$result = $object->setDraft($user);
|
||||
if ($result >= 0)
|
||||
{
|
||||
// Define output language
|
||||
|
|
|
|||
|
|
@ -1771,7 +1771,7 @@ class Reception extends CommonObject
|
|||
* @param User $user Object user that modify
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function set_draft($user)
|
||||
public function setDraft($user)
|
||||
{
|
||||
// phpcs:enable
|
||||
global $conf,$langs;
|
||||
|
|
|
|||
|
|
@ -491,7 +491,7 @@ if (empty($reshook))
|
|||
// Go back to draft
|
||||
if ($action == 'modif' && $user->rights->supplier_proposal->creer)
|
||||
{
|
||||
$object->set_draft($user);
|
||||
$object->setDraft($user);
|
||||
|
||||
if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1878,7 +1878,7 @@ class SupplierProposal extends CommonObject
|
|||
* @param User $user Object user that modify
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function set_draft($user)
|
||||
public function setDraft($user)
|
||||
{
|
||||
// phpcs:enable
|
||||
global $conf,$langs;
|
||||
|
|
|
|||
|
|
@ -777,7 +777,7 @@ dol_syslog("Function: updateInvoice login=".$authentication['login']." id=".$inv
|
|||
{
|
||||
if ($invoice['status'] == Facture::STATUS_DRAFT)
|
||||
{
|
||||
$result = $object->set_draft($fuser);
|
||||
$result = $object->setDraft($fuser);
|
||||
}
|
||||
if ($invoice['status'] == Facture::STATUS_VALIDATED)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user