|
1
|
|
|
<?php |
|
2
|
|
|
|
|
3
|
|
|
/* |
|
4
|
|
|
* This file is part of gpupo/cnova-sdk |
|
5
|
|
|
* Created by Gilmar Pupo <[email protected]> |
|
6
|
|
|
* For the information of copyright and license you should read the file |
|
7
|
|
|
* LICENSE which is distributed with this source code. |
|
8
|
|
|
* Para a informação dos direitos autorais e de licença você deve ler o arquivo |
|
9
|
|
|
* LICENSE que é distribuído com este código-fonte. |
|
10
|
|
|
* Para obtener la información de los derechos de autor y la licencia debe leer |
|
11
|
|
|
* el archivo LICENSE que se distribuye con el código fuente. |
|
12
|
|
|
* For more information, see <https://opensource.gpupo.com/>. |
|
13
|
|
|
*/ |
|
14
|
|
|
|
|
15
|
|
|
namespace Gpupo\CnovaSdk\Entity\Order\Trackings\Tracking; |
|
16
|
|
|
|
|
17
|
|
|
use Gpupo\CommonSdk\Entity\EntityAbstract; |
|
18
|
|
|
use Gpupo\CommonSdk\Entity\EntityInterface; |
|
19
|
|
|
|
|
20
|
|
|
/** |
|
21
|
|
|
* @method array getItems() |
|
22
|
|
|
* @method setItems(array $items) |
|
23
|
|
|
* @method string getControlPoint() |
|
24
|
|
|
* @method setControlPoint(string $controlPoint) |
|
25
|
|
|
* @method string getDescription() |
|
26
|
|
|
* @method setDescription(string $description) |
|
27
|
|
|
* @method string getOccurredAt() |
|
28
|
|
|
* @method setOccurredAt(string $occurredAt) |
|
29
|
|
|
* @method Gpupo\CnovaSdk\Entity\Order\Trackings\Tracking\Carrier getCarrier() |
|
30
|
|
|
* @method setCarrier(Gpupo\CnovaSdk\Entity\Order\Trackings\Tracking\Carrier $carrier) |
|
31
|
|
|
* @method string getUrl() |
|
32
|
|
|
* @method setUrl(string $url) |
|
33
|
|
|
* @method string getNumber() |
|
34
|
|
|
* @method setNumber(string $number) |
|
35
|
|
|
* @method string getSellerDeliveryId() |
|
36
|
|
|
* @method setSellerDeliveryId(string $sellerDeliveryId) |
|
37
|
|
|
* @method string getCte() |
|
38
|
|
|
* @method setCte(string $cte) |
|
39
|
|
|
* @method Gpupo\CnovaSdk\Entity\Order\Trackings\Tracking\Invoice getInvoice() |
|
40
|
|
|
* @method setInvoice(Gpupo\CnovaSdk\Entity\Order\Trackings\Tracking\Invoice $invoice) |
|
41
|
|
|
*/ |
|
42
|
|
|
class Tracking extends EntityAbstract implements EntityInterface |
|
43
|
|
|
{ |
|
44
|
16 |
|
public function getSchema() |
|
45
|
|
|
{ |
|
46
|
|
|
return [ |
|
47
|
16 |
|
'items' => 'array', |
|
48
|
|
|
'controlPoint' => 'string', |
|
49
|
|
|
'description' => 'string', |
|
50
|
|
|
'occurredAt' => 'string', |
|
51
|
|
|
'carrier' => 'object', |
|
52
|
|
|
'url' => 'string', |
|
53
|
|
|
'number' => 'string', |
|
54
|
|
|
'sellerDeliveryId' => 'string', |
|
55
|
|
|
'cte' => 'string', |
|
56
|
|
|
'invoice' => 'object', |
|
57
|
|
|
]; |
|
58
|
|
|
} |
|
59
|
|
|
|
|
60
|
14 |
|
public function setUp() |
|
61
|
|
|
{ |
|
62
|
14 |
|
$this->setRequiredSchema(['number', 'sellerDeliveryId']); |
|
63
|
14 |
|
$this->setOptionalSchema(['controlPoint', 'description', 'cte', 'url']); |
|
64
|
14 |
|
} |
|
65
|
|
|
} |
|
66
|
|
|
|