diff --git a/plugins/dynamix/ArrayOperation.page b/plugins/dynamix/ArrayOperation.page index 874b2427c..70cfb480d 100644 --- a/plugins/dynamix/ArrayOperation.page +++ b/plugins/dynamix/ArrayOperation.page @@ -15,6 +15,8 @@ Tag="snowflake-o" */ ?> "; echo ""; @@ -39,10 +41,14 @@ var ask1 = ; var ask2 = ; var ctrl = ""; -function verify(form) { - swal({title:'Found wrong encryption key',text:'Format unmountable disk(s) and ERASE ALL data?',type:'warning',showCancelButton:true},function(){ - $(form).append(''); - form.submit(); +function verify(form,hide) { + swal({title:'Found wrong encryption key',text:'Format unmountable disk(s) and erase all data?',type:'warning',confirmButtonText:'Format',cancelButtonText:'Ignore',showCancelButton:true},function(p){ + if (p) { + $(form).append(''); + form.submit(); + } else { + $.post('/webGui/include/HideFormatButton.php',{hide:hide},function(){refresh();}); + } }); } function tab0() { @@ -80,9 +86,9 @@ function parity_warning(form) { function stop_array(form) { $(form).append(''); if (ask1) { - swal({title:'Proceed?',text:'This will stop the array',type:'warning',showCancelButton:true},function(p){if (p) form.submit(); else $('input[name="cmdStop"]').remove();}); + swal({title:'Proceed?',text:'This will stop the array',type:'warning',showCancelButton:true},function(p){if (p) $.post('/webGui/include/HideFormatButton.php',{hide:'no'},function(){form.submit();}); else $('input[name="cmdStop"]').remove();}); } else { - form.submit(); + $.post('/webGui/include/HideFormatButton.php',{hide:'no'},function(){form.submit();}); } } function stop_parity(form,text) { @@ -144,17 +150,18 @@ toggle_diskio(true); disabled> Stop will take the array off-line.$parity":($mover?"
$mover":"")?> -0):?> +0 && !file_exists($hide)):?> Unmountable disk present:
".my_disk($disk['name'])." • ".my_id($disk['id'])." (".$disk['device'].")"; - if (strpos($disk['fsStatus'],'Wrong')!==false) $verify = true; + if (strpos($disk['fsStatus'],'Wrong')!==false) $verify = true; else $yesno = 'no'; } ?> - + diff --git a/plugins/dynamix/DeviceInfo.page b/plugins/dynamix/DeviceInfo.page index 52661d0c3..fa43b70f4 100644 --- a/plugins/dynamix/DeviceInfo.page +++ b/plugins/dynamix/DeviceInfo.page @@ -215,7 +215,7 @@ btrfs filesystem show: : ".shell_exec("/sbin/btrfs filesystem show {$disk['uuid']}")."";?> - +
Balance Status
@@ -261,12 +261,12 @@ btrfs balance status:   -: **Balance** is only available when array is Started. +: Balance is only available when array is Started." : "See Cache Settings."?>
- +
Scrub Status
@@ -303,12 +303,12 @@ btrfs scrub status:   -: **Scrub** is only available when array is Started. +: Scrub is only available when array is Started." : "See Cache Settings."?>
- +
Check Filesystem Status
@@ -351,12 +351,12 @@ btrfs check status:   -: **Check** is only available when array is Started in **Maintenance** mode. +: Check is only available when array is Started in Maintenance mode." : "See Cache Settings."?>
- +
Check Filesystem Status
@@ -405,7 +405,7 @@ reiserfsck status:
- +
Check Filesystem Status
diff --git a/plugins/dynamix/include/HideFormatButton.php b/plugins/dynamix/include/HideFormatButton.php new file mode 100644 index 000000000..2d9d78e02 --- /dev/null +++ b/plugins/dynamix/include/HideFormatButton.php @@ -0,0 +1,21 @@ + +