0) {
+ return true;
+ } else {
+ alert("$lt{'none'}");
+ return false;
+ }
+}
+
END
}
@@ -2351,24 +2375,30 @@ sub editor {
my ($paste_res,$save_error,$pastemsgarray,$lockerror) =
&do_paste_from_buffer($coursenum,$coursedom,$folder,$container,
\%paste_errors);
- if (ref($pastemsgarray) eq 'ARRAY') {
- if (@{$pastemsgarray} > 0) {
-
- $r->print(''.
- join('
',@{$pastemsgarray}).
- '
');
- }
- }
- if ($lockerror) {
- $r->print(''.
- $lockerror.
+ if (ref($pastemsgarray) eq 'ARRAY') {
+ if (@{$pastemsgarray} > 0) {
+ $r->print('
'.
+ join('
',@{$pastemsgarray}).
'
');
}
- if ($save_error ne '') {
- return $save_error;
+ }
+ if ($lockerror) {
+ $r->print(''.
+ $lockerror.
+ '
');
+ }
+ if ($save_error ne '') {
+ return $save_error;
+ }
+ if ($paste_res) {
+ my %errortext = &Apache::lonlocal::texthash (
+ fail => 'Storage of folder contents failed',
+ failread => 'Reading folder contents failed',
+ failstore => 'Storage of folder contents failed',
+ );
+ if ($errortext{$paste_res}) {
+ $r->print(''.$errortext{$paste_res}.'
');
}
- if ($paste_res ne 'ok') {
- $r->print(''.$paste_res.'
');
}
if (keys(%paste_errors) > 0) {
$r->print(''."\n".
@@ -3036,7 +3066,7 @@ ENDCOPY
$copylink=(<
$form_common
-$lt{'cp'}
+$lt{'cp'}
$form_end
ENDCOPY
if (($ishash) && (ref($filtersref->{'cancopy'}) eq 'ARRAY')) {
@@ -3053,7 +3083,7 @@ ENDCUT
$cutlink=(<
$form_common
-$lt{'ct'}
+$lt{'ct'}
$form_end
ENDCUT
if (($ishash) && (ref($filtersref->{'cancut'}) eq 'ARRAY')) {
@@ -3070,7 +3100,7 @@ ENDREM
$removelink=(<
$form_common
-$lt{'rm'}
+$lt{'rm'}
$form_end
ENDREM
if (($ishash) && (ref($filtersref->{'canremove'}) eq 'ARRAY')) {
@@ -3102,11 +3132,10 @@ ENDREN
$selectbox
$form_end
-
+ |
$removelink
$cutlink
$copylink
-
|
END
}