Class: ContainerLabel

Inherits:
ActiveRecord::Base
  • Object
show all
Includes:
Housekeeping, Shared::IsData
Defined in:
app/models/container_label.rb

Overview

A buffer for holding specifications for physical labels of the container

Instance Attribute Summary (collapse)

Method Summary

Methods included from Housekeeping

#has_polymorphic_relationship?

Instance Attribute Details

- (Integer) container_id

Returns the container the label will be attached to

Returns:

  • (Integer)

    the container the label will be attached to



23
24
25
26
27
28
29
30
31
32
33
34
# File 'app/models/container_label.rb', line 23

class ContainerLabel < ActiveRecord::Base

  acts_as_list scope: [:container]

  include Housekeeping
  include Shared::IsData

  belongs_to :container

  validates_presence_of :container_id
  validates_presence_of :label
end

- (DateTime) date_printed

Returns date the label was printed

Returns:

  • (DateTime)

    date the label was printed



23
24
25
26
27
28
29
30
31
32
33
34
# File 'app/models/container_label.rb', line 23

class ContainerLabel < ActiveRecord::Base

  acts_as_list scope: [:container]

  include Housekeeping
  include Shared::IsData

  belongs_to :container

  validates_presence_of :container_id
  validates_presence_of :label
end

- (String) label

Returns the physical label applied or to be applied to the drawers

Returns:

  • (String)

    the physical label applied or to be applied to the drawers



23
24
25
26
27
28
29
30
31
32
33
34
# File 'app/models/container_label.rb', line 23

class ContainerLabel < ActiveRecord::Base

  acts_as_list scope: [:container]

  include Housekeeping
  include Shared::IsData

  belongs_to :container

  validates_presence_of :container_id
  validates_presence_of :label
end

Returns reference to a CSS class defining the style of the label

Returns:

  • (String)

    reference to a CSS class defining the style of the label



23
24
25
26
27
28
29
30
31
32
33
34
# File 'app/models/container_label.rb', line 23

class ContainerLabel < ActiveRecord::Base

  acts_as_list scope: [:container]

  include Housekeeping
  include Shared::IsData

  belongs_to :container

  validates_presence_of :container_id
  validates_presence_of :label
end

- (Integer) project_id

the project ID

Returns:

  • (Integer)


23
24
25
26
27
28
29
30
31
32
33
34
# File 'app/models/container_label.rb', line 23

class ContainerLabel < ActiveRecord::Base

  acts_as_list scope: [:container]

  include Housekeeping
  include Shared::IsData

  belongs_to :container

  validates_presence_of :container_id
  validates_presence_of :label
end