diff options
author | Patricio Cano <suprnova32@gmail.com> | 2016-07-16 02:29:23 +0300 |
---|---|---|
committer | Patricio Cano <suprnova32@gmail.com> | 2016-07-19 01:52:29 +0300 |
commit | a3f0f2cc4d9a4c689ae0eeae73e6d4ef19c39cce (patch) | |
tree | e93c2626e1f4fb3451b733a45ee9e8182d33babc /app/assets/javascripts | |
parent | 7943767267873423acb1eddbf00b6c5684f7849f (diff) |
Move inline JS to admin.js.coffee specific file.
Diffstat (limited to 'app/assets/javascripts')
-rw-r--r-- | app/assets/javascripts/admin.js.coffee | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/app/assets/javascripts/admin.js.coffee b/app/assets/javascripts/admin.js.coffee index b2b8e1b7ffb..4dd30973d11 100644 --- a/app/assets/javascripts/admin.js.coffee +++ b/app/assets/javascripts/admin.js.coffee @@ -38,3 +38,15 @@ class @Admin $('li.group_member').bind 'ajax:success', -> Turbolinks.visit(location.href) + + showBlacklistType = -> + if $('input[name=\'blacklist_type\']:checked').val() == 'file' + $('.blacklist-file').show() + $('.blacklist-raw').hide() + else + $('.blacklist-file').hide() + $('.blacklist-raw').show() + return + + $('input[name=\'blacklist_type\']').click showBlacklistType + showBlacklistType() |