2014-08-06 11:37:43 +00:00
|
|
|
<%= render_filter @filter_fields, "index_table" %>
|
2014-05-02 10:21:51 +00:00
|
|
|
<span id="index_table">
|
2014-05-14 02:58:06 +00:00
|
|
|
<%= render 'index'%>
|
2014-05-02 10:21:51 +00:00
|
|
|
</span>
|
2014-05-01 08:41:00 +00:00
|
|
|
|
2016-07-20 12:35:23 +00:00
|
|
|
<%= render 'layouts/delete_modal', delete_options: @delete_options %>
|
|
|
|
|
2021-09-16 10:07:10 +00:00
|
|
|
<% if user_can_approve? %>
|
2016-07-20 12:35:23 +00:00
|
|
|
<%= render :partial=> "approval_modal" %>
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
2020-04-11 09:30:26 +00:00
|
|
|
$(function(){
|
2020-04-11 09:28:58 +00:00
|
|
|
var modal = $("#approvalModal");
|
|
|
|
$(document).on("click", ".approval_button",function(){
|
|
|
|
var url = $(this).attr("href");
|
|
|
|
if(window.location.protocol === "https:"){
|
|
|
|
url = url.replace("http:","https:");
|
|
|
|
}
|
|
|
|
modal.find("iframe").attr("src", url);
|
|
|
|
modal.find("#object_id").val($(this).data("id"));
|
|
|
|
modal.modal("show");
|
|
|
|
return false;
|
|
|
|
})
|
2016-07-21 16:23:19 +00:00
|
|
|
|
2020-04-11 09:28:58 +00:00
|
|
|
var params = getUrlVars();
|
|
|
|
console.log(params["url"])
|
|
|
|
if(typeof params["url"] != "undefined"){
|
|
|
|
modal.find("iframe").attr("src", params["url"]);
|
|
|
|
modal.find("#object_id").val(params["id"]);
|
|
|
|
modal.modal("show");
|
|
|
|
}
|
|
|
|
})
|
2016-07-20 12:35:23 +00:00
|
|
|
</script>
|
|
|
|
<% end %>
|