<?
function panel_send_report_td($send_report=[])
{
    switch ($send_report['status']) {
        case 0:     $status_class = 'blue';     break;
        case 1:     $status_class = 'green';    break;
        default :   $status_class = 'red';      break;
    }
    if (_sizeof($send_report)) {
        ?>
        <td class="left">
            <a href="/cab/send_report/report/<?echo $send_report['pkey'] ?>/"><?echo $send_report['obj_name'] ?></a>
        </td>
        <td>
            <?echo $send_report['class_name'] ?>
        </td>
        <td class="<?echo $status_class ?> bold">
            <div class="cnt_senders">
                <? $cnt_senders = SEND_REPORT()->get_count_active_senders($send_report['pkey']); ?>
                <!--            --><?//echo SEND_REPORT()->report_status[$send_report['status']] ?>
                <span data-content="Общее кол-во отправок"><i class="fa fa-list-ol"></i><? echo count(SEND_REPORT()->get_senders_by_send_report_id($send_report['pkey'])); ?></span>
                <span data-content="Кол-во включенных отправок"><i class="fa fa-thumbs-up"></i><? echo $cnt_senders ?></span>
                <span data-content="Кол-во не настроенных отправок"><i class="fa fa-ban"></i> <? echo SEND_REPORT()->get_count_disabled_senders($send_report['pkey'])?></span>
            </div>
        </td>
        <td>
            <? if ($cnt_senders > 0) { ?>
                <span data-content="Ближайшая отправка"><i class="fa fa-clock-o"></i>
                <? echo SEND_REPORT()->get_next_sender($send_report['pkey']); ?>
                </span>
                <?} else {?><i class="fa fa-minus"></i><?}?>
        </td>
        <?
    }
}
?>
