1 | <?php |
||
9 | class Panel implements Renderable |
||
10 | { |
||
11 | /** |
||
12 | * The view to be rendered. |
||
13 | * |
||
14 | * @var string |
||
15 | */ |
||
16 | protected $view = 'admin::show.panel'; |
||
17 | |||
18 | /** |
||
19 | * The fields that this panel holds. |
||
20 | * |
||
21 | * @var Collection |
||
22 | */ |
||
23 | protected $fields; |
||
24 | |||
25 | /** |
||
26 | * Variables in the view. |
||
27 | * |
||
28 | * @var array |
||
29 | */ |
||
30 | protected $data; |
||
31 | |||
32 | /** |
||
33 | * Parent show instance. |
||
34 | * |
||
35 | * @var Show |
||
36 | */ |
||
37 | protected $parent; |
||
38 | |||
39 | /** |
||
40 | * Panel constructor. |
||
41 | */ |
||
42 | public function __construct(Show $show) |
||
48 | |||
49 | /** |
||
50 | * Initialize view data. |
||
51 | */ |
||
52 | protected function initData() |
||
61 | |||
62 | /** |
||
63 | * Set parent container. |
||
64 | * |
||
65 | * @param Show $show |
||
66 | * |
||
67 | * @return $this |
||
68 | */ |
||
69 | public function setParent(Show $show) |
||
75 | |||
76 | /** |
||
77 | * Get parent container. |
||
78 | * |
||
79 | * @return Show |
||
80 | */ |
||
81 | public function getParent() |
||
85 | |||
86 | /** |
||
87 | * Set style for this panel. |
||
88 | * |
||
89 | * @param string $style |
||
90 | * |
||
91 | * @return $this |
||
92 | */ |
||
93 | public function style($style = 'info') |
||
99 | |||
100 | /** |
||
101 | * Set title for this panel. |
||
102 | * |
||
103 | * @param string $title |
||
104 | * |
||
105 | * @return $this |
||
106 | */ |
||
107 | public function title($title) |
||
113 | |||
114 | /** |
||
115 | * Set view for this panel to render. |
||
116 | * |
||
117 | * @param string $view |
||
118 | * |
||
119 | * @return $this |
||
120 | */ |
||
121 | public function view($view) |
||
127 | |||
128 | /** |
||
129 | * Build panel tools. |
||
130 | * |
||
131 | * @param $callable |
||
132 | */ |
||
133 | public function tools($callable) |
||
137 | |||
138 | /** |
||
139 | * Fill fields to panel. |
||
140 | * |
||
141 | * @param []Field $fields |
||
|
|||
142 | * |
||
143 | * @return $this |
||
144 | */ |
||
145 | public function fill($fields) |
||
151 | |||
152 | /** |
||
153 | * Render this panel. |
||
154 | * |
||
155 | * @return string |
||
156 | */ |
||
157 | public function render() |
||
161 | } |
||
162 |
This check marks PHPDoc comments that could not be parsed by our parser. To see which comment annotations we can parse, please refer to our documentation on supported doc-types.