--- lib/Arh/Model/Unit.pm 2007/11/29 00:34:22 2 +++ lib/Arh/Model/Unit.pm 2007/11/29 16:08:13 8 @@ -15,10 +15,6 @@ type is 'text', label is _("Number"), is mandatory; - - column material => - label is _("Material"), - refers_to Arh::Model::UnitMaterial; column dimensions => label is _("Dimensions"), @@ -30,7 +26,8 @@ type is 'text'; column description => - label is _("Description"); + label is _("Description"), + render as 'textarea'; column chronology => label is _("Chronology"), @@ -45,5 +42,12 @@ # Your model-specific methods go here. +sub material { + my $self = shift; + my $m = Arh::Model::UnitMaterialCollection->new; + $m->limit( column => 'unit', value => $self->id ); + return $m; +} + 1;