View | Details | Raw Unified | Return to bug 40538
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/js/holds.js (-11 / +23 lines)
Lines 386-401 $(document).ready(function () { Link Here
386
                                        "</a>"
386
                                        "</a>"
387
                                    );
387
                                    );
388
                                } else {
388
                                } else {
389
                                    return (
389
                                    const link = document.createElement("a");
390
                                        "<a class='hold-suspend btn btn-default btn-xs' data-hold-id='" +
390
                                    link.classList.add(
391
                                        oObj.reserve_id +
391
                                        "hold-suspend",
392
                                        "' data-hold-title='" +
392
                                        "btn",
393
                                        oObj.title +
393
                                        "btn-default",
394
                                        "'>" +
394
                                        "btn-xs"
395
                                        "<i class='fa fa-pause'></i> " +
395
                                    );
396
                                        __("Suspend") +
396
                                    link.setAttribute(
397
                                        "</a>"
397
                                        "data-hold-id",
398
                                        oObj.reserve_id
399
                                    );
400
                                    link.setAttribute(
401
                                        "data-hold-title",
402
                                        oObj.title
403
                                    );
404
                                    link.textContent = " " + __("Suspend");
405
                                    const icon = document.createElement("i");
406
                                    icon.classList.add("fa", "fa-pause");
407
                                    link.insertAdjacentElement(
408
                                        "afterbegin",
409
                                        icon
398
                                    );
410
                                    );
411
                                    return link.outerHTML;
399
                                }
412
                                }
400
                            },
413
                            },
401
                        },
414
                        },
Lines 504-510 $(document).ready(function () { Link Here
504
                $(".hold-suspend").on("click", function () {
517
                $(".hold-suspend").on("click", function () {
505
                    var hold_id = $(this).data("hold-id");
518
                    var hold_id = $(this).data("hold-id");
506
                    var hold_title = $(this).data("hold-title");
519
                    var hold_title = $(this).data("hold-title");
507
                    $("#suspend-modal-title").html("<i>" + hold_title + "</i>");
520
                    $("#suspend-modal-title").text(hold_title);
508
                    $("#suspend-modal-submit").data("hold-id", hold_id);
521
                    $("#suspend-modal-submit").data("hold-id", hold_id);
509
                    $("#suspend-modal").modal("show");
522
                    $("#suspend-modal").modal("show");
510
                });
523
                });
511
- 

Return to bug 40538