1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-14 07:02:34 +01:00
invoiceninja/app/Ninja/Intents/DownloadInvoiceIntent.php
2016-08-10 15:57:34 +03:00

20 lines
514 B
PHP

<?php namespace App\Ninja\Intents;
use Auth;
use App\Models\EntityModel;
use App\Models\Invoice;
use App\Libraries\Skype\SkypeResponse;
class DownloadInvoiceIntent extends InvoiceIntent
{
public function process()
{
$invoice = $this->invoice();
$message = trans('texts.' . $invoice->getEntityType()) . ' ' . $invoice->invoice_number;
$message = link_to('/download/' . $invoice->invitations[0]->invitation_key, $message);
return SkypeResponse::message($message);
}
}