@@ -34,6 +34,7 @@ class DeliveryNoteBuilder extends DocumentBuilder | |||
$deliveryNote = new DeliveryNote(); | |||
$deliveryNote->status = Document::STATUS_DRAFT; | |||
$this->initDocumentDate($deliveryNote); | |||
$this->initDocumentProducer($deliveryNote); | |||
$this->initTaxCalculationMethod($deliveryNote); | |||
@@ -34,6 +34,11 @@ class DocumentBuilder extends AbstractBuilder | |||
} | |||
} | |||
public function initDocumentDate(Document $document) | |||
{ | |||
$document->date = date('Y-m-d H:i:s'); | |||
} | |||
public function updateDocumentIsSend(Document $document, bool $isSent) | |||
{ | |||
$document->is_sent = $isSent; |