From b494ff2ce6462a89e71c4058f57f876f31d13f8f Mon Sep 17 00:00:00 2001 From: Pierre Goiffon Date: Fri, 11 Feb 2022 10:25:17 +0100 Subject: [PATCH] =?UTF-8?q?N=C2=B04488=20Remove=20cmdbAbstractObject=20met?= =?UTF-8?q?hods=20used=20in=20export.php=20from=20API=20methods=20and=20ad?= =?UTF-8?q?d=20comment=20in=20export.php=20`@deprecated`=20was=20added=20i?= =?UTF-8?q?n=2003e9bcd4=20but=20as=20none=20of=20those=20will=20be=20remov?= =?UTF-8?q?ed=20in=20a=20near=20future,=20we=20are=20using=20`@internal`in?= =?UTF-8?q?stead=20!?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/cmdbabstract.class.inc.php | 7 ++++--- webservices/export.php | 9 +++++++++ 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/application/cmdbabstract.class.inc.php b/application/cmdbabstract.class.inc.php index c230a1ae6..3643504d6 100644 --- a/application/cmdbabstract.class.inc.php +++ b/application/cmdbabstract.class.inc.php @@ -1558,7 +1558,8 @@ HTML * * @throws \Exception * only used in old and deprecated export.php - * @deprecated since 2.7.7 3.0.1 + * + * @internal Only to be used by `/webservices/export.php` : this is a legacy method that produces wrong HTML (no TR on table body rows) */ public static function DisplaySetAsHTMLSpreadsheet(WebPage $oPage, CMDBObjectSet $oSet, $aParams = array()) { @@ -1579,8 +1580,8 @@ HTML * @throws \MySQLException * @throws \MySQLHasGoneAwayException * @throws \Exception - * only used in old and deprecated export.php - * @deprecated since 2.7.7 3.0.1 + * + * @internal Only to be used by `/webservices/export.php` : this is a legacy method that produces wrong HTML (no TR on table body rows) */ public static function GetSetAsHTMLSpreadsheet(DBObjectSet $oSet, $aParams = array()) { diff --git a/webservices/export.php b/webservices/export.php index 9179912eb..a3f6ed2ad 100644 --- a/webservices/export.php +++ b/webservices/export.php @@ -17,6 +17,15 @@ * You should have received a copy of the GNU Affero General Public License */ + +/** + * ⚠ Warning, this page is only kept for legacy usages : **it is not maintained anymore** + * + * Instead, you should use `export-v2.php` + * + * @link https://www.itophub.io/wiki/page?id=latest:advancedtopics:exportdata_v1 script documentation + */ + if (!defined('__DIR__')) define('__DIR__', dirname(__FILE__)); require_once(__DIR__.'/../approot.inc.php'); require_once(APPROOT.'/application/application.inc.php');