Smarty

  1. Home
  2. Docs
  3. Smarty
  4. Portal and application settings
  5. Options for the titanium interface

Options for the titanium interface

Additional options allow you to change the appearance and behavior of the application, and are specified in the configuration file /etc/microimpuls/portal/client.js.

The following options are available for the titanium interface.

Contents show off

Authorization

At the first launch of the application, the subscriber is shown by default the authorization screen in the service by login and password. Optionally, you can also authorize in other ways:

  • by phone number;
  • by device identifier/IP address.

Managing the choice of authorization method occurs in several places, in order of priority:

  • file client.js optional auth_mode;
  • in the admin on the page "Settings of applications and devices", in the field "Method of authorization".

Authorization by device identifier/IP address

Included in option "auth_mode": "device_uid". From the point of view of the user, this authorization occurs in the background when the application is launched:

  • first, the desired account is searched by the user’s IP address (based on the “Subnet” field of the account);
  • if no account is found by IP, an attempt is made to find an account by device identifier (based on the devices associated with the account);
  • after a successful search, a check is made for the availability of authorization from the user’s network, for compliance with the limit of associated devices, status and other rules set for the account (see the account page).

Available limits of devices for the account are regulated by connected tariffs, namely the properties of the “Multi-subscription settings” for connected tariffs. For the convenience of calculating available devices and sessions for an account on its page, its limits and the number of current occupied slots are displayed in the “Account Information” block.

Different fields can be used as an identifier for different types of devices: serial numbers, MAC addresses, pseudo-random generated UIDs, etc. Due to the variability of the park android devices, there is an option android_uid_generation_methodthis allows you to choose which field to use as an identifier.

If the number of attached devices exceeds, the user is shown their list with the ability to untie the unnecessary and try to log in again.

Useful Smarty options for authorization:

Display of the button for selecting the authorization method (by login and password or phone number)

Option name: show_alter_auth_button, data type: bool.

Possible values:

  • true - the authorization screen will display the button for selecting the login method.
  • falsely - the button for selecting the login method will not be displayed (by default).

Example:

var CLIENT_SETTINGS = {
  // …
  'show_alter_auth_button': true
};

Display of the legal document on the authorization screen

Option name: show_auth_legal_documents, data type: bool.

Possible values:

  • true at the bottom of the authorization screen, a legal document will be displayed, to which you can transfer the focus and then open.
  • falsely the legal document will not be displayed (by default).

Example:

var CLIENT_SETTINGS = {
  // …
  'show_auth_legal_documents': false
};

Display of the entered password on the authorization screen

Option name: show_see_password_button, data type: bool.

Possible values:

  • true — на экране ввода пароля будет отображаться кнопка показа пароля (иконка глаза).
  • falsely the password button will be hidden (by default).

Example:

var CLIENT_SETTINGS = {
  // …
  'show_see_password_button': false
};

Length of confirmation code from SMS message

Option name: sms_code_length, data type: int.

Determines the number of windows when entering the confirmation code from SMS. By default 6.

Example:

var CLIENT_SETTINGS = {
  // …
  'sms_code_length': 4
};

Length of confirmation code by phone number

Option name: phone_code_length, data type: int.

Determines the number of windows when entering the confirmation code from the phone number. By default 4.

Example:

var CLIENT_SETTINGS = {
  // …
  'phone_code_length': 4
};

Mobile phone number mask in the authorization screen

Option name: registration_phone_mask, data type: string.

By default +7 ??? ??? ?? ??.

The mask uses a special symbol ?, instead of which the input value will be substituted, the remaining characters will be displayed as is.

Example:

var CLIENT_SETTINGS = {
///...
'registration_phone_mask': '+7??????????
};

Saving the login and password in the input fields on the authorization screen when restarting the application

Option name: restore_login_form_input_from_settings, data type: bool.

Possible values:

  • true when restarting the application and in the case of a logout in the input fields, the login and password from the previous session will be filled on the authorization screen.
  • falsely the data will not be completed (by default).

It is recommended to use this option in the authorization method password to avoid loss of password by subscribers after logout.

Example:

var CLIENT_SETTINGS = {
///...
'restore_login_form_input_from_settings': false
};

The ability to enter characters in the password

Option name: is_letter_in_password, data type: bool.

Possible values:

  • true numbers and letters can be entered in the password.
  • falsely only numbers can be entered in the password (by default).

Example:

var CLIENT_SETTINGS = {
///...
'is_letters_in_password': false
};

Reboot the device after the first activation

Option name: reboot_device_after_login_with_password, data type: bool.

Possible values:

  • true - after the subscriber is authorized with a login and password through the authorization form, the device will be rebooted.
  • falsely no reboot will be made, the application will be downloaded as usual (by default).

It can be used to perform system billing operations during the initial “activation” of the prefix by the subscriber.

Example:

var CLIENT_SETTINGS = {
///...
'reboot_device_after_login_with_password': false
};

Registration

For the registration scenario by the user's phone number through the application, an option is provided registration_available.

Example:

var CLIENT_SETTINGS = {
// ..
'registration_available': true,
};

Main screen screen

The following types of dashboard tapes are available in the interface:

Television channels

Displayed in a grid of two lines of 9 elements.

Films and film selection

For a film with movies, you can specify the poster used in the “Display Type” field:

  • normal_ad_banner use a horizontal advertising banner as a cover
  • blank line – default value, using a standard vertical poster

Recently watched movies

Displays the tape “Continue watching” with films and TV series that began to watch, but did not watch until the end. The series is considered reviewed if you have watched all episodes of all seasons.

Widgets

The tape works in two modes:

  • display of applications run in Smarty - this mode is enabled by option "show_installed_apps": false. Applications will appear in the feed if they have a checkbox “Show the application in the main menu” and the type corresponds to one of the listed: a Web application in the external window, a Web application in the internal window, launching an Android application by ID, launching a system application by ID.
  • display installed on the console applications (only for Android devices).

Transmissions

Transmissions: past or future. When you click on the past transfer, a full-screen player opens with its recording if available, otherwise the information pop-window is shown.

Ограничение порции загружаемых лент

Option name: dashboard_load_portion, data type: int.

By default 4, это означает, что после успешной загрузки 4 первых лент будет осуществлена их отрисовка, а остальные ленты продолжат свою загрузку по мере навигации на экране. Минимальное значение для данной опции — 2.

Example:

var CLIENT_SETTINGS = {
///...
'dashboard_load_portion': 4
};

Main menu

Items of the main menu are regulated by the option custom_main_menu_items, available values:

  • main - item "Main"
  • tv — item “Telechannels”
  • vod - item "Kinosal"
  • archive - item "Archive"
  • search - item "Search"
  • settings - "Settings" item

Example:

var CLIENT_SETTINGS = {
// ..
'custom_main_menu_items': ['main', 'tv', 'vod', 'search', 'settings'],
};

Television channels and EPG

Limit the maximum length of the channel number

Option name: channel_number_max_length, data type: int. By default 3.

Set the maximum length of the channel number:

  • on the television screen;
  • when you directly enter the channel number from the digital buttons of the remote.

Example:

var CLIENT_SETTINGS = {
///...
'channel_number_max_length': 3
};

Limit the maximum length of the channel number

Option name: channel_number_max_length, data type: int. By default 3.

Set the maximum length of the channel number:

  • on the television screen;
  • when you directly enter the channel number from the digital buttons of the remote.

Example:

var CLIENT_SETTINGS = {
///...
'channel_number_max_length': 3
};

Depth of TV program display

Option name: max_epg_depth, data type: int.

Determines the depth of EPG in days for the TV screen:

  • if morethe depth will be equal to this value;
  • if the option is not set (or equal) 0), then:
  • the archive depth will be used for the archive channel (server restriction),
  • if the channel does not have an archive, the tv program will be displayed only for the current day.

By default 0.

Example:

var CLIENT_SETTINGS = {
///...
'max_epg_depth': 0
};

Optimizing the loading of the channel list

Option name: channel_info_request_depth, data type: int.

Determines the portion size of channels for which you need to get more detailed information, by default 24. The loading volume is calculated by the formula: channel_info_request_depth * 2 + 1, i.e. downloaded information about the channel on which the focus and channel_info_request_depth the channels that exist before and after it. Warning: for the correct operation of the option, the Smarty version is not lower than 2.4.

Example:

var CLIENT SETTINGS = {
///...
'channel info request depth': 24
};

Hiding the Zero Rating of TV Programs

Option name: epg_hide_zero_plus_rating, data type: bool.

Possible values:

  • true rating 0+ will be hidden (only for the visual display of rankings, not content).
  • falsely rating 0+ it will be displayed (by default).

Example:

var CLIENT_SETTINGS = {
///...
'epg_hide_zero_plus_rating': false
};

Switching channels within the selected category

Option name: switching_channels_inside_category, data type: bool.

Possible values:

  • true switching channels with buttons Ch+/- it will take place within the selected channel category.
  • falsely Switching will occur within the All category, even if another category is selected (by default).

Example:

var CLIENT_SETTINGS = {
///...
'switching_channels_inside_category': false
};

Automatic playback of the last channel viewed at launch

Option name: auto_launch_last_view_channel, data type: bool.

Possible values:

  • true play the last channel automatically when the application starts.
  • falsely display the main screen (by default).

Example:

var CLIENT_SETTINGS = {
///...
'auto_launch_last_viewed_channel': false
};

Disabling channel autostart in the preview window when navigating the list

Option name: autoplay_tv_preview_channels, data type: bool.

Possible values:

  • true when navigating in the channel list (relevant to the mode) listthe player in the preview window automatically starts playing after a small timeout (by default).
  • falsely When navigating in the list of channels, the preview player does not start. This value is recommended for low-performance devices for which the flow start operation in the preview window is too heavy to cause it so often.

Example:

var CLIENT SETTINGS = {
///...
'autoplay tv preview channels': true
};

Reproduction of streams-stubs for channels with locks

Option name: request_url_for_locked_channels, data type: bool.

Possible values:

  • true when starting the channel with a lock, an attempt is made to start the stream-stub (if it is set) and display a banner-stub; if the stream-stub for the channel is not set, an information popp is shown.
  • falsely when you start the channel with a lock, an information pop-up with a list of tariffs for connecting is shown (by default).

Example:

var CLIENT_SETTINGS = {
///...
'request_url_for_locked_channels': false
};

Remembering the latest TV category

Option name: save_last_tvcategory, data type: bool.

Possible values:

  • true The application remembers the last selected channel category and restores it the next time you log in to the Channels.
  • falsely category is not remembered (the default behavior of the interface).

Example:

var CLIENT SETTINGS = {
///...
'save last tvcategory': true
};

Randomization of the EPG update interval for past transmissions

Option name: expired_programs_update_interval_randomization, data type: int.

The option adds random bias to the periodic update of EPG data (including for past/completed transmissions) to reduce the likelihood of simultaneous requests from a large number of devices.

Example:

var CLIENT SETTINGS = {
///...
'expired programs update interval randomization': 30
};

Popap display with a choice of tariff when starting a channel with a lock

Option name: show_locked_tariff_popup, data type: bool.

Possible values:

  • true — при запуске канала с замочком или нажатии кнопки «Купить» у фильма отображается попап выбора тарифа.
  • falsely — при запуске канала с замочком показывается информационный попап о том, что контент недоступен в рамках подписки (по умолчанию). Поведение кнопки «Купить» у фильма более подробно описано ниже.

Example:

var CLIENT_SETTINGS = {
  // …
  'show_locked_tariff_popup': false
};

Отображение иконок каналов

Option name: use_cover_for_channel_icons, data type: bool.

Possible values:

  • true — иконка канала прямоугольная и занимает всю область, отведенную ей в интерфейсе (в списке каналов, в плеере, на экране передач и в элементах программ — в Smarty должен быть размер иконок 376 на 224 пикселя).
  • falsely — иконка канала квадратная и вписана в прямоугольник с белым фоном (по умолчанию, в таком формате иконки заливаются из EPG-источника).

Example:

var CLIENT_SETTINGS = {
  // …
  'use_cover_for_channel_icons': true
};
‘use_cover_for_channel_icons’: true
‘use_cover_for_channel_icons’: false

Player

Rewinding the archive by re-querying the position

Option name: server_rewind_mode, data type: bool.

Possible values:

  • true - for rewinding will be used positioning by specifying the time stamp. The URL to the thread will be re-requested from the server at each rewind (by default).
  • falsely fast-forward through the stream by the seek method by means of the player (does not always work correctly due to different implementations on players, but faster).

Example:

var CLIENT_SETTINGS = {
///...
'server_rewind_mode': true
};

Player rewind step

Option name: player_wind_step, data type: int.

Allows you to set the step of rewinding the player in the archive and video library mode in one click of the rewind button. Step is given in seconds, by default 60 в titanium (в других шаблонах может быть 30).

Example:

var CLIENT_SETTINGS = {
  // …
  'player_rewind_step': 60
};

Display time of the beginning and end of the transfer in the infobar

Option name: infobar_time_display_mode, data type: string.

Allows you to change the option of displaying the time of the beginning and end of the transfer in the infobar in the archive mode or paused Live TV.

Possible values:

  • by_epg time in the infobar is displayed according to the transmission program (by default).
  • by_duration the start time of the transmission is set at 00:00, and the end time is set equal to the duration of the transmission.

Example:

var CLIENT_SETTINGS = {
///...
'infobar_time_display_mode': "by_epg"
};

Automatically Hiding Menus When Playing Content

Option name: autohide_timer, data type: int.

Allows you to set a timeout (in minutes), after which the current screen will be hidden and open full-screen player, if at the moment there is a playback of some content.

By default 0 (hidden off).

Example:

var CLIENT_SETTINGS = {
///...
'autohide_timer': 2
};

Save the selected audio track language for each channel separately

Option name: save_audio_track_lang_per_channel, data type: bool.

Possible values:

  • true in the application settings on the device, the user selected audio track language will be stored separately for each channel.
  • falsely the last selected language common to all channels will be saved (by default).

Example:

var CLIENT_SETTINGS = {
///...
'save_audio_track_lang_per_channel': false
};

Сохранение выбранного языка субтитров для каждого канала отдельно

Option name: save_subtitle_track_lang_per_channel, data type: bool.

Possible values:

  • true — выбранный язык субтитров сохраняется отдельно для каждого канала.
  • falsely — сохраняется последний выбранный язык субтитров общий для всех каналов (по умолчанию).

Example:

var CLIENT_SETTINGS = {
///...
'save_subtitle_track_lang_per_channel': false
};

Keeping the selected aspect ratio for each channel separately

Option name: save_aspect_ratio_per_channel, data type: bool.

Possible values:

  • true in the application settings on the device, the aspect ratio selected by the user will be stored separately for each channel.
  • falsely the last selected aspect ratio common to all channels will be retained (by default).

Example:

var CLIENT_SETTINGS = {
///...
'save_aspect_ratio_per_channel': false
};

Ignoring the aspect ratio value coming from Smarty

Option name: ignore_server_aspect, data type: bool.

Possible values:

  • true Setting an aspect ratio on the channel editing page in Smarty will not affect the channel aspect ratio (by default).
  • falsely The “Party Ratio” value on the channel editing page in Smarty will be taken by default for channels.

Example:

var CLIENT_SETTINGS = {
///...
'ignore_server_aspect': false
};

Setting a special ratio of screen sides when playing movies

Option name: set_default_aspect_ratio_for_vod, data type: bool.

Possible values:

  • true after the inclusion of the playback of the film from the video library, the aspect ratio of 16×9 will be forcibly established.
  • falsely - the aspect ratio selected earlier by the subscriber will be retained (by default).

Example:

var CLIENT_SETTINGS = {
///...
'set_default_aspect_ratio_for_vod': false
};

Sound control mode on Samsung Smart TV Orsay

Option name: samsung_smart_tv_volume_control_off, data type: bool.

Possible values:

  • true — управление звуком осуществляется на уровне операционной системы устройства (стандартное управление внутри телевизора).
  • falsely sound management is carried out at the application level (by default).

Example:

var CLIENT_SETTINGS = {
///...
'samsung_smart_tv_volume_control_off': false
};

Volume up/down step

Option name: volume_control_step, data type: int.

By default 5 (percentage points out of 100, where 100 is the maximum volume, 0 is the minimum).

Example:

var CLIENT_SETTINGS = {
///...
'volume_control_step': 5
};

Смещение для паузы Live TV относительно текущего времени

Option name: time_offset_from_now_for_tv_use_parameter, data type: int.

Используется при определении доступности паузы прямого эфира: сравнивается время передачи с текущим временем сервера с учётом заданного смещения (в секундах).

Example:

var CLIENT_SETTINGS = {
  // …
  'time_offset_from_now_for_tv_pause_parameter': 300
};

Сдвиг паузы Live TV по умолчанию

Option name: default_pause_live_tv_shift, data type: int.

Смещение в секундах при работе с паузой прямого эфира (используется для уменьшения нагрузки на стример при возобновлении воспроизведения).

Example:

var CLIENT_SETTINGS = {
  // …
  'default_pause_live_tv_shift': 0
};

Задержка при операциях с live-потоком на паузе

Option name: pause_live_stream_delay, data type: int.

Задержка в миллисекундах перед выполнением операций с live-потоком в режиме паузы.

Example:

var CLIENT_SETTINGS = {
  // …
  'pause_live_stream_delay': 1000
};

Интервал отправки позиции просмотра

Option name: content_position_set_interval, data type: int.

Интервал в миллисекундах периодической отправки позиции просмотра на сервер во время воспроизведения.

Example:

var CLIENT_SETTINGS = {
///...
'content_position_set_interval': 30,000
};

Интервал отправки статистики просмотра

Option name: push_stat_interval, data type: int.

Интервал в миллисекундах отправки статистики просмотра. Если не задано, используется значение по умолчанию 300000 (5 minutes).

Example:

var CLIENT_SETTINGS = {
///...
'push_stat_interval': 300,000
};

Video library

Grouping of films by category or genre

Option name: filter_videos_by_genres, data type: bool.

Possible values:

  • true movies will be grouped by genre (by default).
  • falsely Films will be grouped into categories (genres in Smarty with the option “Is a Category” enabled).

Example:

var CLIENT_SETTINGS = {
///...
'filter_videos_by_genres': true
};

Display of the category "Premier" in the video library

Option name: show_vod_premieres, data type: bool.

Possible values:

  • true — в списке категорий видеотеки будет отображаться категория «Премьеры» (фильмы, дата премьеры которых не ранее количества дней, заданного константой TVMIDDLEWARE_VIDEO_PREMIERE_DAYS в настройках Smarty, или, если указан TVMIDDLEWARE_VIDEO_PREMIERE_YEARS в настройках Smarty, то в выборку попадут только те фильмы, год выпуска которых не ранее TVMIDDLEWARE_VIDEO_PREMIERE_YEARS от текущего.).
  • falsely The “Premier” category will be hidden (by default).

Example:

var CLIENT_SETTINGS = {
///...
'show_vod_premieres': false
};

Display in the video library of films, the source of which is archival records

Option name: show_archive_in_vod_screen, data type: bool.

Чтобы заполнить видеотеку архивными записями, необходимо воспользоваться инструкцией по настройке видеотеки из архивных записей. To work correctly, you will need posters 2:3 for archival films.

Possible values:

  • true when a video list is requested, films from archival records will be transmitted.
  • falsely when you request a video list, you will not transfer movies from archive records (by default).

Example:

var CLIENT_SETTINGS = {
  // …
  'show_archive_in_vod_screen': false
};

How to sort movies by default

Option name: default_vod_sort_order, data type: string.

Possible values:

  • name - by name, in alphabetical order (by default).
  • -name by name, in reverse alphabetical order.
  • id - by date of addition to the catalog, first the oldest.
  • -id - by date of addition to the catalog, first the newest.
  • created update, first the oldest.
  • - created_at upgrade date, first the newest.
  • -updated_at — по дате добавления фильма/эпизода, сначала самые новые;
  • updated — по дате добавления фильма/эпизода, сначала самые старые;
  • premiere_date at the premiere date, first the oldest.
  • -premiere_date at the premiere date, first the newest.
  • year by the date of the film, first the oldest.
  • -year by the date of the film, first the newest.
  • average_customers_rating - according to the rating of subscribers, first the most unpopular.
  • -average_customers_rating - according to the rating of subscribers, first the most popular.
  • kinopoisk_rating According to the rating of the film, first the most unpopular.
  • -kinopoisk_rating - according to the rating of the film, first the most popular.
  • imdb_rating According to the IMDB rating, the most unpopular at first.
  • -imdb_rating According to the IMDB rating, first the most popular.
  • number_of_ratings - the number of estimates, at first less evaluated.
  • -number_of_ratings by the number of estimates, first the most evaluated.

Example:

var CLIENT_SETTINGS = {
///...
'default_vod_sort_order': "-created_at"
};

Disabling the display of empty genres

Option name: vod_without_empty_genres, data type: bool.

Possible values:

  • true — в экранах «Видеотека» не будут отображаться жанры, которым не соответствует ни один фильм. Исключение составляют категории «Избранное», «Новинки» и «Просмотренное» — они будут отображаться, если включены соответствующие опции и даже если они пусты.
  • falsely — будут отображаться все жанры, созданные в административной панели Smarty (по умолчанию).

Example:

var CLIENT_SETTINGS = {
  // …
  'vod_without_empty_genres': true
};

Sorting the list of actors on the film page

Option name: actors, data type: string.

Possible values:

  • birthdate sorting by date of birth, from older to younger.
  • birthdate sorting by date of birth, from younger to older.
  • name sorting by name, in alphabetical order (by default).
  • -name sorting by name, in reverse alphabetical order.
  • cyrillic-first sorting by name, first come actors with cyrillic.
  • film — сортировка актеров по количеству фильмов с их участием, в порядке возрастания.
  • -film_count sorting actors by the number of films with their participation in descending order.

Example:

var CLIENT_SETTINGS = {
  // …
  'actors_order': 'name'
};

Sorting the list of films on the actor's description screen

Option name: actor_vod_sort_order, data type: string.

Possible values:

  • name - by name, in alphabetical order (by default).
  • -name by name, in reverse alphabetical order.
  • id - by date of addition to the catalog, first the oldest.
  • -id - by date of addition to the catalog, first the newest.
  • created update, first the oldest.
  • - created_at upgrade date, first the newest.
  • -updated_at — по дате добавления фильма/эпизода, сначала самые новые;
  • updated — по дате добавления фильма/эпизода, сначала самые старые;
  • premiere_date at the premiere date, first the oldest.
  • -premiere_date at the premiere date, first the newest.
  • year by the date of the film, first the oldest.
  • -year by the date of the film, first the newest.
  • average_customers_rating - according to the rating of subscribers, first the most unpopular.
  • -average_customers_rating - according to the rating of subscribers, first the most popular.
  • kinopoisk_rating According to the rating of the film, first the most unpopular.
  • -kinopoisk_rating - according to the rating of the film, first the most popular.
  • imdb_rating According to the IMDB rating, the most unpopular at first.
  • -imdb_rating According to the IMDB rating, first the most popular.
  • number_of_ratings - the number of estimates, at first less evaluated.
  • -number_of_ratings by the number of estimates, first the most evaluated.

Example:

var CLIENT_SETTINGS = {
///...
'actor_vod_sort_order': '-kinopoisk_rating'
};

Limiting the number of actors on the film page

Option name: actors_request_limit, data type: int. By default 16.

Example:

var CLIENT_SETTINGS = {
  // …
  'actors_request_limit': 16
};

Mechanics of generation of the film "Similar films"

Option name: similar_video_genre_limit, data type: int. By default 3.

В данной опции указывается количество жанров, которые нужно использовать для поиска похожих фильмов — например, по умолчанию фильмы считаются похожими, если у них совпадает 3 жанра.

Example:

var CLIENT_SETTINGS = {
  // …
  'similar_video_genre_limit': 3
};

Отображение дисклеймера о вреде наркотических средств

Option name: show_drugs_disclaimer, data type: bool.

Possible values:

  • true — будет показываться дисклеймер в карточке контента, если возрастной рейтинг фильма не ниже порога (в шаблоне titanium порог задан константой 12).
  • falsely — дисклеймер в карточке контента показываться не будет (по умолчанию).

Example:

var CLIENT_SETTINGS = {
  // …
  'show_drugs_disclaimer': true
};

Showing a QR code with a support number when buying a movie

Option name: use_video_purchase_via_sale_qr, data type: bool.

Possible values:

  • true When you click the “Buy” button on the film page, a pop window with a QR code will be shown, in which the technical support / sales department phone number will be sewn. The option is relevant if there is no integration with external billing for the purchase of films - in this case, the specialist includes access to the film manually on call.
  • falsely The purchase of the film works on the internal mechanism of Smarty (by default).

Example:

var CLIENT_SETTINGS = {
  // …
  'use_video_purchase_via_sale_qr': false
};

При этом на покупку фильмов ещё оказывает влияние опция show_locked_tariff_popup, ниже таблица соответствий взаимодействия данных опций между собой:

show_locked_tariff_popupuse_video_purchase_via_sale_qrРезультат
truetrueБудет показан попап с тарифами
truefalselyБудет показан попап с тарифами
falselyfalselyКнопка «Купить» вызовет внутренний механизм покупки фильма в Smarty (VideoAction)
falselytrueБудет показан попап с QR-кодом

Search

In the search screen before entering the search bar, the on-screen keyboard is displayed, and optionally you can display the recommended selection for the subscriber using the option
search_recommended_election_id, which indicates the ID of the selection of films from Smarty.

Example:

var CLIENT_SETTINGS = {
// ..
'search_recommended_election_id': 123,
};

Automatically sending a search query starts with 3 characters, searching through channels, programs, movies and actors.

Delay in search

Option name: search_request_delay, data type: int. Set in milliseconds, the default value is: 3000.

Allows you to set the delay time before starting search queries (after entering 3 characters in the on-screen keyboard). It is designed to reduce the number of search queries to Smarty.

Example:

var CLIENT_SETTINGS = {
///...
'search_request_delay': 3000
};

Personal office

Tariffs

Item "Tariffs" is included by the portal option show_packagesfor example:

var CLIENT_SETTINGS = {
///...
-show_packages': true,
};

The tariff card is customized by the following means on the tariff page in the Smarty admin:

  • icon for STB and Smart TV is used as a label
  • field bg_first_color and bg_second_color used to set colors for the gradient against the background, for example:
  • the card also uses the fields “Name”, “Description”, “Cost” and “Cost of activation”.
List of tariffs in the personal account
List of tariffs when clicking on the channel with a lock (to which there is no subscription)

Notifications

Item "Tariffs" is included by the portal option show_messages_menufor example:

var CLIENT_SETTINGS = {
///...
-show_messages_menu': true,
};

This screen receives messages sent to the subscriber using the Messages and Commands tool in the Smarty admin (you can also automate sending messages via the Smarty admin) Billing API Methods). Messages with the Urgent flag are also shown in this section, with the difference that they will be shown in the pop-up window on top of the interface.

Устройства

Option name: show_device_list_management, data type: bool.

Possible values:

  • true — в экране «Мой профиль» будет отображаться пункт «Мои устройства», где можно просмотреть список привязанных к аккаунту устройств и отвязать ненужное.
  • falsely “My devices” will be hidden (by default).

Список устройств также может отображаться при неудачной авторизации по причине превышения количества привязанных устройств.

Example:

var CLIENT_SETTINGS = {
  // …
  'show_device_list_management': true
};

Exit from the account

The item “Exit from the account” can be shown using the option show_logout_optionfor example:

var CLIENT_SETTINGS = {
// ..
'show_logout_option': true,
};

By default, the item is hidden - this behavior is relevant for the authorization mode by the IP address / device identifier - in this case, the subscriber cannot log off on the current device.

Settings

Selection of the interface used on the Settings page

Option name: show_change_template_settings, data type: bool.

Possible values:

  • true – on the “Settings” page in the application, the “Selection of a template” item will be displayed. The list of templates for selection will be formed from the array prescribed in the option available_templates.
  • falsely - the item "Select the template" on the settings page will be hidden (by default).

Example:

var CLIENT_SETTINGS = {
  // …
  'show_change_template_settings': true,
  'available_templates': ['titanium', 'sibseti']
};

Список доступных шаблонов для выбора

Option name: available_templates, data type: array.

Массив системных имён шаблонов, доступных для выбора в настройках (используется вместе с show_change_template_settings).

Example:

var CLIENT_SETTINGS = {
  // …
  'available_templates': ['titanium', 'sibseti']
};

Ability to change the interface language

Option name: show_change_lang_settings, data type: bool.

Possible values:

  • true – on the “Settings” page in the application, the “Language/Language” option will be displayed (by default).
  • falsely The “Language” item on the settings screen will be hidden.

Example:

var CLIENT_SETTINGS = {
///...
'show_change_lang_settings': true
};

Managing the display item "Player Selection" in the "Settings" screen

Option name: show_change_player_settings, data type: bool.

Possible values:

  • true — на странице «Настройки» внутри приложения будет отображен пункт «Выбор плеера» для тех устройств, которые это поддерживают (на текущий момент это Android-устройства в рамках сборки версии выше 2.0).
  • falsely - the item "Select player" on the settings page will be hidden (by default).

Example:

var CLIENT_SETTINGS = {
///...
'show_change_player_settings': true
};

Managing the display of the item “Player Options” in the screen “Settings”

Option name: show_player_options, data type: bool.

Note: опция show_change_player_settings higher priority show_player_options. То есть, если show_change_player_settings meaningfully falselythen show_player_options также устанавливается в значении falsely.

Possible values:

  • true — на странице «Настройки» внутри приложения будет отображен пункт «Опции плеера» для тех устройств, которые это поддерживают (на текущий момент это Android-устройства в рамках сборки версии выше 2.0). Список опций зависит от выбранного плеера.
  • falsely - the item "Player Options" on the settings page will be hidden (by default).

Example:

var CLIENT_SETTINGS = {
  // …
  'show_player_options': true
};

The ability to select a data center in the settings menu

Option name: allow_to_change_data_center, data type: bool.

Possible values:

  • true In the settings menu, the user can independently choose the broadcast server (corresponds to the configured data centers in Smarty).
  • falsely the user will not be able to select the broadcast server (by default).

Example:

var CLIENT_SETTINGS = {
///...
'allow_to_change_data_center': false
};

Logic of work

Delayed application loading at start

Option name: loading_timeout, data type: int. Set in milliseconds, the default value is: 1000.

The option allows you to set the number of milliseconds by which the initial download of the portal will be delayed. It can be used, for example, to customize the portal to display a welcome picture before launching.

By default 1000, which corresponds to one second. If you specify a zero or too small value, then some application functions on some devices may be disrupted due to asynchronous implementation of the API of some devices. For example, a small delay is necessary to be able to determine the device not only by type, but also by model (if Smarty configures the appropriate types of devices with a model) for Android consoles.

Example:

var CLIENT_SETTINGS = {
///...
'loading_timeout': 1000
};

Verification of additional account status

Option name: check_account_status_reason, data type: bool.

Possible values:

  • true Additional account status will be checked even in case of successful authorization (by default). For example, if the account is active, but the additional status is “Blocked for debt”, then the corresponding authorization error will be issued in the portal.
  • falsely additional status will not be checked.

Example:

var CLIENT_SETTINGS = {
  // …
  'check_account_status_reason': true
};

Selection of the application interface used through account settings in Smarty

Option name: check_account_template, data type: bool.

Possible values:

  • true After logging in, the template installed in the Smarty account settings will be checked, and if it differs from the one used, the application will be restarted in the desired template (by default).
  • falsely The set template in the account settings in Smarty will be ignored.

Example:

var CLIENT_SETTINGS = {
///...
'check_account_template': true
};

Suspension of server requests in Stand-By mode

Option name: block_request_in_standby, data type: bool.

Possible values:

  • true This includes blocking requests to the server if the device is in Stand-By mode. After leaving Stand-By, sending requests to the server is restored, however, the data in the interface may be outdated for some time.
  • falsely Requests do not stop even in Stand-By, the data displayed in the interface does not become outdated (by default).

The option allows you to save server resources in moments of downtime of user devices.

Example:

var CLIENT_SETTINGS = {
///...
'block_requests_in_standby': false
};

Периодический HealthCheck

Option name: enable_health_check, data type: bool.

В шаблоне titanium при значении true после успешного входа планируется периодический вызов requestHealthCheck с интервалом, заданным опцией health check_interval (к интервалу добавляется случайная составляющая до 60000 мс).

Possible values:

  • true — периодический HealthCheck включён.
  • falsely — периодический HealthCheck не планируется (по умолчанию).

Example:

var CLIENT_SETTINGS = {
  // …
  'enable_health_check': false,
  'health_check_interval': 300000
};

Интервал HealthCheck

Option name: health check_interval, data type: int.

Интервал в миллисекундах между периодическими запросами HealthCheck. Используется вместе с enable_health_check. В коде к значению интервала добавляется случайная добавка до 60000мс.

Example:

var CLIENT_SETTINGS = {
///...
'health_check_interval': 300,000
};

Update to build the application on Android STB/TV

Option name: app_package_updating_url, data type: string.

При указании url-адреса на скачивание apk в данной опции приложение совершит попытку её скачивания и самообновления на неё. При обновлении происходит проверка текущей версии приложения — механизм скачивания и установки запускается только если версия, указанная в url, больше текущей версии установленной apk (в примере ниже версия — это подстрока 1.0.0).

The option is only available for Android STB/TV builds over 2.3.

Example:

var CLIENT_SETTINGS = {
  // …
  'app_package_updating_url': "http://your-website.com/example-app-1.0.0_100100.apk"
};

Update build launcher on Android STB/TV

Option name: launcher_package_updating_url, data type: string.

При указании url-адреса на скачивание apk в данной опции приложение совершит попытку её скачивания и самообновления на неё. При обновлении происходит проверка текущей версии приложения-лаунчера — механизм скачивания и установки запускается только если версия, указанная в url, больше текущей версии установленного лаунчера (в примере ниже версия — это подстрока 1.0.0).

The option is only available for launcher builds for Android STB/TV versions over 2.3.

Example:

var CLIENT_SETTINGS = {
  // …
  'launcher_package_updating_url': "http://your-website.com/example-launcher-1.0.0_100100.apk"
};

Enabling the system debugging console on a device with a specific User-Agent

Option name: enable_system_debug_for_user_agent, data type: string.

Если User-Agent устройства совпадает с указанным значением опции, включается системная отладка на устройстве.

Example:

var CLIENT_SETTINGS = {
///...
"enable_system_debug_for_user_agent": "Mozilla/5.0 (Web0S; Linux/SmartTV) AppleWebKit/537.36"
};

Adding Market Name to Device Type

Option name: use_store_flag_from_device_meta, data type: bool.

К типу девайса добавляется название маркета через нижнее подчеркивание (например, android_stb_googleplay). Название маркета берется из сборки, то есть оно должно быть в неё зашито. Данная опция доступна только для Android-маркетов и для её работы потребуется отдельная сборка для каждого из них. Перечень доступных маркетов: googleplaysberboxyandextvrustore.

Possible values:

  • true the market specified in the device metadata will be transmitted.
  • falsely - will be transmitted by default (by default).

Example:

var CLIENT_SETTINGS = {
  // …
  'use_store_flag_from_device_meta': true
};

Disabling the SET button on MAG consoles

Option name: disable_set_button_on_mag, data type: bool.

Possible values:

  • true The SET (Setup) button on the MAG console will be blocked.
  • falsely the button will work according to the settings in the firmware (by default).

Example:

var CLIENT_SETTINGS = {
///...
'disable_set_button_on_mag': false
};

Additional CSS class for body interface

Option name: custom, data type: string.

Позволяет подключить дополнительный класс к тегу body портала. Может быть использовано для кастомизации интерфейса через дополнительный CSS-файл.

No default.

Example:

var CLIENT_SETTINGS = {
///...
'custom_body_class': 'custom'
};