summaryrefslogtreecommitdiffstats
path: root/includes
diff options
context:
space:
mode:
authorAndreaChirulescu <andrea.chirulescu@gmail.com>2022-03-27 11:03:31 +0200
committerAndreaChirulescu <andrea.chirulescu@gmail.com>2022-03-27 11:03:31 +0200
commit93950454195321a58ee73c796b77f380dc9d3f64 (patch)
treed5bb18dcf62b6afb098565b8ddeb7f335909174e /includes
parent1c6ac0fc1390510a0f0e12295c86e90bc313f2ef (diff)
downloadgigologadmin-93950454195321a58ee73c796b77f380dc9d3f64.tar.gz
gigologadmin-93950454195321a58ee73c796b77f380dc9d3f64.tar.bz2
gigologadmin-93950454195321a58ee73c796b77f380dc9d3f64.zip
Filtered out concerts older than today
Concerts should show with upper case
Diffstat (limited to 'includes')
-rw-r--r--includes/admin/views/_concerts_table.php2
-rw-r--r--includes/concert.php4
2 files changed, 3 insertions, 3 deletions
diff --git a/includes/admin/views/_concerts_table.php b/includes/admin/views/_concerts_table.php
index 45d9196..719dda5 100644
--- a/includes/admin/views/_concerts_table.php
+++ b/includes/admin/views/_concerts_table.php
@@ -303,7 +303,7 @@ if (!class_exists("GiglogAdmin_ConcertsTable"))
$content .=
"<td>" . date( 'd.M.Y', strtotime( $concert->cdate() ) ) . "</td>"
- . "<td>" . esc_html($concert->cname()) . "</td>"
+ . "<td>" . strtoupper(esc_html($concert->cname())) . "</td>"
. "<td>" . esc_html($concert->venue()->name()) . "</td>";
if( is_admin() ) {
diff --git a/includes/concert.php b/includes/concert.php
index d749e67..996d79e 100644
--- a/includes/concert.php
+++ b/includes/concert.php
@@ -189,7 +189,7 @@ if ( !class_exists('GiglogAdmin_Concert') ) {
$query = "SELECT {$ct}.*, {$vt}.wpgvenue_name, {$vt}.wpgvenue_city ";
}
- $query .= "FROM {$ct} LEFT JOIN {$vt} ON {$ct}.venue = {$vt}.id ";
+ $query .= "FROM {$ct} LEFT JOIN {$vt} ON {$ct}.venue = {$vt}.id WHERE wpgconcert_date >= CURRENT_TIMESTAMP";
$keymap = [
'id' => $wpdb->prefix . 'giglogadmin_concerts.id',
@@ -234,7 +234,7 @@ if ( !class_exists('GiglogAdmin_Concert') ) {
}
if ( ! empty( $where ) ) {
- $query .= 'WHERE ' . implode(' and ', $where);
+ $query .= 'AND ' . implode(' and ', $where);
}
$query .= ' ORDER BY wpgconcert_date';