本文整理汇总了PHP中Restaurant::get_restaurant_name方法的典型用法代码示例。如果您正苦于以下问题:PHP Restaurant::get_restaurant_name方法的具体用法?PHP Restaurant::get_restaurant_name怎么用?PHP Restaurant::get_restaurant_name使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Restaurant
的用法示例。
在下文中一共展示了Restaurant::get_restaurant_name方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: Restaurant
$new_reservation->create($fields);
$next_capacity = $previous_capacity - $fields['people_size'];
$sql = 'update time_slots_capacity set ' . $time_to_slots_hash[$_POST['time']] . ' = ' . $next_capacity . ' where date = "' . $fields['date_of_reservation'] . '" and restaurant_id = "' . $fields['restaurant_id'] . '"';
if ($query_tool->query($sql)) {
// send email to user to confirm reservation
$restaurant = new Restaurant();
$restaurant->find($fields['restaurant_id']);
$mail = Mail::getInstance();
$mailto = $_POST['user_email'];
$subject = 'FineTable - Restaurant Reservation Confirmation!';
if (isset($_POST['guest_reservation']) && $_POST['guest_reservation'] == 'true') {
$body = '
<div class="mail-body" style="padding: 20px; border: 5px solid rgb(254, 127, 65); border-radius: 4px; margin: 0 auto; width: 90%;">
<p>Hello ' . $_POST['guest_fullname'] . ',</p>
<p>Congratulations!</p>
<p>You have made a reservation with restaurant: ' . $restaurant->get_restaurant_name() . '.</p>
<p>' . $restaurant->get_full_address() . '</p>
<p><b>Date: </b>' . $_POST['date'] . '</p>
<p><b>Time: </b>' . $_POST['time'] . '</p>
<p>If you need to make a change with the reservation, please contact the restaurant at: ' . $restaurant->get_phone() . '</p>
<p>Thank you!</p>
<p>FineTable team</p>
</div>
';
} else {
$body = '
<div class="mail-body" style="padding: 20px; border: 5px solid rgb(254, 127, 65); border-radius: 4px; margin: 0 auto; width: 90%;">
<p>Hello ' . $_COOKIE["login_user_firstname"] . ',</p>
<p>Congratulations!</p>
<p>You have made a reservation with restaurant: ' . $restaurant->get_restaurant_name() . '.</p>
<p>' . $restaurant->get_full_address() . '</p>