aboutsummaryrefslogtreecommitdiffhomepage
path: root/app/Resources/static/themes/material/js/tools.js
diff options
context:
space:
mode:
authorJeremy Benoist <jeremy.benoist@gmail.com>2019-01-19 22:08:29 +0100
committerJeremy Benoist <jeremy.benoist@gmail.com>2019-01-19 22:24:10 +0100
commit50f35f0db2be9586205e793f315608eec59c9666 (patch)
tree0f88f3ab6ad32db026494a7104341c45ee997515 /app/Resources/static/themes/material/js/tools.js
parent9a57653aec85b0f5220436d5cb76545e66c24a11 (diff)
downloadwallabag-50f35f0db2be9586205e793f315608eec59c9666.tar.gz
wallabag-50f35f0db2be9586205e793f315608eec59c9666.tar.zst
wallabag-50f35f0db2be9586205e793f315608eec59c9666.zip
Move icon into the top menu bar
Change the way to select a random entry: - select all ids from the given user (with filters) - choose randomly one in php - find that entry
Diffstat (limited to 'app/Resources/static/themes/material/js/tools.js')
-rw-r--r--app/Resources/static/themes/material/js/tools.js14
1 files changed, 13 insertions, 1 deletions
diff --git a/app/Resources/static/themes/material/js/tools.js b/app/Resources/static/themes/material/js/tools.js
index 39398fd8..0b3d3038 100644
--- a/app/Resources/static/themes/material/js/tools.js
+++ b/app/Resources/static/themes/material/js/tools.js
@@ -8,6 +8,7 @@ function initFilters() {
8 $('#clear_form_filters').on('click', () => { 8 $('#clear_form_filters').on('click', () => {
9 $('#filters input').val(''); 9 $('#filters input').val('');
10 $('#filters :checked').removeAttr('checked'); 10 $('#filters :checked').removeAttr('checked');
11
11 return false; 12 return false;
12 }); 13 });
13 } 14 }
@@ -21,4 +22,15 @@ function initExport() {
21 } 22 }
22} 23}
23 24
24export { initExport, initFilters }; 25function initRandom() {
26 // no display if export (ie: entries) not available
27 if ($('div').is('#export')) {
28 $('#button_random').show();
29 }
30}
31
32export {
33 initExport,
34 initFilters,
35 initRandom,
36};