} if ($this->ms['MODULES']['ORDER_EDIT'] && !$order['is_locked']) { if ($edit_order_popup_width > 980) { $edit_order_popup_width += 155; } else { $edit_order_popup_width += 70; } } // $order=mslib_fe::getOrder($order_row['orders_id']); if (!$tr_type or $tr_type == 'even') { $tr_type = 'odd'; } else { $tr_type = 'even'; } if ($this->masterShop) { $master_shop_col = '<td align="left" nowrap>' . mslib_fe::getShopNameByPageUid($order['page_uid']) . '</td>'; } if ($order['billing_company']) { $customer_name = $order['billing_company']; } else { $customer_name = $order['billing_name']; } $markerArray = array(); $markerArray['ROW_TYPE'] = $tr_type; $markerArray['CUSTOMER_NAME'] = $customer_name; $markerArray['CUSTOMER_NAME_LINK'] = mslib_fe::typolink($this->shop_pid . ',2003', '&tx_multishop_pi1[page_section]=edit_customer&tx_multishop_pi1[cid]=' . $order['customer_id'] . '&action=edit_customer', 1); $markerArray['IP_ADDRESS'] = $order['ip_address']; $markerArray['ORDERS_ID'] = $order['orders_id']; $markerArray['USER_AGENT'] = $order['user_agent']; // custom page hook that can be controlled by third-party plugin eof $orderItem .= $this->cObj->substituteMarkerArray($subparts['useragents_listing'], $markerArray, '###|###');
$sheet_header[] = $this->pi_getLL('order_status'); $sheet_header[] = $this->pi_getLL('modified_on', 'Modified on'); $sheet_header[] = $this->pi_getLL('admin_paid'); // write the header $row_count = 1; $col_count = 0; $colwidth = array(); foreach ($sheet_header as $key => $val) { $colwidth[$col_count] = strlen($val) + 2; $phpexcel->getActiveSheet()->setCellValueByColumnAndRow($col_count, $row_count, $val); $col_count++; } $row_count++; foreach ($tmporders as $order) { $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(0, $row_count, $order['orders_id']); $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(1, $row_count, mslib_fe::getShopNameByPageUid($order['page_uid'])); $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(2, $row_count, $order['billing_name']); $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(3, $row_count, strftime("%x %X", $order['crdate'])); $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(4, $row_count, number_format($order['grand_total'], 2, ',', '.')); $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(5, $row_count, $order['shipping_method_label']); $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(6, $row_count, $order['payment_method_label']); $order_status = ''; if (is_array($all_orders_status)) { foreach ($all_orders_status as $item) { if ($item['id'] == $order['status']) { $order_status = $item['name']; } } } $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(7, $row_count, $order_status); $phpexcel->getActiveSheet()->setCellValueByColumnAndRow(8, $row_count, $order['status_last_modified'] ? strftime("%x %X", $order['status_last_modified']) : '');
if (!defined('TYPO3_MODE')) { die('Access denied.'); } $counter = 0; $totalAmount = 0; $invoiceItem = ''; foreach ($invoices as $invoice) { $grandTotalColumnName = 'grand_total'; if (isset($this->get['tx_multishop_pi1']['excluding_vat'])) { $grandTotalColumnName = 'grand_total_excluding_vat'; } $cb_ctr++; $master_shop_col = ''; if ($this->masterShop) { $master_shop_col = '<td class="cellName">' . mslib_fe::getShopNameByPageUid($invoice['page_uid']) . '</td>'; } if ($invoice['reversal_invoice']) { $totalAmount = $totalAmount - $invoice[$grandTotalColumnName]; } else { $totalAmount = $totalAmount + $invoice[$grandTotalColumnName]; } $paid_status = ''; /** PLAN TO REMOVED **/ /* if (!$invoice['paid']) { $paid_status.='<span class="admin_status_red" alt="'.$this->pi_getLL('has_not_been_paid').'" title="'.$this->pi_getLL('has_not_been_paid').'"></span>'; $paid_status.='<a href="'.mslib_fe::typolink($this->shop_pid.',2003', 'tx_multishop_pi1[page_section]='.$this->ms['page'].'&tx_multishop_pi1[action]=update_selected_invoices_to_paid&selected_invoices[]='.$invoice['id']).'" onclick="return confirm(\''.sprintf($this->pi_getLL('admin_label_are_you_sure_that_invoice_x_has_been_paid'), $invoice['invoice_id']).'\')"><span class="admin_status_green disabled" alt="'.$this->pi_getLL('change_to_paid').'" title="'.$this->pi_getLL('change_to_paid').'"></span></a>'; } else { $paid_status.='<a href="'.mslib_fe::typolink($this->shop_pid.',2003', 'tx_multishop_pi1[page_section]='.$this->ms['page'].'&tx_multishop_pi1[action]=update_selected_invoices_to_not_paid&selected_invoices[]='.$invoice['id']).'" onclick="return confirm(\''.sprintf($this->pi_getLL('admin_label_are_you_sure_that_invoice_x_has_not_been_paid'), $invoice['invoice_id']).'\')"><span class="admin_status_red disabled" alt="'.$this->pi_getLL('change_to_not_paid').'" title="'.$this->pi_getLL('change_to_not_paid').'"></span></a>'; $paid_status.='<span class="admin_status_green" alt="'.$this->pi_getLL('has_been_paid').'" title="'.$this->pi_getLL('has_been_paid').'"></span>';
$tmpcontent .= '<th>' . $this->pi_getLL('shop', 'Shop') . '</th>'; } $tmpcontent .= '<th>' . $this->pi_getLL('payment_method') . '</th><th width="60">' . $this->pi_getLL('template') . '</th><th width="120">' . $this->pi_getLL('date_added') . '</th><th width="60">' . $this->pi_getLL('status') . '</th><th width="30">' . $this->pi_getLL('action') . '</th><th width="30">' . ucfirst($this->pi_getLL('download')) . '</th></tr></thead> <tbody class="sortable_content"> '; while (($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($qry)) != false) { // $tmpcontent.='<h3>'.$cat['name'].'</h3>'; if (!$tr_type or $tr_type == 'even') { $tr_type = 'odd'; } else { $tr_type = 'even'; } $tmpcontent .= '<tr class="' . $tr_type . '" id="multishop_payment_method_' . $row['id'] . '">'; if (count($active_shop) > 1) { if ($row['page_uid'] > 0) { $tmpcontent .= '<td><strong>' . mslib_fe::getShopNameByPageUid($row['page_uid']) . '</strong></td>'; } else { $tmpcontent .= '<td><strong>All</strong></td>'; } } $tmpcontent .= '<td class="cellName"><strong><a href="' . mslib_fe::typolink($this->shop_pid . ',2003', '&tx_multishop_pi1[page_section]=' . $this->ms['page'] . '&payment_method_id=' . $row['id'] . '&edit=1') . '">' . $row['name'] . '</a> </strong></td> <td>' . $row['provider'] . '</td> <td class="cellDate">' . date("Y-m-d", $row['date']) . '</td> <td class="cellStatus">'; if (!$row['status']) { $tmpcontent .= '<span class="admin_status_red" alt="' . $this->pi_getLL('disable') . '"></span>'; $tmpcontent .= '<a href="' . mslib_fe::typolink($this->shop_pid . ',2003', '&tx_multishop_pi1[page_section]=' . $this->ms['page'] . '&payment_method_id=' . $row['id'] . '&status=1') . '"><span class="admin_status_green disabled" alt="' . $this->pi_getLL('enabled') . '"></span></a>'; } else { $tmpcontent .= '<a href="' . mslib_fe::typolink($this->shop_pid . ',2003', '&tx_multishop_pi1[page_section]=' . $this->ms['page'] . '&payment_method_id=' . $row['id'] . '&status=0') . '"><span class="admin_status_red disabled" alt="' . $this->pi_getLL('disabled') . '"></span></a>'; $tmpcontent .= '<span class="admin_status_green" alt="' . $this->pi_getLL('enable') . '"></span>';