From 064bf5dde0497b5fe283ffc57a626a21e3b13c46 Mon Sep 17 00:00:00 2001 From: Tamas Cseke Date: Wed, 19 Mar 2014 11:01:22 +0100 Subject: [PATCH] FS-6371 --resolve json cdr is missing some caller profile times --- src/switch_ivr.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/switch_ivr.c b/src/switch_ivr.c index 664b56fd4b..01b8775846 100644 --- a/src/switch_ivr.c +++ b/src/switch_ivr.c @@ -2862,6 +2862,15 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_generate_json_cdr(switch_core_session switch_snprintf(tmp, sizeof(tmp), "%" SWITCH_TIME_T_FMT, caller_profile->times->answered); cJSON_AddItemToObject(j_times, "answered_time", cJSON_CreateString(tmp)); + switch_snprintf(tmp, sizeof(tmp), "%" SWITCH_TIME_T_FMT, caller_profile->times->bridged); + cJSON_AddItemToObject(j_times, "bridged_time", cJSON_CreateString(tmp)); + + switch_snprintf(tmp, sizeof(tmp), "%" SWITCH_TIME_T_FMT, caller_profile->times->last_hold); + cJSON_AddItemToObject(j_times, "last_hold_time", cJSON_CreateString(tmp)); + + switch_snprintf(tmp, sizeof(tmp), "%" SWITCH_TIME_T_FMT, caller_profile->times->hold_accum); + cJSON_AddItemToObject(j_times, "hold_accum_time", cJSON_CreateString(tmp)); + switch_snprintf(tmp, sizeof(tmp), "%" SWITCH_TIME_T_FMT, caller_profile->times->hungup); cJSON_AddItemToObject(j_times, "hangup_time", cJSON_CreateString(tmp));