python-terminusgps 20.3.0__py3-none-any.whl → 20.4.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-terminusgps
3
- Version: 20.3.0
3
+ Version: 20.4.0
4
4
  Summary: Provides abstractions/utilities for working with Wialon API, Authorize.NET API, AWS API, and more.
5
5
  Project-URL: Documentation, https://app.terminusgps.com/docs/apps/python-terminusgps/index.html
6
6
  Project-URL: Repository, https://github.com/terminusgps/python-terminusgps
@@ -26,10 +26,10 @@ terminusgps/wialon/items/notification.py,sha256=6IrswN6fdEkJErIqtMq45bTl9xVARQw8
26
26
  terminusgps/wialon/items/resource.py,sha256=79SwbCyE1zlaoeBfU0erEqvqBAYUC4KAKs8AOLJqflU,9652
27
27
  terminusgps/wialon/items/retranslator.py,sha256=8q9EDc92w92MElnHIeEzH3Ra4kiPXrx4t9V5nPDZuRU,3728
28
28
  terminusgps/wialon/items/route.py,sha256=PTJx1gmT_PGz7nlSSUS2VzjYD-aAuvkEOIdIFneUSSQ,1148
29
- terminusgps/wialon/items/unit.py,sha256=m--ZQp5qZ3LggLM0BFndFZIIw5ZlikOxPtGLzuC7HX0,8115
29
+ terminusgps/wialon/items/unit.py,sha256=sXgEW3mbGgHCI9-lD69voy8yiKv39rKJei6ybYODKpM,8531
30
30
  terminusgps/wialon/items/unit_group.py,sha256=vGVJMBY1BrKK0tP-C1DCIz4Bh6P-HKRnKY1g8g95UIs,5031
31
31
  terminusgps/wialon/items/user.py,sha256=INwAibQVmjNNelepQXMfDevgJqMvIjHHgEjAMLRvhB0,7082
32
- python_terminusgps-20.3.0.dist-info/METADATA,sha256=rondTaGLahN7lf0Xuz339CfVKv0gp5_7BgertPu9AZQ,912
33
- python_terminusgps-20.3.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
34
- python_terminusgps-20.3.0.dist-info/licenses/COPYING,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
35
- python_terminusgps-20.3.0.dist-info/RECORD,,
32
+ python_terminusgps-20.4.0.dist-info/METADATA,sha256=H4fLla1mYyBTae65x2DTnTWjfKkekP0Arjs61rGBzPE,912
33
+ python_terminusgps-20.4.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
34
+ python_terminusgps-20.4.0.dist-info/licenses/COPYING,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
35
+ python_terminusgps-20.4.0.dist-info/RECORD,,
@@ -39,10 +39,21 @@ class WialonUnit(WialonBase):
39
39
  def populate(self) -> None:
40
40
  super().populate()
41
41
  response = self.session.wialon_api.core_search_item(
42
- **{"id": self.id, "flags": flags.DATAFLAG_UNIT_ADVANCED_PROPERTIES}
42
+ **{
43
+ "id": self.id,
44
+ "flags": sum(
45
+ [flags.DATAFLAG_UNIT_ADVANCED_PROPERTIES, flags.DATAFLAG_UNIT_IMAGE]
46
+ ),
47
+ }
43
48
  ).get("item", {})
44
49
  self._imei_number = response.get("uid")
45
50
  self._active = response.get("act", False)
51
+ self._image_uri = response.get("uri")
52
+
53
+ def get_position(self) -> dict:
54
+ return self.session.wialon_api.core_search_item(
55
+ **{"id": self.id, "flags": flags.DATAFLAG_UNIT_POSITION}
56
+ )
46
57
 
47
58
  @property
48
59
  def available_commands(self) -> dict:
@@ -50,6 +61,10 @@ class WialonUnit(WialonBase):
50
61
  **{"deviceTypeId": 0, "unitId": self.id}
51
62
  )
52
63
 
64
+ @property
65
+ def image_uri(self) -> str:
66
+ return self._image_uri
67
+
53
68
  @property
54
69
  def imei_number(self) -> int | None:
55
70
  if self._imei_number: