aboutsummaryrefslogtreecommitdiff
path: root/resources/js/activities.js
diff options
context:
space:
mode:
Diffstat (limited to 'resources/js/activities.js')
-rw-r--r--resources/js/activities.js15
1 files changed, 15 insertions, 0 deletions
diff --git a/resources/js/activities.js b/resources/js/activities.js
new file mode 100644
index 0000000..f9c19ac
--- /dev/null
+++ b/resources/js/activities.js
@@ -0,0 +1,15 @@
+$.ajaxSetup({
+ headers: {
+ 'X-CSRF-TOKEN': $('input[name="csrf-token"]').attr('content')
+ }
+});
+
+jQuery('select#call-sign').change(fillTable);
+jQuery(document).ready(fillTable);
+
+function fillTable() {
+ sign = jQuery('select#call-sign').first().val();
+ jQuery.post('/api/activities', {'call-sign': sign}, function (data, status) {
+ console.log(data);
+ });
+}