added new relations
This commit is contained in:
parent
bea1301475
commit
c456428681
14 changed files with 4782 additions and 4 deletions
|
@ -105,6 +105,18 @@ __PACKAGE__->belongs_to(
|
|||
"entity_id",
|
||||
);
|
||||
|
||||
__PACKAGE__->belongs_to(
|
||||
"organisation_type",
|
||||
"Pear::LocalLoop::Schema::Result::OrganisationType",
|
||||
"type_id",
|
||||
);
|
||||
|
||||
__PACKAGE__->belongs_to(
|
||||
"social_type",
|
||||
"Pear::LocalLoop::Schema::Result::OrganisationType",
|
||||
"social_type_id",
|
||||
);
|
||||
|
||||
__PACKAGE__->has_many(
|
||||
"payroll",
|
||||
"Pear::LocalLoop::Schema::Result::OrganisationPayroll",
|
||||
|
|
|
@ -87,6 +87,12 @@ __PACKAGE__->has_one(
|
|||
{ 'foreign.transaction_id' => 'self.id' },
|
||||
);
|
||||
|
||||
__PACKAGE__->has_many(
|
||||
"external_reference",
|
||||
"Pear::LocalLoop::Schema::Result::TransactionExternal",
|
||||
{ 'foreign.transaction_id' => 'self.id' },
|
||||
);
|
||||
|
||||
sub sqlt_deploy_hook {
|
||||
my ( $source_instance, $sqlt_table ) = @_;
|
||||
my $pending_field = $sqlt_table->get_field('essential');
|
||||
|
|
|
@ -8,7 +8,7 @@ use base 'DBIx::Class::Core';
|
|||
__PACKAGE__->table("transactions_external");
|
||||
|
||||
__PACKAGE__->add_columns(
|
||||
"id" => {
|
||||
"id" => {
|
||||
data_type => "integer",
|
||||
is_auto_increment => 1,
|
||||
is_nullable => 0,
|
||||
|
@ -23,7 +23,7 @@ __PACKAGE__->add_columns(
|
|||
is_foreign_key => 1,
|
||||
is_nullable => 0,
|
||||
},
|
||||
"external_id" => {
|
||||
"external_id" => {
|
||||
data_type => "varchar",
|
||||
size => 255,
|
||||
is_nullable => 0,
|
||||
|
@ -46,4 +46,4 @@ __PACKAGE__->belongs_to(
|
|||
{ 'foreign.id' => 'self.external_reference_id' },
|
||||
);
|
||||
|
||||
1;
|
||||
1;
|
||||
|
|
Reference in a new issue