Class: Files::Settings

Inherits:
Object
  • Object
show all
Defined in:
lib/files.com/models/settings.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}, options = {}) ⇒ Settings

Returns a new instance of Settings.



7
8
9
10
# File 'lib/files.com/models/settings.rb', line 7

def initialize(attributes = {}, options = {})
  @attributes = attributes || {}
  @options = options || {}
end

Instance Attribute Details

#attributesObject (readonly)

Returns the value of attribute attributes.



5
6
7
# File 'lib/files.com/models/settings.rb', line 5

def attributes
  @attributes
end

#optionsObject (readonly)

Returns the value of attribute options.



5
6
7
# File 'lib/files.com/models/settings.rb', line 5

def options
  @options
end

Instance Method Details

#allowed_2fa_method_smsObject

boolean - Is SMS two factor authentication allowed?



193
194
195
# File 'lib/files.com/models/settings.rb', line 193

def allowed_2fa_method_sms
  @attributes[:allowed_2fa_method_sms]
end

#allowed_2fa_method_totpObject

boolean - Is TOTP two factor authentication allowed?



198
199
200
# File 'lib/files.com/models/settings.rb', line 198

def allowed_2fa_method_totp
  @attributes[:allowed_2fa_method_totp]
end

#allowed_2fa_method_u2fObject

boolean - Is U2F two factor authentication allowed?



203
204
205
# File 'lib/files.com/models/settings.rb', line 203

def allowed_2fa_method_u2f
  @attributes[:allowed_2fa_method_u2f]
end

#allowed_2fa_method_yubiObject

boolean - Is yubikey two factor authentication allowed?



208
209
210
# File 'lib/files.com/models/settings.rb', line 208

def allowed_2fa_method_yubi
  @attributes[:allowed_2fa_method_yubi]
end

#attachments_permissionObject

boolean - Can the user create attachments, including bundles?



78
79
80
# File 'lib/files.com/models/settings.rb', line 78

def attachments_permission
  @attributes[:attachments_permission]
end

#audio_regexObject

string - All supported audio types



23
24
25
# File 'lib/files.com/models/settings.rb', line 23

def audio_regex
  @attributes[:audio_regex]
end

#authentication_methodObject

string - Authentication method for the user. Can be ‘password`, `ldap`, `sso`, or `none`



83
84
85
# File 'lib/files.com/models/settings.rb', line 83

def authentication_method
  @attributes[:authentication_method]
end

#avatar_urlObject

string - URL holding the user’s avatar



88
89
90
# File 'lib/files.com/models/settings.rb', line 88

def avatar_url
  @attributes[:avatar_url]
end

#beta_feature2Object

boolean - Is beta feature 2 available?



218
219
220
# File 'lib/files.com/models/settings.rb', line 218

def beta_feature2
  @attributes[:beta_feature2]
end

#beta_feature3Object

boolean - Is beta feature 3 available?



223
224
225
# File 'lib/files.com/models/settings.rb', line 223

def beta_feature3
  @attributes[:beta_feature3]
end

#beta_featuresObject

boolean - Is beta feature 1 available?



213
214
215
# File 'lib/files.com/models/settings.rb', line 213

def beta_features
  @attributes[:beta_features]
end

#bundle_expirationObject

int64 - Site-wide bundle expiration in days



228
229
230
# File 'lib/files.com/models/settings.rb', line 228

def bundle_expiration
  @attributes[:bundle_expiration]
end

#bundle_password_requiredObject

boolean - Do bundle shares require password protection?



233
234
235
# File 'lib/files.com/models/settings.rb', line 233

def bundle_password_required
  @attributes[:bundle_password_required]
end

#color2_leftObject

string - Page link and button color



353
354
355
# File 'lib/files.com/models/settings.rb', line 353

def color2_left
  @attributes[:color2_left]
end

string - Top bar link color



358
359
360
# File 'lib/files.com/models/settings.rb', line 358

def color2_link
  @attributes[:color2_link]
end

#color2_textObject

string - Page link and button color



363
364
365
# File 'lib/files.com/models/settings.rb', line 363

def color2_text
  @attributes[:color2_text]
end

#color2_topObject

string - Top bar background color



368
369
370
# File 'lib/files.com/models/settings.rb', line 368

def color2_top
  @attributes[:color2_top]
end

#color2_top_textObject

string - Top bar text color



373
374
375
# File 'lib/files.com/models/settings.rb', line 373

def color2_top_text
  @attributes[:color2_top_text]
end

#current_languageObject

string - Current language locale setting



58
59
60
# File 'lib/files.com/models/settings.rb', line 58

def current_language
  @attributes[:current_language]
end

#dav_permissionObject

boolean - Can the user connect with WebDAV?



93
94
95
# File 'lib/files.com/models/settings.rb', line 93

def dav_permission
  @attributes[:dav_permission]
end

#desktop_appObject

boolean - Is the desktop app enabled?



243
244
245
# File 'lib/files.com/models/settings.rb', line 243

def desktop_app
  @attributes[:desktop_app]
end

#disable_password_resetObject

boolean - Is password reset disabled?



378
379
380
# File 'lib/files.com/models/settings.rb', line 378

def disable_password_reset
  @attributes[:disable_password_reset]
end

#emailObject

email - User email address



98
99
100
# File 'lib/files.com/models/settings.rb', line 98

def email
  @attributes[:email]
end

#externally_managedObject

boolean - Is this user automatically managed?



153
154
155
# File 'lib/files.com/models/settings.rb', line 153

def externally_managed
  @attributes[:externally_managed]
end

#folder_permissions_groups_onlyObject

boolean - If true, permissions for this site must be bound to a group (not a user). Otherwise, permissions must be bound to a user.



103
104
105
# File 'lib/files.com/models/settings.rb', line 103

def folder_permissions_groups_only
  @attributes[:folder_permissions_groups_only]
end

#ftp_permissionObject

boolean - Can the user access with FTP/FTPS?



108
109
110
# File 'lib/files.com/models/settings.rb', line 108

def ftp_permission
  @attributes[:ftp_permission]
end

#group_adminObject

boolean - Is a group administrator?



113
114
115
# File 'lib/files.com/models/settings.rb', line 113

def group_admin
  @attributes[:group_admin]
end

#has_accountObject

boolean - Connected to an account?



248
249
250
# File 'lib/files.com/models/settings.rb', line 248

def 
  @attributes[:has_account]
end

#hide_billingObject

boolean - Hide billing information?



253
254
255
# File 'lib/files.com/models/settings.rb', line 253

def hide_billing
  @attributes[:hide_billing]
end

#high_users_countObject

boolean - Does the site have a large number of users? (Used to hide some UI features that may be slow in this case.)



343
344
345
# File 'lib/files.com/models/settings.rb', line 343

def high_users_count
  @attributes[:high_users_count]
end

#history_unavailableObject

boolean - Is history unavailable?



258
259
260
# File 'lib/files.com/models/settings.rb', line 258

def history_unavailable
  @attributes[:history_unavailable]
end

#icon128Object

Branded icon 128x128



417
418
419
# File 'lib/files.com/models/settings.rb', line 417

def icon128
  @attributes[:icon128]
end

#icon16Object

Branded icon 16x16



422
423
424
# File 'lib/files.com/models/settings.rb', line 422

def icon16
  @attributes[:icon16]
end

#icon32Object

Branded icon 32x32



427
428
429
# File 'lib/files.com/models/settings.rb', line 427

def icon32
  @attributes[:icon32]
end

#icon48Object

Branded icon 48x48



432
433
434
# File 'lib/files.com/models/settings.rb', line 432

def icon48
  @attributes[:icon48]
end

#image_regexObject

string - All supported image types



13
14
15
# File 'lib/files.com/models/settings.rb', line 13

def image_regex
  @attributes[:image_regex]
end

#immutable_filesObject

boolean - Are files protected from modification?



263
264
265
# File 'lib/files.com/models/settings.rb', line 263

def immutable_files
  @attributes[:immutable_files]
end

#last_read_announcements_atObject

date-time - The last date/time this user has read announcements



118
119
120
# File 'lib/files.com/models/settings.rb', line 118

def last_read_announcements_at
  @attributes[:last_read_announcements_at]
end

#login_help_textObject

string - Login help text



383
384
385
# File 'lib/files.com/models/settings.rb', line 383

def 
  @attributes[:login_help_text]
end

#logoObject

Branded logo



437
438
439
# File 'lib/files.com/models/settings.rb', line 437

def 
  @attributes[:logo]
end

#nameObject

string - User name



123
124
125
# File 'lib/files.com/models/settings.rb', line 123

def name
  @attributes[:name]
end

#notification_daily_send_timeObject

int64 - Hour of the day at which daily notifications should be sent. Can be in range 0 to 23



128
129
130
# File 'lib/files.com/models/settings.rb', line 128

def notification_daily_send_time
  @attributes[:notification_daily_send_time]
end

#overdueObject

boolean - Is billing overdue?



268
269
270
# File 'lib/files.com/models/settings.rb', line 268

def overdue
  @attributes[:overdue]
end

#password_min_lengthObject

int64 - Shortest password length for users



278
279
280
# File 'lib/files.com/models/settings.rb', line 278

def password_min_length
  @attributes[:password_min_length]
end

#password_require_letterObject

boolean - Require a letter in passwords?



283
284
285
# File 'lib/files.com/models/settings.rb', line 283

def password_require_letter
  @attributes[:password_require_letter]
end

#password_require_mixedObject

boolean - Require lower and upper case letters in passwords?



288
289
290
# File 'lib/files.com/models/settings.rb', line 288

def password_require_mixed
  @attributes[:password_require_mixed]
end

#password_require_numberObject

boolean - Require a number in passwords?



293
294
295
# File 'lib/files.com/models/settings.rb', line 293

def password_require_number
  @attributes[:password_require_number]
end

#password_require_specialObject

boolean - Require special characters in password?



298
299
300
# File 'lib/files.com/models/settings.rb', line 298

def password_require_special
  @attributes[:password_require_special]
end

#password_requirements_apply_to_bundlesObject

boolean - Do site-wide password requirements apply to bundles?



238
239
240
# File 'lib/files.com/models/settings.rb', line 238

def password_requirements_apply_to_bundles
  @attributes[:password_requirements_apply_to_bundles]
end

#pdf_regexObject

string - All supported PDF types



28
29
30
# File 'lib/files.com/models/settings.rb', line 28

def pdf_regex
  @attributes[:pdf_regex]
end

#primary_sub_domain_baseObject

string - Primary domain name base of the site



73
74
75
# File 'lib/files.com/models/settings.rb', line 73

def primary_sub_domain_base
  @attributes[:primary_sub_domain_base]
end

#public_urlObject

string - Site public url



303
304
305
# File 'lib/files.com/models/settings.rb', line 303

def public_url
  @attributes[:public_url]
end

#read_onlyObject

string - Is this session read only?



63
64
65
# File 'lib/files.com/models/settings.rb', line 63

def read_only
  @attributes[:read_only]
end

#reauthObject

boolean - Password check skipped?



38
39
40
# File 'lib/files.com/models/settings.rb', line 38

def reauth
  @attributes[:reauth]
end

#reauth_2faObject

string - 2fa type



168
169
170
# File 'lib/files.com/models/settings.rb', line 168

def reauth_2fa
  @attributes[:reauth_2fa]
end

#regionsObject

array - Region name and description



43
44
45
# File 'lib/files.com/models/settings.rb', line 43

def regions
  @attributes[:regions]
end

#require_2faObject

boolean - Require two-factor authentication for the current user?



308
309
310
# File 'lib/files.com/models/settings.rb', line 308

def require_2fa
  @attributes[:require_2fa]
end

#s3_regionsObject

array - Region name and description



48
49
50
# File 'lib/files.com/models/settings.rb', line 48

def s3_regions
  @attributes[:s3_regions]
end

#sales_tax_regionsObject

array - States with applicable sales tax



53
54
55
# File 'lib/files.com/models/settings.rb', line 53

def sales_tax_regions
  @attributes[:sales_tax_regions]
end

#self_managedObject

boolean - Does this user manage it’s own credentials?



133
134
135
# File 'lib/files.com/models/settings.rb', line 133

def self_managed
  @attributes[:self_managed]
end

#session_languageObject

string - Session locale setting



68
69
70
# File 'lib/files.com/models/settings.rb', line 68

def session_language
  @attributes[:session_language]
end

#sftp_permissionObject

boolean - Can the user access with SFTP?



138
139
140
# File 'lib/files.com/models/settings.rb', line 138

def sftp_permission
  @attributes[:sftp_permission]
end

boolean - Show request access link for users without access?



313
314
315
# File 'lib/files.com/models/settings.rb', line 313

def show_request_access_link
  @attributes[:show_request_access_link]
end

#site_adminObject

boolean - Is the user an administrator for this site?



143
144
145
# File 'lib/files.com/models/settings.rb', line 143

def site_admin
  @attributes[:site_admin]
end

string - Site footer for branding



397
398
399
# File 'lib/files.com/models/settings.rb', line 397

def site_footer
  @attributes[:site_footer]
end

#site_headerObject

string - Site header for branding



402
403
404
# File 'lib/files.com/models/settings.rb', line 402

def site_header
  @attributes[:site_header]
end

#site_languageObject

string - Site language locale



407
408
409
# File 'lib/files.com/models/settings.rb', line 407

def site_language
  @attributes[:site_language]
end

#site_nameObject

string - Site name



388
389
390
# File 'lib/files.com/models/settings.rb', line 388

def site_name
  @attributes[:site_name]
end

#site_unavailableObject

boolean - Is the site unavailable?



273
274
275
# File 'lib/files.com/models/settings.rb', line 273

def site_unavailable
  @attributes[:site_unavailable]
end

#skip_welcome_screenObject

boolean - Skip the welcome screen?



148
149
150
# File 'lib/files.com/models/settings.rb', line 148

def skip_welcome_screen
  @attributes[:skip_welcome_screen]
end

#sso_strategiesObject



392
393
394
# File 'lib/files.com/models/settings.rb', line 392

def sso_strategies
  @attributes[:sso_strategies]
end

#tab_configObject

string - Deprecated



33
34
35
# File 'lib/files.com/models/settings.rb', line 33

def tab_config
  @attributes[:tab_config]
end

#time_zoneObject

string - User time zone



158
159
160
# File 'lib/files.com/models/settings.rb', line 158

def time_zone
  @attributes[:time_zone]
end

#trial_days_leftObject

int64 - Number of days left in trial



318
319
320
# File 'lib/files.com/models/settings.rb', line 318

def trial_days_left
  @attributes[:trial_days_left]
end

#trial_flagged_as_duplicateObject

boolean - Has this site been flagged as a duplicate of another trial?



328
329
330
# File 'lib/files.com/models/settings.rb', line 328

def trial_flagged_as_duplicate
  @attributes[:trial_flagged_as_duplicate]
end

#trial_lockedObject

boolean - Is this site a free trial that is locked due to fraud concerns?



323
324
325
# File 'lib/files.com/models/settings.rb', line 323

def trial_locked
  @attributes[:trial_locked]
end

#trial_untilObject

date-time - When does this Site trial expire?



333
334
335
# File 'lib/files.com/models/settings.rb', line 333

def trial_until
  @attributes[:trial_until]
end

#type_of_2faObject

string - 2fa type



163
164
165
# File 'lib/files.com/models/settings.rb', line 163

def type_of_2fa
  @attributes[:type_of_2fa]
end

#use_provided_modified_atObject

boolean - Allow setting provided_modified_at?



338
339
340
# File 'lib/files.com/models/settings.rb', line 338

def use_provided_modified_at
  @attributes[:use_provided_modified_at]
end

#user_idObject

int64 - User ID



173
174
175
# File 'lib/files.com/models/settings.rb', line 173

def user_id
  @attributes[:user_id]
end

#user_languageObject

string - Preferred language



178
179
180
# File 'lib/files.com/models/settings.rb', line 178

def user_language
  @attributes[:user_language]
end

#usernameObject

string - User’s username



183
184
185
# File 'lib/files.com/models/settings.rb', line 183

def username
  @attributes[:username]
end

#users_countObject

int64 - Count of users on the site. Only exposed for site admins.



348
349
350
# File 'lib/files.com/models/settings.rb', line 348

def users_count
  @attributes[:users_count]
end

#video_regexObject

string - All supported video types



18
19
20
# File 'lib/files.com/models/settings.rb', line 18

def video_regex
  @attributes[:video_regex]
end

#web_rootObject

string - Root web folder



188
189
190
# File 'lib/files.com/models/settings.rb', line 188

def web_root
  @attributes[:web_root]
end

#welcome_screenObject

string - Does the welcome screen appear? Can be ‘enabled`, `hidden`, or `disabled`



412
413
414
# File 'lib/files.com/models/settings.rb', line 412

def welcome_screen
  @attributes[:welcome_screen]
end