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

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

=head1 NAME

CLMApp::Schema::Result::ChainGroup

=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<ChainGroup>

=cut

__PACKAGE__->table("ChainGroup");

=head1 ACCESSORS

=head2 chaingroupid

  data_type: 'integer'
  is_auto_increment: 1
  is_nullable: 0

=head2 chaingroupname

  data_type: 'varchar'
  is_nullable: 1
  size: 50

=head2 chaingroupamphireid

  data_type: 'integer'
  is_nullable: 1

=head2 chaingroupvp

  data_type: 'integer'
  is_nullable: 1

=head2 chaingrouppam

  data_type: 'integer'
  is_nullable: 1

=head2 chaingroupnotes

  data_type: 'text'
  is_nullable: 1

=head2 active

  data_type: 'integer'
  default_value: 1
  is_nullable: 1

=head2 bpstorefrontcode

  data_type: 'varchar'
  is_nullable: 1
  size: 50

=head2 arrowstreamid

  data_type: 'integer'
  default_value: 0
  is_nullable: 1

=head2 invoicesystem

  data_type: 'integer'
  default_value: 0
  is_nullable: 1

=head2 ordersystem

  data_type: 'integer'
  default_value: 0
  is_nullable: 1

=cut

__PACKAGE__->add_columns(
  "chaingroupid",
  { data_type => "integer", is_auto_increment => 1, is_nullable => 0 },
  "chaingroupname",
  { data_type => "varchar", is_nullable => 1, size => 50 },
  "chaingroupamphireid",
  { data_type => "integer", is_nullable => 1 },
  "chaingroupvp",
  { data_type => "integer", is_nullable => 1 },
  "chaingrouppam",
  { data_type => "integer", is_nullable => 1 },
  "chaingroupnotes",
  { data_type => "longtext", is_nullable => 1 },
  "active",
  { data_type => "integer", is_nullable => 1 },   
  "bpstorefrontcode",
  { data_type => "varchar", is_nullable => 1, size => 50 },
  "arrowstreamid",
  { data_type => "integer", default_value => 0, is_nullable => 1 },
  "invoicesystem",
  { data_type => "integer", default_value => 0, is_nullable => 1 },
  "ordersystem",
  { data_type => "integer", default_value => 0, is_nullable => 1 },
);

=head1 PRIMARY KEY

=over 4

=item * L</chaingroupid>

=back

=cut

__PACKAGE__->set_primary_key("chaingroupid");

__PACKAGE__->belongs_to(
  "programmanager",
  "CLMApp::Schema::Result::DmaprogramManager",
  { "foreign.dmaprogrammanagerid" => "self.chaingrouppam" },
  { is_deferrable => 0, on_delete => "NO ACTION", on_update => "NO ACTION", join_type => 'left' },
);

__PACKAGE__->belongs_to(
  "vp",
  "CLMApp::Schema::Result::Dmavp",
  { "foreign.dmavpid" => "self.chaingroupvp" },
  { is_deferrable => 0, on_delete => "NO ACTION", on_update => "NO ACTION", join_type => 'left' },
);
# Created by DBIx::Class::Schema::Loader v0.07039 @ 2017-05-06 14:53:22
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:n/vomG4jYQy6vuUboEG5FA


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