@@ -42,8 +42,8 @@ discard block |
||
42 | 42 | // purchase-specific fields are ignored. This little condition handle this fact. |
43 | 43 | $itemPrice = $serviceSale['price']; |
44 | 44 | |
45 | - $returnUrl = api_get_path(WEB_PLUGIN_PATH) . 'buycourses/src/service_success.php'; |
|
46 | - $cancelUrl = api_get_path(WEB_PLUGIN_PATH) . 'buycourses/src/service_error.php'; |
|
45 | + $returnUrl = api_get_path(WEB_PLUGIN_PATH).'buycourses/src/service_success.php'; |
|
46 | + $cancelUrl = api_get_path(WEB_PLUGIN_PATH).'buycourses/src/service_error.php'; |
|
47 | 47 | |
48 | 48 | // The extra params for handle the hard job, this var is VERY IMPORTANT !! |
49 | 49 | $extra = ''; |
@@ -75,7 +75,7 @@ discard block |
||
75 | 75 | |
76 | 76 | $plugin->cancelServiceSale(intval($serviceSale['id'])); |
77 | 77 | |
78 | - header('Location: '. api_get_path(WEB_PLUGIN_PATH) . 'buycourses/src/service_catalog.php'); |
|
78 | + header('Location: '.api_get_path(WEB_PLUGIN_PATH).'buycourses/src/service_catalog.php'); |
|
79 | 79 | exit; |
80 | 80 | } |
81 | 81 | |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | Display::addFlash( |
113 | 113 | Display::return_message($plugin->get_lang('OrderCancelled'), 'error', false) |
114 | 114 | ); |
115 | - header('Location: '. api_get_path(WEB_PLUGIN_PATH) . 'buycourses/src/service_catalog.php'); |
|
115 | + header('Location: '.api_get_path(WEB_PLUGIN_PATH).'buycourses/src/service_catalog.php'); |
|
116 | 116 | exit; |
117 | 117 | } |
118 | 118 | |
@@ -151,7 +151,7 @@ discard block |
||
151 | 151 | ); |
152 | 152 | |
153 | 153 | unset($_SESSION['bc_service_sale_id']); |
154 | - header('Location: ' . api_get_path(WEB_PLUGIN_PATH) . 'buycourses/src/service_catalog.php'); |
|
154 | + header('Location: '.api_get_path(WEB_PLUGIN_PATH).'buycourses/src/service_catalog.php'); |
|
155 | 155 | exit; |
156 | 156 | } |
157 | 157 | |
@@ -201,7 +201,7 @@ discard block |
||
201 | 201 | ) |
202 | 202 | ); |
203 | 203 | |
204 | - header('Location: ' . api_get_path(WEB_PLUGIN_PATH) . 'buycourses/index.php'); |
|
204 | + header('Location: '.api_get_path(WEB_PLUGIN_PATH).'buycourses/index.php'); |
|
205 | 205 | exit; |
206 | 206 | } |
207 | 207 | } |
@@ -58,20 +58,20 @@ discard block |
||
58 | 58 | |
59 | 59 | $userInfo = api_get_user_info($sale['user_id']); |
60 | 60 | |
61 | - $html = '<h2>' . $sale['product_name'] .'</h2>'; |
|
61 | + $html = '<h2>'.$sale['product_name'].'</h2>'; |
|
62 | 62 | $html .= '<div class="row">'; |
63 | 63 | $html .= '<div class="col-sm-6 col-md-6">'; |
64 | 64 | $html .= '<ul>'; |
65 | - $html .= '<li><b>'. $plugin->get_lang('OrderPrice') . ':</b> '. $sale['price'] . '</li>'; |
|
66 | - $html .= '<li><b>'. $plugin->get_lang('CurrencyType') . ':</b> '. $currency['iso_code'] . '</li>'; |
|
67 | - $html .= '<li><b>'. $plugin->get_lang('ProductType') . ':</b> '. $productType . '</li>'; |
|
68 | - $html .= '<li><b>'. $plugin->get_lang('OrderDate') . ':</b> '. api_format_date($sale['date'], DATE_TIME_FORMAT_LONG_24H) . '</li>'; |
|
69 | - $html .= '<li><b>'. $plugin->get_lang('Buyer') . ':</b> '. $userInfo['complete_name'] . '</li>'; |
|
70 | - $html .= '<li><b>'. $plugin->get_lang('PaymentMethods') . ':</b> '. $paymentType . '</li>'; |
|
65 | + $html .= '<li><b>'.$plugin->get_lang('OrderPrice').':</b> '.$sale['price'].'</li>'; |
|
66 | + $html .= '<li><b>'.$plugin->get_lang('CurrencyType').':</b> '.$currency['iso_code'].'</li>'; |
|
67 | + $html .= '<li><b>'.$plugin->get_lang('ProductType').':</b> '.$productType.'</li>'; |
|
68 | + $html .= '<li><b>'.$plugin->get_lang('OrderDate').':</b> '.api_format_date($sale['date'], DATE_TIME_FORMAT_LONG_24H).'</li>'; |
|
69 | + $html .= '<li><b>'.$plugin->get_lang('Buyer').':</b> '.$userInfo['complete_name'].'</li>'; |
|
70 | + $html .= '<li><b>'.$plugin->get_lang('PaymentMethods').':</b> '.$paymentType.'</li>'; |
|
71 | 71 | $html .= '</ul>'; |
72 | 72 | $html .= '</div>'; |
73 | 73 | $html .= '<div class="col-sm-6 col-md-6">'; |
74 | - $html .= '<img class="thumbnail" src="'. $productImage .'" >'; |
|
74 | + $html .= '<img class="thumbnail" src="'.$productImage.'" >'; |
|
75 | 75 | $html .= '</div>'; |
76 | 76 | $html .= '</div>'; |
77 | 77 | |
@@ -119,9 +119,9 @@ discard block |
||
119 | 119 | $html = '<div class="row">' |
120 | 120 | . '<p>' |
121 | 121 | . '<ul>' |
122 | - . '<li>'. get_plugin_lang("PayoutsTotalCompleted", "BuyCoursesPlugin") .' <b>'. $stats['completed_count'] .'</b> - '. get_plugin_lang("TotalAmount", "BuyCoursesPlugin") .' <b>'. $stats['completed_total_amount'] .' '. $currency['iso_code'] . '</b></li>' |
|
123 | - . '<li>'. get_plugin_lang("PayoutsTotalPending", "BuyCoursesPlugin") .' <b>'. $stats['pending_count'] .'</b> - '. get_plugin_lang("TotalAmount", "BuyCoursesPlugin") .' <b>'. $stats['pending_total_amount'] .' '. $currency['iso_code'] . '</b></li>' |
|
124 | - . '<li>'. get_plugin_lang("PayoutsTotalCanceled", "BuyCoursesPlugin") .' <b>'. $stats['canceled_count'] .'</b> - '. get_plugin_lang("TotalAmount", "BuyCoursesPlugin") .' <b>'. $stats['canceled_total_amount'] .' '. $currency['iso_code'] . '</b></li>' |
|
122 | + . '<li>'.get_plugin_lang("PayoutsTotalCompleted", "BuyCoursesPlugin").' <b>'.$stats['completed_count'].'</b> - '.get_plugin_lang("TotalAmount", "BuyCoursesPlugin").' <b>'.$stats['completed_total_amount'].' '.$currency['iso_code'].'</b></li>' |
|
123 | + . '<li>'.get_plugin_lang("PayoutsTotalPending", "BuyCoursesPlugin").' <b>'.$stats['pending_count'].'</b> - '.get_plugin_lang("TotalAmount", "BuyCoursesPlugin").' <b>'.$stats['pending_total_amount'].' '.$currency['iso_code'].'</b></li>' |
|
124 | + . '<li>'.get_plugin_lang("PayoutsTotalCanceled", "BuyCoursesPlugin").' <b>'.$stats['canceled_count'].'</b> - '.get_plugin_lang("TotalAmount", "BuyCoursesPlugin").' <b>'.$stats['canceled_total_amount'].' '.$currency['iso_code'].'</b></li>' |
|
125 | 125 | . '</ul>' |
126 | 126 | . '</p>'; |
127 | 127 | $html .= '</div>'; |
@@ -161,15 +161,15 @@ discard block |
||
161 | 161 | |
162 | 162 | $isoCode = $currentCurrency['iso_code']; |
163 | 163 | |
164 | - $html .= '<p>'. get_plugin_lang("VerifyTotalAmountToProceedPayout", "BuyCoursesPlugin") .'</p>'; |
|
164 | + $html .= '<p>'.get_plugin_lang("VerifyTotalAmountToProceedPayout", "BuyCoursesPlugin").'</p>'; |
|
165 | 165 | $html .= '' |
166 | 166 | . '<p>' |
167 | 167 | . '<ul>' |
168 | - . '<li>'. get_plugin_lang("TotalAcounts", "BuyCoursesPlugin") .' <b>'. $totalAccounts .'</b></li>' |
|
169 | - . '<li>'. get_plugin_lang("TotalPayout", "BuyCoursesPlugin") .' <b>'. $isoCode .' '. $totalPayout .'</b></li>' |
|
168 | + . '<li>'.get_plugin_lang("TotalAcounts", "BuyCoursesPlugin").' <b>'.$totalAccounts.'</b></li>' |
|
169 | + . '<li>'.get_plugin_lang("TotalPayout", "BuyCoursesPlugin").' <b>'.$isoCode.' '.$totalPayout.'</b></li>' |
|
170 | 170 | . '</ul>' |
171 | 171 | . '</p>'; |
172 | - $html .= '<p>'. get_plugin_lang("CautionThisProcessCantBeCanceled", "BuyCoursesPlugin") .'</p>'; |
|
172 | + $html .= '<p>'.get_plugin_lang("CautionThisProcessCantBeCanceled", "BuyCoursesPlugin").'</p>'; |
|
173 | 173 | $html .= '<br /><br />'; |
174 | 174 | $html .= '<div id="spinner" class="text-center"></div>'; |
175 | 175 | |
@@ -223,7 +223,7 @@ discard block |
||
223 | 223 | |
224 | 224 | } else { |
225 | 225 | |
226 | - echo Display::return_message('<b>'.$result['L_SEVERITYCODE0'].' '.$result['L_ERRORCODE0'].'</b> - '.$result['L_SHORTMESSAGE0'].'<br /><ul><li>'. $result['L_LONGMESSAGE0'].'</li></ul>', 'error', false); |
|
226 | + echo Display::return_message('<b>'.$result['L_SEVERITYCODE0'].' '.$result['L_ERRORCODE0'].'</b> - '.$result['L_SHORTMESSAGE0'].'<br /><ul><li>'.$result['L_LONGMESSAGE0'].'</li></ul>', 'error', false); |
|
227 | 227 | |
228 | 228 | } |
229 | 229 | |
@@ -312,7 +312,7 @@ discard block |
||
312 | 312 | |
313 | 313 | echo json_encode($cargo); |
314 | 314 | |
315 | - } catch(Exception $e) { |
|
315 | + } catch (Exception $e) { |
|
316 | 316 | |
317 | 317 | $cargo = json_decode($e->getMessage(), true); |
318 | 318 | |
@@ -411,7 +411,7 @@ discard block |
||
411 | 411 | |
412 | 412 | echo json_encode($cargo); |
413 | 413 | |
414 | - } catch(Exception $e) { |
|
414 | + } catch (Exception $e) { |
|
415 | 415 | |
416 | 416 | $cargo = json_decode($e->getMessage(), true); |
417 | 417 |