add call duration to the active calls page (#7191)
* add call duration to the active calls page * add duration label for active calls
This commit is contained in:
parent
f0837e173b
commit
014adb461b
|
|
@ -650,6 +650,33 @@ $text['label-eavesdrop']['zh-cn'] = "窃听";
|
|||
$text['label-eavesdrop']['ja-jp'] = "盗聴";
|
||||
$text['label-eavesdrop']['ko-kr'] = "엿듣다";
|
||||
|
||||
$text['label-duration']['en-us'] = "Duration";
|
||||
$text['label-duration']['en-gb'] = "Duration";
|
||||
$text['label-duration']['ar-eg'] = "المدة";
|
||||
$text['label-duration']['de-at'] = "Dauer";
|
||||
$text['label-duration']['de-ch'] = "Dauer";
|
||||
$text['label-duration']['de-de'] = "Dauer";
|
||||
$text['label-duration']['el-gr'] = "Διάρκεια";
|
||||
$text['label-duration']['es-cl'] = "Duración";
|
||||
$text['label-duration']['es-mx'] = "Duración";
|
||||
$text['label-duration']['fr-ca'] = "Durée";
|
||||
$text['label-duration']['fr-fr'] = "Durée";
|
||||
$text['label-duration']['he-il'] = "משך השיחה";
|
||||
$text['label-duration']['it-it'] = "Durata";
|
||||
$text['label-duration']['ka-ge'] = "ხანგრძლივობა";
|
||||
$text['label-duration']['nl-nl'] = "Duur";
|
||||
$text['label-duration']['pl-pl'] = "Czas trwania";
|
||||
$text['label-duration']['pt-br'] = "Duração";
|
||||
$text['label-duration']['pt-pt'] = "Duração";
|
||||
$text['label-duration']['ro-ro'] = "Durată";
|
||||
$text['label-duration']['ru-ru'] = "Продолжительность";
|
||||
$text['label-duration']['sv-se'] = "Samtalstid";
|
||||
$text['label-duration']['uk-ua'] = "Тривалість";
|
||||
$text['label-duration']['tr-tr'] = "Süre";
|
||||
$text['label-duration']['zh-cn'] = "期间";
|
||||
$text['label-duration']['ja-jp'] = "間隔";
|
||||
$text['label-duration']['ko-kr'] = "지속";
|
||||
|
||||
$text['description-2']['en-us'] = "Use this to view all extensions and monitor and interact with active calls.";
|
||||
$text['description-2']['en-gb'] = "Use this to view all extensions and monitor and interact with active calls.";
|
||||
$text['description-2']['ar-eg'] = "استخدم هذا لعرض جميع الملحقات ومراقبة المكالمات النشطة والتفاعل معها.";
|
||||
|
|
|
|||
|
|
@ -170,6 +170,7 @@
|
|||
}
|
||||
echo " <th>".$text['label-profile']."</th>\n";
|
||||
echo " <th>".$text['label-created']."</th>\n";
|
||||
echo " <th>".$text['label-duration']."</th>\n";
|
||||
if ($show == 'all') {
|
||||
echo " <th>".$text['label-domain']."</th>\n";
|
||||
}
|
||||
|
|
@ -229,6 +230,24 @@
|
|||
}
|
||||
echo " <td>".escape($sip_profile)." </td>\n";
|
||||
echo " <td>".escape($created)." </td>\n";
|
||||
// Convert $created to a UNIX timestamp
|
||||
$created_timestamp = strtotime($created);
|
||||
|
||||
// Get the current timestamp
|
||||
$now = time();
|
||||
|
||||
// Calculate elapsed seconds
|
||||
$elapsed_seconds = $now - $created_timestamp;
|
||||
|
||||
// Convert seconds to hours, minutes, and seconds
|
||||
$hours = floor($elapsed_seconds / 3600);
|
||||
$minutes = floor(($elapsed_seconds % 3600) / 60);
|
||||
$seconds = $elapsed_seconds % 60;
|
||||
|
||||
// Format the elapsed time as HH:MM:SS
|
||||
$elapsed_time = sprintf('%02d:%02d:%02d', $hours, $minutes, $seconds);
|
||||
|
||||
echo " <td>".escape($elapsed_time)."</td>\n";
|
||||
if ($show == 'all') {
|
||||
echo " <td>".escape($domain_name)." </td>\n";
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue