Class: LWS::Presence::Person

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

Overview

The person class

Instance Attribute Summary collapse

Attributes inherited from Generic::Model

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

Method Summary

Methods inherited from Generic::Model

#reload, #rollback, #save

Instance Attribute Details

#companyLWS::Auth::Company

Returns the company the person belongs to.

Returns:



248
# File 'lib/lws/apps/presence.rb', line 248

belongs_to :company, class_name: "LWS::Auth::Company"

#company_idInteger

Returns the ID of the company the person belongs to.

Returns:

  • (Integer)

    the ID of the company the person belongs to



252
# File 'lib/lws/apps/presence.rb', line 252

attribute :company_id

#customer_referenceString?

Returns the customer specific reference for the person.

Returns:

  • (String, nil)

    the customer specific reference for the person



256
# File 'lib/lws/apps/presence.rb', line 256

attribute :customer_reference

#emailString?

Returns the email address of the person.

Returns:

  • (String, nil)

    the email address of the person



260
# File 'lib/lws/apps/presence.rb', line 260

attribute :email

#eroBoolean

Returns whether the person is emergency response ceritified.

Returns:

  • (Boolean)

    whether the person is emergency response ceritified



265
# File 'lib/lws/apps/presence.rb', line 265

attribute :ero

#extra_infoString?

Returns some extra info for the person.

Returns:

  • (String, nil)

    some extra info for the person



269
# File 'lib/lws/apps/presence.rb', line 269

attribute :extra_info

#import_refString?

Returns reference for storing the uid of the remote database.

Returns:

  • (String, nil)

    reference for storing the uid of the remote database



273
# File 'lib/lws/apps/presence.rb', line 273

attribute :import_ref

#last_syncString?

Returns the last date/time the status was updated via a device or RFID tag.

Returns:

  • (String, nil)

    the last date/time the status was updated via a device or RFID tag



278
# File 'lib/lws/apps/presence.rb', line 278

attribute :last_sync

#latFloat?

Returns the exact latitude of the person’s location.

Returns:

  • (Float, nil)

    the exact latitude of the person’s location



282
# File 'lib/lws/apps/presence.rb', line 282

attribute :lat

#locationLocation

Returns the location the person is located at.

Returns:

  • (Location)

    the location the person is located at



290
# File 'lib/lws/apps/presence.rb', line 290

belongs_to :location

#location_ancestors_idsArray<Integer>

Returns the IDs of the (nesting) locations the person is located at.

Returns:

  • (Array<Integer>)

    the IDs of the (nesting) locations the person is located at



295
# File 'lib/lws/apps/presence.rb', line 295

attribute :location_ancestor_ids

#location_idInteger

Returns the ID of the location the person is located at.

Returns:

  • (Integer)

    the ID of the location the person is located at



299
# File 'lib/lws/apps/presence.rb', line 299

attribute :location_id

#longFloat?

Returns the exact longitude of the person’s location.

Returns:

  • (Float, nil)

    the exact longitude of the person’s location



286
# File 'lib/lws/apps/presence.rb', line 286

attribute :long

#nameString

Returns the name of the person.

Returns:

  • (String)

    the name of the person



303
# File 'lib/lws/apps/presence.rb', line 303

attribute :name

#phone_extensionString

Returns the fixed phonenumber extension of the person.

Returns:

  • (String)

    the fixed phonenumber extension of the person



315
# File 'lib/lws/apps/presence.rb', line 315

attribute :phone_extension

#phone_fixedString

Returns the fixed phonenumber of the person.

Returns:

  • (String)

    the fixed phonenumber of the person



307
# File 'lib/lws/apps/presence.rb', line 307

attribute :phone_fixed

#phone_mobileString

Returns the mobile phonenumber of the person.

Returns:

  • (String)

    the mobile phonenumber of the person



311
# File 'lib/lws/apps/presence.rb', line 311

attribute :phone_moblie

#picture_urlString?

Returns the URL of the picture of the person.

Returns:

  • (String, nil)

    the URL of the picture of the person



319
# File 'lib/lws/apps/presence.rb', line 319

attribute :picture_url

#presentBoolean

Returns if a person is present at a location. It looks at the state of a person so that local state checking is not needed.

Returns:

  • (Boolean)

    if a person is present at a location. It looks at the state of a person so that local state checking is not needed.



325
# File 'lib/lws/apps/presence.rb', line 325

attribute :present

#rfidString?

Returns the RFID tag ID linked to the person.

Returns:

  • (String, nil)

    the RFID tag ID linked to the person



329
# File 'lib/lws/apps/presence.rb', line 329

attribute :rfid

#status"available", ...

Returns the presence status of the person.

Returns:

  • ("available", "busy", "away", "disabled", nil)

    the presence status of the person



334
# File 'lib/lws/apps/presence.rb', line 334

attribute :status

#udidString?

Returns the unique device ID (e.g. of a mobile phone) linked to the person.

Returns:

  • (String, nil)

    the unique device ID (e.g. of a mobile phone) linked to the person



339
# File 'lib/lws/apps/presence.rb', line 339

attribute :udid

#vehicle_registration_plateString?

Returns The vehicle registration plate of the persons transport.

Returns:

  • (String, nil)

    The vehicle registration plate of the persons transport



343
# File 'lib/lws/apps/presence.rb', line 343

attribute :vehicle_registration_plate

#visibility"public", "private"

Returns if a person should be protected by not showing critical information.

Returns:

  • ("public", "private")

    if a person should be protected by not showing critical information



347
# File 'lib/lws/apps/presence.rb', line 347

attribute :visibility