hass-core/homeassistant/components/fivem/const.py
Sander Jochems 0ea82bdbfb
Fivem integration (#65089)
* Initial fivem integration setup

* Use licenseKey for unique ID

* Create FiveMServer class

* Create FiveMStatusBinarySensor

* Fix platform loading

* Create sensor platform

* Remove config flow tests

* Update manifest.json

* Use attr_ instead or properties in sensors.py

* Use entry_id as unique_id

* Move device info to _attr instead of property

* Register callback in FiveMEntity

* Create config flow tests

* Add loggin to fivem

* Use FiveM in config_flow

* Use update_coordinator instead of dispatcher

* Bump fivem-api to 0.1.2

* Remove leftovers

* More tests for config flow

* Add component files to .coveragerc

* Fix simple comments

* Add gamename check to config flow

* Use entity descriptions for sensors

* Move extra attributes to init

* Use [] instead of get() for server info

* Fix error in gamename test
2022-02-08 11:27:11 +02:00

24 lines
547 B
Python

"""Constants for the FiveM integration."""
ATTR_PLAYERS_LIST = "players_list"
ATTR_RESOURCES_LIST = "resources_list"
DOMAIN = "fivem"
ICON_PLAYERS_MAX = "mdi:account-multiple"
ICON_PLAYERS_ONLINE = "mdi:account-multiple"
ICON_RESOURCES = "mdi:playlist-check"
ICON_STATUS = "mdi:lan"
MANUFACTURER = "Cfx.re"
NAME_PLAYERS_MAX = "Players Max"
NAME_PLAYERS_ONLINE = "Players Online"
NAME_RESOURCES = "Resources"
NAME_STATUS = "Status"
SCAN_INTERVAL = 60
UNIT_PLAYERS_MAX = "players"
UNIT_PLAYERS_ONLINE = "players"
UNIT_RESOURCES = "resources"