Merge josh features and sagar features #11
@ -148,12 +148,13 @@ void current_status_parkspots(vector<Park_spot>& spots) {
|
|||||||
vector<Park_time> reports_from_customer(int cid, pair<int, int> period) {
|
vector<Park_time> reports_from_customer(int cid, pair<int, int> period) {
|
||||||
vector<Park_time> park_times;
|
vector<Park_time> park_times;
|
||||||
// debug
|
// debug
|
||||||
cout << "it called";
|
|
||||||
SQLite::Statement query(
|
SQLite::Statement query(
|
||||||
data::db, "SELECT * FROM Park_time WHERE 'customer_id' = '?' AND start > ? AND end < ?;");
|
data::db, "SELECT * FROM Park_time WHERE 'customer_id' = '?' AND start > '?' AND end < '?';");
|
||||||
query.bind(1, cid);
|
// query.bind(1, cid);
|
||||||
query.bind(2, period.first);
|
query.bind(2, period.first);
|
||||||
|
cout << "before\n";
|
||||||
query.bind(3, period.second);
|
query.bind(3, period.second);
|
||||||
|
cout << "after\n";
|
||||||
while (query.executeStep()) {
|
while (query.executeStep()) {
|
||||||
int id = query.getColumn(1);
|
int id = query.getColumn(1);
|
||||||
int spotid = query.getColumn(2);
|
int spotid = query.getColumn(2);
|
||||||
|
Loading…
Reference in New Issue
Block a user