removed debug line and unneeded code
This commit is contained in:
parent
8db595c43b
commit
4ebe99f6ad
3 changed files with 0 additions and 26 deletions
|
@ -38,33 +38,9 @@ sub post_category_list {
|
|||
}
|
||||
);
|
||||
|
||||
my $month_transaction_rs = $c->schema->resultset('ViewQuantisedTransaction' . $driver)->search(
|
||||
{
|
||||
purchase_time => {
|
||||
-between => [
|
||||
$dtf->format_datetime($start),
|
||||
$dtf->format_datetime($end),
|
||||
],
|
||||
},
|
||||
buyer_id => $entity->id,
|
||||
},
|
||||
{
|
||||
columns => [
|
||||
{
|
||||
quantised => 'quantised_weeks',
|
||||
value => 'value',
|
||||
essential => 'essential',
|
||||
}
|
||||
],
|
||||
group_by => [ qw/ essential quantised_weeks / ],
|
||||
order_by => { '-desc' => 'value' },
|
||||
}
|
||||
);
|
||||
|
||||
my $data = { categories => {}, essentials => {} };
|
||||
|
||||
for my $cat_trans ( $month_transaction_category_rs->all ) {
|
||||
use Devel::Dwarn; Dwarn {$cat_trans->get_columns};
|
||||
my $quantised = $c->db_datetime_parser->parse_datetime($cat_trans->get_column('quantised'));
|
||||
my $days = $c->format_iso_date( $quantised ) || 0;
|
||||
my $category = $cat_trans->get_column('category_id') || 0;
|
||||
|
|
|
@ -15,7 +15,6 @@ SELECT "value",
|
|||
"purchase_time",
|
||||
"buyer_id",
|
||||
"seller_id",
|
||||
"essential",
|
||||
DATE_TRUNC('hour', "purchase_time") AS "quantised_hours",
|
||||
DATE_TRUNC('day', "purchase_time") AS "quantised_days",
|
||||
DATE_TRUNC('week', "purchase_time") AS "quantised_weeks"
|
||||
|
|
|
@ -15,7 +15,6 @@ SELECT "value",
|
|||
"purchase_time",
|
||||
"buyer_id",
|
||||
"seller_id",
|
||||
"essential",
|
||||
DATETIME(STRFTIME('%Y-%m-%d %H:00:00',"purchase_time")) AS "quantised_hours",
|
||||
DATETIME(STRFTIME('%Y-%m-%d 00:00:00',"purchase_time")) AS "quantised_days",
|
||||
DATETIME(STRFTIME('%Y-%m-%d 00:00:00',"purchase_time", 'weekday 1')) AS "quantised_weeks"
|
||||
|
|
Reference in a new issue