some fix for chrome
This commit is contained in:
parent
dbc9e5a931
commit
ac4f8374cc
|
@ -33,6 +33,10 @@ class Admin::RegisteredSitesController < OrbitAdminController
|
|||
end
|
||||
|
||||
def change_access_status
|
||||
if !request.xhr?
|
||||
redirect_to admin_registered_sites_path(:page => params[:page])
|
||||
return
|
||||
end
|
||||
status = params[:status]
|
||||
site = RegisteredSite.find_by(:uid => params[:uid])
|
||||
case status
|
||||
|
|
|
@ -1,16 +1 @@
|
|||
$("#index_table").html("<%= j render 'index' %>");
|
||||
var atags = $(".pagination a");
|
||||
if (atags.length > 0){
|
||||
atags.each(function(){
|
||||
var el = $(this);
|
||||
if(el.attr("href")){
|
||||
var url = "http://" + window.location.host + el.attr("href");
|
||||
uri = new URL(url);
|
||||
if(uri.searchParams.get("page")){
|
||||
$(this).attr("href","/<%= locale.to_s %>/admin/registered_sites?page=" + uri.searchParams.get("page"));
|
||||
}else{
|
||||
$(this).attr("href","/<%= locale.to_s %>/admin/registered_sites");
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
$("#index_table").html("<%= j render 'index' %>");
|
Loading…
Reference in New Issue