Move api routes to /api and add /api/sessions
This commit is contained in:
@ -12,10 +12,10 @@
|
||||
// Get the corresponding route to activate/inactivate the category
|
||||
let url;
|
||||
if(active) {
|
||||
url = "/category/" + id + "/end_session";
|
||||
url = "/api/category/" + id + "/end_session";
|
||||
cl.remove(toggled_class);
|
||||
} else {
|
||||
url = "/category/" + id + "/start_session";
|
||||
url = "/api/category/" + id + "/start_session";
|
||||
cl.add(toggled_class);
|
||||
}
|
||||
|
||||
@ -40,7 +40,7 @@
|
||||
></div>
|
||||
<span class="category_name">{{this.1.name}}</span>
|
||||
{{#if this.1.started}}
|
||||
<form action="/category/{{this.0}}/bump_session/minutes/5", method="post">
|
||||
<form action="/api/category/{{this.0}}/bump_session/minutes/5", method="post">
|
||||
<button style="height: 100%; color: green;" type="submit">+5</button>
|
||||
</form>
|
||||
{{/if}}
|
||||
|
||||
Reference in New Issue
Block a user