mirror of
https://github.com/R0m1k3/LogiFlow.git
synced 2026-10-20 13:38:15 +02:00
Order advertisements by their number from smallest to largest
Update server/storage.ts to sort publicities by pubNumber in ascending order using asc(publicities.pubNumber). Replit-Commit-Author: Agent Replit-Commit-Session-Id: 2e1318c6-77b3-4174-b8c7-432d781590ed Replit-Commit-Checkpoint-Type: full_checkpoint Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/1957c339-2757-4d1f-8e92-e9f71a1ce58e/2e1318c6-77b3-4174-b8c7-432d781590ed/D0szOHB
This commit is contained in:
1 parent
07f64d4713
commit
287b2aa702
1 file changed
+1
-1
+1
-1
@@ -1209,7 +1209,7 @@ export class DatabaseStorage implements IStorage {
|
|||||||
query = query.where(eq(publicities.year, year));
|
query = query.where(eq(publicities.year, year));
|
||||||
}
|
}
|
||||||
|
|
||||||
const results = await query.orderBy(desc(publicities.pubNumber));
|
const results = await query.orderBy(asc(publicities.pubNumber));
|
||||||
|
|
||||||
const publicityIds = results.map((p: any) => p.id);
|
const publicityIds = results.map((p: any) => p.id);
|
||||||
const participations = publicityIds.length > 0
|
const participations = publicityIds.length > 0
|
||||||
|
|||||||
Reference in new issue
Block a user