FIX#30491 token not set to launch cron task manually (#30492)

This commit is contained in:
IC-Ilies 2024-07-31 15:36:07 +02:00 committed by GitHub
parent 84dff519b6
commit 3fda1ce4c0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -731,7 +731,7 @@ if ($num > 0) {
}
if ($user->hasRight('cron', 'execute')) {
if (!empty($obj->status)) {
print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?id='.$obj->rowid.'&action=execute';
print '<a class="reposition" href="'.$_SERVER["PHP_SELF"].'?id='.$obj->rowid.'&action=execute&token='.newToken();
print(!getDolGlobalString('CRON_KEY') ? '' : '&securitykey=' . getDolGlobalString('CRON_KEY'));
print($sortfield ? '&sortfield='.$sortfield : '');
print($sortorder ? '&sortorder='.$sortorder : '');