Document: Fix multiple delete function - refs #3605

pull/3643/head
carlos alvarado 6 years ago committed by GitHub
parent a037ee8205
commit 7b83036064
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      main/document/document.php
  2. 2
      main/inc/lib/document.lib.php

@ -37,7 +37,7 @@ $parent_id = null;
$lib_path = api_get_path(LIBRARY_PATH);
$actionsRight = '';
$action = isset($_REQUEST['action']) ? $_REQUEST['action'] : '';
if (isset($_POST['currentFile'])) {
if (isset($_POST['currentFile']) && !empty($_POST['currentFile']) && empty($action)) {
$action = 'replace';
}
$allowUseTool = false;

@ -5689,7 +5689,7 @@ class DocumentManager
);
$form->addElement('html', "<div class='replaceIndividualFile upload_element_".$randomUploadName." hidden'>");
$form->addElement('hidden', 'id_'.$randomUploadName, $randomUploadName);
$form->addElement('hidden', 'currentFile', $randomUploadName);
$form->addElement('hidden', 'currentFile', '');
$form->addElement('hidden', 'currentUrl', api_get_self().'?'.api_get_cidreq().'&id='.$document_id);
$form->addElement('hidden', 'id_'.$randomUploadName, $document_id);
$label = '';

Loading…
Cancel
Save