mirror of
https://github.com/fspc/BikeShed-1.git
synced 2025-02-28 08:43:23 -05:00
Fix: more explicit (and correct) time entries delete URL
This commit is contained in:
parent
2c6a58206a
commit
76980a8903
@ -67,7 +67,7 @@ $(document).ready(function () {
|
|||||||
|
|
||||||
$("#confirmation_delete").click(function () {
|
$("#confirmation_delete").click(function () {
|
||||||
var entry_id = $(this).data("entry_id");
|
var entry_id = $(this).data("entry_id");
|
||||||
var url = $("#confirmation_delete").data("url") + entry_id;
|
var url = $("#confirmation_delete").data("url-template").replace(/__ID__/, entry_id);
|
||||||
$.ajax({
|
$.ajax({
|
||||||
url: url,
|
url: url,
|
||||||
type: "delete",
|
type: "delete",
|
||||||
|
@ -41,7 +41,7 @@
|
|||||||
#work_entry_description Description
|
#work_entry_description Description
|
||||||
.modal-footer
|
.modal-footer
|
||||||
%button.btn.btn-default(data-dismiss="modal" aria-hidden="true") Cancel
|
%button.btn.btn-default(data-dismiss="modal" aria-hidden="true") Cancel
|
||||||
%button.btn.btn-danger#confirmation_delete(data-url="api/v1/time_entries/") Delete
|
%button.btn.btn-danger#confirmation_delete{data: {url_template: api_delete_time_entry_path('__ID__')}} Delete
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user