Store service types that are builtin as numbers to reference in code easier.

This commit is contained in:
2020-06-10 13:31:17 -04:00
parent bb3904e2d1
commit 420d36a1a0
4 changed files with 22 additions and 8 deletions

View File

@@ -59,7 +59,7 @@ Q_DECL_EXPORT int main(int argc, char *argv[])
//Create table structure
db.open();
db.exec("CREATE TABLE vehicles (id INTEGER PRIMARY KEY, name TEXT, maker TEXT, vmodel TEXT, year INTEGER, image TEXT, vin TEXT);");
db.exec("CREATE TABLE records (id INTEGER PRIMARY KEY, vehicle INTEGER, serviceprovider TEXT, servicetype TEXT, servicedate TEXT, miles INTEGER, notes TEXT);");
db.exec("CREATE TABLE records (id INTEGER PRIMARY KEY, vehicle INTEGER, serviceprovider TEXT, servicetype INTEGER, servicetypename TEXT, servicedate TEXT, miles INTEGER, notes TEXT);");
db.commit();
db.close();
}