本文整理汇总了PHP中datenull函数的典型用法代码示例。如果您正苦于以下问题:PHP datenull函数的具体用法?PHP datenull怎么用?PHP datenull使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了datenull函数的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: order
function order()
{
$jshopConfig = JSFactory::getConfig();
checkUserLogin();
$db = JFactory::getDBO();
$user = JFactory::getUser();
$lang = JSFactory::getLang();
JPluginHelper::importPlugin('jshoppingorder');
$dispatcher = JDispatcher::getInstance();
appendPathWay(_JSHOP_MY_ORDERS, SEFLink('index.php?option=com_jshopping&controller=user&task=orders', 0, 0, $jshopConfig->use_ssl));
$seo = JTable::getInstance("seo", "jshop");
$seodata = $seo->loadData("myorder-detail");
if ($seodata->title == "") {
$seodata->title = _JSHOP_MY_ORDERS;
}
setMetaData($seodata->title, $seodata->keyword, $seodata->description);
$order_id = JRequest::getInt('order_id');
$order = JTable::getInstance('order', 'jshop');
$order->load($order_id);
$dispatcher->trigger('onAfterLoadOrder', array(&$order, &$user));
appendPathWay(_JSHOP_ORDER_NUMBER . ": " . $order->order_number);
if ($user->id != $order->user_id) {
JError::raiseError(500, "Error order number. You are not the owner of this order");
}
$order->items = $order->getAllItems();
$order->weight = $order->getWeightItems();
$order->status_name = $order->getStatus();
$order->history = $order->getHistory();
if ($jshopConfig->client_allow_cancel_order && $order->order_status != $jshopConfig->payment_status_for_cancel_client && !in_array($order->order_status, $jshopConfig->payment_status_disable_cancel_client)) {
$allow_cancel = 1;
} else {
$allow_cancel = 0;
}
$order->birthday = getDisplayDate($order->birthday, $jshopConfig->field_birthday_format);
$order->d_birthday = getDisplayDate($order->d_birthday, $jshopConfig->field_birthday_format);
$shipping_method = JTable::getInstance('shippingMethod', 'jshop');
$shipping_method->load($order->shipping_method_id);
$name = $lang->get("name");
$description = $lang->get("description");
$order->shipping_info = $shipping_method->{$name};
$pm_method = JTable::getInstance('paymentMethod', 'jshop');
$pm_method->load($order->payment_method_id);
$order->payment_name = $pm_method->{$name};
if ($pm_method->show_descr_in_email) {
$order->payment_description = $pm_method->{$description};
} else {
$order->payment_description = "";
}
$country = JTable::getInstance('country', 'jshop');
$country->load($order->country);
$field_country_name = $lang->get("name");
$order->country = $country->{$field_country_name};
$d_country = JTable::getInstance('country', 'jshop');
$d_country->load($order->d_country);
$field_country_name = $lang->get("name");
$order->d_country = $d_country->{$field_country_name};
$jshopConfig->user_field_client_type[0] = "";
$order->client_type_name = $jshopConfig->user_field_client_type[$order->client_type];
$order->delivery_time_name = '';
$order->delivery_date_f = '';
if ($jshopConfig->show_delivery_time_checkout) {
$deliverytimes = JSFactory::getAllDeliveryTime();
$order->delivery_time_name = $deliverytimes[$order->delivery_times_id];
if ($order->delivery_time_name == "") {
$order->delivery_time_name = $order->delivery_time;
}
}
if ($jshopConfig->show_delivery_date && !datenull($order->delivery_date)) {
$order->delivery_date_f = formatdate($order->delivery_date);
}
$order->order_tax_list = $order->getTaxExt();
$show_percent_tax = 0;
if (count($order->order_tax_list) > 1 || $jshopConfig->show_tax_in_product) {
$show_percent_tax = 1;
}
if ($jshopConfig->hide_tax) {
$show_percent_tax = 0;
}
$hide_subtotal = 0;
if (($jshopConfig->hide_tax || count($order->order_tax_list) == 0) && $order->order_discount == 0 && $order->order_payment == 0 && $jshopConfig->without_shipping) {
$hide_subtotal = 1;
}
$text_total = _JSHOP_ENDTOTAL;
if (($jshopConfig->show_tax_in_product || $jshopConfig->show_tax_product_in_cart) && count($order->order_tax_list) > 0) {
$text_total = _JSHOP_ENDTOTAL_INKL_TAX;
}
$tmp_fields = $jshopConfig->getListFieldsRegister();
$config_fields = $tmp_fields["address"];
$count_filed_delivery = $jshopConfig->getEnableDeliveryFiledRegistration('address');
if ($jshopConfig->order_display_new_digital_products) {
$product = JTable::getInstance('product', 'jshop');
foreach ($order->items as $k => $v) {
$product->product_id = $v->product_id;
$product->setAttributeActive(unserialize($v->attributes));
$files = $product->getSaleFiles();
$order->items[$k]->files = serialize($files);
}
}
$dispatcher->trigger('onBeforeDisplayOrder', array(&$order));
$view_name = "order";
//.........这里部分代码省略.........
示例2: setInvoiceDate
function setInvoiceDate()
{
if (datenull($this->invoice_date)) {
$db = JFactory::getDBO();
$this->invoice_date = getJsDate();
$query = "UPDATE `#__jshopping_orders` SET invoice_date='" . $db->escape($this->invoice_date) . "' WHERE order_id = '" . $db->escape($this->order_id) . "'";
$db->setQuery($query);
$db->query();
}
}
示例3: show
function show()
{
$order_id = JRequest::getInt("order_id");
$lang = JSFactory::getLang();
$db = JFactory::getDBO();
$jshopConfig = JSFactory::getConfig();
$orders = $this->getModel("orders");
$order = JTable::getInstance('order', 'jshop');
$order->load($order_id);
$orderstatus = JTable::getInstance('orderStatus', 'jshop');
$orderstatus->load($order->order_status);
$name = $lang->get("name");
$order->status_name = $orderstatus->{$name};
$id_vendor_cuser = getIdVendorForCUser();
$shipping_method = JTable::getInstance('shippingMethod', 'jshop');
$shipping_method->load($order->shipping_method_id);
$name = $lang->get("name");
$order->shipping_info = $shipping_method->{$name};
$pm_method = JTable::getInstance('paymentMethod', 'jshop');
$pm_method->load($order->payment_method_id);
$order->payment_name = $pm_method->{$name};
$order_items = $order->getAllItems();
if ($jshopConfig->admin_show_vendors) {
$tmp_order_vendors = $order->getVendors();
$order_vendors = array();
foreach ($tmp_order_vendors as $v) {
$order_vendors[$v->id] = $v;
}
}
$order->weight = $order->getWeightItems();
$order_history = $order->getHistory();
$lists['status'] = JHTML::_('select.genericlist', $orders->getAllOrderStatus(), 'order_status', 'class = "inputbox" size = "1" id = "order_status"', 'status_id', 'name', $order->order_status);
$country = JTable::getInstance('country', 'jshop');
$country->load($order->country);
$field_country_name = $lang->get("name");
$order->country = $country->{$field_country_name};
$d_country = JTable::getInstance('country', 'jshop');
$d_country->load($order->d_country);
$field_country_name = $lang->get("name");
$order->d_country = $d_country->{$field_country_name};
$order->title = $jshopConfig->user_field_title[$order->title];
$order->d_title = $jshopConfig->user_field_title[$order->d_title];
$order->birthday = getDisplayDate($order->birthday, $jshopConfig->field_birthday_format);
$order->d_birthday = getDisplayDate($order->d_birthday, $jshopConfig->field_birthday_format);
$jshopConfig->user_field_client_type[0] = "";
$order->client_type_name = $jshopConfig->user_field_client_type[$order->client_type];
$order->order_tax_list = $order->getTaxExt();
if ($order->coupon_id) {
$coupon = JTable::getInstance('coupon', 'jshop');
$coupon->load($order->coupon_id);
$order->coupon_code = $coupon->coupon_code;
}
$tmp_fields = $jshopConfig->getListFieldsRegister();
$config_fields = $tmp_fields["address"];
$count_filed_delivery = $jshopConfig->getEnableDeliveryFiledRegistration('address');
$display_info_only_product = 0;
if ($jshopConfig->admin_show_vendors && $id_vendor_cuser) {
if ($order->vendor_id != $id_vendor_cuser) {
$display_info_only_product = 1;
}
}
$display_block_change_order_status = $order->order_created;
if ($jshopConfig->admin_show_vendors && $id_vendor_cuser) {
if ($order->vendor_id != $id_vendor_cuser) {
$display_block_change_order_status = 0;
}
foreach ($order_items as $k => $v) {
if ($v->vendor_id != $id_vendor_cuser) {
unset($order_items[$k]);
}
}
}
$order->delivery_time_name = '';
$order->delivery_date_f = '';
if ($jshopConfig->show_delivery_time_checkout) {
$deliverytimes = JSFactory::getAllDeliveryTime();
$order->delivery_time_name = $deliverytimes[$order->delivery_times_id];
if ($order->delivery_time_name == "") {
$order->delivery_time_name = $order->delivery_time;
}
}
if ($jshopConfig->show_delivery_date && !datenull($order->delivery_date)) {
$order->delivery_date_f = formatdate($order->delivery_date);
}
$stat_download = $order->getFilesStatDownloads(1);
JPluginHelper::importPlugin('jshoppingorder');
$dispatcher = JDispatcher::getInstance();
$dispatcher->trigger('onBeforeDisplayOrderAdmin', array(&$order, &$order_items, &$order_history));
$print = JRequest::getInt("print");
$view = $this->getView("orders", 'html');
$view->setLayout("show");
$view->assign('config', $jshopConfig);
$view->assign('order', $order);
$view->assign('order_history', $order_history);
$view->assign('order_items', $order_items);
$view->assign('lists', $lists);
$view->assign('print', $print);
$view->assign('config_fields', $config_fields);
$view->assign('count_filed_delivery', $count_filed_delivery);
$view->assign('display_info_only_product', $display_info_only_product);
//.........这里部分代码省略.........
示例4: getDisplayDate
function getDisplayDate($date, $format = '%d.%m.%Y')
{
if (datenull($date)) {
return '';
}
$adate = array(substr($date, 0, 4), substr($date, 5, 2), substr($date, 8, 2));
$str = str_replace(array("%Y", "%m", "%d"), $adate, $format);
return $str;
}
示例5: onBeforeDisplayCheckoutFinish
public function onBeforeDisplayCheckoutFinish(&$text, &$order_id)
{
$user = JFactory::getUser();
if ($user->id > 0) {
return true;
}
// Скрытие текста
$text = ' ';
// Показ гостю копии страницы из личного кабинета
// $dispatcher = JDispatcher::getInstance();
$jshopConfig = JSFactory::getConfig();
$lang = JSFactory::getLang();
$order = JTable::getInstance('order', 'jshop');
$order->load($order_id);
$order->items = $order->getAllItems();
$order->weight = $order->getWeightItems();
$order->status_name = $order->getStatus();
$order->history = $order->getHistory();
$order->order_tax_list = $order->getTaxExt();
$order->birthday = getDisplayDate($order->birthday, $jshopConfig->field_birthday_format);
$order->d_birthday = getDisplayDate($order->d_birthday, $jshopConfig->field_birthday_format);
$name = $lang->get("name");
$description = $lang->get("description");
$pm_method = JTable::getInstance('paymentMethod', 'jshop');
$pm_method->load($order->payment_method_id);
$order->payment_name = $pm_method->{$name};
if ($pm_method->show_descr_in_email) {
$order->payment_description = $pm_method->{$description};
} else {
$order->payment_description = "";
}
$country = JTable::getInstance('country', 'jshop');
$country->load($order->country);
$field_country_name = $lang->get("name");
$order->country = $country->{$field_country_name};
$d_country = JTable::getInstance('country', 'jshop');
$d_country->load($order->d_country);
$field_country_name = $lang->get("name");
$order->d_country = $d_country->{$field_country_name};
$jshopConfig->user_field_client_type[0] = "";
$order->client_type_name = $jshopConfig->user_field_client_type[$order->client_type];
$order->delivery_time_name = '';
$order->delivery_date_f = '';
if ($jshopConfig->show_delivery_time_checkout) {
$deliverytimes = JSFactory::getAllDeliveryTime();
$order->delivery_time_name = $deliverytimes[$order->delivery_times_id];
if ($order->delivery_time_name == "") {
$order->delivery_time_name = $order->delivery_time;
}
}
if ($jshopConfig->show_delivery_date && !datenull($order->delivery_date)) {
$order->delivery_date_f = formatdate($order->delivery_date);
}
if ($order->weight == 0 && $jshopConfig->hide_weight_in_cart_weight0) {
$jshopConfig->show_weight_order = 0;
}
$jshopConfig->order_send_pdf_client = 0;
$show_percent_tax = 0;
if (count($order->order_tax_list) > 1 || $jshopConfig->show_tax_in_product) {
$show_percent_tax = 1;
}
if ($jshopConfig->hide_tax) {
$show_percent_tax = 0;
}
$hide_subtotal = 0;
if (($jshopConfig->hide_tax || count($order->order_tax_list) == 0) && $order->order_discount == 0 && $order->order_payment == 0 && $jshopConfig->without_shipping) {
$hide_subtotal = 1;
}
$text_total = _JSHOP_ENDTOTAL;
if (($jshopConfig->show_tax_in_product || $jshopConfig->show_tax_product_in_cart) && count($order->order_tax_list) > 0) {
$text_total = _JSHOP_ENDTOTAL_INKL_TAX;
}
$tmp_fields = $jshopConfig->getListFieldsRegister();
$config_fields = $tmp_fields["address"];
$count_filed_delivery = $jshopConfig->getEnableDeliveryFiledRegistration('address');
$className = 'JshoppingViewOrder';
$view_name = "order";
if (!class_exists($className)) {
require_once JPATH_COMPONENT . '/views/' . $view_name . '/view.html.php';
}
$view_config = array("template_path" => $jshopConfig->template_path . $jshopConfig->template . "/" . $view_name);
$view = new $className($view_config);
$view->setLayout("order");
$view->assign('order', $order);
$view->assign('config', $jshopConfig);
$view->assign('text_total', $text_total);
$view->assign('show_percent_tax', $show_percent_tax);
$view->assign('hide_subtotal', $hide_subtotal);
$view->assign('image_path', $jshopConfig->live_path . "images");
$view->assign('config_fields', $config_fields);
$view->assign('count_filed_delivery', $count_filed_delivery);
$view->assign('allow_cancel', false);
$view->display();
return true;
}
示例6: generatePDF
//.........这里部分代码省略.........
$text_total = _JSHOP_ENDTOTAL;
if (($jshopConfig->show_tax_in_product || $jshopConfig->show_tax_product_in_cart) && count($order->order_tax_list) > 0) {
$text_total = _JSHOP_ENDTOTAL_INKL_TAX;
}
$pdf->SetFont('freesansb', '', 10);
$pdf->SetXY(20, $y + 10);
$pdf->Rect(20, $y + 10, 170, 5.1, 'F');
$pdf->MultiCell(130, 5, $text_total, '1', 'R');
$pdf->SetXY(150, $y + 10);
$pdf->MultiCell(40, 5, formatprice($order->order_total, $order->currency_code) . $order->_pdf_ext_total, '1', 'R');
if ($jshopConfig->display_tax_id_in_pdf && $order->tax_number) {
$y = $y + 5.2;
$pdf->SetFont('freesans', '', 7);
$pdf->SetXY(20, $y + 10);
$pdf->MultiCell(170, 4, _JSHOP_TAX_NUMBER . ": " . $order->tax_number, '1', 'L');
}
$dispatcher->trigger('onBeforeCreatePdfOrderAfterEndTotal', array(&$order, &$pdf, &$y));
$y = $y + 10;
if ($jshopConfig->show_delivery_time_checkout && ($order->delivery_times_id || $order->delivery_time)) {
if ($y > 250) {
$pdf->addNewPage();
$y = 60;
}
$deliverytimes = JSFactory::getAllDeliveryTime();
$delivery = $deliverytimes[$order->delivery_times_id];
if ($delivery == "") {
$delivery = $order->delivery_time;
}
$y = $y + 8;
$pdf->SetFont('freesans', '', 7);
$pdf->SetXY(20, $y);
$pdf->MultiCell(170, 4, _JSHOP_ORDER_DELIVERY_TIME . ": " . $delivery, '0', 'L');
}
if ($jshopConfig->show_delivery_date && !datenull($order->delivery_date)) {
if ($y > 250) {
$pdf->addNewPage();
$y = 60;
}
$delivery_date_f = formatdate($order->delivery_date);
$y = $y + 6;
$pdf->SetFont('freesans', '', 7);
$pdf->SetXY(20, $y);
$pdf->MultiCell(170, 4, _JSHOP_DELIVERY_DATE . ": " . $delivery_date_f, '0', 'L');
}
if ($jshopConfig->weight_in_invoice) {
if ($y > 250) {
$pdf->addNewPage();
$y = 60;
}
$y = $y + 6;
$pdf->SetFont('freesans', '', 7);
$pdf->SetXY(20, $y);
$pdf->MultiCell(170, 4, _JSHOP_WEIGHT_PRODUCTS . ": " . formatweight($order->weight), '0', 'L');
}
if (!$jshopConfig->without_payment && $jshopConfig->payment_in_invoice) {
if ($y > 240) {
$pdf->addNewPage();
$y = 60;
}
$y = $y + 6;
$pdf->SetFont('freesansb', '', 7);
$pdf->SetXY(20, $y);
$pdf->MultiCell(170, 4, _JSHOP_PAYMENT_INFORMATION, '0', 'L');
$y = $y + 4;
$pdf->SetFont('freesans', '', 7);
$pdf->SetXY(20, $y);
示例7: sendOrderEmail
function sendOrderEmail($order_id, $manuallysend = 0)
{
$mainframe = JFactory::getApplication();
$lang = JSFactory::getLang();
$jshopConfig = JSFactory::getConfig();
$db = JFactory::getDBO();
$order = JSFactory::getTable('order', 'jshop');
$jshopConfig->user_field_title[0] = '';
$jshopConfig->user_field_client_type[0] = '';
$file_generete_pdf_order = $jshopConfig->file_generete_pdf_order;
$tmp_fields = $jshopConfig->getListFieldsRegister();
$config_fields = $tmp_fields["address"];
$count_filed_delivery = $jshopConfig->getEnableDeliveryFiledRegistration('address');
$order->load($order_id);
$status = JSFactory::getTable('orderStatus', 'jshop');
$status->load($order->order_status);
$name = $lang->get("name");
$order->status = $status->{$name};
$order->order_date = strftime($jshopConfig->store_date_format, strtotime($order->order_date));
$order->products = $order->getAllItems();
$order->weight = $order->getWeightItems();
if ($jshopConfig->show_delivery_time_checkout) {
$deliverytimes = JSFactory::getAllDeliveryTime();
$order->order_delivery_time = $deliverytimes[$order->delivery_times_id];
if ($order->order_delivery_time == "") {
$order->order_delivery_time = $order->delivery_time;
}
}
$order->order_tax_list = $order->getTaxExt();
$show_percent_tax = 0;
if (count($order->order_tax_list) > 1 || $jshopConfig->show_tax_in_product) {
$show_percent_tax = 1;
}
if ($jshopConfig->hide_tax) {
$show_percent_tax = 0;
}
$hide_subtotal = 0;
if (($jshopConfig->hide_tax || count($order->order_tax_list) == 0) && $order->order_discount == 0 && $jshopConfig->without_shipping && $order->order_payment == 0) {
$hide_subtotal = 1;
}
if ($order->weight == 0 && $jshopConfig->hide_weight_in_cart_weight0) {
$jshopConfig->show_weight_order = 0;
}
$country = JSFactory::getTable('country', 'jshop');
$country->load($order->country);
$field_country_name = $lang->get("name");
$order->country = $country->{$field_country_name};
$d_country = JSFactory::getTable('country', 'jshop');
$d_country->load($order->d_country);
$field_country_name = $lang->get("name");
$order->d_country = $d_country->{$field_country_name};
if ($jshopConfig->show_delivery_date && !datenull($order->delivery_date)) {
$order->delivery_date_f = formatdate($order->delivery_date);
} else {
$order->delivery_date_f = '';
}
$order->title = $jshopConfig->user_field_title[$order->title];
$order->d_title = $jshopConfig->user_field_title[$order->d_title];
$order->birthday = getDisplayDate($order->birthday, $jshopConfig->field_birthday_format);
$order->d_birthday = getDisplayDate($order->d_birthday, $jshopConfig->field_birthday_format);
$order->client_type_name = $jshopConfig->user_field_client_type[$order->client_type];
$shippingMethod = JSFactory::getTable('shippingMethod', 'jshop');
$shippingMethod->load($order->shipping_method_id);
$pm_method = JSFactory::getTable('paymentMethod', 'jshop');
$pm_method->load($order->payment_method_id);
$paymentsysdata = $pm_method->getPaymentSystemData();
$payment_system = $paymentsysdata->paymentSystem;
$name = $lang->get("name");
$description = $lang->get("description");
$order->shipping_information = $shippingMethod->{$name};
$shippingForm = $shippingMethod->getShippingForm();
if ($shippingForm) {
$shippingForm->prepareParamsDispayMail($order, $shippingMethod);
}
$order->payment_name = $pm_method->{$name};
$order->payment_information = $order->payment_params;
if ($payment_system) {
$payment_system->prepareParamsDispayMail($order, $pm_method);
}
if ($pm_method->show_descr_in_email) {
$order->payment_description = $pm_method->{$description};
} else {
$order->payment_description = "";
}
$statictext = JSFactory::getTable("statictext", "jshop");
$rowstatictext = $statictext->loadData("order_email_descr");
$order_email_descr = $rowstatictext->text;
$order_email_descr = str_replace("{name}", $order->f_name, $order_email_descr);
$order_email_descr = str_replace("{family}", $order->l_name, $order_email_descr);
$order_email_descr = str_replace("{email}", $order->email, $order_email_descr);
$order_email_descr = str_replace("{title}", $order->title, $order_email_descr);
$rowstatictext = $statictext->loadData("order_email_descr_end");
$order_email_descr_end = $rowstatictext->text;
$order_email_descr_end = str_replace("{name}", $order->f_name, $order_email_descr_end);
$order_email_descr_end = str_replace("{family}", $order->l_name, $order_email_descr_end);
$order_email_descr_end = str_replace("{email}", $order->email, $order_email_descr_end);
$order_email_descr_end = str_replace("{title}", $order->title, $order_email_descr_end);
if ($jshopConfig->show_return_policy_text_in_email_order) {
$list = $order->getReturnPolicy();
$listtext = array();
//.........这里部分代码省略.........
示例8: prepareOrderPrint
function prepareOrderPrint($page = '', $date_format = 0)
{
$jshopConfig = JSFactory::getConfig();
$lang = JSFactory::getLang();
$jshopConfig->user_field_title[0] = '';
$jshopConfig->user_field_client_type[0] = '';
if ($page == 'order_show') {
$this->status_name = $this->getStatus();
} else {
$this->status = $this->getStatus();
}
if (!isset($this->order_date_print)) {
$this->order_date_print = formatdate($this->order_date);
$this->order_datetime_print = formatdate($this->order_date, 1);
if ($date_format) {
$this->order_date = $this->order_date_print;
}
}
$this->products = $this->getAllItems();
$this->weight = $this->getWeightItems();
if ($jshopConfig->show_delivery_time_checkout) {
$deliverytimes = JSFactory::getAllDeliveryTime();
if (isset($deliverytimes[$this->delivery_times_id])) {
$this->order_delivery_time = $deliverytimes[$this->delivery_times_id];
} else {
$this->order_delivery_time = '';
}
if ($this->order_delivery_time == "") {
$this->order_delivery_time = $this->delivery_time;
}
if ($page == 'order_show') {
$this->delivery_time_name = $this->order_delivery_time;
}
}
$this->order_tax_list = $this->getTaxExt();
if (!isset($this->country_id)) {
$this->country_id = $this->country;
$this->d_country_id = $this->d_country;
}
$country = JSFactory::getTable('country', 'jshop');
$country->load($this->country_id);
$this->country = $country->getName();
$d_country = JSFactory::getTable('country', 'jshop');
$d_country->load($this->d_country_id);
$this->d_country = $d_country->getName();
if ($jshopConfig->show_delivery_date && !datenull($this->delivery_date)) {
$this->delivery_date_f = formatdate($this->delivery_date);
} else {
$this->delivery_date_f = '';
}
if (!isset($this->title_id)) {
$this->title_id = $this->title;
$this->d_title_id = $this->d_title;
}
if (!isset($this->birthday_date)) {
$this->birthday_date = $this->birthday;
$this->d_birthday_date = $this->d_birthday;
}
$this->title = $jshopConfig->user_field_title[$this->title_id];
$this->d_title = $jshopConfig->user_field_title[$this->d_title_id];
$this->birthday = getDisplayDate($this->birthday_date, $jshopConfig->field_birthday_format);
$this->d_birthday = getDisplayDate($this->d_birthday_date, $jshopConfig->field_birthday_format);
$this->client_type_name = $this->getClientTypeName();
$shippingMethod = $this->getShipping();
$pm_method = $this->getPayment();
$paymentsysdata = $pm_method->getPaymentSystemData();
$payment_system = $paymentsysdata->paymentSystem;
if ($page == 'order_show') {
$this->shipping_info = $shippingMethod->getName();
} else {
$this->shipping_information = $shippingMethod->getName();
}
$shippingForm = $shippingMethod->getShippingForm();
if ($shippingForm) {
$shippingForm->prepareParamsDispayMail($order, $shippingMethod);
}
$this->payment_name = $pm_method->getName();
$this->payment_information = $this->payment_params;
if ($payment_system) {
$payment_system->prepareParamsDispayMail($order, $pm_method);
}
if ($pm_method->show_descr_in_email) {
$this->payment_description = $pm_method->getDescription();
} else {
$this->payment_description = "";
}
if ($this->coupon_id) {
$coupon = JSFactory::getTable('coupon', 'jshop');
$coupon->load($this->coupon_id);
$this->coupon_code = $coupon->coupon_code;
}
if ($page == 'order_show') {
$this->history = $this->getHistory();
}
$this->prepareOrderPrint = 1;
}