Class: LWS::DigitalSignage::Layout

Inherits:
Generic::Model show all
Defined in:
lib/lws/apps/digital_signage.rb

Overview

The layout class

Defined Under Namespace

Classes: Category, Element, Version

Instance Attribute Summary collapse

Attributes inherited from Generic::Model

#created_at, #id, #updated_at, #url, #url_html

Method Summary

Methods inherited from Generic::Model

#deep_dup, #dig, #reload, #rollback, #save

Instance Attribute Details

#categoriesArray<Layout::Category>

Returns the categories associated with the layout.

Returns:



509
510
# File 'lib/lws/apps/digital_signage.rb', line 509

has_many :categories, class_name: "LWS::DigitalSignage::Layout::Category",
uri: "layout/:layout_id/categories(/:id)"

#category_idsArray<Integer>

Returns the IDs of the categories assoicated with the layout.

Returns:

  • (Array<Integer>)

    the IDs of the categories assoicated with the layout



503
# File 'lib/lws/apps/digital_signage.rb', line 503

attribute :category_ids

#company_ownerLWS::Auth::Company

Returns the company that owns the layout.

Returns:



514
515
516
# File 'lib/lws/apps/digital_signage.rb', line 514

belongs_to :company_owner, class_name: "LWS::Auth::Company",
foreign_key: :company_owner_id,
uri: "companies/:id"

#company_owner_idInteger

Returns the ID of the company that owns the layout.

Returns:

  • (Integer)

    the ID of the company that owns the layout



520
# File 'lib/lws/apps/digital_signage.rb', line 520

attribute :company_owner_id

#company_shared_idsArray<Integer>

Returns the IDs of the company the layout is shared with.

Returns:

  • (Array<Integer>)

    the IDs of the company the layout is shared with



524
# File 'lib/lws/apps/digital_signage.rb', line 524

attribute :company_shared_ids

#default_duration5..3600

Returns the default duration of a slide created from the layout.

Returns:

  • (5..3600)

    the default duration of a slide created from the layout



528
# File 'lib/lws/apps/digital_signage.rb', line 528

attribute :default_duration

#descriptionString?

Returns the description of the layout.

Returns:

  • (String, nil)

    the description of the layout



532
# File 'lib/lws/apps/digital_signage.rb', line 532

attribute :description

#description_htmlString?

Returns an HTML version of the description of the layout.

Returns:

  • (String, nil)

    an HTML version of the description of the layout



536
# File 'lib/lws/apps/digital_signage.rb', line 536

attribute :description_html

#duration_kind"variable", ...

Returns the duration kind of the layout.

Returns:

  • ("variable", "fixed", "kind")

    the duration kind of the layout



540
# File 'lib/lws/apps/digital_signage.rb', line 540

attribute :duration_kind

#favoriteBoolean

Returns whether the layout is a favorite for the current account.

Returns:

  • (Boolean)

    whether the layout is a favorite for the current account



544
# File 'lib/lws/apps/digital_signage.rb', line 544

attribute :favorite

#kind"marquee", "slide"

Returns the kind of the layout.

Returns:

  • ("marquee", "slide")

    the kind of the layout



548
# File 'lib/lws/apps/digital_signage.rb', line 548

attribute :kind

#nameString

Returns the name of the layout.

Returns:

  • (String)

    the name of the layout



552
# File 'lib/lws/apps/digital_signage.rb', line 552

attribute :name

#parentLayout?

Returns the parent of the layout.

Returns:

  • (Layout, nil)

    the parent of the layout



557
558
559
# File 'lib/lws/apps/digital_signage.rb', line 557

belongs_to :parent, class_name: "LWS::DigitalSignage::Layout",
foreign_key: :parent_id,
uri: "layouts/:id"

#parent_idInteger?

Returns the ID of the parent of the layout.

Returns:

  • (Integer, nil)

    the ID of the parent of the layout



563
# File 'lib/lws/apps/digital_signage.rb', line 563

attribute :parent_id

#priorityBoolean

Returns whether the layout has priority over others.

Returns:

  • (Boolean)

    whether the layout has priority over others



567
# File 'lib/lws/apps/digital_signage.rb', line 567

attribute :priority

#publicBoolean

Returns whether the layout is public (i.e. shared with all companies).

Returns:

  • (Boolean)

    whether the layout is public (i.e. shared with all companies)



572
# File 'lib/lws/apps/digital_signage.rb', line 572

attribute :public

#rotation"landscape", "portrait"

Returns the rotation (orientation) of the layout.

Returns:

  • ("landscape", "portrait")

    the rotation (orientation) of the layout



577
# File 'lib/lws/apps/digital_signage.rb', line 577

attribute :rotation

#slidesArray<Slide>

Returns the slides using the layout.

Returns:

  • (Array<Slide>)

    the slides using the layout



581
582
# File 'lib/lws/apps/digital_signage.rb', line 581

has_many :slides, class_name: "LWS::DigitalSignage::Slide",
uri: "layouts/:layout_id/slides(/:id)"

#thumbnail_urlString?

Returns the URL of the thumbnail of the layout.

Returns:

  • (String, nil)

    the URL of the thumbnail of the layout



586
# File 'lib/lws/apps/digital_signage.rb', line 586

attribute :thumbnail_url

#trans"cut", ...

Returns the transition of the entire layout.

Returns:

  • ("cut", "fadein", "zoomin", "slidein")

    the transition of the entire layout



591
# File 'lib/lws/apps/digital_signage.rb', line 591

attribute :trans

#trans_direction"left", ...

Returns the direction of the transition of the entire layout.

Returns:

  • ("left", "right", "up", "down")

    the direction of the transition of the entire layout



596
# File 'lib/lws/apps/digital_signage.rb', line 596

attribute :trans_direction

#trans_durationInteger

Returns the duration of the transition of the entire layout.

Returns:

  • (Integer)

    the duration of the transition of the entire layout



600
# File 'lib/lws/apps/digital_signage.rb', line 600

attribute :trans_duration

#versionsArray<Version>

Returns the versions of the layout.

Returns:

  • (Array<Version>)

    the versions of the layout



604
605
# File 'lib/lws/apps/digital_signage.rb', line 604

has_many :versions, class_name: "LWS::DigitalSignage::Layout::Version",
uri: "layouts/:layout_id/versions(/:id)"