webservices 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 webservices. If not, see <http://www.gnu.org/licenses/>. -------------------------------------------------------------------------- */ include "../../../inc/includes.php"; Plugin::load('webservices', true); if (!isset($_GET["id"])) { $_GET["id"] = ""; } $webservices = new PluginWebservicesClient(); if (isset($_POST["add"])) { $webservices->check(-1, 'w', $_POST); $webservices->add($_POST); Html::back(); } else { if (isset($_POST["update"])) { $webservices->check($_POST["id"], 'w'); $webservices->update($_POST); Html::back(); } else { if (isset($_POST["delete"])) { $webservices->check($_POST["id"], 'w'); $webservices->delete($_POST); Html::redirect($CFG_GLPI["root_doc"] . "/plugins/webservices/front/client.php"); } else {
@package Webservices @author Nelly Mahu-Lasson @copyright Copyright (c) 2009-2015 Webservices plugin team @license AGPL License 3.0 or (at your option) any later version http://www.gnu.org/licenses/agpl-3.0-standalone.html @link https://forge.glpi-project.org/projects/webservices @link http://www.glpi-project.org/ @since 2009 -------------------------------------------------------------------------- */ include "../../../inc/includes.php"; Plugin::load('webservices', true); if (!isset($_GET["id"])) { $_GET["id"] = ""; } $webservices = new PluginWebservicesClient(); if (isset($_POST["add"])) { $webservices->check(-1, CREATE, $_POST); $webservices->add($_POST); Html::back(); } else { if (isset($_POST["update"])) { $webservices->check($_POST["id"], UPDATE); $webservices->update($_POST); Html::back(); } else { if (isset($_POST["purge"])) { $webservices->check($_POST["id"], PURGE); $webservices->delete($_POST); Html::redirect($CFG_GLPI["root_doc"] . "/plugins/webservices/front/client.php"); } else {
function plugin_webservices_uninstall() { // No autoload when plugin is not activated require_once 'inc/client.class.php'; PluginWebservicesClient::uninstall(); return true; }