PHP Classes

File: SetaStatusPedido.php

Recommend this page to a friend!
  Classes of Julio Cezar Kronbauer   PHP ClearSale   SetaStatusPedido.php   Download  
File: SetaStatusPedido.php
Role: Example script
Content type: text/plain
Description: Envia comando à ClearSale para alterar o status de um pedido
Class: PHP ClearSale
Evaluate the risk of orders with ClearSale
Author: By
Last change: Added some variables
Date: 10 years ago
Size: 466 bytes
 

Contents

Class file image Download
<?php

require_once $_SERVER['DOCUMENT_ROOT'] . '/ClearSale/ClearSale.Class.php';

$ClearSale1 = new ClearSale;

// Seta o status de um pedido //
$id = isset($_POST['id']) ? $_POST['id'] : (isset($_GET['id']) ? $_GET['id'] : '');
$status = isset($_POST['status']) ? $_POST['status'] : (isset($_GET['status']) ? $_GET['status'] : '');

echo
$ClearSale1->setPedidoStatus(CLEARSALE_CODIGO_INTEGRACAO, $id, $status);
// ========================== //

?>