2
0
mirror of https://github.com/ACSPRI/queXS synced 2024-04-02 12:12:16 +00:00

Replace date time hardcoding with defaults from config

Add operator and respondent details to core replacements in Limesurvey expression manager (need to use capitalisation)
This commit is contained in:
Adam Zammit
2013-03-27 11:02:23 +11:00
parent c3e5570444
commit 7cb7de5d16
2 changed files with 6 additions and 3 deletions

View File

@@ -632,7 +632,10 @@ function quexs_core_replace()
$core['PERCCOMPLETE'] = round(get_percent_complete($case_id),0); $core['PERCCOMPLETE'] = round(get_percent_complete($case_id),0);
$core['ENDINTERVIEWURL'] = get_end_interview_url(); $core['ENDINTERVIEWURL'] = get_end_interview_url();
$core['STARTINTERVIEWURL'] = get_start_interview_url(); $core['STARTINTERVIEWURL'] = get_start_interview_url();
$core['OPERATOR:FIRSTNAME'] = get_operator_variable('firstName',$operator_id);
$core['OPERATOR:LASTNAME'] = get_operator_variable('lastName',$operator_id);
$core['RESPONDENT:FIRSTNAME'] = get_respondent_variable('firstName',$respondent_id);
$core['RESPONDENT:LASTNAME'] = get_respondent_variable('lastName',$respondent_id);
return $core; return $core;
} }

View File

@@ -76,7 +76,7 @@ if (AUTO_LOGOUT_MINUTES !== false)
xhtml_head(T_("Status"),true,array("css/status.css"),$js,$btext,60); xhtml_head(T_("Status"),true,array("css/status.css"),$js,$btext,60);
print "<div class='text'>" . get_operator_time($operator_id,"%a %d %b %h:%i%p") ."</div>"; print "<div class='text'>" . get_operator_time($operator_id,DATE_TIME_FORMAT) ."</div>";
//need to determine VoIP status by confirming with the VoIP server if this operator is online //need to determine VoIP status by confirming with the VoIP server if this operator is online
@@ -124,7 +124,7 @@ else if ($state == 3)
$ca = get_call_attempt($operator_id,false); $ca = get_call_attempt($operator_id,false);
if ($ca) if ($ca)
{ {
print "<div class='text'>" . get_respondent_time(get_respondent_id($ca),"%h:%i%p") ."</div>"; print "<div class='text'>" . get_respondent_time(get_respondent_id($ca),TIME_FORMAT) ."</div>";
if (is_on_appointment($ca)) print "<div class='online statusbutton'>" . T_("APPT") . "</div>"; if (is_on_appointment($ca)) print "<div class='online statusbutton'>" . T_("APPT") . "</div>";
if (missed_appointment($ca)) print "<div class='tobecoded statusbutton'>" . T_("MISSED") . "</div>"; if (missed_appointment($ca)) print "<div class='tobecoded statusbutton'>" . T_("MISSED") . "</div>";
} }