Order/Export/OrderExporter.php
protected function buildRow(OrderInterface $order)
    {
        $date = null;
        $term = null;

        $formatter = $this->getFormatter();

        if (null !== $date = $order->getOutstandingDate()) {
            $date = $formatter->date($date);
        }
        if (null !== $term = $order->getPaymentTerm()) {
            $term = $term->getName();
        }

        return [
            'id'                  => $order->getId(),
            'number'              => $order->getNumber(),
            'company'             => $order->getCompany(),
            'payment_state'       => $order->getPaymentState(),
            'shipment_state'      => $order->getShipmentState(),
            'invoice_state'       => $order->getInvoiceState(),
            'payment_term'        => $term,
            'due_amount'          => $order->getGrandTotal() - $order->getPaidTotal(),
            'outstanding_expired' => $order->getOutstandingExpired(),
            'outstanding_date'    => $date,
            'created_at'          => $formatter->date($order->getCreatedAt()),
        ];
    }
protected function buildRow(OrderInterface $order)
    {
        $date = null;
        $term = null;

        $formatter = $this->getFormatter();

        if (null !== $date = $order->getOutstandingDate()) {
            $date = $formatter->date($date);
        }
        if (null !== $term = $order->getPaymentTerm()) {
            $term = $term->getName();
        }

        return [
            'id'                  => $order->getId(),
            'number'              => $order->getNumber(),
            'company'             => $order->getCompany(),
            'payment_state'       => $order->getPaymentState(),
            'shipment_state'      => $order->getShipmentState(),
            'invoice_state'       => $order->getInvoiceState(),
            'payment_term'        => $term,
            'due_amount'          => $order->getGrandTotal() - $order->getPaidTotal(),
            'outstanding_expired' => $order->getOutstandingExpired(),
            'outstanding_date'    => $date,
            'created_at'          => $formatter->date($order->getCreatedAt()),
        ];
    }
Builds the order row.

@param OrderInterface $order

@return array