35 lines
674 B
Perl
35 lines
674 B
Perl
package LasTres::Schema::Result::EquipmentItem;
|
|
|
|
use v5.36.0;
|
|
|
|
use strict;
|
|
use warnings;
|
|
|
|
use parent 'DBIx::Class::Core';
|
|
|
|
__PACKAGE__->table('equipment_items');
|
|
|
|
__PACKAGE__->add_columns(
|
|
kind => {
|
|
data_type => 'text',
|
|
is_nullable => 0,
|
|
},
|
|
equipment => {
|
|
data_type => 'uuid',
|
|
is_nullable => 0,
|
|
is_foreign_key => 1,
|
|
},
|
|
identifier => {
|
|
data_type => 'text',
|
|
is_nullable => 0,
|
|
},
|
|
quantity => {
|
|
data_type => 'Integer',
|
|
is_nullable => 0,
|
|
},
|
|
);
|
|
|
|
__PACKAGE__->set_primary_key('kind', 'equipment');
|
|
__PACKAGE__->belongs_to('equipment', 'LasTres::Schema::Result::Equipment');
|
|
1;
|