From e28e10518626a944b3f0458b3faaccd7106d5410 Mon Sep 17 00:00:00 2001 From: Andreas Granig Date: Tue, 15 Oct 2013 10:16:31 +0200 Subject: [PATCH] MT#4225 Revert the revert, we'll patch later. This reverts commit 2cd76e7b89ce30c8bb9a45267a3b2e99a7fbe485. --- lib/NGCP/Schema/Result/acc.pm | 31 ++------- lib/NGCP/Schema/Result/acc_backup.pm | 31 ++------- lib/NGCP/Schema/Result/acc_trash.pm | 31 ++------- lib/NGCP/Schema/Result/active_watchers.pm | 32 ++------- lib/NGCP/Schema/Result/address.pm | 31 ++------- lib/NGCP/Schema/Result/admins.pm | 32 ++------- lib/NGCP/Schema/Result/aliases.pm | 32 ++------- lib/NGCP/Schema/Result/autoprov_configs.pm | 32 ++------- .../Result/autoprov_device_line_ranges.pm | 31 ++------- lib/NGCP/Schema/Result/autoprov_devices.pm | 30 ++------ .../Result/autoprov_field_device_lines.pm | 33 ++------- .../Schema/Result/autoprov_field_devices.pm | 31 ++------- lib/NGCP/Schema/Result/autoprov_firmwares.pm | 30 ++------ lib/NGCP/Schema/Result/autoprov_profiles.pm | 32 ++------- lib/NGCP/Schema/Result/billing_fees.pm | 34 ++-------- .../Schema/Result/billing_fees_history.pm | 33 ++------- lib/NGCP/Schema/Result/billing_mappings.pm | 34 ++-------- .../Schema/Result/billing_peaktime_special.pm | 32 ++------- .../Result/billing_peaktime_weekdays.pm | 32 ++------- lib/NGCP/Schema/Result/billing_profiles.pm | 40 ++--------- lib/NGCP/Schema/Result/billing_zones.pm | 35 ++-------- .../Schema/Result/billing_zones_history.pm | 33 ++------- lib/NGCP/Schema/Result/carrier_contracts.pm | 35 ++-------- lib/NGCP/Schema/Result/carrier_customers.pm | 35 ++-------- lib/NGCP/Schema/Result/carrier_orders.pm | 33 ++------- lib/NGCP/Schema/Result/carrier_payments.pm | 33 ++------- lib/NGCP/Schema/Result/cdr.pm | 46 +++++-------- lib/NGCP/Schema/Result/cfg_schema.pm | 32 ++------- lib/NGCP/Schema/Result/contacts.pm | 37 ++-------- lib/NGCP/Schema/Result/contract_balances.pm | 34 ++-------- lib/NGCP/Schema/Result/contract_credits.pm | 33 ++------- .../Result/contract_fraud_preferences.pm | 33 ++------- lib/NGCP/Schema/Result/contract_registers.pm | 32 ++------- lib/NGCP/Schema/Result/contracts.pm | 38 ++--------- lib/NGCP/Schema/Result/credit_payments.pm | 33 ++------- lib/NGCP/Schema/Result/credits.pm | 33 ++------- lib/NGCP/Schema/Result/customer_registers.pm | 32 ++------- lib/NGCP/Schema/Result/customers.pm | 39 ++--------- lib/NGCP/Schema/Result/db_schema.pm | 32 ++------- lib/NGCP/Schema/Result/dbaliases.pm | 32 ++------- lib/NGCP/Schema/Result/dialog.pm | 31 ++------- lib/NGCP/Schema/Result/dialog_vars.pm | 31 ++------- lib/NGCP/Schema/Result/dialplan.pm | 31 ++------- lib/NGCP/Schema/Result/dispatcher.pm | 31 ++------- lib/NGCP/Schema/Result/dom_preferences.pm | 31 ++------- lib/NGCP/Schema/Result/domain.pm | 32 ++------- lib/NGCP/Schema/Result/domain_attrs.pm | 32 ++------- lib/NGCP/Schema/Result/domain_resellers.pm | 33 ++------- lib/NGCP/Schema/Result/domains.pm | 34 ++-------- lib/NGCP/Schema/Result/fax_destinations.pm | 31 ++------- lib/NGCP/Schema/Result/fax_journal.pm | 31 ++------- lib/NGCP/Schema/Result/fax_preferences.pm | 31 ++------- lib/NGCP/Schema/Result/htable.pm | 31 ++------- lib/NGCP/Schema/Result/interceptions.pm | 31 ++------- lib/NGCP/Schema/Result/invoices.pm | 34 ++-------- lib/NGCP/Schema/Result/kamailio_acc.pm | 31 ++------- lib/NGCP/Schema/Result/kamailio_acc_backup.pm | 31 ++------- lib/NGCP/Schema/Result/kamailio_acc_trash.pm | 31 ++------- lib/NGCP/Schema/Result/language_strings.pm | 32 ++------- lib/NGCP/Schema/Result/lcr_gw.pm | 34 ++-------- lib/NGCP/Schema/Result/lcr_rule.pm | 33 ++------- lib/NGCP/Schema/Result/lcr_rule_target.pm | 34 ++-------- lib/NGCP/Schema/Result/lnp_numbers.pm | 32 ++------- lib/NGCP/Schema/Result/lnp_providers.pm | 33 ++------- lib/NGCP/Schema/Result/location.pm | 32 ++------- lib/NGCP/Schema/Result/location_attrs.pm | 31 ++------- lib/NGCP/Schema/Result/mark.pm | 31 ++------- lib/NGCP/Schema/Result/message_packets.pm | 31 ++------- lib/NGCP/Schema/Result/messages.pm | 48 +++++-------- .../Result/mobile_push_registrations.pm | 31 ++------- lib/NGCP/Schema/Result/ncos_levels.pm | 35 ++-------- lib/NGCP/Schema/Result/ncos_lnp_list.pm | 34 ++-------- lib/NGCP/Schema/Result/ncos_pattern_list.pm | 33 ++------- lib/NGCP/Schema/Result/numbers.pm | 32 ++------- lib/NGCP/Schema/Result/order_payments.pm | 33 ++------- lib/NGCP/Schema/Result/orders.pm | 37 ++-------- lib/NGCP/Schema/Result/packets.pm | 30 ++------ lib/NGCP/Schema/Result/payments.pm | 33 ++------- lib/NGCP/Schema/Result/peer_preferences.pm | 31 ++------- lib/NGCP/Schema/Result/prepaid_costs.pm | 31 ++------- lib/NGCP/Schema/Result/presentity.pm | 32 ++------- lib/NGCP/Schema/Result/products.pm | 36 ++-------- .../Result/provisioning_voip_subscribers.pm | 68 ++----------------- lib/NGCP/Schema/Result/pua.pm | 32 ++------- lib/NGCP/Schema/Result/resellers.pm | 43 ++---------- lib/NGCP/Schema/Result/rls_presentity.pm | 32 ++------- lib/NGCP/Schema/Result/rls_watchers.pm | 32 ++------- lib/NGCP/Schema/Result/sca_subscriptions.pm | 32 ++------- lib/NGCP/Schema/Result/sems_registrations.pm | 31 ++------- lib/NGCP/Schema/Result/silo.pm | 31 ++------- lib/NGCP/Schema/Result/sipstats_mark.pm | 31 ++------- lib/NGCP/Schema/Result/speed_dial.pm | 32 ++------- lib/NGCP/Schema/Result/statistics.pm | 31 ++------- lib/NGCP/Schema/Result/subscriber.pm | 32 ++------- lib/NGCP/Schema/Result/subscribers.pm | 36 ++-------- lib/NGCP/Schema/Result/trusted.pm | 31 ++------- lib/NGCP/Schema/Result/uid_credentials.pm | 31 ++------- lib/NGCP/Schema/Result/uid_domain.pm | 32 ++------- lib/NGCP/Schema/Result/uid_domain_attrs.pm | 32 ++------- lib/NGCP/Schema/Result/uid_global_attrs.pm | 32 ++------- lib/NGCP/Schema/Result/uid_uri.pm | 31 ++------- lib/NGCP/Schema/Result/uid_uri_attrs.pm | 32 ++------- lib/NGCP/Schema/Result/uid_user_attrs.pm | 32 ++------- lib/NGCP/Schema/Result/usr_preferences.pm | 31 ++------- lib/NGCP/Schema/Result/version.pm | 31 ++------- lib/NGCP/Schema/Result/voicemail_spool.pm | 48 +++++-------- lib/NGCP/Schema/Result/voicemail_users.pm | 45 ++++-------- lib/NGCP/Schema/Result/voip_aig_sequence.pm | 31 ++------- .../Schema/Result/voip_allowed_ip_groups.pm | 32 ++------- lib/NGCP/Schema/Result/voip_cc_mappings.pm | 32 ++------- .../Schema/Result/voip_cf_destination_sets.pm | 34 ++-------- .../Schema/Result/voip_cf_destinations.pm | 32 ++------- lib/NGCP/Schema/Result/voip_cf_mappings.pm | 34 ++-------- lib/NGCP/Schema/Result/voip_cf_periods.pm | 32 ++------- lib/NGCP/Schema/Result/voip_cf_time_sets.pm | 34 ++-------- lib/NGCP/Schema/Result/voip_contacts.pm | 32 ++------- lib/NGCP/Schema/Result/voip_dbaliases.pm | 34 ++-------- .../Schema/Result/voip_dom_preferences.pm | 33 ++------- lib/NGCP/Schema/Result/voip_domains.pm | 35 ++-------- .../Schema/Result/voip_fax_destinations.pm | 33 ++------- .../Schema/Result/voip_fax_preferences.pm | 33 ++------- lib/NGCP/Schema/Result/voip_intercept.pm | 32 ++------- .../Result/voip_number_block_resellers.pm | 33 ++------- lib/NGCP/Schema/Result/voip_number_blocks.pm | 33 ++------- lib/NGCP/Schema/Result/voip_numbers.pm | 34 ++-------- lib/NGCP/Schema/Result/voip_pbx_groups.pm | 32 ++------- lib/NGCP/Schema/Result/voip_peer_groups.pm | 33 ++------- lib/NGCP/Schema/Result/voip_peer_hosts.pm | 34 ++-------- .../Schema/Result/voip_peer_preferences.pm | 33 ++------- lib/NGCP/Schema/Result/voip_peer_rules.pm | 32 ++------- .../Schema/Result/voip_preference_groups.pm | 32 ++------- lib/NGCP/Schema/Result/voip_preferences.pm | 37 ++-------- .../Schema/Result/voip_preferences_enum.pm | 32 ++------- lib/NGCP/Schema/Result/voip_reminder.pm | 33 ++------- .../Schema/Result/voip_rewrite_rule_sets.pm | 33 ++------- lib/NGCP/Schema/Result/voip_rewrite_rules.pm | 32 ++------- lib/NGCP/Schema/Result/voip_rwrs_sequence.pm | 31 ++------- lib/NGCP/Schema/Result/voip_sound_files.pm | 33 ++------- lib/NGCP/Schema/Result/voip_sound_groups.pm | 32 ++------- lib/NGCP/Schema/Result/voip_sound_handles.pm | 33 ++------- lib/NGCP/Schema/Result/voip_sound_sets.pm | 31 ++------- lib/NGCP/Schema/Result/voip_speed_dial.pm | 33 ++------- lib/NGCP/Schema/Result/voip_subscribers.pm | 51 ++++---------- .../Schema/Result/voip_trusted_sources.pm | 32 ++------- .../Schema/Result/voip_usr_preferences.pm | 33 ++------- lib/NGCP/Schema/Result/watchers.pm | 32 ++------- lib/NGCP/Schema/Result/xcap.pm | 32 ++------- lib/NGCP/Schema/Result/xmlgroups.pm | 32 ++------- lib/NGCP/Schema/Result/xmlhostgroups.pm | 33 ++------- lib/NGCP/Schema/Result/xmlhosts.pm | 32 ++------- lib/NGCP/Schema/Result/xmlqueue.pm | 31 ++------- 151 files changed, 1087 insertions(+), 3942 deletions(-) diff --git a/lib/NGCP/Schema/Result/acc.pm b/lib/NGCP/Schema/Result/acc.pm index d1122fbc..9db513aa 100644 --- a/lib/NGCP/Schema/Result/acc.pm +++ b/lib/NGCP/Schema/Result/acc.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::acc; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("accounting.acc"); - __PACKAGE__->add_columns( "id", { @@ -69,14 +59,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 128 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -214,14 +208,3 @@ NGCP::Schema::Result::acc =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:39 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qFObA0okTMjXtkRwrOqUpw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/acc_backup.pm b/lib/NGCP/Schema/Result/acc_backup.pm index 4e74f3ce..6a2d347e 100644 --- a/lib/NGCP/Schema/Result/acc_backup.pm +++ b/lib/NGCP/Schema/Result/acc_backup.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::acc_backup; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("accounting.acc_backup"); - __PACKAGE__->add_columns( "id", { @@ -69,14 +59,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 128 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -214,14 +208,3 @@ NGCP::Schema::Result::acc_backup =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:39 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:eE2nUDj5epmYmSJsJm8TSQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/acc_trash.pm b/lib/NGCP/Schema/Result/acc_trash.pm index 12850255..5e3efa56 100644 --- a/lib/NGCP/Schema/Result/acc_trash.pm +++ b/lib/NGCP/Schema/Result/acc_trash.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::acc_trash; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("accounting.acc_trash"); - __PACKAGE__->add_columns( "id", { @@ -69,14 +59,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 128 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -214,14 +208,3 @@ NGCP::Schema::Result::acc_trash =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:39 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:557rTw193beyGGnLcAdVBw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/active_watchers.pm b/lib/NGCP/Schema/Result/active_watchers.pm index 598712b0..4e9584aa 100644 --- a/lib/NGCP/Schema/Result/active_watchers.pm +++ b/lib/NGCP/Schema/Result/active_watchers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::active_watchers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.active_watchers"); - __PACKAGE__->add_columns( "id", { @@ -81,17 +71,20 @@ __PACKAGE__->add_columns( { data_type => "integer", is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("active_watchers_idx", ["callid", "to_tag", "from_tag"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -279,14 +272,3 @@ NGCP::Schema::Result::active_watchers =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:58 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qR39S248hh/N3RPJhm19YQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/address.pm b/lib/NGCP/Schema/Result/address.pm index 0d9e61d6..43dc3306 100644 --- a/lib/NGCP/Schema/Result/address.pm +++ b/lib/NGCP/Schema/Result/address.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::address; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.address"); - __PACKAGE__->add_columns( "id", { @@ -48,14 +38,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -122,14 +116,3 @@ NGCP::Schema::Result::address =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:TYow4rXbP/U+xZXeww4i/Q - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/admins.pm b/lib/NGCP/Schema/Result/admins.pm index 57f75de8..9ccfdc34 100644 --- a/lib/NGCP/Schema/Result/admins.pm +++ b/lib/NGCP/Schema/Result/admins.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::admins; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON", "EncodedColumn"); - __PACKAGE__->table("billing.admins"); - __PACKAGE__->add_columns( "id", { @@ -61,10 +51,8 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("login_idx", ["login"]); @@ -79,12 +67,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -198,14 +191,3 @@ NGCP::Schema::Result::admins Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:HtK2drQTRWUtkxH5uEqh9g - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/aliases.pm b/lib/NGCP/Schema/Result/aliases.pm index 78e34fa6..700614fc 100644 --- a/lib/NGCP/Schema/Result/aliases.pm +++ b/lib/NGCP/Schema/Result/aliases.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::aliases; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.aliases"); - __PACKAGE__->add_columns( "id", { @@ -84,17 +74,20 @@ __PACKAGE__->add_columns( { data_type => "integer", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("ruid_idx", ["ruid"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -254,14 +247,3 @@ NGCP::Schema::Result::aliases =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ZiycXJUkxrz/omgPSZc9Sw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/autoprov_configs.pm b/lib/NGCP/Schema/Result/autoprov_configs.pm index 53cd507f..79aed221 100644 --- a/lib/NGCP/Schema/Result/autoprov_configs.pm +++ b/lib/NGCP/Schema/Result/autoprov_configs.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::autoprov_configs; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.autoprov_configs"); - __PACKAGE__->add_columns( "id", { @@ -41,10 +31,8 @@ __PACKAGE__->add_columns( { data_type => "mediumtext", is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "device", "NGCP::Schema::Result::autoprov_devices", @@ -59,13 +47,16 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -126,14 +117,3 @@ NGCP::Schema::provisioning::Result::autoprov_configs Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-09-09 18:26:38 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rr7y7bh33fX3UgE8IXLl5w - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/autoprov_device_line_ranges.pm b/lib/NGCP/Schema/Result/autoprov_device_line_ranges.pm index 66040099..1d7dbf7d 100644 --- a/lib/NGCP/Schema/Result/autoprov_device_line_ranges.pm +++ b/lib/NGCP/Schema/Result/autoprov_device_line_ranges.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::autoprov_device_line_ranges; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.autoprov_device_line_ranges"); - __PACKAGE__->add_columns( "id", { @@ -65,10 +55,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "device", "NGCP::Schema::Result::autoprov_devices", @@ -89,6 +77,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -172,14 +164,3 @@ NGCP::Schema::provisioning::Result::autoprov_device_line_ranges Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-10-01 15:26:08 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:bQQCuGxq7fEn1i/jkPZFxQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/autoprov_devices.pm b/lib/NGCP/Schema/Result/autoprov_devices.pm index 55409e23..0ba9795e 100644 --- a/lib/NGCP/Schema/Result/autoprov_devices.pm +++ b/lib/NGCP/Schema/Result/autoprov_devices.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::autoprov_devices; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.autoprov_devices"); - __PACKAGE__->add_columns( "id", { @@ -90,12 +80,17 @@ __PACKAGE__->has_many( ); __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -148,14 +143,3 @@ NGCP::Schema::provisioning::Result::autoprov_devices =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-09-09 12:29:48 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:fFY/6TuWLmvWIb9jDVyYFA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/autoprov_field_device_lines.pm b/lib/NGCP/Schema/Result/autoprov_field_device_lines.pm index 17e029fe..4a293e74 100644 --- a/lib/NGCP/Schema/Result/autoprov_field_device_lines.pm +++ b/lib/NGCP/Schema/Result/autoprov_field_device_lines.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::autoprov_field_device_lines; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.autoprov_field_device_lines"); - __PACKAGE__->add_columns( "id", { @@ -60,10 +50,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "device", "NGCP::Schema::Result::autoprov_field_devices", @@ -71,14 +59,12 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "provisioning_voip_subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "autoprov_device_line_range", "NGCP::Schema::Result::autoprov_device_line_ranges", @@ -92,6 +78,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -166,14 +156,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-10-04 11:19:30 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:uKpCn7D/6aeJAwDWT7k3yw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/autoprov_field_devices.pm b/lib/NGCP/Schema/Result/autoprov_field_devices.pm index f30de436..3cfd5393 100644 --- a/lib/NGCP/Schema/Result/autoprov_field_devices.pm +++ b/lib/NGCP/Schema/Result/autoprov_field_devices.pm @@ -1,23 +1,14 @@ package NGCP::Schema::Result::autoprov_field_devices; use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.autoprov_field_devices"); - __PACKAGE__->add_columns( "id", { @@ -49,11 +40,9 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); __PACKAGE__->add_unique_constraint("uk_identifier_idx", ["identifier"]); - __PACKAGE__->belongs_to( "profile", "NGCP::Schema::Result::autoprov_profiles", @@ -61,7 +50,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::contracts", @@ -82,6 +70,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -150,14 +142,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-09-13 15:15:24 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:nPg7ocQR/hxOrPWVhmsyQA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/autoprov_firmwares.pm b/lib/NGCP/Schema/Result/autoprov_firmwares.pm index db50fdc4..26403e55 100644 --- a/lib/NGCP/Schema/Result/autoprov_firmwares.pm +++ b/lib/NGCP/Schema/Result/autoprov_firmwares.pm @@ -1,23 +1,14 @@ package NGCP::Schema::Result::autoprov_firmwares; use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.autoprov_firmwares"); - __PACKAGE__->add_columns( "id", { @@ -41,10 +32,8 @@ __PACKAGE__->add_columns( { data_type => "longblob", is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "device", "NGCP::Schema::Result::autoprov_devices", @@ -65,6 +54,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -119,14 +112,3 @@ NGCP::Schema::provisioning::Result::autoprov_firmwares Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-09-09 16:43:11 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:HXEGelcjENvGXpVeIfpWOw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/autoprov_profiles.pm b/lib/NGCP/Schema/Result/autoprov_profiles.pm index db89538e..b58398e9 100644 --- a/lib/NGCP/Schema/Result/autoprov_profiles.pm +++ b/lib/NGCP/Schema/Result/autoprov_profiles.pm @@ -1,23 +1,14 @@ package NGCP::Schema::Result::autoprov_profiles; use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.autoprov_profiles"); - __PACKAGE__->add_columns( "id", { @@ -44,10 +35,8 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "config", "NGCP::Schema::Result::autoprov_configs", @@ -55,7 +44,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "firmware", "NGCP::Schema::Result::autoprov_firmwares", @@ -67,12 +55,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -141,14 +134,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-09-09 22:49:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:c7ukjLDxp+bOS99nHMBm6A - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/billing_fees.pm b/lib/NGCP/Schema/Result/billing_fees.pm index 4a595799..2e80d58a 100644 --- a/lib/NGCP/Schema/Result/billing_fees.pm +++ b/lib/NGCP/Schema/Result/billing_fees.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::billing_fees; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.billing_fees"); - __PACKAGE__->add_columns( "id", { @@ -98,10 +88,8 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "billing_fees_histories", "NGCP::Schema::Result::billing_fees_history", @@ -109,7 +97,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "billing_profile", "NGCP::Schema::Result::billing_profiles", @@ -117,7 +104,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "billing_zone", "NGCP::Schema::Result::billing_zones", @@ -129,12 +115,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -288,14 +279,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:arm3oIYMKgMXvCZPEQXC8A - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/billing_fees_history.pm b/lib/NGCP/Schema/Result/billing_fees_history.pm index d61b073a..634d16a9 100644 --- a/lib/NGCP/Schema/Result/billing_fees_history.pm +++ b/lib/NGCP/Schema/Result/billing_fees_history.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::billing_fees_history; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.billing_fees_history"); - __PACKAGE__->add_columns( "id", { @@ -100,10 +90,8 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "bf", "NGCP::Schema::Result::billing_fees", @@ -116,7 +104,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "billing_zones_history", "NGCP::Schema::Result::billing_zones_history", @@ -128,12 +115,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -287,14 +279,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:fWccRpyDJ1pXfVc9EBHWAw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/billing_mappings.pm b/lib/NGCP/Schema/Result/billing_mappings.pm index 4fb20d69..285ecd9d 100644 --- a/lib/NGCP/Schema/Result/billing_mappings.pm +++ b/lib/NGCP/Schema/Result/billing_mappings.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::billing_mappings; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.billing_mappings"); - __PACKAGE__->add_columns( "id", { @@ -61,10 +51,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "billing_profile", "NGCP::Schema::Result::billing_profiles", @@ -77,7 +65,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::contracts", @@ -85,7 +72,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "product", "NGCP::Schema::Result::products", @@ -97,12 +83,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -190,14 +181,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:S6XFjNZ0ZH7q5/z57dvClw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/billing_peaktime_special.pm b/lib/NGCP/Schema/Result/billing_peaktime_special.pm index a179311a..80712993 100644 --- a/lib/NGCP/Schema/Result/billing_peaktime_special.pm +++ b/lib/NGCP/Schema/Result/billing_peaktime_special.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::billing_peaktime_special; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.billing_peaktime_special"); - __PACKAGE__->add_columns( "id", { @@ -47,22 +37,25 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "billing_profile", "NGCP::Schema::Result::billing_profiles", { id => "billing_profile_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -124,14 +117,3 @@ NGCP::Schema::Result::billing_peaktime_special Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Oo6GvhSNBXvZ5yD6HecDfg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/billing_peaktime_weekdays.pm b/lib/NGCP/Schema/Result/billing_peaktime_weekdays.pm index 245f9621..2af8f343 100644 --- a/lib/NGCP/Schema/Result/billing_peaktime_weekdays.pm +++ b/lib/NGCP/Schema/Result/billing_peaktime_weekdays.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::billing_peaktime_weekdays; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.billing_peaktime_weekdays"); - __PACKAGE__->add_columns( "id", { @@ -41,22 +31,25 @@ __PACKAGE__->add_columns( { data_type => "time", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "billing_profile", "NGCP::Schema::Result::billing_profiles", { id => "billing_profile_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -122,14 +115,3 @@ NGCP::Schema::Result::billing_peaktime_weekdays Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Y+10K8lQ4NIWypayYoR3Mg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/billing_profiles.pm b/lib/NGCP/Schema/Result/billing_profiles.pm index 3bf5e2cc..69b53281 100644 --- a/lib/NGCP/Schema/Result/billing_profiles.pm +++ b/lib/NGCP/Schema/Result/billing_profiles.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::billing_profiles; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.billing_profiles"); - __PACKAGE__->add_columns( "id", { @@ -79,16 +69,12 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 1, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("reshand_idx", ["reseller_id", "handle"]); - __PACKAGE__->add_unique_constraint("resnam_idx", ["reseller_id", "name"]); - __PACKAGE__->has_many( "billing_fees", "NGCP::Schema::Result::billing_fees", @@ -96,7 +82,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "billing_mappings", "NGCP::Schema::Result::billing_mappings", @@ -104,7 +89,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "billing_peaktime_specials", "NGCP::Schema::Result::billing_peaktime_special", @@ -112,7 +96,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "billing_peaktime_weekdays", "NGCP::Schema::Result::billing_peaktime_weekdays", @@ -120,7 +103,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "billing_zones", "NGCP::Schema::Result::billing_zones", @@ -128,7 +110,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "products", "NGCP::Schema::Result::products", @@ -136,7 +117,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", @@ -148,12 +128,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -365,14 +350,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:kBsfgQ+Fwqg/LmClPFeS8Q - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/billing_zones.pm b/lib/NGCP/Schema/Result/billing_zones.pm index 379189be..0e22fdba 100644 --- a/lib/NGCP/Schema/Result/billing_zones.pm +++ b/lib/NGCP/Schema/Result/billing_zones.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::billing_zones; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.billing_zones"); - __PACKAGE__->add_columns( "id", { @@ -39,13 +29,10 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 127 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("profnamdes_idx", ["billing_profile_id", "zone", "detail"]); - __PACKAGE__->has_many( "billing_fees", "NGCP::Schema::Result::billing_fees", @@ -53,7 +40,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "billing_profile", "NGCP::Schema::Result::billing_profiles", @@ -61,19 +47,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "billing_zones_histories", "NGCP::Schema::Result::billing_zones_history", { "foreign.bz_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -161,14 +151,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:wUp76Orr9EWY2LhRQtOeTw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/billing_zones_history.pm b/lib/NGCP/Schema/Result/billing_zones_history.pm index ccc576ca..afaa608d 100644 --- a/lib/NGCP/Schema/Result/billing_zones_history.pm +++ b/lib/NGCP/Schema/Result/billing_zones_history.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::billing_zones_history; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.billing_zones_history"); - __PACKAGE__->add_columns( "id", { @@ -41,10 +31,8 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 127 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "billing_fees_histories", "NGCP::Schema::Result::billing_fees_history", @@ -52,7 +40,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "bz", "NGCP::Schema::Result::billing_zones", @@ -64,12 +51,17 @@ __PACKAGE__->belongs_to( on_update => "NO ACTION", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -143,14 +135,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:kmF6BvjNbumSCnH9+xKVpA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/carrier_contracts.pm b/lib/NGCP/Schema/Result/carrier_contracts.pm index d8f7edb6..f60367e0 100644 --- a/lib/NGCP/Schema/Result/carrier_contracts.pm +++ b/lib/NGCP/Schema/Result/carrier_contracts.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::carrier_contracts; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("carrier.contracts"); - __PACKAGE__->add_columns( "id", { @@ -41,13 +31,10 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 127 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("externalid_idx", ["external_id"]); - __PACKAGE__->has_many( "credits", "NGCP::Schema::Result::credits", @@ -55,7 +42,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "customer", "NGCP::Schema::Result::carrier_customers", @@ -68,19 +54,23 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "subscribers", "NGCP::Schema::Result::subscribers", { "foreign.contract_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -170,14 +160,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:50 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:MWXcuL3FRPTIc4QJ5Rwkbg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/carrier_customers.pm b/lib/NGCP/Schema/Result/carrier_customers.pm index f0b40aee..5b914bf8 100644 --- a/lib/NGCP/Schema/Result/carrier_customers.pm +++ b/lib/NGCP/Schema/Result/carrier_customers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::carrier_customers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("carrier.customers"); - __PACKAGE__->add_columns( "id", { @@ -34,16 +24,12 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 31 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("externalid_idx", ["external_id"]); - __PACKAGE__->add_unique_constraint("shopuser_idx", ["shopuser"]); - __PACKAGE__->has_many( "carrier_contracts", "NGCP::Schema::Result::carrier_contracts", @@ -51,19 +37,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "carrier_orders", "NGCP::Schema::Result::carrier_orders", { "foreign.customer_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -148,14 +138,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:50 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:XX9ztRJXpw3s7t3FbfgnpA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/carrier_orders.pm b/lib/NGCP/Schema/Result/carrier_orders.pm index a00d281a..9275a8e7 100644 --- a/lib/NGCP/Schema/Result/carrier_orders.pm +++ b/lib/NGCP/Schema/Result/carrier_orders.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::carrier_orders; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("carrier.orders"); - __PACKAGE__->add_columns( "id", { @@ -35,10 +25,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "customer", "NGCP::Schema::Result::carrier_customers", @@ -46,19 +34,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "carrier_payments", "NGCP::Schema::Result::carrier_payments", { "foreign.order_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -114,14 +106,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:50 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:RZd8/hVfRoeVg+ipiVTDCw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/carrier_payments.pm b/lib/NGCP/Schema/Result/carrier_payments.pm index 48290af9..64a97215 100644 --- a/lib/NGCP/Schema/Result/carrier_payments.pm +++ b/lib/NGCP/Schema/Result/carrier_payments.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::carrier_payments; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("carrier.payments"); - __PACKAGE__->add_columns( "id", { @@ -42,10 +32,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "credit", "NGCP::Schema::Result::credits", @@ -58,7 +46,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "order", "NGCP::Schema::Result::carrier_orders", @@ -70,12 +57,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -138,14 +130,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:50 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:aHymcrxg+BF4S/T620WKfA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/cdr.pm b/lib/NGCP/Schema/Result/cdr.pm index e6d5a924..8b5c3693 100644 --- a/lib/NGCP/Schema/Result/cdr.pm +++ b/lib/NGCP/Schema/Result/cdr.pm @@ -1,16 +1,8 @@ package NGCP::Schema::Result::cdr; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components( "InflateColumn::DateTime", @@ -18,10 +10,8 @@ __PACKAGE__->load_components( "+NGCP::Schema::InflateColumn::DateTime::EpochMilli", ); - __PACKAGE__->table("accounting.cdr"); - __PACKAGE__->add_columns( "id", { @@ -208,14 +198,27 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + +for my $col (qw/init_time start_time/) { + if(__PACKAGE__->has_column($col)) { + __PACKAGE__->remove_column($col); + __PACKAGE__->add_column($col => + { data_type => "decimal", is_nullable => 0, size => [13, 3], inflate_datetime => 'epoch_milli' } + ); + } +} + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -632,20 +635,3 @@ NGCP::Schema::Result::cdr =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:39 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rNMfsyIh9LAGJGoe/or06w - -for my $col (qw/init_time start_time/) { - if(__PACKAGE__->has_column($col)) { - __PACKAGE__->remove_column($col); - __PACKAGE__->add_column($col => - { data_type => "decimal", is_nullable => 0, size => [13, 3], inflate_datetime => 'epoch_milli' } - ); - } -} - -__PACKAGE__->meta->make_immutable; diff --git a/lib/NGCP/Schema/Result/cfg_schema.pm b/lib/NGCP/Schema/Result/cfg_schema.pm index 208dd75b..ddec16c2 100644 --- a/lib/NGCP/Schema/Result/cfg_schema.pm +++ b/lib/NGCP/Schema/Result/cfg_schema.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::cfg_schema; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("ngcp.cfg_schema"); - __PACKAGE__->add_columns( "id", { @@ -39,17 +29,20 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("rev_idx", ["revision", "node"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -115,14 +108,3 @@ NGCP::Schema::Result::cfg_schema =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:03 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:uB2uQwZD0O5Kr7feLw5ekA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/contacts.pm b/lib/NGCP/Schema/Result/contacts.pm index 5fd884b0..6e348a14 100644 --- a/lib/NGCP/Schema/Result/contacts.pm +++ b/lib/NGCP/Schema/Result/contacts.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::contacts; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.contacts"); - __PACKAGE__->add_columns( "id", { @@ -81,10 +71,8 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 31 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", @@ -97,7 +85,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "contracts", "NGCP::Schema::Result::contracts", @@ -105,7 +92,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "customers_comm_contacts", "NGCP::Schema::Result::customers", @@ -113,7 +99,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "customers_contacts", "NGCP::Schema::Result::customers", @@ -121,7 +106,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "customers_tech_contacts", "NGCP::Schema::Result::customers", @@ -129,19 +113,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "orders", "NGCP::Schema::Result::orders", { "foreign.delivery_contact_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -312,14 +300,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:f9lGIGrPbefm2oIODZMn0A - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/contract_balances.pm b/lib/NGCP/Schema/Result/contract_balances.pm index b403461c..73163b00 100644 --- a/lib/NGCP/Schema/Result/contract_balances.pm +++ b/lib/NGCP/Schema/Result/contract_balances.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::contract_balances; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.contract_balances"); - __PACKAGE__->add_columns( "id", { @@ -62,10 +52,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::contracts", @@ -73,7 +61,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "contract_credits", "NGCP::Schema::Result::contract_credits", @@ -81,7 +68,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "invoice", "NGCP::Schema::Result::invoices", @@ -93,12 +79,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -201,14 +192,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:sRLFO3vmh0A+E+mYtc/qHg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/contract_credits.pm b/lib/NGCP/Schema/Result/contract_credits.pm index 1824ad4b..9892a723 100644 --- a/lib/NGCP/Schema/Result/contract_credits.pm +++ b/lib/NGCP/Schema/Result/contract_credits.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::contract_credits; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.contract_credits"); - __PACKAGE__->add_columns( "id", { @@ -60,10 +50,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "balance", "NGCP::Schema::Result::contract_balances", @@ -71,19 +59,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "credit_payments", "NGCP::Schema::Result::credit_payments", { "foreign.credit_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -170,14 +162,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:SoTTHXgpLT25E1NeCDK8ig - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/contract_fraud_preferences.pm b/lib/NGCP/Schema/Result/contract_fraud_preferences.pm index 28e38f74..9817d0ca 100644 --- a/lib/NGCP/Schema/Result/contract_fraud_preferences.pm +++ b/lib/NGCP/Schema/Result/contract_fraud_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::contract_fraud_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.contract_fraud_preferences"); - __PACKAGE__->add_columns( "id", { @@ -47,25 +37,27 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("contract_id", ["contract_id"]); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::contracts", { id => "contract_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -161,14 +153,3 @@ NGCP::Schema::Result::contract_fraud_preferences Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:46 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:vsOWtz3OM7MMgIMAoruagg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/contract_registers.pm b/lib/NGCP/Schema/Result/contract_registers.pm index 29d3425e..74db2252 100644 --- a/lib/NGCP/Schema/Result/contract_registers.pm +++ b/lib/NGCP/Schema/Result/contract_registers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::contract_registers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.contract_registers"); - __PACKAGE__->add_columns( "id", { @@ -41,22 +31,25 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::contracts", { id => "contract_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -123,14 +116,3 @@ NGCP::Schema::Result::contract_registers Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:i2tdRhLpGpYLPFvU0S5sXQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/contracts.pm b/lib/NGCP/Schema/Result/contracts.pm index 88cbf0fb..60a914c4 100644 --- a/lib/NGCP/Schema/Result/contracts.pm +++ b/lib/NGCP/Schema/Result/contracts.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::contracts; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.contracts"); - __PACKAGE__->add_columns( "id", { @@ -84,10 +74,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "billing_mappings", "NGCP::Schema::Result::billing_mappings", @@ -95,7 +83,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "contact", "NGCP::Schema::Result::contacts", @@ -108,7 +95,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "contract_balances", "NGCP::Schema::Result::contract_balances", @@ -116,7 +102,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->might_have( "contract_fraud_preference", "NGCP::Schema::Result::contract_fraud_preferences", @@ -124,7 +109,6 @@ __PACKAGE__->might_have( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "contract_registers", "NGCP::Schema::Result::contract_registers", @@ -132,7 +116,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "customer", "NGCP::Schema::Result::customers", @@ -145,7 +128,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "order", "NGCP::Schema::Result::orders", @@ -158,7 +140,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "voip_subscribers", "NGCP::Schema::Result::voip_subscribers", @@ -193,6 +174,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -355,14 +340,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:M9sf5Sy/nN3bhIaFEtlOWw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/credit_payments.pm b/lib/NGCP/Schema/Result/credit_payments.pm index cbfb6473..035f5c58 100644 --- a/lib/NGCP/Schema/Result/credit_payments.pm +++ b/lib/NGCP/Schema/Result/credit_payments.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::credit_payments; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.credit_payments"); - __PACKAGE__->add_columns( "id", { @@ -42,10 +32,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "credit", "NGCP::Schema::Result::contract_credits", @@ -53,19 +41,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "payment", "NGCP::Schema::Result::payments", { id => "payment_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -128,14 +120,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:b5mY2DCe5CjVuUfRMvqtRA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/credits.pm b/lib/NGCP/Schema/Result/credits.pm index 4158e788..a02e638e 100644 --- a/lib/NGCP/Schema/Result/credits.pm +++ b/lib/NGCP/Schema/Result/credits.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::credits; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("carrier.credits"); - __PACKAGE__->add_columns( "id", { @@ -35,10 +25,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::carrier_contracts", @@ -46,19 +34,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "carrier_payments", "NGCP::Schema::Result::carrier_payments", { "foreign.credit_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -114,14 +106,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:50 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:cq7rxYrgz/j3rG9nKKNa+A - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/customer_registers.pm b/lib/NGCP/Schema/Result/customer_registers.pm index 3cbcfc5d..2024eda9 100644 --- a/lib/NGCP/Schema/Result/customer_registers.pm +++ b/lib/NGCP/Schema/Result/customer_registers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::customer_registers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.customer_registers"); - __PACKAGE__->add_columns( "id", { @@ -41,22 +31,25 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "customer", "NGCP::Schema::Result::customers", { id => "customer_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -123,14 +116,3 @@ NGCP::Schema::Result::customer_registers Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:kGa4KTxeF8y+KuDSuHjiwg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/customers.pm b/lib/NGCP/Schema/Result/customers.pm index 18a31fa4..64cc3db9 100644 --- a/lib/NGCP/Schema/Result/customers.pm +++ b/lib/NGCP/Schema/Result/customers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::customers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.customers"); - __PACKAGE__->add_columns( "id", { @@ -78,13 +68,10 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("reseller_id", ["reseller_id", "shopuser"]); - __PACKAGE__->belongs_to( "comm_contact", "NGCP::Schema::Result::contacts", @@ -97,7 +84,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "contact", "NGCP::Schema::Result::contacts", @@ -110,7 +96,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "contracts", "NGCP::Schema::Result::contracts", @@ -118,7 +103,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "customer_registers", "NGCP::Schema::Result::customer_registers", @@ -126,7 +110,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "orders", "NGCP::Schema::Result::orders", @@ -134,7 +117,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", @@ -147,7 +129,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "tech_contact", "NGCP::Schema::Result::contacts", @@ -159,12 +140,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -321,14 +307,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:y7YqlD6rqhL6T+l5QFCKzA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/db_schema.pm b/lib/NGCP/Schema/Result/db_schema.pm index a88ec09a..cde1e166 100644 --- a/lib/NGCP/Schema/Result/db_schema.pm +++ b/lib/NGCP/Schema/Result/db_schema.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::db_schema; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("ngcp.db_schema"); - __PACKAGE__->add_columns( "id", { @@ -39,17 +29,20 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("rev_idx", ["revision", "node"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -115,14 +108,3 @@ NGCP::Schema::Result::db_schema =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:03 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:G75ihqiXlRQoyJK57K/FfA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/dbaliases.pm b/lib/NGCP/Schema/Result/dbaliases.pm index 94738b86..4c1b7629 100644 --- a/lib/NGCP/Schema/Result/dbaliases.pm +++ b/lib/NGCP/Schema/Result/dbaliases.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::dbaliases; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.dbaliases"); - __PACKAGE__->add_columns( "id", { @@ -36,17 +26,20 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("alias_idx", ["alias_username", "alias_domain"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -121,14 +114,3 @@ NGCP::Schema::Result::dbaliases =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:5S1hFbo4/Dpv6+ytWwhOxg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/dialog.pm b/lib/NGCP/Schema/Result/dialog.pm index 4eab97d5..f63bca7f 100644 --- a/lib/NGCP/Schema/Result/dialog.pm +++ b/lib/NGCP/Schema/Result/dialog.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::dialog; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.dialog"); - __PACKAGE__->add_columns( "id", { @@ -89,14 +79,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 512 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -272,14 +266,3 @@ NGCP::Schema::Result::dialog =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum://TB31SImEvxJ2xdwlclYg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/dialog_vars.pm b/lib/NGCP/Schema/Result/dialog_vars.pm index 2ffb4be2..e6e16eb4 100644 --- a/lib/NGCP/Schema/Result/dialog_vars.pm +++ b/lib/NGCP/Schema/Result/dialog_vars.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::dialog_vars; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.dialog_vars"); - __PACKAGE__->add_columns( "id", { @@ -36,14 +26,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 512 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -102,14 +96,3 @@ NGCP::Schema::Result::dialog_vars =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:BX3ztSsppPyuHUF2WlkEfQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/dialplan.pm b/lib/NGCP/Schema/Result/dialplan.pm index 114342bf..90329148 100644 --- a/lib/NGCP/Schema/Result/dialplan.pm +++ b/lib/NGCP/Schema/Result/dialplan.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::dialplan; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.dialplan"); - __PACKAGE__->add_columns( "id", { @@ -44,14 +34,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 32 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -130,14 +124,3 @@ NGCP::Schema::Result::dialplan =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:0zWWAUqsTsvOvZ6V/RwXEA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/dispatcher.pm b/lib/NGCP/Schema/Result/dispatcher.pm index e2af5e7d..d7e0bd48 100644 --- a/lib/NGCP/Schema/Result/dispatcher.pm +++ b/lib/NGCP/Schema/Result/dispatcher.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::dispatcher; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.dispatcher"); - __PACKAGE__->add_columns( "id", { @@ -40,14 +30,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -121,14 +115,3 @@ NGCP::Schema::Result::dispatcher =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:5jzrLkll7DO38SycdSaTXQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/dom_preferences.pm b/lib/NGCP/Schema/Result/dom_preferences.pm index c28755d0..ac2754cd 100644 --- a/lib/NGCP/Schema/Result/dom_preferences.pm +++ b/lib/NGCP/Schema/Result/dom_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::dom_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.dom_preferences"); - __PACKAGE__->add_columns( "id", { @@ -47,14 +37,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -136,14 +130,3 @@ NGCP::Schema::Result::dom_preferences =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:OlDocoyhD05x+pad1EtlbA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/domain.pm b/lib/NGCP/Schema/Result/domain.pm index 82a184c3..105c11e3 100644 --- a/lib/NGCP/Schema/Result/domain.pm +++ b/lib/NGCP/Schema/Result/domain.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::domain; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.domain"); - __PACKAGE__->add_columns( "id", { @@ -39,17 +29,20 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("domain_idx", ["domain"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -113,14 +106,3 @@ NGCP::Schema::Result::domain =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:RT3m/mCu0f8cNAITLtDaJg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/domain_attrs.pm b/lib/NGCP/Schema/Result/domain_attrs.pm index c65a7699..22074f14 100644 --- a/lib/NGCP/Schema/Result/domain_attrs.pm +++ b/lib/NGCP/Schema/Result/domain_attrs.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::domain_attrs; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.domain_attrs"); - __PACKAGE__->add_columns( "id", { @@ -43,17 +33,20 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("domain_attrs_idx", ["did", "name", "value"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -133,14 +126,3 @@ NGCP::Schema::Result::domain_attrs =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:pAZuyhtxIitvW8RtbIxPJA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/domain_resellers.pm b/lib/NGCP/Schema/Result/domain_resellers.pm index 3ab5b0e9..11114a15 100644 --- a/lib/NGCP/Schema/Result/domain_resellers.pm +++ b/lib/NGCP/Schema/Result/domain_resellers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::domain_resellers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.domain_resellers"); - __PACKAGE__->add_columns( "id", { @@ -42,10 +32,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "domain", "NGCP::Schema::Result::domains", @@ -53,19 +41,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", { id => "reseller_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -128,14 +120,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:c/brst43n5Q/K2Uxl4+69w - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/domains.pm b/lib/NGCP/Schema/Result/domains.pm index c5badbfb..b3017241 100644 --- a/lib/NGCP/Schema/Result/domains.pm +++ b/lib/NGCP/Schema/Result/domains.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::domains; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.domains"); - __PACKAGE__->add_columns( "id", { @@ -30,13 +20,10 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 127 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("domain_idx", ["domain"]); - __PACKAGE__->has_many( "domain_resellers", "NGCP::Schema::Result::domain_resellers", @@ -44,19 +31,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_subscribers", "NGCP::Schema::Result::voip_subscribers", { "foreign.domain_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -121,14 +112,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:408RZZEOBWuD1+SjUnYbHA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/fax_destinations.pm b/lib/NGCP/Schema/Result/fax_destinations.pm index 8fc07b97..33e180f1 100644 --- a/lib/NGCP/Schema/Result/fax_destinations.pm +++ b/lib/NGCP/Schema/Result/fax_destinations.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::fax_destinations; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.fax_destinations"); - __PACKAGE__->add_columns( "id", { @@ -67,14 +57,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -156,14 +150,3 @@ NGCP::Schema::Result::fax_destinations =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:QadQu9QxzBRrdhCSsRraTg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/fax_journal.pm b/lib/NGCP/Schema/Result/fax_journal.pm index c40228c4..3f454e86 100644 --- a/lib/NGCP/Schema/Result/fax_journal.pm +++ b/lib/NGCP/Schema/Result/fax_journal.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::fax_journal; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.fax_journal"); - __PACKAGE__->add_columns( "id", { @@ -82,14 +72,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -207,14 +201,3 @@ NGCP::Schema::Result::fax_journal =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:TEf0WRwgQKpJvAFVrHG6SA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/fax_preferences.pm b/lib/NGCP/Schema/Result/fax_preferences.pm index 78c70776..d7982e29 100644 --- a/lib/NGCP/Schema/Result/fax_preferences.pm +++ b/lib/NGCP/Schema/Result/fax_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::fax_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.fax_preferences"); - __PACKAGE__->add_columns( "subscriber_id", { data_type => "integer", extra => { unsigned => 1 }, is_nullable => 0 }, @@ -55,14 +45,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("subscriber_id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -136,14 +130,3 @@ NGCP::Schema::Result::fax_preferences =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:uAuDAVv+/jziv3khAD57Jg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/htable.pm b/lib/NGCP/Schema/Result/htable.pm index 8b73d1b0..15cf1d00 100644 --- a/lib/NGCP/Schema/Result/htable.pm +++ b/lib/NGCP/Schema/Result/htable.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::htable; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.htable"); - __PACKAGE__->add_columns( "id", { @@ -38,14 +28,18 @@ __PACKAGE__->add_columns( { data_type => "integer", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -112,14 +106,3 @@ NGCP::Schema::Result::htable =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:mBXHtm+jpq6H55FwzNEMFg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/interceptions.pm b/lib/NGCP/Schema/Result/interceptions.pm index 0ba46eee..5556a4e5 100644 --- a/lib/NGCP/Schema/Result/interceptions.pm +++ b/lib/NGCP/Schema/Result/interceptions.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::interceptions; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("carrier.interceptions"); - __PACKAGE__->add_columns( "id", { @@ -30,14 +20,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 31 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -78,14 +72,3 @@ NGCP::Schema::Result::interceptions =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:50 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:hIPHw93VVP18hXKsKMflxw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/invoices.pm b/lib/NGCP/Schema/Result/invoices.pm index ceee1d23..ec7aacc0 100644 --- a/lib/NGCP/Schema/Result/invoices.pm +++ b/lib/NGCP/Schema/Result/invoices.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::invoices; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.invoices"); - __PACKAGE__->add_columns( "id", { @@ -36,13 +26,10 @@ __PACKAGE__->add_columns( { data_type => "blob", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("yms_idx", ["year", "month", "serial"]); - __PACKAGE__->has_many( "contract_balances", "NGCP::Schema::Result::contract_balances", @@ -50,19 +37,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "orders", "NGCP::Schema::Result::orders", { "foreign.invoice_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -148,14 +139,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:hszT+4EqnW8rTicg2nvr6w - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/kamailio_acc.pm b/lib/NGCP/Schema/Result/kamailio_acc.pm index d84dcb3c..3389388c 100644 --- a/lib/NGCP/Schema/Result/kamailio_acc.pm +++ b/lib/NGCP/Schema/Result/kamailio_acc.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::kamailio_acc; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.acc"); - __PACKAGE__->add_columns( "id", { @@ -69,14 +59,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 128 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -214,14 +208,3 @@ NGCP::Schema::Result::kamailio_acc =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:58 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:aNoNq/I64bo72Qh02K9WEg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/kamailio_acc_backup.pm b/lib/NGCP/Schema/Result/kamailio_acc_backup.pm index b6b0eb4f..b4db8752 100644 --- a/lib/NGCP/Schema/Result/kamailio_acc_backup.pm +++ b/lib/NGCP/Schema/Result/kamailio_acc_backup.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::kamailio_acc_backup; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.acc_backup"); - __PACKAGE__->add_columns( "id", { @@ -69,14 +59,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 128 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -214,14 +208,3 @@ NGCP::Schema::Result::kamailio_acc_backup =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:58 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ytEmWh6kooVkBo656daUlg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/kamailio_acc_trash.pm b/lib/NGCP/Schema/Result/kamailio_acc_trash.pm index 4eac6762..19b75219 100644 --- a/lib/NGCP/Schema/Result/kamailio_acc_trash.pm +++ b/lib/NGCP/Schema/Result/kamailio_acc_trash.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::kamailio_acc_trash; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.acc_trash"); - __PACKAGE__->add_columns( "id", { @@ -69,14 +59,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 128 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -214,14 +208,3 @@ NGCP::Schema::Result::kamailio_acc_trash =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:58 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qaAjbljClGuz7EgyTx3A1Q - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/language_strings.pm b/lib/NGCP/Schema/Result/language_strings.pm index 332da5fb..41815b66 100644 --- a/lib/NGCP/Schema/Result/language_strings.pm +++ b/lib/NGCP/Schema/Result/language_strings.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::language_strings; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.language_strings"); - __PACKAGE__->add_columns( "id", { @@ -34,17 +24,20 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("codelang_idx", ["code", "language"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -108,14 +101,3 @@ NGCP::Schema::Result::language_strings =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:+MFxT4fyKRXsi0KEWgCIcA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/lcr_gw.pm b/lib/NGCP/Schema/Result/lcr_gw.pm index c7699b4e..9e700cd9 100644 --- a/lib/NGCP/Schema/Result/lcr_gw.pm +++ b/lib/NGCP/Schema/Result/lcr_gw.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::lcr_gw; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.lcr_gw"); - __PACKAGE__->add_columns( "id", { @@ -61,28 +51,29 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 16 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("lcr_id_gw_name_idx", ["lcr_id", "gw_name"]); - __PACKAGE__->add_unique_constraint("lcr_id_ip_addr_idx", ["lcr_id", "ip_addr"]); - __PACKAGE__->has_many( "lcr_rule_targets", "NGCP::Schema::Result::lcr_rule_target", { "foreign.gw_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -232,14 +223,3 @@ NGCP::Schema::Result::lcr_gw Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:3xvIcw0YamScXUux+OxFog - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/lcr_rule.pm b/lib/NGCP/Schema/Result/lcr_rule.pm index edba51fe..0ef5f63f 100644 --- a/lib/NGCP/Schema/Result/lcr_rule.pm +++ b/lib/NGCP/Schema/Result/lcr_rule.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::lcr_rule; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.lcr_rule"); - __PACKAGE__->add_columns( "id", { @@ -52,28 +42,30 @@ __PACKAGE__->add_columns( { data_type => "integer", extra => { unsigned => 1 }, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint( "lcr_id_prefix_from_uri_idx", ["lcr_id", "prefix", "from_uri", "request_uri", "group_id"], ); - __PACKAGE__->has_many( "lcr_rule_targets", "NGCP::Schema::Result::lcr_rule_target", { "foreign.rule_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -179,14 +171,3 @@ NGCP::Schema::Result::lcr_rule Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:VLDo6V10HsYZMqW1xv0mOg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/lcr_rule_target.pm b/lib/NGCP/Schema/Result/lcr_rule_target.pm index d294d160..daee1913 100644 --- a/lib/NGCP/Schema/Result/lcr_rule_target.pm +++ b/lib/NGCP/Schema/Result/lcr_rule_target.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::lcr_rule_target; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.lcr_rule_target"); - __PACKAGE__->add_columns( "id", { @@ -53,13 +43,10 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("rule_id_gw_id_idx", ["rule_id", "gw_id"]); - __PACKAGE__->belongs_to( "gw", "NGCP::Schema::Result::lcr_gw", @@ -67,19 +54,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "rule", "NGCP::Schema::Result::lcr_rule", { id => "rule_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -173,14 +164,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:CD/mdYijs1mw7UL9qRWh8w - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/lnp_numbers.pm b/lib/NGCP/Schema/Result/lnp_numbers.pm index a2e437ce..9994ac4f 100644 --- a/lib/NGCP/Schema/Result/lnp_numbers.pm +++ b/lib/NGCP/Schema/Result/lnp_numbers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::lnp_numbers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.lnp_numbers"); - __PACKAGE__->add_columns( "id", { @@ -49,22 +39,25 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "lnp_provider", "NGCP::Schema::Result::lnp_providers", { id => "lnp_provider_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -132,14 +125,3 @@ NGCP::Schema::Result::lnp_numbers Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:tGBeT84ulgbvuK+sAv4ZfA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/lnp_providers.pm b/lib/NGCP/Schema/Result/lnp_providers.pm index 28b86438..040f8a8a 100644 --- a/lib/NGCP/Schema/Result/lnp_providers.pm +++ b/lib/NGCP/Schema/Result/lnp_providers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::lnp_providers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.lnp_providers"); - __PACKAGE__->add_columns( "id", { data_type => "integer", extra => { unsigned => 1 }, is_nullable => 0 }, @@ -25,10 +15,8 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "lnp_numbers", "NGCP::Schema::Result::lnp_numbers", @@ -36,19 +24,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "ncos_lnp_lists", "NGCP::Schema::Result::ncos_lnp_list", { "foreign.lnp_provider_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -102,14 +94,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:RX3uJZqBdZ7o0gpZFV3vZQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/location.pm b/lib/NGCP/Schema/Result/location.pm index c7c0ea57..09886f7f 100644 --- a/lib/NGCP/Schema/Result/location.pm +++ b/lib/NGCP/Schema/Result/location.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::location; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.location"); - __PACKAGE__->add_columns( "id", { @@ -84,17 +74,20 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("ruid_idx", ["ruid"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -254,14 +247,3 @@ NGCP::Schema::Result::location =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:1ApRNGpNTS22heMpd2MjLQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/location_attrs.pm b/lib/NGCP/Schema/Result/location_attrs.pm index 698d8a19..df94f825 100644 --- a/lib/NGCP/Schema/Result/location_attrs.pm +++ b/lib/NGCP/Schema/Result/location_attrs.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::location_attrs; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.location_attrs"); - __PACKAGE__->add_columns( "id", { @@ -47,14 +37,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -136,14 +130,3 @@ NGCP::Schema::Result::location_attrs =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:tLkGn8xK97wMsEjERwMF6A - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/mark.pm b/lib/NGCP/Schema/Result/mark.pm index 72b83522..31acfa81 100644 --- a/lib/NGCP/Schema/Result/mark.pm +++ b/lib/NGCP/Schema/Result/mark.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::mark; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("accounting.mark"); - __PACKAGE__->add_columns( "id", { @@ -32,14 +22,18 @@ __PACKAGE__->add_columns( { data_type => "integer", extra => { unsigned => 1 }, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -86,14 +80,3 @@ NGCP::Schema::Result::mark =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:39 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Ukv7v8i+NsHWpR11rgC4Ww - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/message_packets.pm b/lib/NGCP/Schema/Result/message_packets.pm index 8fd7e305..5d17de03 100644 --- a/lib/NGCP/Schema/Result/message_packets.pm +++ b/lib/NGCP/Schema/Result/message_packets.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::message_packets; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("sipstats.message_packets"); - __PACKAGE__->add_columns( "message", { data_type => "bigint", extra => { unsigned => 1 }, is_nullable => 0 }, @@ -32,7 +22,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "message", "NGCP::Schema::Result::messages", @@ -41,12 +30,17 @@ __PACKAGE__->belongs_to( ); __PACKAGE__->set_primary_key("message", "packet"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -88,14 +82,3 @@ NGCP::Schema::Result::message_packets =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:12 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:3CvBPiIZYVwwf8w/PskEcg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/messages.pm b/lib/NGCP/Schema/Result/messages.pm index 9c0543a8..5e9b5b35 100644 --- a/lib/NGCP/Schema/Result/messages.pm +++ b/lib/NGCP/Schema/Result/messages.pm @@ -1,27 +1,17 @@ package NGCP::Schema::Result::messages; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components( - "InflateColumn::DateTime", + "InflateColumn::DateTime", "Helper::Row::ToJSON", "+NGCP::Schema::InflateColumn::DateTime::EpochMicro", ); - __PACKAGE__->table("sipstats.messages"); - __PACKAGE__->add_columns( "id", { @@ -83,12 +73,26 @@ __PACKAGE__->has_many( ); __PACKAGE__->set_primary_key("id"); + +for my $col (qw/timestamp/) { + if(__PACKAGE__->has_column($col)) { + __PACKAGE__->remove_column($col); + __PACKAGE__->add_column($col => + { data_type => "decimal", is_nullable => 0, size => [17, 6], inflate_datetime => 'epoch_micro' } + ); + } +} + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -213,21 +217,3 @@ NGCP::Schema::Result::messages =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:12 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:bYbdYKBz9w7LgX1fXS2wzQ - -for my $col (qw/timestamp/) { - if(__PACKAGE__->has_column($col)) { - __PACKAGE__->remove_column($col); - __PACKAGE__->add_column($col => - { data_type => "decimal", is_nullable => 0, size => [17, 6], inflate_datetime => 'epoch_micro' } - ); - } -} - -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/mobile_push_registrations.pm b/lib/NGCP/Schema/Result/mobile_push_registrations.pm index 7bfafd40..c0fc9ff8 100644 --- a/lib/NGCP/Schema/Result/mobile_push_registrations.pm +++ b/lib/NGCP/Schema/Result/mobile_push_registrations.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::mobile_push_registrations; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.mobile_push_registrations"); - __PACKAGE__->add_columns( "reg_id", { data_type => "varbinary", is_nullable => 0, size => 255 }, @@ -43,14 +33,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("reg_id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -104,14 +98,3 @@ NGCP::Schema::Result::mobile_push_registrations =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:XY4ijL/JrJa4QXX0sOAhjA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/ncos_levels.pm b/lib/NGCP/Schema/Result/ncos_levels.pm index 8507807d..3bde1ebd 100644 --- a/lib/NGCP/Schema/Result/ncos_levels.pm +++ b/lib/NGCP/Schema/Result/ncos_levels.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::ncos_levels; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.ncos_levels"); - __PACKAGE__->add_columns( "id", { @@ -48,13 +38,10 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("reslev_idx", ["reseller_id", "level"]); - __PACKAGE__->has_many( "ncos_lnp_lists", "NGCP::Schema::Result::ncos_lnp_list", @@ -62,7 +49,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "ncos_pattern_lists", "NGCP::Schema::Result::ncos_pattern_list", @@ -70,7 +56,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", @@ -82,12 +67,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -185,14 +175,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:o/iMN7CPlUuTqhp514feZg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/ncos_lnp_list.pm b/lib/NGCP/Schema/Result/ncos_lnp_list.pm index e50a934c..16223221 100644 --- a/lib/NGCP/Schema/Result/ncos_lnp_list.pm +++ b/lib/NGCP/Schema/Result/ncos_lnp_list.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::ncos_lnp_list; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.ncos_lnp_list"); - __PACKAGE__->add_columns( "id", { @@ -44,13 +34,10 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("levpro_idx", ["ncos_level_id", "lnp_provider_id"]); - __PACKAGE__->belongs_to( "lnp_provider", "NGCP::Schema::Result::lnp_providers", @@ -58,19 +45,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "ncos_level", "NGCP::Schema::Result::ncos_levels", { id => "ncos_level_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -150,14 +141,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:tyFy2q6Pb4BVZlO51cYXrw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/ncos_pattern_list.pm b/lib/NGCP/Schema/Result/ncos_pattern_list.pm index 6863b025..26811980 100644 --- a/lib/NGCP/Schema/Result/ncos_pattern_list.pm +++ b/lib/NGCP/Schema/Result/ncos_pattern_list.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::ncos_pattern_list; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.ncos_pattern_list"); - __PACKAGE__->add_columns( "id", { @@ -39,25 +29,27 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("levpat_idx", ["ncos_level_id", "pattern"]); - __PACKAGE__->belongs_to( "ncos_level", "NGCP::Schema::Result::ncos_levels", { id => "ncos_level_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -130,14 +122,3 @@ NGCP::Schema::Result::ncos_pattern_list Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:l/bo1cbK1S2QD528GlpRTg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/numbers.pm b/lib/NGCP/Schema/Result/numbers.pm index 755fab77..a2947a5a 100644 --- a/lib/NGCP/Schema/Result/numbers.pm +++ b/lib/NGCP/Schema/Result/numbers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::numbers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("carrier.numbers"); - __PACKAGE__->add_columns( "number", { data_type => "varchar", is_nullable => 0, size => 42 }, @@ -30,10 +20,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("number"); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::subscribers", @@ -45,12 +33,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -99,14 +92,3 @@ NGCP::Schema::Result::numbers Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:50 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ln3HIKttfpB2ZwCbMqOFfw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/order_payments.pm b/lib/NGCP/Schema/Result/order_payments.pm index 37be789b..b7b1170c 100644 --- a/lib/NGCP/Schema/Result/order_payments.pm +++ b/lib/NGCP/Schema/Result/order_payments.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::order_payments; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.order_payments"); - __PACKAGE__->add_columns( "id", { @@ -42,10 +32,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "order", "NGCP::Schema::Result::orders", @@ -53,19 +41,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "payment", "NGCP::Schema::Result::payments", { id => "payment_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -128,14 +120,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:P6uf3+Wz3k5sIDeH2QPo7A - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/orders.pm b/lib/NGCP/Schema/Result/orders.pm index 8d27fb15..7034c4ec 100644 --- a/lib/NGCP/Schema/Result/orders.pm +++ b/lib/NGCP/Schema/Result/orders.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::orders; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.orders"); - __PACKAGE__->add_columns( "id", { @@ -90,10 +80,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "contracts", "NGCP::Schema::Result::contracts", @@ -101,7 +89,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "customer", "NGCP::Schema::Result::customers", @@ -114,7 +101,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "delivery_contact", "NGCP::Schema::Result::contacts", @@ -127,7 +113,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "invoice", "NGCP::Schema::Result::invoices", @@ -140,7 +125,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "order_payments", "NGCP::Schema::Result::order_payments", @@ -148,7 +132,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", @@ -160,12 +143,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -310,14 +298,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:IRUPJVWT80Ma2hxsKnT9Tw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/packets.pm b/lib/NGCP/Schema/Result/packets.pm index f49c258c..4c97decf 100644 --- a/lib/NGCP/Schema/Result/packets.pm +++ b/lib/NGCP/Schema/Result/packets.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::packets; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("sipstats.packets"); - __PACKAGE__->add_columns( "id", { @@ -48,12 +38,17 @@ __PACKAGE__->has_many( ); __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -121,14 +116,3 @@ NGCP::Schema::Result::packets =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:12 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:xyCGQ5SkZR7CCIQUdOkTlA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/payments.pm b/lib/NGCP/Schema/Result/payments.pm index a6fc1a4f..e6ce1727 100644 --- a/lib/NGCP/Schema/Result/payments.pm +++ b/lib/NGCP/Schema/Result/payments.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::payments; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.payments"); - __PACKAGE__->add_columns( "id", { @@ -62,10 +52,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "credit_payments", "NGCP::Schema::Result::credit_payments", @@ -73,19 +61,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "order_payments", "NGCP::Schema::Result::order_payments", { "foreign.payment_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -193,14 +185,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:zW9AaD/pkQ5yi4/lNeRq0A - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/peer_preferences.pm b/lib/NGCP/Schema/Result/peer_preferences.pm index e0f6dac0..b651f5db 100644 --- a/lib/NGCP/Schema/Result/peer_preferences.pm +++ b/lib/NGCP/Schema/Result/peer_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::peer_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.peer_preferences"); - __PACKAGE__->add_columns( "id", { @@ -47,14 +37,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -136,14 +130,3 @@ NGCP::Schema::Result::peer_preferences =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:mbF+UBu0qW3QDrSDiaa+Ww - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/prepaid_costs.pm b/lib/NGCP/Schema/Result/prepaid_costs.pm index e0e73aeb..55e3c307 100644 --- a/lib/NGCP/Schema/Result/prepaid_costs.pm +++ b/lib/NGCP/Schema/Result/prepaid_costs.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::prepaid_costs; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("accounting.prepaid_costs"); - __PACKAGE__->add_columns( "id", { @@ -41,14 +31,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -107,14 +101,3 @@ NGCP::Schema::Result::prepaid_costs =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:39 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:iOK0ghqc1h66203Vxld/Xw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/presentity.pm b/lib/NGCP/Schema/Result/presentity.pm index f994d611..7d1903f2 100644 --- a/lib/NGCP/Schema/Result/presentity.pm +++ b/lib/NGCP/Schema/Result/presentity.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::presentity; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.presentity"); - __PACKAGE__->add_columns( "id", { @@ -44,17 +34,20 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 128 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("presentity_idx", ["username", "domain", "event", "etag"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -150,14 +143,3 @@ NGCP::Schema::Result::presentity =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:wa/a4rhqsQwta6+sTruhvw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/products.pm b/lib/NGCP/Schema/Result/products.pm index f132dfee..892ccfaa 100644 --- a/lib/NGCP/Schema/Result/products.pm +++ b/lib/NGCP/Schema/Result/products.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::products; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.products"); - __PACKAGE__->add_columns( "id", { @@ -66,16 +56,12 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("reshand_idx", ["reseller_id", "handle"]); - __PACKAGE__->add_unique_constraint("resnam_idx", ["reseller_id", "name"]); - __PACKAGE__->has_many( "billing_mappings", "NGCP::Schema::Result::billing_mappings", @@ -83,7 +69,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "billing_profile", "NGCP::Schema::Result::billing_profiles", @@ -96,7 +81,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", @@ -108,12 +92,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -239,14 +228,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:W5QBTDCAY3GR3SLhhuuwIw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/provisioning_voip_subscribers.pm b/lib/NGCP/Schema/Result/provisioning_voip_subscribers.pm index 73906948..9369efd4 100644 --- a/lib/NGCP/Schema/Result/provisioning_voip_subscribers.pm +++ b/lib/NGCP/Schema/Result/provisioning_voip_subscribers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::provisioning_voip_subscribers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_subscribers"); - __PACKAGE__->add_columns( "id", { @@ -67,19 +57,14 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("user_dom_idx", ["username", "domain_id"]); - __PACKAGE__->add_unique_constraint("uuid_idx", ["uuid"]); - __PACKAGE__->add_unique_constraint("webuser_dom_idx", ["webusername", "domain_id"]); - __PACKAGE__->belongs_to( "domain", "NGCP::Schema::Result::voip_domains", @@ -94,7 +79,6 @@ __PACKAGE__->belongs_to( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_cc_mappings", "NGCP::Schema::Result::voip_cc_mappings", @@ -102,7 +86,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_cf_destination_sets", "NGCP::Schema::Result::voip_cf_destination_sets", @@ -110,7 +93,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_cf_mappings", "NGCP::Schema::Result::voip_cf_mappings", @@ -118,7 +100,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_cf_time_sets", "NGCP::Schema::Result::voip_cf_time_sets", @@ -126,7 +107,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_contacts", "NGCP::Schema::Result::voip_contacts", @@ -134,7 +114,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_dbaliases", "NGCP::Schema::Result::voip_dbaliases", @@ -142,7 +121,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_fax_destinations", "NGCP::Schema::Result::voip_fax_destinations", @@ -150,7 +128,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->might_have( "voip_fax_preference", "NGCP::Schema::Result::voip_fax_preferences", @@ -158,7 +135,6 @@ __PACKAGE__->might_have( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->might_have( "voip_reminder", "NGCP::Schema::Result::voip_reminder", @@ -166,7 +142,6 @@ __PACKAGE__->might_have( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_speed_dials", "NGCP::Schema::Result::voip_speed_dial", @@ -174,7 +149,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_trusted_sources", "NGCP::Schema::Result::voip_trusted_sources", @@ -182,7 +156,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_usr_preferences", "NGCP::Schema::Result::voip_usr_preferences", @@ -238,6 +211,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -463,36 +440,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Qpw0gD+LaI+g0k3EWr42tQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration - -__PACKAGE__->has_one( - "voip_subscriber", - 'NGCP::Schema::Result::voip_subscribers', - { 'foreign.uuid' => 'self.uuid' }, - { cascade_copy => 0, cascade_delete => 0 }, -); - -__PACKAGE__->belongs_to( - "contract", - "NGCP::Schema::Result::contracts", - { 'foreign.id' => 'self.account_id' }, - { cascade_copy => 0, cascade_delete => 0 }, -); - -__PACKAGE__->has_one( - "voicemail_user", - "NGCP::Schema::Result::voicemail_users", - { "foreign.customer_id" => "self.uuid" }, - { cascade_copy => 1, cascade_delete => 1 }, -); - -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/pua.pm b/lib/NGCP/Schema/Result/pua.pm index 6f9e1ac4..58802f06 100644 --- a/lib/NGCP/Schema/Result/pua.pm +++ b/lib/NGCP/Schema/Result/pua.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::pua; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.pua"); - __PACKAGE__->add_columns( "id", { @@ -64,17 +54,20 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("pua_idx", ["etag", "tuple_id", "call_id", "from_tag"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -225,14 +218,3 @@ NGCP::Schema::Result::pua =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ygJUzcwYOslx7C8IYsJriQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/resellers.pm b/lib/NGCP/Schema/Result/resellers.pm index 06f1f4bf..1ec16b7b 100644 --- a/lib/NGCP/Schema/Result/resellers.pm +++ b/lib/NGCP/Schema/Result/resellers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::resellers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.resellers"); - __PACKAGE__->add_columns( "id", { @@ -44,16 +34,12 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("contractid_idx", ["contract_id"]); - __PACKAGE__->add_unique_constraint("name_idx", ["name"]); - __PACKAGE__->has_many( "admins", "NGCP::Schema::Result::admins", @@ -61,7 +47,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "billing_profiles", "NGCP::Schema::Result::billing_profiles", @@ -69,7 +54,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::contracts", @@ -77,7 +61,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "customers", "NGCP::Schema::Result::customers", @@ -85,7 +68,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "domain_resellers", "NGCP::Schema::Result::domain_resellers", @@ -93,7 +75,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "ncos_levels", "NGCP::Schema::Result::ncos_levels", @@ -101,7 +82,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "orders", "NGCP::Schema::Result::orders", @@ -109,7 +89,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "products", "NGCP::Schema::Result::products", @@ -117,7 +96,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_intercepts", "NGCP::Schema::Result::voip_intercept", @@ -125,7 +103,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_number_block_resellers", "NGCP::Schema::Result::voip_number_block_resellers", @@ -133,7 +110,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_numbers", "NGCP::Schema::Result::voip_numbers", @@ -168,6 +144,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -308,14 +288,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:jwPBSCFSUgONmOLVp+SO+w - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/rls_presentity.pm b/lib/NGCP/Schema/Result/rls_presentity.pm index ae13ba19..5d933113 100644 --- a/lib/NGCP/Schema/Result/rls_presentity.pm +++ b/lib/NGCP/Schema/Result/rls_presentity.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::rls_presentity; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.rls_presentity"); - __PACKAGE__->add_columns( "id", { @@ -44,17 +34,20 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("rls_presentity_idx", ["rlsubs_did", "resource_uri"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -145,14 +138,3 @@ NGCP::Schema::Result::rls_presentity =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:+oFx6xWrVArjVR9iOQCDbQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/rls_watchers.pm b/lib/NGCP/Schema/Result/rls_watchers.pm index 2db12462..7063c739 100644 --- a/lib/NGCP/Schema/Result/rls_watchers.pm +++ b/lib/NGCP/Schema/Result/rls_watchers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::rls_watchers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.rls_watchers"); - __PACKAGE__->add_columns( "id", { @@ -79,17 +69,20 @@ __PACKAGE__->add_columns( { data_type => "integer", is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("rls_watcher_idx", ["callid", "to_tag", "from_tag"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -272,14 +265,3 @@ NGCP::Schema::Result::rls_watchers =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:7Hom3LtfcQnLjuPvKVQ6ig - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/sca_subscriptions.pm b/lib/NGCP/Schema/Result/sca_subscriptions.pm index 449a4c9f..5c8d11c4 100644 --- a/lib/NGCP/Schema/Result/sca_subscriptions.pm +++ b/lib/NGCP/Schema/Result/sca_subscriptions.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::sca_subscriptions; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.sca_subscriptions"); - __PACKAGE__->add_columns( "id", { @@ -52,20 +42,23 @@ __PACKAGE__->add_columns( { data_type => "integer", is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint( "sca_subscriptions_idx", ["subscriber", "call_id", "from_tag", "to_tag"], ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -185,14 +178,3 @@ NGCP::Schema::Result::sca_subscriptions =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:psR3WnlgoB7BZkCzsi0gRw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/sems_registrations.pm b/lib/NGCP/Schema/Result/sems_registrations.pm index c0746065..38f97b50 100644 --- a/lib/NGCP/Schema/Result/sems_registrations.pm +++ b/lib/NGCP/Schema/Result/sems_registrations.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::sems_registrations; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.sems_registrations"); - __PACKAGE__->add_columns( "subscriber_id", { data_type => "integer", is_nullable => 0 }, @@ -43,14 +33,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 512 }, ); - __PACKAGE__->set_primary_key("subscriber_id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -118,14 +112,3 @@ NGCP::Schema::Result::sems_registrations =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:keH+HF16e8LQPC4Up/54Tg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/silo.pm b/lib/NGCP/Schema/Result/silo.pm index 024262c7..68dcb885 100644 --- a/lib/NGCP/Schema/Result/silo.pm +++ b/lib/NGCP/Schema/Result/silo.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::silo; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.silo"); - __PACKAGE__->add_columns( "id", { @@ -57,14 +47,18 @@ __PACKAGE__->add_columns( { data_type => "integer", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -175,14 +169,3 @@ NGCP::Schema::Result::silo =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:1YSmqYtHyiP9lYfL0mAFHg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/sipstats_mark.pm b/lib/NGCP/Schema/Result/sipstats_mark.pm index 9c44dbb9..17de4bee 100644 --- a/lib/NGCP/Schema/Result/sipstats_mark.pm +++ b/lib/NGCP/Schema/Result/sipstats_mark.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::sipstats_mark; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("sipstats.mark"); - __PACKAGE__->add_columns( "name", { data_type => "varchar", is_nullable => 0, size => 255 }, @@ -25,14 +15,18 @@ __PACKAGE__->add_columns( { data_type => "bigint", extra => { unsigned => 1 }, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("name"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -72,14 +66,3 @@ NGCP::Schema::Result::sipstats_mark =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:12 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:q2fscRrY5Zv1w5Sf6kb3pg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/speed_dial.pm b/lib/NGCP/Schema/Result/speed_dial.pm index f1a2610b..7fff6d30 100644 --- a/lib/NGCP/Schema/Result/speed_dial.pm +++ b/lib/NGCP/Schema/Result/speed_dial.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::speed_dial; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.speed_dial"); - __PACKAGE__->add_columns( "id", { @@ -44,20 +34,23 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint( "speed_dial_idx", ["username", "domain", "sd_domain", "sd_username"], ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -164,14 +157,3 @@ NGCP::Schema::Result::speed_dial =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:0YBaZnKaPLDpt7O+XXTFpA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/statistics.pm b/lib/NGCP/Schema/Result/statistics.pm index be21217d..40cca58b 100644 --- a/lib/NGCP/Schema/Result/statistics.pm +++ b/lib/NGCP/Schema/Result/statistics.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::statistics; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("sipstats.statistics"); - __PACKAGE__->add_columns( "id", { @@ -233,14 +223,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id", "timestamp"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -486,14 +480,3 @@ NGCP::Schema::Result::statistics =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:13 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:9kpsF9dz/JLuknzhWElJDg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/subscriber.pm b/lib/NGCP/Schema/Result/subscriber.pm index a7527846..9184014a 100644 --- a/lib/NGCP/Schema/Result/subscriber.pm +++ b/lib/NGCP/Schema/Result/subscriber.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::subscriber; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.subscriber"); - __PACKAGE__->add_columns( "id", { @@ -53,17 +43,20 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("account_idx", ["username", "domain"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -178,14 +171,3 @@ NGCP::Schema::Result::subscriber =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:/nFKJCqgf6ODIPwyTEGAXw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/subscribers.pm b/lib/NGCP/Schema/Result/subscribers.pm index ecab11e6..1da85d7d 100644 --- a/lib/NGCP/Schema/Result/subscribers.pm +++ b/lib/NGCP/Schema/Result/subscribers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::subscribers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("carrier.subscribers"); - __PACKAGE__->add_columns( "id", { @@ -43,19 +33,14 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("domwebuser_idx", ["domain", "webusername"]); - __PACKAGE__->add_unique_constraint("externalid_idx", ["external_id"]); - __PACKAGE__->add_unique_constraint("usrdom_idx", ["username", "domain"]); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::carrier_contracts", @@ -63,19 +48,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "numbers", "NGCP::Schema::Result::numbers", { "foreign.subscriber_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -185,14 +174,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:50 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:E2EDHNYHXN0uk68QP4gzEg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/trusted.pm b/lib/NGCP/Schema/Result/trusted.pm index b6b6dbae..24eb1e42 100644 --- a/lib/NGCP/Schema/Result/trusted.pm +++ b/lib/NGCP/Schema/Result/trusted.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::trusted; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.trusted"); - __PACKAGE__->add_columns( "id", { @@ -36,14 +26,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -102,14 +96,3 @@ NGCP::Schema::Result::trusted =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:6hCtfqG0t2Oua4AB9q4aXg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/uid_credentials.pm b/lib/NGCP/Schema/Result/uid_credentials.pm index 2dc8973f..a61c45f4 100644 --- a/lib/NGCP/Schema/Result/uid_credentials.pm +++ b/lib/NGCP/Schema/Result/uid_credentials.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::uid_credentials; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.uid_credentials"); - __PACKAGE__->add_columns( "id", { @@ -49,14 +39,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -142,14 +136,3 @@ NGCP::Schema::Result::uid_credentials =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:oX0wkzWbvkXVl/cCbTcLxQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/uid_domain.pm b/lib/NGCP/Schema/Result/uid_domain.pm index 6d4ed466..20457866 100644 --- a/lib/NGCP/Schema/Result/uid_domain.pm +++ b/lib/NGCP/Schema/Result/uid_domain.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::uid_domain; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.uid_domain"); - __PACKAGE__->add_columns( "id", { @@ -39,17 +29,20 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("domain_idx", ["domain"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -113,14 +106,3 @@ NGCP::Schema::Result::uid_domain =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qPYbiX49LezlOTyWcSD1GA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/uid_domain_attrs.pm b/lib/NGCP/Schema/Result/uid_domain_attrs.pm index 71d075c1..8772d0a8 100644 --- a/lib/NGCP/Schema/Result/uid_domain_attrs.pm +++ b/lib/NGCP/Schema/Result/uid_domain_attrs.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::uid_domain_attrs; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.uid_domain_attrs"); - __PACKAGE__->add_columns( "id", { @@ -43,17 +33,20 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("domain_attr_idx", ["did", "name", "value"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -133,14 +126,3 @@ NGCP::Schema::Result::uid_domain_attrs =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:uyB00nyfhtO/+x2vJs7m6w - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/uid_global_attrs.pm b/lib/NGCP/Schema/Result/uid_global_attrs.pm index c68210f4..0ba4be5d 100644 --- a/lib/NGCP/Schema/Result/uid_global_attrs.pm +++ b/lib/NGCP/Schema/Result/uid_global_attrs.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::uid_global_attrs; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.uid_global_attrs"); - __PACKAGE__->add_columns( "id", { @@ -41,17 +31,20 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("global_attrs_idx", ["name", "value"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -123,14 +116,3 @@ NGCP::Schema::Result::uid_global_attrs =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Bo74cbc7vAUfdXhSB5+yIQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/uid_uri.pm b/lib/NGCP/Schema/Result/uid_uri.pm index 953097c5..c740b842 100644 --- a/lib/NGCP/Schema/Result/uid_uri.pm +++ b/lib/NGCP/Schema/Result/uid_uri.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::uid_uri; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.uid_uri"); - __PACKAGE__->add_columns( "id", { @@ -43,14 +33,18 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "sip", is_nullable => 0, size => 8 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -117,14 +111,3 @@ NGCP::Schema::Result::uid_uri =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:94l86GZgnqM/F9DQeGU+Pw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/uid_uri_attrs.pm b/lib/NGCP/Schema/Result/uid_uri_attrs.pm index b67289b0..a335cdee 100644 --- a/lib/NGCP/Schema/Result/uid_uri_attrs.pm +++ b/lib/NGCP/Schema/Result/uid_uri_attrs.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::uid_uri_attrs; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.uid_uri_attrs"); - __PACKAGE__->add_columns( "id", { @@ -47,20 +37,23 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "sip", is_nullable => 0, size => 8 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint( "uriattrs_idx", ["username", "did", "name", "value", "scheme"], ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -157,14 +150,3 @@ NGCP::Schema::Result::uid_uri_attrs =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:/A/+Vs2HDpAnXZ9ZkH5w+Q - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/uid_user_attrs.pm b/lib/NGCP/Schema/Result/uid_user_attrs.pm index 1ad59ac8..409572a8 100644 --- a/lib/NGCP/Schema/Result/uid_user_attrs.pm +++ b/lib/NGCP/Schema/Result/uid_user_attrs.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::uid_user_attrs; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.uid_user_attrs"); - __PACKAGE__->add_columns( "id", { @@ -43,17 +33,20 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("userattrs_idx", ["uid", "name", "value"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -133,14 +126,3 @@ NGCP::Schema::Result::uid_user_attrs =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:mnkD0IH22K2u6OtsZSg/5w - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/usr_preferences.pm b/lib/NGCP/Schema/Result/usr_preferences.pm index cee8c158..79ea5554 100644 --- a/lib/NGCP/Schema/Result/usr_preferences.pm +++ b/lib/NGCP/Schema/Result/usr_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::usr_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.usr_preferences"); - __PACKAGE__->add_columns( "id", { @@ -47,14 +37,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -136,14 +130,3 @@ NGCP::Schema::Result::usr_preferences =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:UvADsoZF4ZBfvGaizdnngQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/version.pm b/lib/NGCP/Schema/Result/version.pm index 73519137..dbfd77b9 100644 --- a/lib/NGCP/Schema/Result/version.pm +++ b/lib/NGCP/Schema/Result/version.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::version; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.version"); - __PACKAGE__->add_columns( "table_name", { data_type => "varchar", is_nullable => 0, size => 32 }, @@ -30,14 +20,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->add_unique_constraint("table_name_idx", ["table_name"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -80,14 +74,3 @@ NGCP::Schema::Result::version =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:/NNiY6/KS5CWjdBER2Vqrw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voicemail_spool.pm b/lib/NGCP/Schema/Result/voicemail_spool.pm index 1ed74909..972d7842 100644 --- a/lib/NGCP/Schema/Result/voicemail_spool.pm +++ b/lib/NGCP/Schema/Result/voicemail_spool.pm @@ -1,16 +1,8 @@ package NGCP::Schema::Result::voicemail_spool; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components( "InflateColumn::DateTime", @@ -18,10 +10,8 @@ __PACKAGE__->load_components( "+NGCP::Schema::InflateColumn::DateTime::EpochString", ); - __PACKAGE__->table("kamailio.voicemail_spool"); - __PACKAGE__->add_columns( "id", { @@ -58,10 +48,8 @@ __PACKAGE__->add_columns( { data_type => "longblob", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "mailboxuser", "NGCP::Schema::Result::voicemail_users", @@ -73,12 +61,26 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + +for my $col (qw/origtime/) { + if(__PACKAGE__->has_column($col)) { + __PACKAGE__->remove_column($col); + __PACKAGE__->add_column($col => + { data_type => "varchar", is_nullable => 0, inflate_datetime => 'epoch_string' } + ); + } +} + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -189,21 +191,3 @@ NGCP::Schema::Result::voicemail_spool Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:59 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:pVE7vFt85S24avmUm7FIMg - -for my $col (qw/origtime/) { - if(__PACKAGE__->has_column($col)) { - __PACKAGE__->remove_column($col); - __PACKAGE__->add_column($col => - { data_type => "varchar", is_nullable => 0, inflate_datetime => 'epoch_string' } - ); - } -} - -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voicemail_users.pm b/lib/NGCP/Schema/Result/voicemail_users.pm index d123aac5..31cae91b 100644 --- a/lib/NGCP/Schema/Result/voicemail_users.pm +++ b/lib/NGCP/Schema/Result/voicemail_users.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voicemail_users; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.voicemail_users"); - __PACKAGE__->add_columns( "uniqueid", { @@ -97,22 +87,32 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("uniqueid"); - __PACKAGE__->has_many( "voicemail_spools", "NGCP::Schema::Result::voicemail_spool", { "foreign.mailboxuser" => "self.customer_id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + +__PACKAGE__->belongs_to( + "provisioning_voip_subscriber", + "NGCP::Schema::Result::provisioning_voip_subscribers", + { "foreign.uuid" => "self.customer_id" }, + { cascade_copy => 0, cascade_delete => 0 }, +); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -322,20 +322,3 @@ NGCP::Schema::Result::voicemail_users Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:00 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:K1FVw9YTkzSlwWUQoPe/1A - - -__PACKAGE__->belongs_to( - "provisioning_voip_subscriber", - "NGCP::Schema::Result::provisioning_voip_subscribers", - { "foreign.uuid" => "self.customer_id" }, - { cascade_copy => 0, cascade_delete => 0 }, -); - -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_aig_sequence.pm b/lib/NGCP/Schema/Result/voip_aig_sequence.pm index a92d5f6d..fa05d2cc 100644 --- a/lib/NGCP/Schema/Result/voip_aig_sequence.pm +++ b/lib/NGCP/Schema/Result/voip_aig_sequence.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_aig_sequence; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_aig_sequence"); - __PACKAGE__->add_columns( "id", { @@ -28,14 +18,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -70,14 +64,3 @@ NGCP::Schema::Result::voip_aig_sequence =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:HM5k+efiqSSkwbbFxMaAJg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_allowed_ip_groups.pm b/lib/NGCP/Schema/Result/voip_allowed_ip_groups.pm index e88333aa..9fb4acda 100644 --- a/lib/NGCP/Schema/Result/voip_allowed_ip_groups.pm +++ b/lib/NGCP/Schema/Result/voip_allowed_ip_groups.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_allowed_ip_groups; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_allowed_ip_groups"); - __PACKAGE__->add_columns( "id", { @@ -32,17 +22,20 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 18 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("groupnet_idx", ["group_id", "ipnet"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -101,14 +94,3 @@ NGCP::Schema::Result::voip_allowed_ip_groups =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:3mjI5CK1u6ZlL3BDVjTAXw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_cc_mappings.pm b/lib/NGCP/Schema/Result/voip_cc_mappings.pm index 72066dcf..184c3ef4 100644 --- a/lib/NGCP/Schema/Result/voip_cc_mappings.pm +++ b/lib/NGCP/Schema/Result/voip_cc_mappings.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_cc_mappings; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_cc_mappings"); - __PACKAGE__->add_columns( "id", { @@ -34,22 +24,25 @@ __PACKAGE__->add_columns( { data_type => "char", is_nullable => 0, size => 36 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "uuid", "NGCP::Schema::Result::provisioning_voip_subscribers", { uuid => "uuid" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -111,14 +104,3 @@ NGCP::Schema::Result::voip_cc_mappings Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:/cEz4j+FSFxg+FBraBmbeA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_cf_destination_sets.pm b/lib/NGCP/Schema/Result/voip_cf_destination_sets.pm index d4e68781..ec1b2681 100644 --- a/lib/NGCP/Schema/Result/voip_cf_destination_sets.pm +++ b/lib/NGCP/Schema/Result/voip_cf_destination_sets.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_cf_destination_sets; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_cf_destination_sets"); - __PACKAGE__->add_columns( "id", { @@ -37,10 +27,8 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", @@ -53,7 +41,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "voip_cf_destinations", "NGCP::Schema::Result::voip_cf_destinations", @@ -61,19 +48,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_cf_mappings", "NGCP::Schema::Result::voip_cf_mappings", { "foreign.destination_set_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -141,14 +132,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:zDy4g/gbKE02iAhWAN+aMQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_cf_destinations.pm b/lib/NGCP/Schema/Result/voip_cf_destinations.pm index 44a82f18..846b69d3 100644 --- a/lib/NGCP/Schema/Result/voip_cf_destinations.pm +++ b/lib/NGCP/Schema/Result/voip_cf_destinations.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_cf_destinations; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_cf_destinations"); - __PACKAGE__->add_columns( "id", { @@ -46,22 +36,25 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "destination_set", "NGCP::Schema::Result::voip_cf_destination_sets", { id => "destination_set_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -130,14 +123,3 @@ NGCP::Schema::Result::voip_cf_destinations Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ZeMZQNnsEOyRVG0beIkGPg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_cf_mappings.pm b/lib/NGCP/Schema/Result/voip_cf_mappings.pm index 9a6b5f7b..6e1a4a40 100644 --- a/lib/NGCP/Schema/Result/voip_cf_mappings.pm +++ b/lib/NGCP/Schema/Result/voip_cf_mappings.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_cf_mappings; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_cf_mappings"); - __PACKAGE__->add_columns( "id", { @@ -56,10 +46,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "destination_set", "NGCP::Schema::Result::voip_cf_destination_sets", @@ -72,7 +60,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", @@ -80,7 +67,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "time_set", "NGCP::Schema::Result::voip_cf_time_sets", @@ -92,12 +78,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -180,14 +171,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:HLSCXjrl0QY2FyFjw/YLYg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_cf_periods.pm b/lib/NGCP/Schema/Result/voip_cf_periods.pm index 6597c695..69d83d13 100644 --- a/lib/NGCP/Schema/Result/voip_cf_periods.pm +++ b/lib/NGCP/Schema/Result/voip_cf_periods.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_cf_periods; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_cf_periods"); - __PACKAGE__->add_columns( "id", { @@ -47,22 +37,25 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "time_set", "NGCP::Schema::Result::voip_cf_time_sets", { id => "time_set_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -148,14 +141,3 @@ NGCP::Schema::Result::voip_cf_periods Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:EKfXw897JzAaeHCNvYm24g - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_cf_time_sets.pm b/lib/NGCP/Schema/Result/voip_cf_time_sets.pm index caf81dd5..3f2b716a 100644 --- a/lib/NGCP/Schema/Result/voip_cf_time_sets.pm +++ b/lib/NGCP/Schema/Result/voip_cf_time_sets.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_cf_time_sets; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_cf_time_sets"); - __PACKAGE__->add_columns( "id", { @@ -37,10 +27,8 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", @@ -53,7 +41,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "voip_cf_mappings", "NGCP::Schema::Result::voip_cf_mappings", @@ -61,19 +48,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_cf_periods", "NGCP::Schema::Result::voip_cf_periods", { "foreign.time_set_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -141,14 +132,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:5qaV6cRMDQ4JUSKfQu1bcQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_contacts.pm b/lib/NGCP/Schema/Result/voip_contacts.pm index 530a5881..2a7e4a96 100644 --- a/lib/NGCP/Schema/Result/voip_contacts.pm +++ b/lib/NGCP/Schema/Result/voip_contacts.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_contacts; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_contacts"); - __PACKAGE__->add_columns( "id", { @@ -53,22 +43,25 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -172,14 +165,3 @@ NGCP::Schema::Result::voip_contacts Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rk0pvQYvbcvdA7WdVPphCQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_dbaliases.pm b/lib/NGCP/Schema/Result/voip_dbaliases.pm index c97028d6..bc314261 100644 --- a/lib/NGCP/Schema/Result/voip_dbaliases.pm +++ b/lib/NGCP/Schema/Result/voip_dbaliases.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_dbaliases; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_dbaliases"); - __PACKAGE__->add_columns( "id", { @@ -44,13 +34,10 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("user_dom_idx", ["username", "domain_id"]); - __PACKAGE__->belongs_to( "domain", "NGCP::Schema::Result::voip_domains", @@ -58,19 +45,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -151,14 +142,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:w9Hhn+rzX3dnvnjsLiB3Fg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_dom_preferences.pm b/lib/NGCP/Schema/Result/voip_dom_preferences.pm index 59377a2c..319f7696 100644 --- a/lib/NGCP/Schema/Result/voip_dom_preferences.pm +++ b/lib/NGCP/Schema/Result/voip_dom_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_dom_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_dom_preferences"); - __PACKAGE__->add_columns( "id", { @@ -51,10 +41,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "attribute", "NGCP::Schema::Result::voip_preferences", @@ -62,19 +50,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "domain", "NGCP::Schema::Result::voip_domains", { id => "domain_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -150,14 +142,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:BzVq5nZGbVs7pzcQiIyb8w - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_domains.pm b/lib/NGCP/Schema/Result/voip_domains.pm index d7256137..aaeddcdb 100644 --- a/lib/NGCP/Schema/Result/voip_domains.pm +++ b/lib/NGCP/Schema/Result/voip_domains.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_domains; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_domains"); - __PACKAGE__->add_columns( "id", { @@ -30,13 +20,10 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 127 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("domain_idx", ["domain"]); - __PACKAGE__->has_many( "voip_dbaliases", "NGCP::Schema::Result::voip_dbaliases", @@ -44,7 +31,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_dom_preferences", "NGCP::Schema::Result::voip_dom_preferences", @@ -52,19 +38,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "provisioning_voip_subscribers", "NGCP::Schema::Result::provisioning_voip_subscribers", { "foreign.domain_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -135,14 +125,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:OxiQ6Q21w1CmhSpW6YTNNg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_fax_destinations.pm b/lib/NGCP/Schema/Result/voip_fax_destinations.pm index 6f0dc777..76cc2606 100644 --- a/lib/NGCP/Schema/Result/voip_fax_destinations.pm +++ b/lib/NGCP/Schema/Result/voip_fax_destinations.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_fax_destinations; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_fax_destinations"); - __PACKAGE__->add_columns( "id", { @@ -52,25 +42,27 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("subdest_idx", ["subscriber_id", "destination"]); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -169,14 +161,3 @@ NGCP::Schema::Result::voip_fax_destinations Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Js4M9CHLMvjfJ+7Ecelc3Q - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_fax_preferences.pm b/lib/NGCP/Schema/Result/voip_fax_preferences.pm index 663435c0..a240f4be 100644 --- a/lib/NGCP/Schema/Result/voip_fax_preferences.pm +++ b/lib/NGCP/Schema/Result/voip_fax_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_fax_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_fax_preferences"); - __PACKAGE__->add_columns( "id", { @@ -45,25 +35,27 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 1, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("subscriberid_idx", ["subscriber_id"]); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -153,14 +145,3 @@ NGCP::Schema::Result::voip_fax_preferences Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:WboF1meXv9ew8u9vL9LjfA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_intercept.pm b/lib/NGCP/Schema/Result/voip_intercept.pm index 4aa15f75..6479588b 100644 --- a/lib/NGCP/Schema/Result/voip_intercept.pm +++ b/lib/NGCP/Schema/Result/voip_intercept.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_intercept; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.voip_intercept"); - __PACKAGE__->add_columns( "id", { @@ -65,10 +55,8 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", @@ -80,12 +68,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -195,14 +188,3 @@ NGCP::Schema::Result::voip_intercept Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:HSbXjeZvDF+aJOpkeQAANA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_number_block_resellers.pm b/lib/NGCP/Schema/Result/voip_number_block_resellers.pm index 1de7d020..3e827271 100644 --- a/lib/NGCP/Schema/Result/voip_number_block_resellers.pm +++ b/lib/NGCP/Schema/Result/voip_number_block_resellers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_number_block_resellers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.voip_number_block_resellers"); - __PACKAGE__->add_columns( "id", { @@ -42,10 +32,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "number_block", "NGCP::Schema::Result::voip_number_blocks", @@ -53,19 +41,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", { id => "reseller_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -128,14 +120,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:o6JylieCVBzZsjcYA9AZAg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_number_blocks.pm b/lib/NGCP/Schema/Result/voip_number_blocks.pm index c9242edb..04d48a2e 100644 --- a/lib/NGCP/Schema/Result/voip_number_blocks.pm +++ b/lib/NGCP/Schema/Result/voip_number_blocks.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_number_blocks; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.voip_number_blocks"); - __PACKAGE__->add_columns( "id", { @@ -40,25 +30,27 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("prefix_idx", ["cc", "ac", "sn_prefix"]); - __PACKAGE__->has_many( "voip_number_block_resellers", "NGCP::Schema::Result::voip_number_block_resellers", { "foreign.number_block_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -151,14 +143,3 @@ NGCP::Schema::Result::voip_number_blocks Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:vVgCgcB8twydsAjMOpWR+g - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_numbers.pm b/lib/NGCP/Schema/Result/voip_numbers.pm index ed68cb4c..2fffabdf 100644 --- a/lib/NGCP/Schema/Result/voip_numbers.pm +++ b/lib/NGCP/Schema/Result/voip_numbers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_numbers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.voip_numbers"); - __PACKAGE__->add_columns( "id", { @@ -64,13 +54,10 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("number_idx", ["cc", "ac", "sn"]); - __PACKAGE__->belongs_to( "reseller", "NGCP::Schema::Result::resellers", @@ -83,7 +70,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::voip_subscribers", @@ -96,7 +82,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "voip_subscribers", "NGCP::Schema::Result::voip_subscribers", @@ -110,6 +95,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -230,14 +219,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Vq+N7GpcAMtkUj3s0wPz0g - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_pbx_groups.pm b/lib/NGCP/Schema/Result/voip_pbx_groups.pm index 9bb24d06..7c76284f 100644 --- a/lib/NGCP/Schema/Result/voip_pbx_groups.pm +++ b/lib/NGCP/Schema/Result/voip_pbx_groups.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_pbx_groups; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_pbx_groups"); - __PACKAGE__->add_columns( "id", { @@ -59,7 +49,6 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); __PACKAGE__->belongs_to( @@ -84,13 +73,16 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -182,15 +174,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Qpw0gD+LaI+g0k3EWr42tQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration - -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_peer_groups.pm b/lib/NGCP/Schema/Result/voip_peer_groups.pm index 7b6e70ef..a2c953ad 100644 --- a/lib/NGCP/Schema/Result/voip_peer_groups.pm +++ b/lib/NGCP/Schema/Result/voip_peer_groups.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_peer_groups; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_peer_groups"); - __PACKAGE__->add_columns( "id", { @@ -36,13 +26,10 @@ __PACKAGE__->add_columns( { data_type => "integer", extra => { unsigned => 1 }, is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("name", ["name"]); - __PACKAGE__->has_many( "voip_peer_hosts", "NGCP::Schema::Result::voip_peer_hosts", @@ -50,7 +37,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_peer_rules", "NGCP::Schema::Result::voip_peer_rules", @@ -71,6 +57,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -153,14 +143,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:w5Tq59EkKacs/5GZQEBizw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_peer_hosts.pm b/lib/NGCP/Schema/Result/voip_peer_hosts.pm index b86c3777..9cdf676a 100644 --- a/lib/NGCP/Schema/Result/voip_peer_hosts.pm +++ b/lib/NGCP/Schema/Result/voip_peer_hosts.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_peer_hosts; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_peer_hosts"); - __PACKAGE__->add_columns( "id", { @@ -51,13 +41,10 @@ __PACKAGE__->add_columns( { data_type => "tinyint", default_value => 0, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("grpname", ["group_id", "name"]); - __PACKAGE__->belongs_to( "group", "NGCP::Schema::Result::voip_peer_groups", @@ -65,19 +52,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "voip_peer_preferences", "NGCP::Schema::Result::voip_peer_preferences", { "foreign.peer_host_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -188,14 +179,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:pEvrR6WwrOPwe/JROCZnOQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_peer_preferences.pm b/lib/NGCP/Schema/Result/voip_peer_preferences.pm index bfae9f63..934cb092 100644 --- a/lib/NGCP/Schema/Result/voip_peer_preferences.pm +++ b/lib/NGCP/Schema/Result/voip_peer_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_peer_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_peer_preferences"); - __PACKAGE__->add_columns( "id", { @@ -51,10 +41,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "attribute", "NGCP::Schema::Result::voip_preferences", @@ -62,19 +50,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "peer_host", "NGCP::Schema::Result::voip_peer_hosts", { id => "peer_host_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -150,14 +142,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:a7jcc6aD2Rv9HJe3+yYdgA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_peer_rules.pm b/lib/NGCP/Schema/Result/voip_peer_rules.pm index c296133a..9db75c79 100644 --- a/lib/NGCP/Schema/Result/voip_peer_rules.pm +++ b/lib/NGCP/Schema/Result/voip_peer_rules.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_peer_rules; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_peer_rules"); - __PACKAGE__->add_columns( "id", { @@ -43,22 +33,25 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "group", "NGCP::Schema::Result::voip_peer_groups", { id => "group_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -134,14 +127,3 @@ NGCP::Schema::Result::voip_peer_rules Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:BW+xPCn03rDsacE/mJhFmQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_preference_groups.pm b/lib/NGCP/Schema/Result/voip_preference_groups.pm index d095bb54..5bdd13b3 100644 --- a/lib/NGCP/Schema/Result/voip_preference_groups.pm +++ b/lib/NGCP/Schema/Result/voip_preference_groups.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_preference_groups; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_preference_groups"); - __PACKAGE__->add_columns( "id", { @@ -30,22 +20,25 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "voip_preferences", "NGCP::Schema::Result::voip_preferences", { "foreign.voip_preference_groups_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -94,14 +87,3 @@ NGCP::Schema::Result::voip_preference_groups Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:bJO/DOZq98OWQadkhnyHyA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_preferences.pm b/lib/NGCP/Schema/Result/voip_preferences.pm index 6e96c28f..f84e9032 100644 --- a/lib/NGCP/Schema/Result/voip_preferences.pm +++ b/lib/NGCP/Schema/Result/voip_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_preferences"); - __PACKAGE__->add_columns( "id", { @@ -72,13 +62,10 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("attribute_idx", ["attribute"]); - __PACKAGE__->has_many( "voip_dom_preferences", "NGCP::Schema::Result::voip_dom_preferences", @@ -86,7 +73,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_peer_preferences", "NGCP::Schema::Result::voip_peer_preferences", @@ -94,7 +80,6 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->belongs_to( "voip_preference_group", "NGCP::Schema::Result::voip_preference_groups", @@ -102,7 +87,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "RESTRICT", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "voip_preferences_enums", "NGCP::Schema::Result::voip_preferences_enum", @@ -110,19 +94,23 @@ __PACKAGE__->has_many( { cascade_copy => 0, cascade_delete => 0 }, ); - __PACKAGE__->has_many( "voip_usr_preferences", "NGCP::Schema::Result::voip_usr_preferences", { "foreign.attribute_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -278,14 +266,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:7eJNPcqBgeQIQwSODtcdOQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_preferences_enum.pm b/lib/NGCP/Schema/Result/voip_preferences_enum.pm index a0b7cb20..b6770a7d 100644 --- a/lib/NGCP/Schema/Result/voip_preferences_enum.pm +++ b/lib/NGCP/Schema/Result/voip_preferences_enum.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_preferences_enum; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_preferences_enum"); - __PACKAGE__->add_columns( "id", { data_type => "integer", is_auto_increment => 1, is_nullable => 0 }, @@ -42,10 +32,8 @@ __PACKAGE__->add_columns( { data_type => "tinyint", is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "preference", "NGCP::Schema::Result::voip_preferences", @@ -57,12 +45,17 @@ __PACKAGE__->belongs_to( on_update => "RESTRICT", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -146,14 +139,3 @@ NGCP::Schema::Result::voip_preferences_enum Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:OV9kMBzgf+aKB/ZCA3oQuQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_reminder.pm b/lib/NGCP/Schema/Result/voip_reminder.pm index 6d8a0e8c..31a4fee5 100644 --- a/lib/NGCP/Schema/Result/voip_reminder.pm +++ b/lib/NGCP/Schema/Result/voip_reminder.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_reminder; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_reminder"); - __PACKAGE__->add_columns( "id", { @@ -44,25 +34,27 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("subscriber_id", ["subscriber_id"]); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -135,14 +127,3 @@ NGCP::Schema::Result::voip_reminder Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:nvhtEWDw8of8Z6J7UmVO2Q - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_rewrite_rule_sets.pm b/lib/NGCP/Schema/Result/voip_rewrite_rule_sets.pm index f311d491..f0b42e41 100644 --- a/lib/NGCP/Schema/Result/voip_rewrite_rule_sets.pm +++ b/lib/NGCP/Schema/Result/voip_rewrite_rule_sets.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_rewrite_rule_sets; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_rewrite_rule_sets"); - __PACKAGE__->add_columns( "id", { @@ -47,13 +37,10 @@ __PACKAGE__->add_columns( { data_type => "integer", extra => { unsigned => 1 }, is_nullable => 1 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("name_idx", ["name"]); - __PACKAGE__->has_many( "voip_rewrite_rules", "NGCP::Schema::Result::voip_rewrite_rules", @@ -66,12 +53,17 @@ __PACKAGE__->belongs_to( { id => "reseller_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -160,14 +152,3 @@ NGCP::Schema::Result::voip_rewrite_rule_sets Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:08J8WJFZR9UDonglv8Q/9g - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_rewrite_rules.pm b/lib/NGCP/Schema/Result/voip_rewrite_rules.pm index d153e588..565e4583 100644 --- a/lib/NGCP/Schema/Result/voip_rewrite_rules.pm +++ b/lib/NGCP/Schema/Result/voip_rewrite_rules.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_rewrite_rules; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_rewrite_rules"); - __PACKAGE__->add_columns( "id", { @@ -62,22 +52,25 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "set", "NGCP::Schema::Result::voip_rewrite_rule_sets", { id => "set_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -168,14 +161,3 @@ NGCP::Schema::Result::voip_rewrite_rules Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:BqbpAAJ5Sg4jF2J0BnbbTg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_rwrs_sequence.pm b/lib/NGCP/Schema/Result/voip_rwrs_sequence.pm index fff169e8..0e7928e7 100644 --- a/lib/NGCP/Schema/Result/voip_rwrs_sequence.pm +++ b/lib/NGCP/Schema/Result/voip_rwrs_sequence.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_rwrs_sequence; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_rwrs_sequence"); - __PACKAGE__->add_columns( "id", { @@ -28,14 +18,18 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -70,14 +64,3 @@ NGCP::Schema::Result::voip_rwrs_sequence =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:cxon5/+SHSv5skYEZYkbDw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_sound_files.pm b/lib/NGCP/Schema/Result/voip_sound_files.pm index 0139ee8b..b699178c 100644 --- a/lib/NGCP/Schema/Result/voip_sound_files.pm +++ b/lib/NGCP/Schema/Result/voip_sound_files.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_sound_files; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_sound_files"); - __PACKAGE__->add_columns( "id", { data_type => "integer", is_auto_increment => 1, is_nullable => 0 }, @@ -35,10 +25,8 @@ __PACKAGE__->add_columns( { data_type => "varchar", default_value => "", is_nullable => 0, size => 16 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "handle", "NGCP::Schema::Result::voip_sound_handles", @@ -51,7 +39,6 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->belongs_to( "set", "NGCP::Schema::Result::voip_sound_sets", @@ -63,12 +50,17 @@ __PACKAGE__->belongs_to( on_update => "CASCADE", }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -152,14 +144,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Rx9kSKu6+3/vmeGrUA6xBQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_sound_groups.pm b/lib/NGCP/Schema/Result/voip_sound_groups.pm index 3ec05513..a8686ebd 100644 --- a/lib/NGCP/Schema/Result/voip_sound_groups.pm +++ b/lib/NGCP/Schema/Result/voip_sound_groups.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_sound_groups; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_sound_groups"); - __PACKAGE__->add_columns( "id", { @@ -30,22 +20,25 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "voip_sounds_handles", "NGCP::Schema::Result::voip_sound_handles", { "foreign.group_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -94,14 +87,3 @@ NGCP::Schema::Result::voip_sound_groups Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:d0i5WeLtbqXAidH2VWsbWw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_sound_handles.pm b/lib/NGCP/Schema/Result/voip_sound_handles.pm index 0f484dd4..acff77bb 100644 --- a/lib/NGCP/Schema/Result/voip_sound_handles.pm +++ b/lib/NGCP/Schema/Result/voip_sound_handles.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_sound_handles; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_sound_handles"); - __PACKAGE__->add_columns( "id", { data_type => "integer", is_auto_increment => 1, is_nullable => 0 }, @@ -32,10 +22,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "group", "NGCP::Schema::Result::voip_sound_groups", @@ -43,19 +31,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->has_many( "voip_sound_files", "NGCP::Schema::Result::voip_sound_files", { "foreign.handle_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -116,14 +108,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:bYaKLiKO+eap8zjd3Pu3Kw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_sound_sets.pm b/lib/NGCP/Schema/Result/voip_sound_sets.pm index 28d8b24e..5b1706ac 100644 --- a/lib/NGCP/Schema/Result/voip_sound_sets.pm +++ b/lib/NGCP/Schema/Result/voip_sound_sets.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_sound_sets; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_sound_sets"); - __PACKAGE__->add_columns( "id", { data_type => "integer", is_auto_increment => 1, is_nullable => 0 }, @@ -40,10 +30,8 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "voip_sound_files", "NGCP::Schema::Result::voip_sound_files", @@ -71,6 +59,10 @@ sub TO_JSON { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -124,14 +116,3 @@ NGCP::Schema::Result::voip_sound_sets Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:F+aZALvSthum3GWLvvvmRA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_speed_dial.pm b/lib/NGCP/Schema/Result/voip_speed_dial.pm index ca29a9df..6f18e533 100644 --- a/lib/NGCP/Schema/Result/voip_speed_dial.pm +++ b/lib/NGCP/Schema/Result/voip_speed_dial.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_speed_dial; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_speed_dial"); - __PACKAGE__->add_columns( "id", { @@ -39,25 +29,27 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 192 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("subscriberid_slot_idx", ["subscriber_id", "slot"]); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -131,14 +123,3 @@ NGCP::Schema::Result::voip_speed_dial Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:TXpCogBmg346/hOMGjScag - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_subscribers.pm b/lib/NGCP/Schema/Result/voip_subscribers.pm index 3728d5bb..6947c333 100644 --- a/lib/NGCP/Schema/Result/voip_subscribers.pm +++ b/lib/NGCP/Schema/Result/voip_subscribers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_subscribers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("billing.voip_subscribers"); - __PACKAGE__->add_columns( "id", { @@ -62,13 +52,10 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("uuid_idx", ["uuid"]); - __PACKAGE__->belongs_to( "contract", "NGCP::Schema::Result::contracts", @@ -76,7 +63,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "domain", "NGCP::Schema::Result::domains", @@ -84,7 +70,6 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "primary_number", "NGCP::Schema::Result::voip_numbers", @@ -97,19 +82,30 @@ __PACKAGE__->belongs_to( }, ); - __PACKAGE__->has_many( "voip_numbers", "NGCP::Schema::Result::voip_numbers", { "foreign.subscriber_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + +__PACKAGE__->might_have( + "provisioning_voip_subscriber", + 'NGCP::Schema::Result::provisioning_voip_subscribers', + { 'foreign.uuid' => 'self.uuid' }, + { cascade_copy => 0, cascade_delete => 0 }, +); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -226,22 +222,3 @@ Related object: L Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:51:47 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qT/XQFGM1l0ygvjRpIy47g - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration - -__PACKAGE__->might_have( - "provisioning_voip_subscriber", - 'NGCP::Schema::Result::provisioning_voip_subscribers', - { 'foreign.uuid' => 'self.uuid' }, - { cascade_copy => 0, cascade_delete => 0 }, -); - -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_trusted_sources.pm b/lib/NGCP/Schema/Result/voip_trusted_sources.pm index 47b9fbdc..9bb46b56 100644 --- a/lib/NGCP/Schema/Result/voip_trusted_sources.pm +++ b/lib/NGCP/Schema/Result/voip_trusted_sources.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_trusted_sources; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_trusted_sources"); - __PACKAGE__->add_columns( "id", { @@ -43,22 +33,25 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 64 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -132,14 +125,3 @@ NGCP::Schema::Result::voip_trusted_sources Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:qmpEy5Q8ZIdWLs1dq+gNhA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/voip_usr_preferences.pm b/lib/NGCP/Schema/Result/voip_usr_preferences.pm index 4b790b2a..0da6129d 100644 --- a/lib/NGCP/Schema/Result/voip_usr_preferences.pm +++ b/lib/NGCP/Schema/Result/voip_usr_preferences.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::voip_usr_preferences; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.voip_usr_preferences"); - __PACKAGE__->add_columns( "id", { @@ -51,10 +41,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "attribute", "NGCP::Schema::Result::voip_preferences", @@ -62,19 +50,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "subscriber", "NGCP::Schema::Result::provisioning_voip_subscribers", { id => "subscriber_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -150,14 +142,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ZfiqO+ffmay8CvsAWeseTw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/watchers.pm b/lib/NGCP/Schema/Result/watchers.pm index fdf8dd79..7488e021 100644 --- a/lib/NGCP/Schema/Result/watchers.pm +++ b/lib/NGCP/Schema/Result/watchers.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::watchers; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.watchers"); - __PACKAGE__->add_columns( "id", { @@ -47,20 +37,23 @@ __PACKAGE__->add_columns( { data_type => "integer", is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint( "watcher_idx", ["presentity_uri", "watcher_username", "watcher_domain", "event"], ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -152,14 +145,3 @@ NGCP::Schema::Result::watchers =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:00 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:tdAX3cPrWcunKoFTWiPiXg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/xcap.pm b/lib/NGCP/Schema/Result/xcap.pm index 923e5df2..842c821a 100644 --- a/lib/NGCP/Schema/Result/xcap.pm +++ b/lib/NGCP/Schema/Result/xcap.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::xcap; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("kamailio.xcap"); - __PACKAGE__->add_columns( "id", { @@ -44,17 +34,20 @@ __PACKAGE__->add_columns( { data_type => "integer", is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->add_unique_constraint("doc_uri_idx", ["doc_uri"]); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -143,14 +136,3 @@ NGCP::Schema::Result::xcap =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:00 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:h1i8myXfqHQYuKAGjzkWSw - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/xmlgroups.pm b/lib/NGCP/Schema/Result/xmlgroups.pm index 3e7a5ab9..68f70750 100644 --- a/lib/NGCP/Schema/Result/xmlgroups.pm +++ b/lib/NGCP/Schema/Result/xmlgroups.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::xmlgroups; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.xmlgroups"); - __PACKAGE__->add_columns( "id", { @@ -30,22 +20,25 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 0, size => 32 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "xmlhostgroups", "NGCP::Schema::Result::xmlhostgroups", { "foreign.group_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -94,14 +87,3 @@ NGCP::Schema::Result::xmlgroups Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:pxQiDR/+prEx2ZU/Dx33iA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/xmlhostgroups.pm b/lib/NGCP/Schema/Result/xmlhostgroups.pm index a453805c..cc2a501b 100644 --- a/lib/NGCP/Schema/Result/xmlhostgroups.pm +++ b/lib/NGCP/Schema/Result/xmlhostgroups.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::xmlhostgroups; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.xmlhostgroups"); - __PACKAGE__->add_columns( "id", { @@ -42,10 +32,8 @@ __PACKAGE__->add_columns( }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->belongs_to( "group", "NGCP::Schema::Result::xmlgroups", @@ -53,19 +41,23 @@ __PACKAGE__->belongs_to( { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); - __PACKAGE__->belongs_to( "host", "NGCP::Schema::Result::xmlhosts", { id => "host_id" }, { is_deferrable => 1, on_delete => "CASCADE", on_update => "CASCADE" }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -128,14 +120,3 @@ Related object: L Type: belongs_to Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:9nWe2/73V8IzloSkr12NcA - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/xmlhosts.pm b/lib/NGCP/Schema/Result/xmlhosts.pm index fba50168..b24c8bfa 100644 --- a/lib/NGCP/Schema/Result/xmlhosts.pm +++ b/lib/NGCP/Schema/Result/xmlhosts.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::xmlhosts; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.xmlhosts"); - __PACKAGE__->add_columns( "id", { @@ -38,22 +28,25 @@ __PACKAGE__->add_columns( { data_type => "varchar", is_nullable => 1, size => 255 }, ); - __PACKAGE__->set_primary_key("id"); - __PACKAGE__->has_many( "xmlhostgroups", "NGCP::Schema::Result::xmlhostgroups", { "foreign.host_id" => "self.id" }, { cascade_copy => 0, cascade_delete => 0 }, ); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -127,14 +120,3 @@ NGCP::Schema::Result::xmlhosts Type: has_many Related object: L - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:jfFGxSZejX64pMtvs0HMpg - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1; diff --git a/lib/NGCP/Schema/Result/xmlqueue.pm b/lib/NGCP/Schema/Result/xmlqueue.pm index 1c6d2408..0d1bfc62 100644 --- a/lib/NGCP/Schema/Result/xmlqueue.pm +++ b/lib/NGCP/Schema/Result/xmlqueue.pm @@ -1,23 +1,13 @@ package NGCP::Schema::Result::xmlqueue; -use Sipwise::Base; -use MooseX::NonMoose; use Scalar::Util qw(blessed); -our $VERSION = '2.006'; - -# Created by DBIx::Class::Schema::Loader -# DO NOT MODIFY THE FIRST PART OF THIS FILE - - - -extends 'DBIx::Class::Core'; +use parent 'DBIx::Class::Core'; +our $VERSION = '2.006'; __PACKAGE__->load_components("InflateColumn::DateTime", "Helper::Row::ToJSON"); - __PACKAGE__->table("provisioning.xmlqueue"); - __PACKAGE__->add_columns( "id", { @@ -40,14 +30,18 @@ __PACKAGE__->add_columns( { data_type => "integer", extra => { unsigned => 1 }, is_nullable => 0 }, ); - __PACKAGE__->set_primary_key("id"); + sub TO_JSON { my ($self) = @_; return { map { blessed($_) && $_->isa('DateTime') ? $_->datetime : $_ } %{ $self->next::method } }; } + +1; +__END__ + =encoding UTF-8 =head1 NAME @@ -117,14 +111,3 @@ NGCP::Schema::Result::xmlqueue =item * L =back - -=cut - - -# Created by DBIx::Class::Schema::Loader v0.07035 @ 2013-06-27 12:52:09 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:DPqPjZSiD9p2eMHozeeofQ - - -# You can replace this text with custom code or comments, and it will be preserved on regeneration -__PACKAGE__->meta->make_immutable; -1;