@@ 252-271 (lines=20) @@ | ||
249 | * @return string |
|
250 | * @throws \EE_Error |
|
251 | */ |
|
252 | protected function noTicketAvailableMessage() |
|
253 | { |
|
254 | $no_ticket_available_msg = esc_html__( 'We\'re sorry, but all ticket sales have ended.', 'event_espresso' ); |
|
255 | if (current_user_can('edit_post', $this->event->ID())) { |
|
256 | $no_ticket_available_msg .= sprintf( |
|
257 | esc_html__( |
|
258 | '%1$sNote to Event Admin:%2$sNo tickets were found for this event. This effectively turns off ticket sales. Please ensure that at least one ticket is available for if you want people to be able to register.%3$s(click to edit this event)%4$s', |
|
259 | 'event_espresso' |
|
260 | ), |
|
261 | '<div class="ee-attention" style="text-align: left;"><b>', |
|
262 | '</b><br />', |
|
263 | '<span class="edit-link"><a class="post-edit-link" href="'.get_edit_post_link($this->event->ID()).'">', |
|
264 | '</a></span></div>' |
|
265 | ); |
|
266 | } |
|
267 | return ' |
|
268 | <div class="ee-event-expired-notice"> |
|
269 | <span class="important-notice">' . $no_ticket_available_msg . '</span> |
|
270 | </div>'; |
|
271 | } |
|
272 | ||
273 | ||
274 | ||
@@ 282-301 (lines=20) @@ | ||
279 | * @return string |
|
280 | * @throws \EE_Error |
|
281 | */ |
|
282 | protected function ticketSalesClosedMessage() |
|
283 | { |
|
284 | $sales_closed_msg = esc_html__( |
|
285 | 'We\'re sorry, but ticket sales have been closed at this time. Please check back again later.', |
|
286 | 'event_espresso' |
|
287 | ); |
|
288 | if (current_user_can('edit_post', $this->event->ID())) { |
|
289 | $sales_closed_msg .= sprintf( |
|
290 | esc_html__( |
|
291 | '%sNote to Event Admin:%sThe "Maximum number of tickets allowed per order for this event" in the Event Registration Options has been set to "0". This effectively turns off ticket sales. %s(click to edit this event)%s', |
|
292 | 'event_espresso' |
|
293 | ), |
|
294 | '<div class="ee-attention" style="text-align: left;"><b>', |
|
295 | '</b><br />', |
|
296 | '<span class="edit-link"><a class="post-edit-link" href="'.get_edit_post_link($this->event->ID()).'">', |
|
297 | '</a></span></div>' |
|
298 | ); |
|
299 | } |
|
300 | return '<p><span class="important-notice">' . $sales_closed_msg . '</span></p>'; |
|
301 | } |
|
302 | ||
303 | ||
304 |