|
@@ 292-305 (lines=14) @@
|
| 289 |
|
echo "\n <link href='/{$cacheDir}/all{$timeMd5}.css' rel='stylesheet' type='text/css' />"; |
| 290 |
|
} |
| 291 |
|
|
| 292 |
|
public function getCss() { |
| 293 |
|
$css = []; |
| 294 |
|
if (!empty($this->libAssets['css'])) { |
| 295 |
|
$this->ResolveCssHref($this->libAssets['css'], 'libs', $css); |
| 296 |
|
} |
| 297 |
|
if (!empty($this->template->config['css'])) { |
| 298 |
|
$this->ResolveCssHref($this->template->config['css'], 'template', $css); |
| 299 |
|
} |
| 300 |
|
if (!empty($this->dynAssets['css'])) { |
| 301 |
|
$this->ResolveCssHref($this->dynAssets['css'], 'custom', $css); |
| 302 |
|
} |
| 303 |
|
return $css; |
| 304 |
|
} |
| 305 |
|
|
| 306 |
|
public function ResolveCssHref($cssArray, $type = 'custom', &$hrefs) { |
| 307 |
|
switch ($type) { |
| 308 |
|
case'libs': |
|
@@ 442-455 (lines=14) @@
|
| 439 |
|
$this->widget('View\bodyEnd', compact('options')); |
| 440 |
|
} |
| 441 |
|
|
| 442 |
|
public function getScripts() { |
| 443 |
|
$scripts = []; |
| 444 |
|
if (!empty($this->libAssets['js'])) { |
| 445 |
|
$this->genScriptArray($this->libAssets['js'], 'libs', $scripts); |
| 446 |
|
} |
| 447 |
|
if (!empty($this->dynAssets['js'])) { |
| 448 |
|
$this->genScriptArray($this->dynAssets['js'], 'custom', $scripts); |
| 449 |
|
} |
| 450 |
|
if (!empty($this->template->config['js'])) { |
| 451 |
|
$this->genScriptArray($this->template->config['js'], 'template', $scripts); |
| 452 |
|
} |
| 453 |
|
return $scripts; |
| 454 |
|
} |
| 455 |
|
|
| 456 |
|
public function genScriptArray($jsArray, $type = 'custom', &$resultArray) { |
| 457 |
|
switch ($type) { |
| 458 |
|
case 'libs': |