public function __construct(ShipmentLabel $shipmentLabel)
 {
     $this->entity = $shipmentLabel;
     $this->entityDTO = new ShipmentLabelDTO();
     $this->entityDTO->externalId = $this->entity->getExternalId();
     $this->entityDTO->resolution = $this->entity->getResolution();
     $this->entityDTO->size = $this->entity->getSize();
     $this->entityDTO->type = $this->entity->getType();
     $this->entityDTO->fileType = $this->entity->getFileType();
     $this->entityDTO->url = $this->entity->getUrl();
     $this->entityDTO->pdfUrl = $this->entity->getPdfUrl();
     $this->entityDTO->epl2Url = $this->entity->getEpl2Url();
     $this->entityDTO->zplUrl = $this->entity->getZplUrl();
 }
예제 #2
0
 public function testCreateDefaults()
 {
     $shipmentLabel = new ShipmentLabel();
     $this->assertSame(null, $shipmentLabel->getExternalId());
     $this->assertSame(null, $shipmentLabel->getResolution());
     $this->assertSame(null, $shipmentLabel->getSize());
     $this->assertSame(null, $shipmentLabel->getType());
     $this->assertSame(null, $shipmentLabel->getFileType());
     $this->assertSame(null, $shipmentLabel->getUrl());
     $this->assertSame(null, $shipmentLabel->getPdfUrl());
     $this->assertSame(null, $shipmentLabel->getEpl2Url());
     $this->assertSame(null, $shipmentLabel->getZplUrl());
 }