Skip to content

Commit b9972eb

Browse files
committed
Added image by platform in result search
1 parent 9f04bf5 commit b9972eb

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

Diff for: src/views/package/_search_item.php

+4
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,16 @@
88
/* @var $widget ListView */
99
/* @var $model Project */
1010

11+
$bundle = \hiqdev\assetpackagist\assets\AppAsset::register($this);
12+
$logoUrl = $bundle->baseUrl . '/logo';
13+
1114
$url = Url::to(['package/detail', 'fullname' => $model->fullName]);
1215
$url = str_replace('%2F', '/', $url);
1316
?>
1417
<div class="row well well-sm">
1518
<div class="col-sm-9">
1619
<h4 class="search-result-item-heading">
20+
<img src="<?= $logoUrl . '/' . strtolower($model->platform) ?>.svg" title="<?= Html::encode($model->platform) ?>" height="20px" />
1721
<a href="<?= $url ?>"><?= Html::encode($model->fullName) ?></a>
1822
</h4>
1923
<?php if ($model->description): ?>

0 commit comments

Comments
 (0)