add of seteventmessages
This commit is contained in:
parent
bb2aa2701a
commit
cf88987c52
@ -3383,9 +3383,12 @@ function dragAndDropFileUpload($htmlname)
|
|||||||
data:fd,
|
data:fd,
|
||||||
success:function(){
|
success:function(){
|
||||||
console.log("Uploaded.",arguments);
|
console.log("Uploaded.",arguments);
|
||||||
window.location.href = "'.$_SERVER["PHP_SELF"].'?id='.dol_escape_json($object->id).'";
|
window.location.href = "'.$_SERVER["PHP_SELF"].'?id='.dol_escape_json($object->id).'&seteventmessages=uploadFileDragDropSuccess:mesgs";
|
||||||
|
},
|
||||||
|
error:function(){
|
||||||
|
console.log("Error Uploading.",arguments)
|
||||||
|
window.location.href = "'.$_SERVER["PHP_SELF"].'?id='.dol_escape_json($object->id).'&seteventmessages=uploadFileDragDropError:errors";
|
||||||
},
|
},
|
||||||
error:function(){ console.log("Error Uploading.",arguments) },
|
|
||||||
})
|
})
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@ -1228,3 +1228,5 @@ PublicVirtualCardUrl=Virtual business card page URL
|
|||||||
PublicVirtualCard=Virtual business card
|
PublicVirtualCard=Virtual business card
|
||||||
TreeView=Tree view
|
TreeView=Tree view
|
||||||
DropFileToAddItToObject=Drop a file to add it to this object
|
DropFileToAddItToObject=Drop a file to add it to this object
|
||||||
|
uploadFileDragDropSuccess=The file(s) have been uploaded successfully
|
||||||
|
uploadFileDragDropError=There was an error while the file(s) upload
|
||||||
|
|||||||
@ -1388,7 +1388,14 @@ if (!defined('NOREQUIREMENU')) {
|
|||||||
$menumanager->loadMenu();
|
$menumanager->loadMenu();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!empty(GETPOST('seteventmessages', 'alpha'))) {
|
||||||
|
$message = GETPOST('seteventmessages', 'alpha');
|
||||||
|
$messages = explode(',', $message);
|
||||||
|
foreach ($messages as $key => $msg) {
|
||||||
|
$tmp = explode(':', $msg);
|
||||||
|
setEventMessages($tmp[0], null, !empty($tmp[1]) ? $tmp[1] : 'mesgs');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Functions
|
// Functions
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user