1 package SL::DB::CustomDataExportQueryParameter;
5 use SL::DB::MetaSetup::CustomDataExportQueryParameter;
6 use SL::DB::Manager::CustomDataExportQueryParameter;
8 __PACKAGE__->meta->initialize;
10 sub _default_value_type_fixed_value { $_[0]->default_value }
11 sub _default_value_type_current_user_login { $::myconfig{login} }
13 sub _default_value_type_sql_query {
16 return '' if !$self->default_value;
18 my @result = $self->db->dbh->selectrow_array($self->default_value);
19 $::form->dberror if !@result;
24 sub calculate_default_value {
27 my $method = "_default_value_type_" . ($self->default_value_type // '');
28 return $self->can($method) ? $self->$method : '';