|
|
|
|
18
|
/* Set Lifetime range. */
|
18
|
/* Set Lifetime range. */
|
19
|
var dateSelect = findChildObject(this, 'dates');
|
19
|
var dateSelect = findChildObject(this, 'dates');
|
20
|
var query = new QSqlQuery();
|
20
|
var query = new QSqlQuery();
|
21
|
- query.exec("SELECT concat(EXTRACT(YEAR FROM time::date), '-01-01') FROM purchase WHERE time = (SELECT min(time) FROM purchase) UNION SELECT concat(EXTRACT(YEAR FROM 'now'::date), '-12-31')");
|
|
|
|
|
21
|
+ query.exec("SELECT concat(EXTRACT(YEAR FROM time::date), '-01-01') FROM purchase WHERE time = (SELECT min(time) FROM purchase) UNION SELECT concat(EXTRACT(YEAR FROM 'now'::date), '-12-31') ORDER BY concat ASC");
|
22
|
query.next();
|
22
|
query.next();
|
23
|
var lifetimeStartDate = query.value(0);
|
23
|
var lifetimeStartDate = query.value(0);
|
24
|
query.next();
|
24
|
query.next();
|