コード例 #1
0
ファイル: posting_bcc.php プロジェクト: DarneoStudio/bitrix
            continue;
        }
        switch ($_REQUEST['action']) {
            case "sudelete":
                CSubscription::Delete($SUBSCR_ID);
                break;
            case "inactive":
                $oSubscription = new CSubscription();
                $oSubscription->Update($SUBSCR_ID, array("ACTIVE" => "N"));
                break;
        }
    }
}
$lAdmin->AddHeaders(array(array("id" => "EMAIL", "content" => GetMessage("POST_EMAIL"), "default" => true), array("id" => "SUBSCRIPTION_ID", "content" => GetMessage("POST_SUBSCRIPTION_ID"), "default" => true, "align" => "right"), array("id" => "USER_ID", "content" => GetMessage("POST_USER_ID"), "default" => true, "align" => "right")));
$cData = new CPosting();
$rsData = $cData->GetEmailsByStatus($ID, $find_status_id);
$rsData = new CAdminResult($rsData, $sTableID);
$rsData->NavStart();
$lAdmin->NavText($rsData->GetNavPrint(""));
while ($arRes = $rsData->NavNext(true, "f_")) {
    $row =& $lAdmin->AddRow($f_EMAIL, $arRes);
    if ($f_SUBSCRIPTION_ID > 0) {
        $rs = CSubscription::GetByID($f_SUBSCRIPTION_ID);
        $ar = $rs->Fetch();
        if (!$ar) {
            $row->AddViewField("SUBSCRIPTION_ID", $f_SUBSCRIPTION_ID . ' (' . GetMessage("POST_SUBSCR_DELETED") . ')');
        } elseif ($ar["ACTIVE"] == "N") {
            $row->AddViewField("SUBSCRIPTION_ID", '<a target="_blank" href="subscr_edit.php?lang=' . LANGUAGE_ID . '&amp;ID=' . $f_SUBSCRIPTION_ID . '">' . $f_SUBSCRIPTION_ID . '</a> (' . GetMessage("POST_SUBSCR_INACTIVE") . ')');
        } else {
            $row->AddViewField("SUBSCRIPTION_ID", '<a target="_blank" href="subscr_edit.php?lang=' . LANGUAGE_ID . '&amp;ID=' . $f_SUBSCRIPTION_ID . '">' . $f_SUBSCRIPTION_ID . '</a>');
        }