Ejemplo n.º 1
0
     echo '<h1>File dont exist</h1>';
     return;
 }
 $list = TaskQueue::getQueuedTasks($fileId);
 if (!empty($list)) {
     echo '<h1>' . count($list) . ' queued actions</h1>';
     foreach ($list as $row) {
         echo '<h3>Was enqueued ' . ago($row['timeCreated']) . ' by ' . Users::link($row['creatorId']);
         echo ' type=' . $row['orderType'] . ', params=' . $row['orderParams'];
         echo '</h3>';
     }
 } else {
     echo '<h1>No queued action</h1>';
 }
 echo 'Process log:<br/>';
 $list = TaskQueue::getLog($fileId);
 echo '<table border="1">';
 echo '<tr>';
 echo '<th>Added</th>';
 echo '<th>Completed</th>';
 echo '<th>Exec time</th>';
 echo '<th>Type</th>';
 echo '<th>Created by</th>';
 echo '</tr>';
 foreach ($list as $row) {
     echo '<tr>';
     echo '<td>' . $row['timeCreated'] . '</td>';
     if ($row['orderStatus'] == ORDER_COMPLETED) {
         echo '<td>' . $row['timeCompleted'] . '</td>';
         echo '<td>' . round($row['timeExec'], 3) . 's</td>';
     } else {