本文整理汇总了PHP中Operator::load方法的典型用法代码示例。如果您正苦于以下问题:PHP Operator::load方法的具体用法?PHP Operator::load怎么用?PHP Operator::load使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Operator
的用法示例。
在下文中一共展示了Operator::load方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: template_new_ggi_mail
public static function template_new_ggi_mail($param, $is_resend = false)
{
$param = json_decode(json_encode($param), FALSE);
$user_name = str_replace('@gameloft.com', '', $_SERVER['REMOTE_USER']);
$user_name = str_replace('.', ' ', ucfirst($user_name));
$to[] = $_SERVER['REMOTE_USER'];
if (ENVIRONMENT == GOLD || ENVIRONMENT == STAGING) {
$cc[] = MAIL_WOA;
$bcc[] = 'usmar.soto@gameloft.com';
}
$platform = Platform::load($param->platform_id)->to_array();
$operator = Operator::load($param->operator_id)->to_array();
$country = Country::load($param->country_id)->to_array();
$product = Product::load($param->product_id)->to_array();
$store = Appstores::load($param->store_id)->to_array();
$template_params = array();
$template_params['user_name'] = $user_name;
$template_params['platform_name'] = $platform['name'];
$template_params['operator_name'] = $operator['name'];
$template_params['country_name'] = $country['name'];
$template_params['product_name'] = $product['name'];
$template_params['product_id'] = $param->product_id;
$template_params['ggi'] = $param->ggi;
$template_params['store_name'] = $store['name'];
$template_params['deployment_silo'] = $param->deployment_silo;
$tpl = (object) $template_params;
//Get email template
ob_start();
$subject = 'TUNA - Request of new project (GGI): ' . $param->ggi;
include_once 'mail_templates/new_project.php';
$body = ob_get_contents();
ob_end_clean();
//Send the email
$m = new Mail('text/html');
$m->to(@implode(',', $to));
$m->cc(@implode(',', $cc));
$m->bcc(@implode(',', $bcc));
$m->subject($subject);
$m->body($body);
$m->send();
TunaLog::info_log(__CLASS__, __FUNCTION__, $_SERVER['REMOTE_USER'], '');
}