[-] BO : AdminModule Addons Icon now appear in AutoComplete Search
This commit is contained in:
1 parent
3b034002cc
commit
43f58a84f3
3 files changed
+5
-3
No files matched your search
@@ -72,7 +72,10 @@
|
|||||||
matchContains: true,
|
matchContains: true,
|
||||||
highlightItem: true,
|
highlightItem: true,
|
||||||
formatItem: function(row, i, max, term) {
|
formatItem: function(row, i, max, term) {
|
||||||
return '<img src="../modules/'+row.name+'/logo.gif" style="float:left;margin:5px"><strong>'+row.displayName+'</strong>'+((row.author != '') ? ' ' + by + ' ' + truncate_author(row.author) : '') + '<br /><span style="font-size: 80%;">'+ row.desc +'</span><br/><div style="height:15px;padding-top:5px">'+ row.option +'</div>';
|
var image = '../modules/'+row.name+'/logo.gif';
|
||||||
|
if (row.image != '')
|
||||||
|
image = row.image;
|
||||||
|
return '<img src="'+image+'" style="float:left;margin:5px;width:16px;height:16px"><strong>'+row.displayName+'</strong>'+((row.author != '') ? ' ' + by + ' ' + truncate_author(row.author) : '') + '<br /><span style="font-size: 80%;">'+ row.desc +'</span><br/><div style="height:15px;padding-top:5px">'+ row.option +'</div>';
|
||||||
},
|
},
|
||||||
formatResult: function(row) {
|
formatResult: function(row) {
|
||||||
return row.displayName;
|
return row.displayName;
|
||||||
|
|||||||
@@ -773,8 +773,6 @@ abstract class ModuleCore
|
|||||||
$item->need_instance = 0;
|
$item->need_instance = 0;
|
||||||
$item->available_on_addons = 1;
|
$item->available_on_addons = 1;
|
||||||
$item->active = 0;
|
$item->active = 0;
|
||||||
if (!isset($modaddons->img) && isset($modaddons->id))
|
|
||||||
$modaddons->img = 'http://media.prestastore.com/img/pico/'.(int)$modaddons->id.'.jpg';
|
|
||||||
if (isset($modaddons->img))
|
if (isset($modaddons->img))
|
||||||
{
|
{
|
||||||
if (!file_exists('../img/tmp/'.md5($modaddons->name).'.jpg'))
|
if (!file_exists('../img/tmp/'.md5($modaddons->name).'.jpg'))
|
||||||
|
|||||||
@@ -827,6 +827,7 @@ class AdminModulesControllerCore extends AdminController
|
|||||||
'desc' => (string)$module->description,
|
'desc' => (string)$module->description,
|
||||||
'name' => (string)$module->name,
|
'name' => (string)$module->name,
|
||||||
'author' => (string)$module->author,
|
'author' => (string)$module->author,
|
||||||
|
'image' => (isset($module->image) ? (string)$module->image : ''),
|
||||||
'option' => $this->displayModuleOptions($module)
|
'option' => $this->displayModuleOptions($module)
|
||||||
)).', ';
|
)).', ';
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user