diff --git a/ChangeLog b/ChangeLog index 9c7db6d51a5..6ae31ed8033 100644 --- a/ChangeLog +++ b/ChangeLog @@ -33,7 +33,7 @@ Following changes may create regressions for some external modules, but were nec an invoice from a shipment is validated (and if your process is to make invoice on shipment and not on order), because this setup has changed. * It was possible to use a variable $soc or $right inside a php code condition of some extrafields properties, this is no more true (this 2 variables are no more global variables). * New hook files of modules actions_mymodule.class.php should "extends CommonHookActions" -* Endpoint for API /partnershipapi has been renamed into /partnerships to follow conventions +* Endpoint for API /partnershipapi and /recruitment has been renamed into /partnerships and /recruitments to follow name conventions. ***** ChangeLog for 18.0.2 compared to 18.0.1 ***** diff --git a/htdocs/core/lib/functions2.lib.php b/htdocs/core/lib/functions2.lib.php index b7ceac840a5..394a341aa7f 100644 --- a/htdocs/core/lib/functions2.lib.php +++ b/htdocs/core/lib/functions2.lib.php @@ -2661,7 +2661,7 @@ function getModuleDirForApiClass($moduleobject) $moduledirforclass = 'mrp'; } elseif ($moduleobject == 'accounting') { $moduledirforclass = 'accountancy'; - } elseif (in_array($moduleobject, array('products', 'expensereports', 'users', 'tickets', 'boms', 'receptions', 'partnerships'))) { + } elseif (in_array($moduleobject, array('products', 'expensereports', 'users', 'tickets', 'boms', 'receptions', 'partnerships', 'recruitments'))) { $moduledirforclass = preg_replace('/s$/', '', $moduleobject); } diff --git a/htdocs/install/upgrade2.php b/htdocs/install/upgrade2.php index d8b9b862298..e7a571b88a2 100644 --- a/htdocs/install/upgrade2.php +++ b/htdocs/install/upgrade2.php @@ -4160,6 +4160,7 @@ function migrate_delete_old_files($db, $langs, $conf) '/user/class/api_user.class.php', '/partnership/class/api_partnership.class.php', '/product/class/api_product.class.php', + '/recruitment/class/api_recruitment.class.php', '/societe/class/api_contact.class.php', '/societe/class/api_thirdparty.class.php', '/support/online.php', diff --git a/htdocs/recruitment/class/api_recruitment.class.php b/htdocs/recruitment/class/api_recruitments.class.php similarity index 99% rename from htdocs/recruitment/class/api_recruitment.class.php rename to htdocs/recruitment/class/api_recruitments.class.php index 91b5934ab06..adb854813b3 100644 --- a/htdocs/recruitment/class/api_recruitment.class.php +++ b/htdocs/recruitment/class/api_recruitments.class.php @@ -34,7 +34,7 @@ dol_include_once('/recruitment/class/recruitmentcandidature.class.php'); * @access protected * @class DolibarrApiAccess {@requires user,external} */ -class Recruitment extends DolibarrApi +class Recruitments extends DolibarrApi { /** * @var RecruitmentJobPosition $jobposition {@type RecruitmentJobPosition}