update
This commit is contained in:
parent
7eff0efa68
commit
28d38e23a1
@ -45,5 +45,8 @@ class ApplicationController < ActionController::Base
|
||||
return @files
|
||||
end
|
||||
|
||||
|
||||
def checkDir
|
||||
files = file_directory(params[:path])
|
||||
render :json => {:file => files , :current => @current_dir}
|
||||
end
|
||||
end
|
||||
|
@ -38,13 +38,6 @@ class VolumeController < ApplicationController
|
||||
redirect_to '/volume/info'
|
||||
end
|
||||
|
||||
|
||||
|
||||
def checkDir
|
||||
files = file_directory(params[:path])
|
||||
render :json => {:file => files , :current => @current_dir}
|
||||
end
|
||||
|
||||
def volume_mount
|
||||
@config = get_conf
|
||||
volume_name = params[:volume_name]
|
||||
|
@ -207,7 +207,7 @@
|
||||
function change_directory(directory){
|
||||
$.ajax({
|
||||
method: "POST",
|
||||
url: "/volume/changeDir",
|
||||
url: "/application/changeDir",
|
||||
data: { path: directory },
|
||||
success : function(result){
|
||||
$("#table_div").empty();
|
||||
|
@ -6,6 +6,8 @@ Rails.application.routes.draw do
|
||||
# You can have the root of your site routed with "root"
|
||||
root 'home#index'
|
||||
|
||||
post 'application/changeDir' => 'application#checkDir'
|
||||
|
||||
get 'index' => 'plainpage#index'
|
||||
|
||||
#Home
|
||||
@ -15,7 +17,6 @@ Rails.application.routes.draw do
|
||||
#Volume
|
||||
get 'volume/index' => 'volume#index'
|
||||
post 'file_upload' => 'volume#file_upload'
|
||||
post 'volume/changeDir' => 'volume#checkDir'
|
||||
post 'volume/mount' => "volume#volume_mount"
|
||||
get 'volume/start/:volume_name' => "volume#volume_start"
|
||||
get 'volume/stop/:volume_name' => "volume#volume_stop"
|
||||
|
Loading…
Reference in New Issue
Block a user