use utf8;
package CLMApp::Schema::Result::EmailNotificationWarehouse;

# Created by DBIx::Class::Schema::Loader
# DO NOT MODIFY THE FIRST PART OF THIS FILE

=head1 NAME

CLMApp::Schema::Result::EmailNotificationWarehouse

=cut

use strict;
use warnings;

use base 'DBIx::Class::Core';

=head1 COMPONENTS LOADED

=over 4

=item * L<DBIx::Class::InflateColumn::DateTime>

=back

=cut

__PACKAGE__->load_components("InflateColumn::DateTime");

=head1 TABLE: C<EmailNotificationWarehouse>

=cut

__PACKAGE__->table("EmailNotificationWarehouse");

=head1 ACCESSORS

=head2 emailnotificationwarehouseid

  data_type: 'integer'
  is_auto_increment: 1
  is_nullable: 0

=head2 emailnotificationid

  data_type: 'integer'
  default_value: 0
  is_foreign_key: 1
  is_nullable: 0

=head2 distributorwarehouseid

  data_type: 'integer'
  default_value: 0
  is_foreign_key: 1
  is_nullable: 0

=cut

__PACKAGE__->add_columns(
  "emailnotificationwarehouseid",
  { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
  "emailnotificationid",
  {
    data_type      => "integer",
    default_value  => 0,
    is_foreign_key => 1,
    is_nullable    => 0,
  },
  "distributorwarehouseid",
  {
    data_type      => "integer",
    default_value  => 0,
    is_foreign_key => 1,
    is_nullable    => 0,
  },
);

=head1 PRIMARY KEY

=over 4

=item * L</emailnotificationwarehouseid>

=back

=cut

__PACKAGE__->set_primary_key("emailnotificationwarehouseid");

=head1 RELATIONS

=head2 distributorwarehouseid

Type: belongs_to

Related object: L<CLMApp::Schema::Result::DistributorWarehouse>

=cut

__PACKAGE__->belongs_to(
  "distributorwarehouseid",
  "CLMApp::Schema::Result::DistributorWarehouse",
  { distributorwarehouseid => "distributorwarehouseid" },
  { is_deferrable => 1, on_delete => "RESTRICT", on_update => "RESTRICT" },
);

=head2 emailnotificationid

Type: belongs_to

Related object: L<CLMApp::Schema::Result::EmailNotification>

=cut

__PACKAGE__->belongs_to(
  "emailnotificationid",
  "CLMApp::Schema::Result::EmailNotification",
  { emailnotificationid => "emailnotificationid" },
  { is_deferrable => 1, on_delete => "RESTRICT", on_update => "RESTRICT" },
);


# Created by DBIx::Class::Schema::Loader v0.07039 @ 2019-01-03 09:50:09
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:uYFKGZi0OV+RBZkNgquYAA


# You can replace this text with custom code or comments, and it will be preserved on regeneration
1;
