restaurant order placement: new order #3350
This commit is contained in:
parent
26580d8ef5
commit
acab93dca9
@ -1778,6 +1778,28 @@ class Crunchbutton_Order extends Cana_Table {
|
||||
|
||||
break;
|
||||
case 'sms-admin':
|
||||
|
||||
if( $this->type == 'restaurant' ){
|
||||
$spacer = ' / ';
|
||||
$msg = $this->name . $spacer . strtoupper( $this->pay_type ) . $spacer . preg_replace( '/[^\d.]/', '', $this->phone ) . $spacer;
|
||||
if( $this->delivery_type == Crunchbutton_Order::SHIPPING_DELIVERY ){
|
||||
$msg .= $this->address . $spacer;
|
||||
}
|
||||
$msg .= $this->restaurant()->name . $spacer ;
|
||||
if( $this->pay_type == Crunchbutton_Order::PAY_TYPE_CASH ){
|
||||
$msg .= strtoupper( 'Charge Customer $' . $this->final_price_plus_delivery_markup );
|
||||
$msg .= $spacer;
|
||||
$msg .= strtoupper( 'Pay Restaurant $' . $this->final_price );
|
||||
} else if( $this->pay_type == Crunchbutton_Order::PAY_TYPE_CREDIT_CARD ){
|
||||
$msg .= strtoupper( 'Customer Paid $' . $this->final_price_plus_delivery_markup );
|
||||
$msg .= $spacer;
|
||||
if( $this->tip ){
|
||||
$msg .= 'TIP ' . $this->tip();
|
||||
} else {
|
||||
$msg .= 'TIP BY CASH';
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$spacer = ' / ';
|
||||
$payment =
|
||||
$msg = $this->name . $spacer . strtoupper( $this->pay_type ) . $spacer . strtoupper( $this->delivery_type ) . $spacer . preg_replace( '/[^\d.]/', '', $this->phone ) . $spacer;
|
||||
@ -1798,6 +1820,7 @@ class Crunchbutton_Order extends Cana_Table {
|
||||
}
|
||||
|
||||
$msg .= $spacer . $this->driverInstructionsFoodStatus() . $spacer . $this->driverInstructionsPaymentStatus();
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user