This repository has been archived on 2023-08-16. You can view files and clone it, but cannot push or open issues or pull requests.
Foodloop-Server/share/ddl/_common/deploy/_any/100-leaderboards.pl

25 lines
636 B
Perl
Raw Permalink Normal View History

#! perl
use strict;
use warnings;
use DBIx::Class::DeploymentHandler::DeployMethod::SQL::Translator::ScriptHelpers
'schema_from_schema_loader';
schema_from_schema_loader({ naming => 'v7' }, sub {
my $schema = shift;
$schema->resultset('Leaderboard')->populate([
[ qw/ name type / ],
[ 'Daily Total', 'daily_total' ],
[ 'Daily Count', 'daily_count' ],
[ 'Weekly Total', 'weekly_total' ],
[ 'Weekly Count', 'weekly_count' ],
[ 'Monthly Total', 'monthly_total' ],
[ 'Monthly Count', 'monthly_count' ],
[ 'All Time Total', 'all_time_total' ],
[ 'All Time Count', 'all_time_count' ],
]);
});