Update server.js and related components
This commit is contained in:
parent
44d75e36b3
commit
443b66d27e
@ -734,7 +734,7 @@ function slugify(text) {
|
|||||||
// GET all upcoming events
|
// GET all upcoming events
|
||||||
app.get('/api/upcoming-events', async (req, res) => {
|
app.get('/api/upcoming-events', async (req, res) => {
|
||||||
try {
|
try {
|
||||||
const [rows] = await pool.execute('SELECT * FROM upcoming_events ORDER BY sort_order ASC, id DESC');
|
const [rows] = await pool.execute('SELECT * FROM upcoming_events ORDER BY sort_order ASC, id ASC');
|
||||||
res.json({
|
res.json({
|
||||||
success: true,
|
success: true,
|
||||||
data: rows
|
data: rows
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user