From aa1b585354d1d0c3b81d08e266001534c2d0ff3e Mon Sep 17 00:00:00 2001 From: bergware Date: Tue, 20 Aug 2019 07:27:42 +0200 Subject: [PATCH 1/6] Add share access to user edit --- plugins/dynamix/UserEdit.page | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/plugins/dynamix/UserEdit.page b/plugins/dynamix/UserEdit.page index 81f3f8129..13f2b25f0 100644 --- a/plugins/dynamix/UserEdit.page +++ b/plugins/dynamix/UserEdit.page @@ -181,12 +181,12 @@ foreach ($users as $user) { } foreach ($shares as $share => $data) { echo "security[\"$share\"]=\"{$sec[$share]['security']}\";\n"; - echo "readList[\"$share\"]=\"{$sec[$share]['readList']},\";\n"; - echo "writeList[\"$share\"]=\"{$sec[$share]['writeList']},\";\n"; + echo "readList[\"$share\"]=\",{$sec[$share]['readList']},\";\n"; + echo "writeList[\"$share\"]=\",{$sec[$share]['writeList']},\";\n"; } ?> function updateAccess(form,data,n,i) { - var name = ","; + var name = ",,"; if (data) { if (n' : ''; break; case 'private': - if (user+',' == name) access = $(this).val(); + if (','+user+',' == name) access = $(this).val(); else access = writeList[share].indexOf(name)!==-1 ? '' : (readList[share].indexOf(name)!==-1 ? '' : ''); break; } From 9f3959381c4bee7c6d00797453faac5cbcc0690f Mon Sep 17 00:00:00 2001 From: bergware Date: Tue, 20 Aug 2019 09:08:29 +0200 Subject: [PATCH 2/6] Added cache and disk type to shares page --- plugins/dynamix/DiskList.page | 6 +++--- plugins/dynamix/ShareList.page | 6 +++--- plugins/dynamix/include/DiskList.php | 10 +++++++--- plugins/dynamix/include/ShareList.php | 10 +++++++--- 4 files changed, 20 insertions(+), 12 deletions(-) diff --git a/plugins/dynamix/DiskList.page b/plugins/dynamix/DiskList.page index b564c690a..6ff9122d5 100644 --- a/plugins/dynamix/DiskList.page +++ b/plugins/dynamix/DiskList.page @@ -4,8 +4,8 @@ Tag="user-circle-o" Cond="$var['fsState']!='Stopped' && $var['shareDisk']!='no'" --- - +

diff --git a/plugins/dynamix/ShareList.page b/plugins/dynamix/ShareList.page index 0a65805b7..09d9201e7 100644 --- a/plugins/dynamix/ShareList.page +++ b/plugins/dynamix/ShareList.page @@ -4,8 +4,8 @@ Tag="user-circle" Cond="$var['fsState']!='Stopped' && $var['shareUser']=='e'" --- - +

diff --git a/plugins/dynamix/include/DiskList.php b/plugins/dynamix/include/DiskList.php index 3a2f74d89..44d0691a5 100644 --- a/plugins/dynamix/include/DiskList.php +++ b/plugins/dynamix/include/DiskList.php @@ -1,6 +1,6 @@ $disk) { echo "".disk_share_settings($var['shareNFSEnabled'], $sec_nfs[$name]).""; echo "".disk_share_settings($var['shareAFPEnabled'], $sec_afp[$name]).""; $cmd="/webGui/scripts/disk_size"."&arg1=".urlencode($name)."&arg2=ssz2"; + $type = $disk['rotational'] ? 'HDD' : 'SSD'; if (array_key_exists($name, $ssz2)) { + echo "$type"; echo "".my_scale(($disk['fsSize'])*1024, $unit)." $unit"; echo "".my_scale($disk['fsFree']*1024, $unit)." $unit"; echo ""; @@ -106,12 +108,14 @@ foreach ($disks as $name => $disk) { echo ""; echo ""; echo ""; + echo ""; echo "".my_scale($sharesize*1024, $unit)." $unit"; echo "".my_scale($disk['fsFree']*1024, $unit)." $unit"; echo ""; echo ""; } } else { + echo "$type"; echo "Compute..."; echo "".my_scale($disk['fsFree']*1024, $unit)." $unit"; echo ""; @@ -119,6 +123,6 @@ foreach ($disks as $name => $disk) { } } if ($row==0) { - echo "There are no exportable disk shares"; + echo "There are no exportable disk shares"; } ?> diff --git a/plugins/dynamix/include/ShareList.php b/plugins/dynamix/include/ShareList.php index 8d5f69a4c..a78d18eca 100644 --- a/plugins/dynamix/include/ShareList.php +++ b/plugins/dynamix/include/ShareList.php @@ -1,6 +1,6 @@ $share) { echo "".user_share_settings($var['shareNFSEnabled'], $sec_nfs[$name]).""; echo "".user_share_settings($var['shareAFPEnabled'], $sec_afp[$name]).""; $cmd="/webGui/scripts/share_size"."&arg1=".urlencode($name)."&arg2=ssz1"; + $cache = ucfirst($share['useCache']); if (array_key_exists($name, $ssz1)) { + echo "$cache"; echo "".my_scale($ssz1[$name]['disk.total']*1024, $unit)." $unit"; echo "".my_scale($share['free']*1024, $unit)." $unit"; echo ""; @@ -107,12 +109,14 @@ foreach ($shares as $name => $share) { echo ""; echo ""; echo ""; + echo ""; echo "".my_scale($disksize*1024, $unit)." $unit"; echo "".my_scale($disks[$diskname]['fsFree']*1024, $unit)." $unit"; echo ""; echo ""; } } else { + echo "$cache"; echo "Compute..."; echo "".my_scale($share['free']*1024, $unit)." $unit"; echo ""; @@ -120,5 +124,5 @@ foreach ($shares as $name => $share) { } } if ($row==0) { - echo "There are no exportable user shares"; + echo "There are no exportable user shares"; } From 36a4abd26e04fc16de124e90a2a92a55ee39abfa Mon Sep 17 00:00:00 2001 From: bergware Date: Tue, 20 Aug 2019 16:10:05 +0200 Subject: [PATCH 3/6] Aligned management page layout --- plugins/dynamix/ManagementAccess.page | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/plugins/dynamix/ManagementAccess.page b/plugins/dynamix/ManagementAccess.page index 2320a13f8..e373c84dc 100644 --- a/plugins/dynamix/ManagementAccess.page +++ b/plugins/dynamix/ManagementAccess.page @@ -4,8 +4,8 @@ Icon="icon-key" Tag="expeditedssl" --- -