aboutsummaryrefslogtreecommitdiffstats
path: root/static/js/jams.js
diff options
context:
space:
mode:
authorGravatar Gareth Coles <[email protected]>2018-05-19 13:53:53 +0100
committerGravatar Gareth Coles <[email protected]>2018-05-19 13:53:53 +0100
commit4a66fe0427aaacac3cbfdf6b2ea47bb3e056e88b (patch)
tree581cef536c213ed00cc6ca48998f67b0df7e0b5b /static/js/jams.js
parentFix some small question-editing bugs (diff)
[Jams] Linting and infractions
Diffstat (limited to 'static/js/jams.js')
-rw-r--r--static/js/jams.js24
1 files changed, 24 insertions, 0 deletions
diff --git a/static/js/jams.js b/static/js/jams.js
index 37d8a764..2ee547fa 100644
--- a/static/js/jams.js
+++ b/static/js/jams.js
@@ -173,4 +173,28 @@ class Actions {
callback
)
}
+
+ create_infraction(id, reason, number, callback) {
+ this.send(
+ "infraction",
+ "POST",
+ {
+ "participant": id,
+ "reason": reason,
+ "number": number
+ },
+ callback
+ )
+ }
+
+ delete_infraction(id, callback) {
+ this.send(
+ "infraction",
+ "DELETE",
+ {
+ "id": id,
+ },
+ callback
+ )
+ }
} \ No newline at end of file