Revision 53d80f2a
Von Moritz Bunkus vor mehr als 10 Jahren hinzugefügt
bin/mozilla/ct.pl | ||
---|---|---|
48 | 48 |
use POSIX qw(strftime); |
49 | 49 |
|
50 | 50 |
use SL::CT; |
51 |
use SL::CTI; |
|
51 | 52 |
use SL::CVar; |
52 | 53 |
use SL::Request qw(flatten); |
53 | 54 |
use SL::DB::Business; |
... | ... | |
268 | 269 |
my $column = $ref->{formtype} eq 'invoice' ? 'invnumber' : $ref->{formtype} eq 'order' ? 'ordnumber' : 'quonumber'; |
269 | 270 |
$row->{$column}->{data} = $ref->{$column}; |
270 | 271 |
|
272 |
if (my $number = SL::CTI->sanitize_number(number => $ref->{phone})) { |
|
273 |
$row->{phone}->{link} = SL::CTI->call_link(number => $number); |
|
274 |
$row->{phone}->{link_class} = 'cti_call_action'; |
|
275 |
} |
|
276 |
|
|
271 | 277 |
$report->add_data($row); |
272 | 278 |
} |
273 | 279 |
|
... | ... | |
392 | 398 |
$row->{$_}->{link} = 'mailto:' . E($ref->{$_}) if $ref->{$_}; |
393 | 399 |
} |
394 | 400 |
|
401 |
for (qw(cp_phone1 cp_phone2 cp_mobile1)) { |
|
402 |
next unless my $number = SL::CTI->sanitize_number(number => $ref->{$_}); |
|
403 |
|
|
404 |
$row->{$_}->{link} = SL::CTI->call_link(number => $number); |
|
405 |
$row->{$_}->{link_class} = 'cti_call_action'; |
|
406 |
} |
|
407 |
|
|
395 | 408 |
$report->add_data($row); |
396 | 409 |
} |
397 | 410 |
|
Auch abrufbar als: Unified diff
Generische Unterstützung für CTI: Click-to-dial