Page MenuHomeIn-Portal Phabricator

affiliate_payments_tag_processor.php
No OneTemporary

File Metadata

Created
Sat, Sep 20, 2:32 PM

affiliate_payments_tag_processor.php

<?php
/**
* @version $Id: affiliate_payments_tag_processor.php 15156 2012-03-04 09:27:14Z alex $
* @package In-Commerce
* @copyright Copyright (C) 1997 - 2009 Intechnic. All rights reserved.
* @license Commercial License
* This software is protected by copyright law and international treaties.
* Unauthorized reproduction or unlicensed usage of the code of this program,
* or any portion of it may result in severe civil and criminal penalties,
* and will be prosecuted to the maximum extent possible under the law
* See http://www.in-portal.org/commercial-license for copyright notices and details.
*/
defined('FULL_PATH') or die('restricted access!');
class AffiliatePaymentsTagProcessor extends kDBTagProcessor {
/**
* Returns url for editing user from current record
*
* @param Array $params
* @return string
*/
function UserLink($params)
{
$object = $this->getObject($params);
$user_id = $object->GetDBField('PortalUserId');
if (!$user_id) {
return '';
}
$url_params = Array (
'm_opener' => 'd',
'u_mode' => 't',
'u_event' => 'OnEdit',
'u_id' => $user_id,
'pass' => 'all,u'
);
return $this->Application->HREF($params['edit_template'], '', $url_params);
}
function ListPayments($params)
{
$o = '';
$params['render_as'] = $params['item_render_as'];
$o_payments = $this->PrintList($params);
if ($o_payments)
{
$payments_params = Array('name' => $params['header_render_as']);
$o = $this->Application->ParseBlock($payments_params);
$o .= $o_payments;
}
else
{
$payments_params = array('name' => $params['empty_mypayments_render_as']);
$o = $this->Application->ParseBlock($payments_params);
}
return $o;
}
}

Event Timeline