diff options
author | Robin Appelman <icewind1991@gmail.com> | 2011-07-31 00:50:04 +0200 |
---|---|---|
committer | Robin Appelman <icewind1991@gmail.com> | 2011-07-31 00:50:04 +0200 |
commit | e6821e9d7c716d4808c11789ff7065430213f2d0 (patch) | |
tree | 12cfec0c09ce218a617a9cb7a7b733ac8c1d4dc1 /search/js | |
parent | 0503c3499ee03bcb220416ac1162cafcf5b38bc4 (diff) | |
download | nextcloud-server-e6821e9d7c716d4808c11789ff7065430213f2d0.tar.gz nextcloud-server-e6821e9d7c716d4808c11789ff7065430213f2d0.zip |
Show play and add-to-playlist buttons in instant search results
for now this only works from inside the media app
Diffstat (limited to 'search/js')
-rw-r--r-- | search/js/result.js | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/search/js/result.js b/search/js/result.js index b550d4d314d..cb5ec31cd31 100644 --- a/search/js/result.js +++ b/search/js/result.js @@ -43,6 +43,9 @@ OC.search.showResults=function(results){ row.find('td.result a').attr('href',type[0].link); row.find('td.result div.name').text(type[0].name); row.find('td.result div.text').text(type[0].text); + if(OC.search.customResults[name]){//give plugins the ability to customize the entries in here + OC.search.customResults[name](row,type[0]); + } $('#searchresults tbody').append(row); for(var i=1;i<type.length;i++){ var row=$('#searchresults tr.template').clone(); @@ -51,6 +54,9 @@ OC.search.showResults=function(results){ row.find('td.result a').attr('href',type[i].link); row.find('td.result div.name').text(type[i].name); row.find('td.result div.text').text(type[i].text); + if(OC.search.customResults[name]){//give plugins the ability to customize the entries in here + OC.search.customResults[name](row,type[i]); + } $('#searchresults tbody').append(row); } } |