From 7762ceaa7e2bb34f8758e17a4c8f512fa6a81b9e Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Sun, 15 Jan 2017 18:24:09 -0800 Subject: Initial Vueification --- public/js/profile.coffee | 30 ------------------------------ 1 file changed, 30 deletions(-) delete mode 100644 public/js/profile.coffee (limited to 'public/js/profile.coffee') diff --git a/public/js/profile.coffee b/public/js/profile.coffee deleted file mode 100644 index a894f275..00000000 --- a/public/js/profile.coffee +++ /dev/null @@ -1,30 +0,0 @@ -g = exports ? this -g.proceed = false - -$(-> - $('[data-toggle=popover]').popover() - $('#title').focus() - - user = $('#username').val() - $.getJSON("/#{user}.json", (data) -> - $('#email').val(data.email) - $('#phone').val(data.phone) - $('#profile').fadeIn() - ) - - $('#confirm').blur(-> - $('#confirm_error').remove() - if $('#password').val() != $('#confirm').val() - $('#password, #confirm').parent().addClass('has-error') - $('#confirm').parent().after('
Passwords don\'t match
') - else - $('#password, #confirm').parent().removeClass('has-error') - ) - - $('#profile').submit(-> - $('#profile .form-control').blur() - if $('#profile .has-error').length > 0 - $('#profile .has-error').effect('shake', 500) - return false - ) -) -- cgit v1.2.3