| @@ 96-101 (lines=6) @@ | ||
| 93 | // as necessary. |
|
| 94 | ||
| 95 | // Specify a date range constraint. |
|
| 96 | if ($start_date && $end_date) { |
|
| 97 | $text = 'From @start_date to @end_date'; |
|
| 98 | ||
| 99 | $args['@start_date'] = $start_date; |
|
| 100 | $args['@end_date'] = $end_date; |
|
| 101 | } |
|
| 102 | ||
| 103 | // Specify the day of the week constraint. |
|
| 104 | if ($day_of_the_week) { |
|
| @@ 104-112 (lines=9) @@ | ||
| 101 | } |
|
| 102 | ||
| 103 | // Specify the day of the week constraint. |
|
| 104 | if ($day_of_the_week) { |
|
| 105 | if ($start_date && $end_date) { |
|
| 106 | $text = 'From @start_date to @end_date, bookings must start on @day_of_the_week'; |
|
| 107 | } else { |
|
| 108 | $text = 'Bookings must start on @day_of_the_week'; |
|
| 109 | } |
|
| 110 | ||
| 111 | $args['@day_of_the_week'] = $day_of_the_week; |
|
| 112 | } |
|
| 113 | ||
| 114 | return array('text' => $text, 'args' => $args); |
|
| 115 | } |
|
| @@ 99-104 (lines=6) @@ | ||
| 96 | } |
|
| 97 | ||
| 98 | // Specify a date range constraint. |
|
| 99 | if ($start_date && $end_date) { |
|
| 100 | $text = 'From @start_date to @end_date'; |
|
| 101 | ||
| 102 | $args['@start_date'] = $start_date; |
|
| 103 | $args['@end_date'] = $end_date; |
|
| 104 | } |
|
| 105 | ||
| 106 | // Specify the start/end constraint. |
|
| 107 | if ($start_date && $end_date) { |
|
| @@ 138-142 (lines=5) @@ | ||
| 135 | // as necessary. |
|
| 136 | ||
| 137 | // Specify a date range constraint. |
|
| 138 | if ($start_date && $end_date) { |
|
| 139 | $text = 'From @start_date to @end_date'; |
|
| 140 | $args['@start_date'] = $start_date; |
|
| 141 | $args['@end_date'] = $end_date; |
|
| 142 | } |
|
| 143 | ||
| 144 | // Specify the day of the week constraint. |
|
| 145 | if ($day_of_the_week) { |
|