mirror of
https://github.com/snipe/snipe-it.git
synced 2024-11-13 17:14:10 -08:00
a6f90cb3fc
* Rename licenses route checkin parameter to clarify it's purpose and fix incorrect route in users view page. * Checkin note can be nullable for checking in a license. * License Seat view was only showing 20 license seats due to faulty transformer logic.
33 lines
852 B
PHP
33 lines
852 B
PHP
<?php
|
|
|
|
namespace App\Events;
|
|
|
|
use App\Models\User;
|
|
use Illuminate\Foundation\Events\Dispatchable;
|
|
use Illuminate\Queue\SerializesModels;
|
|
|
|
class CheckoutableCheckedIn
|
|
{
|
|
use Dispatchable, SerializesModels;
|
|
|
|
public $checkoutable;
|
|
public $checkedOutTo;
|
|
public $checkedInBy;
|
|
public $note;
|
|
public $action_date; // Date setted in the hardware.checkin view at the checkin_at input, for the action log
|
|
|
|
/**
|
|
* Create a new event instance.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function __construct($checkoutable, $checkedOutTo, User $checkedInBy, $note, $action_date = null)
|
|
{
|
|
$this->checkoutable = $checkoutable;
|
|
$this->checkedOutTo = $checkedOutTo;
|
|
$this->checkedInBy = $checkedInBy;
|
|
$this->note = $note;
|
|
$this->action_date = $action_date ?? date('Y-m-d');
|
|
}
|
|
}
|