Passed
Pull Request — master (#721)
by Florian
14:00 queued 04:02
created

InputDate   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 35
Duplicated Lines 0 %

Importance

Changes 2
Bugs 1 Features 0
Metric Value
eloc 22
c 2
b 1
f 0
dl 0
loc 35
rs 10
wmc 2

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 17 1
A render() 0 3 1
1
<?php
2
3
namespace JeroenNoten\LaravelAdminLte\Components;
4
5
use Illuminate\View\Component;
6
7
class InputDate extends Component
8
{
9
    public $id;
10
    public $name;
11
    public $label;
12
    public $placeholder;
13
    public $topclass;
14
    public $inputclass;
15
    public $value;
16
    public $disabled;
17
    public $required;
18
    public $format;
19
20
    public function __construct(
21
            $id, $name = null,
22
            $label = 'Input Label', $placeholder = null,
23
            $topclass = null, $inputclass = null,
24
            $value = null, $disabled = false, $required = false,
25
            $format = 'YYYY-MM-DD'
26
        ) {
27
        $this->id = $id;
28
        $this->name = $name;
29
        $this->label = $label;
30
        $this->placeholder = $placeholder;
31
        $this->topclass = $topclass;
32
        $this->inputclass = $inputclass;
33
        $this->value = $value;
34
        $this->required = $required;
35
        $this->disabled = $disabled;
36
        $this->format = $format;
37
    }
38
39
    public function render()
40
    {
41
        return view('adminlte::input-date');
42
    }
43
}
44