mirror of
https://github.com/mblanke/Gov_Travel_App.git
synced 2026-03-01 22:20:21 -05:00
feat: add scripts for database inspection and migration
- Implemented multiple scripts to check and inspect meal plans, scraped data, and accommodations for Munich and Riga. - Added a migration script to convert scraped data into the application's database format. - Introduced new database service methods for querying and updating travel rates. - Enhanced server configuration for serving static files in production. - Updated PostCSS configuration for consistency.
This commit is contained in:
16
scripts/queryMunich.js
Normal file
16
scripts/queryMunich.js
Normal file
@@ -0,0 +1,16 @@
|
||||
const Database = require("better-sqlite3");
|
||||
const path = require("path");
|
||||
const db = new Database(
|
||||
path.join(__dirname, "..", "database", "travel_rates.db")
|
||||
);
|
||||
const row = db
|
||||
.prepare(
|
||||
`
|
||||
SELECT city_name, country, currency, meal_currency, meal_plan_type, meal_total,
|
||||
breakfast, lunch, dinner, incidentals
|
||||
FROM travel_rates
|
||||
WHERE lower(city_name) = 'munich'
|
||||
`
|
||||
)
|
||||
.get();
|
||||
console.log(row);
|
||||
Reference in New Issue
Block a user