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

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/invoice-files.tt (-4 / +13 lines)
Lines 75-82 Link Here
75
                            [% f.date_uploaded | $KohaDates %]
75
                            [% f.date_uploaded | $KohaDates %]
76
                          </td>
76
                          </td>
77
                          <td>[% f.file_size | html %]</td>
77
                          <td>[% f.file_size | html %]</td>
78
                          <td><a class="delete_file" href="?invoiceid=[% invoiceid | html %]&amp;op=delete&amp;file_id=[% f.file_id | html %]">Delete</a></td>
78
                          <td>
79
                          <td><a href="?invoiceid=[% invoiceid | uri %]&amp;op=download&amp;file_id=[% f.file_id | uri %]">Download</a></td>
79
                                <form action="invoice-files.pl" method="post">
80
                                    [% INCLUDE 'csrf-token.inc' %]
81
                                    <input type="hidden" name="invoiceid" value="[% invoiceid | html %]" />
82
                                    <input type="hidden" name="file_id" value="[% f.file_id | html %]" />
83
                                    <input type="hidden" name="op" value="cud-delete" />
84
                                    <button type="submit" class="btn btn-default btn-xs delete_file">
85
                                        <i class="fa fa-trash"></i> Delete
86
                                    </button>
87
                                </form>
88
                            </td>
89
                          <td><a class="btn btn-default btn-xs" href="?invoiceid=[% invoiceid | uri %]&amp;op=download&amp;file_id=[% f.file_id | uri %]"><i class="fa fa-download"></i> Download</a></td>
80
                      </tr>
90
                      </tr>
81
                    [% END %]
91
                    [% END %]
82
                  </tbody>
92
                  </tbody>
Lines 128-134 Link Here
128
                "searching": false,
138
                "searching": false,
129
                "dom": "t"
139
                "dom": "t"
130
            }));
140
            }));
131
            $("a.delete_file").click(function(){
141
            $(".delete_file").click(function(){
132
                return ( confirm( _("Are you sure you want to delete this file ?") ) );
142
                return ( confirm( _("Are you sure you want to delete this file ?") ) );
133
            });
143
            });
134
        });
144
        });
135
- 

Return to bug 34478