mirror of
https://github.com/mblanke/Gov_Travel_App.git
synced 2026-03-01 14:10:22 -05:00
- 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.
15 lines
392 B
JavaScript
15 lines
392 B
JavaScript
const Database = require("better-sqlite3");
|
|
const path = require("path");
|
|
const db = new Database(
|
|
path.join(__dirname, "..", "data", "travel_rates_scraped.sqlite3")
|
|
);
|
|
const row = db
|
|
.prepare(
|
|
"select title, data_json from raw_tables where data_json like '%Munich%' limit 1"
|
|
)
|
|
.get();
|
|
console.log(row?.title);
|
|
if (row?.data_json) {
|
|
console.log(row.data_json.slice(0, 2000));
|
|
}
|