$payment_status .= 'red bold">Not Paid'; break; } $payment_status .= '</div>'; $t['s'] = $payment_status; $table[] = $t; } $result .= tep_draw_table('spo', $table); } echo utf8_encode($result); exit; } else { if ($_POST['me_action'] == 'REPORTBANKEINZUGWITHDRAWAL') { $orders_id = tep_db_prepare_input($_POST['orders_id']); $order = $class_o->retrieveDetail($orders_id); $orders_total = $class_o->retrieveTotals($orders_id); $btw_raw = tep_db_prepare_input($_POST['date_withdrawal']); $btw = explode('.', $btw_raw); $date_withdrawal = strtotime($btw[2] . '-' . $btw[1] . '-' . $btw[0]); $date_notification = time(); $date_repayment = strtotime('+' . PAYMENT_METHOD_DIRECT_DEBIT_FAILURE_CHARGE_OVERDUE); $additional_charge = PAYMENT_METHOD_DIRECT_DEBIT_FAILURE_CHARGE; $repayment_amount = $orders_total['ot_total']['value'] + $additional_charge; $data = array(); $data['date_withdrawal'] = date('Y-m-d', $date_withdrawal); $data['date_notification'] = date('Y-m-d H:i:s', $date_notification); $data['date_repayment'] = date('Y-m-d', $date_repayment); $data['additional_charge'] = $additional_charge; $data['repayment_amount'] = $repayment_amount; $created = $class_o->banktransferWithdrawalReport($orders_id, $data); if ($created) {
} if ($return['return_comment'] != '') { $content .= '<tr><td>Comment</td><td>' . nl2br($return['return_comment']) . '</td></tr>'; } $content .= '<tr><td>Product receive</td><td>' . $receive . '</td></tr>'; $content .= '<tr><td>Product Price</td><td>' . displayCurrency($order['currency'], $product['final_price']) . ' / Qty</td></tr>'; if ($return['return_type'] == 'C') { $content .= '<tr><td colspan="2"> </td></tr>'; if ($order['paid_status'] == '0') { $content .= '<tr><td colspan="2">'; $content .= '<div class="float-box ui-corner-all red bold">THIS ORDER IS UNPAID</div>'; $content .= '</td></tr>'; } else { $suggest_amount = $return['return_qty'] * $product['final_price']; $products = $class_o->retrieveProducts($product['orders_id']); $totals = $class_o->retrieveTotals($product['orders_id']); if (count($products) == 1 && $totals['ot_total']['value'] != $suggest_amount) { $suggest_amount = $totals['ot_total']['value']; } $dis = 'disabled="disabled"'; $cb_value_dis = $return['return_status'] == '1' ? $dis : ''; $cb_check_dis = $return['return_status'] == '1' || $return['product_received'] != '1' ? $dis : ''; $cb_detail = $class_o->getChargedbackDetail($return['orders_products_id']); $cb_value = !is_null($cb_detail) ? $cb_detail['chargedback'] : ''; $cb_value_text = '<input type="text" id="cb_value" name="cb_value" value="' . $cb_value . '" ' . $cb_value_dis . ' />'; $cb_paid_checked = is_null($cb_detail) || $cb_detail['chargedback_status'] != '1' ? '' : 'checked="checked"'; $cb_paid_label = is_null($cb_detail) || $cb_detail['chargedback_status'] != '1' ? 'Not Paid' : 'Paid'; $content .= '<tr><td>Suggested Amount</td><td>' . displayCurrency($order['currency'], $suggest_amount); if (is_null($cb_detail)) { $content .= ' <a href="?open=order&id=' . $product['orders_id'] . '">» view order detail</a>'; }