_booking_tile.php
1 week ago
_bundle_tile.php
1 year ago
_order_tile.php
2 months ago
dashboard.php
2 months ago
login.php
9 months ago
password_reset_form.php
2 months ago
request_password_reset_token.php
2 months ago
scheduling_summary_for_bundle.php
1 year ago
view_booking_summary_in_lightbox.php
1 year ago
view_order_summary_in_lightbox.php
1 year ago
_order_tile.php
54 lines
| 1 | <?php |
| 2 | /* |
| 3 | * Copyright (c) 2024 LatePoint LLC. All rights reserved. |
| 4 | */ |
| 5 | |
| 6 | /** |
| 7 | * @var $order OsOrderModel |
| 8 | */ |
| 9 | |
| 10 | if ( ! defined( 'ABSPATH' ) ) { |
| 11 | exit; // Exit if accessed directly |
| 12 | } |
| 13 | ?> |
| 14 | <div class="customer-order status-<?php echo esc_attr( $order->status ); ?>" data-id="<?php echo esc_attr( $order->id ); ?>" |
| 15 | data-route-name="<?php echo esc_attr( OsRouterHelper::build_route_name( 'customer_cabinet', 'reload_order_tile' ) ); ?>"> |
| 16 | <div class="customer-order-confirmation"> |
| 17 | <?php echo esc_html( $order->confirmation_code ); ?> |
| 18 | </div> |
| 19 | <div class="customer-order-datetime"> |
| 20 | <?php echo esc_html( OsTimeHelper::get_readable_date( new OsWpDateTime( $order->created_at, new DateTimeZone('UTC') ) ) ); ?> |
| 21 | </div> |
| 22 | <?php OsPriceBreakdownHelper::output_price_breakdown( $order->generate_price_breakdown_rows() ); ?> |
| 23 | <div class="customer-order-bottom-actions"> |
| 24 | <div class="load-booking-summary-btn-w"> |
| 25 | <a href="#" |
| 26 | class="latepoint-btn latepoint-btn-primary latepoint-btn-outline latepoint-btn-sm" |
| 27 | data-os-after-call="latepoint_init_order_summary_lightbox" |
| 28 | data-os-params="<?php echo esc_attr( OsUtilHelper::build_os_params( [ 'order_id' => $order->id ] ) ); ?>" |
| 29 | data-os-action="<?php echo esc_attr( OsRouterHelper::build_route_name( 'customer_cabinet', 'view_order_summary_in_lightbox' ) ); ?>" |
| 30 | data-os-output-target="lightbox" |
| 31 | data-os-lightbox-classes="width-500 customer-dashboard-order-summary-lightbox"> |
| 32 | <i class="latepoint-icon latepoint-icon-list"></i> |
| 33 | <span><?php esc_html_e( 'Summary', 'latepoint' ); ?></span> |
| 34 | </a> |
| 35 | </div> |
| 36 | <?php |
| 37 | if ( OsPaymentsHelper::is_accepting_payments() && OsInvoicesHelper::is_enabled() ) { |
| 38 | $unpaid_invoices = $order->get_invoices( [ LATEPOINT_INVOICE_STATUS_OPEN ] ); |
| 39 | if ( $unpaid_invoices ) { |
| 40 | foreach ( $unpaid_invoices as $invoice ) { ?> |
| 41 | <a href="#" class="latepoint-btn latepoint-btn-primary latepoint-btn-outline latepoint-btn-sm" |
| 42 | data-os-params="<?php echo esc_attr( http_build_query( [ 'key' => $invoice->access_key ] ) ); ?>" |
| 43 | data-os-action="<?php echo esc_attr( OsRouterHelper::build_route_name( 'invoices', 'summary_before_payment' ) ); ?>" |
| 44 | data-os-output-target="lightbox" |
| 45 | data-os-lightbox-classes="width-500"> |
| 46 | <i class="latepoint-icon latepoint-icon-credit-card"></i> |
| 47 | <span><?php esc_html_e( 'Pay Balance', 'latepoint' ); ?></span> |
| 48 | </a> |
| 49 | <?php |
| 50 | } |
| 51 | } |
| 52 | } ?> |
| 53 | </div> |
| 54 | </div> |