simo 2.8.6__py3-none-any.whl → 2.8.7__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.
Potentially problematic release.
This version of simo might be problematic. Click here for more details.
- simo/core/controllers.py +15 -5
- simo/core/models.py +1 -13
- {simo-2.8.6.dist-info → simo-2.8.7.dist-info}/METADATA +1 -1
- {simo-2.8.6.dist-info → simo-2.8.7.dist-info}/RECORD +8 -8
- {simo-2.8.6.dist-info → simo-2.8.7.dist-info}/LICENSE.md +0 -0
- {simo-2.8.6.dist-info → simo-2.8.7.dist-info}/WHEEL +0 -0
- {simo-2.8.6.dist-info → simo-2.8.7.dist-info}/entry_points.txt +0 -0
- {simo-2.8.6.dist-info → simo-2.8.7.dist-info}/top_level.txt +0 -0
simo/core/controllers.py
CHANGED
|
@@ -289,12 +289,23 @@ class ControllerBase(ABC):
|
|
|
289
289
|
actor = self._get_actor(value)
|
|
290
290
|
if not actor:
|
|
291
291
|
actor = get_current_user()
|
|
292
|
-
if actor:
|
|
293
|
-
introduce_user(actor)
|
|
294
292
|
|
|
295
293
|
self.component.refresh_from_db()
|
|
296
294
|
if value != self.component.value:
|
|
297
295
|
self.component.value_previous = self.component.value
|
|
296
|
+
from .models import ComponentHistory
|
|
297
|
+
ComponentHistory.objects.create(
|
|
298
|
+
component=self.component, type='value', value=value,
|
|
299
|
+
user=actor
|
|
300
|
+
)
|
|
301
|
+
from actstream import action
|
|
302
|
+
action.send(
|
|
303
|
+
actor, target=self, verb="value change",
|
|
304
|
+
instance_id=self.component.zone.instance.id,
|
|
305
|
+
action_type='comp_value', value=value
|
|
306
|
+
)
|
|
307
|
+
actor.last_action = timezone.now()
|
|
308
|
+
actor.save()
|
|
298
309
|
self.component.value = value
|
|
299
310
|
|
|
300
311
|
self.component.change_init_by = None
|
|
@@ -303,6 +314,8 @@ class ControllerBase(ABC):
|
|
|
303
314
|
self.component.change_init_fingerprint = None
|
|
304
315
|
self.component.save()
|
|
305
316
|
|
|
317
|
+
|
|
318
|
+
|
|
306
319
|
def _receive_from_device(
|
|
307
320
|
self, value, is_alive=True, battery_level=None, error_msg=None
|
|
308
321
|
):
|
|
@@ -314,9 +327,6 @@ class ControllerBase(ABC):
|
|
|
314
327
|
init_by_device = True
|
|
315
328
|
actor = get_device_user()
|
|
316
329
|
|
|
317
|
-
# Introducing user to this thread for changes that might happen to other components
|
|
318
|
-
# in relation to the change of this component
|
|
319
|
-
introduce_user(actor)
|
|
320
330
|
self.component.alive = is_alive
|
|
321
331
|
if error_msg != None:
|
|
322
332
|
self.component.error_msg = error_msg if error_msg.strip() else None
|
simo/core/models.py
CHANGED
|
@@ -510,18 +510,7 @@ def is_in_alarm(self):
|
|
|
510
510
|
|
|
511
511
|
if self.pk:
|
|
512
512
|
actor = get_current_user()
|
|
513
|
-
|
|
514
|
-
if 'value' in dirty_fields:
|
|
515
|
-
ComponentHistory.objects.create(
|
|
516
|
-
component=self, type='value', value=self.value,
|
|
517
|
-
user=actor
|
|
518
|
-
)
|
|
519
|
-
action.send(
|
|
520
|
-
actor, target=self, verb="value change",
|
|
521
|
-
instance_id=self.zone.instance.id,
|
|
522
|
-
action_type='comp_value', value=self.value
|
|
523
|
-
)
|
|
524
|
-
action_performed = True
|
|
513
|
+
|
|
525
514
|
if 'arm_status' in dirty_fields:
|
|
526
515
|
ComponentHistory.objects.create(
|
|
527
516
|
component=self, type='security',
|
|
@@ -533,7 +522,6 @@ def is_in_alarm(self):
|
|
|
533
522
|
action_type='security', value=self.value
|
|
534
523
|
)
|
|
535
524
|
action_performed = True
|
|
536
|
-
if action_performed:
|
|
537
525
|
actor.last_action = timezone.now()
|
|
538
526
|
actor.save()
|
|
539
527
|
|
|
@@ -98,7 +98,7 @@ simo/core/auto_urls.py,sha256=FqKhH0fF7cGO6P2YrjblwG4JA2UkVXj3lreJUOB2Jq4,1194
|
|
|
98
98
|
simo/core/autocomplete_views.py,sha256=x3MKOZvXYS3xVQ-V1S7Liv_U5bxr-uc0gePa85wv5nA,4561
|
|
99
99
|
simo/core/base_types.py,sha256=WypW8hTfzveuTQtruGjLYAGQZIuczxTlW-SdRk3iQug,666
|
|
100
100
|
simo/core/context.py,sha256=LKw1I4iIRnlnzoTCuSLLqDX7crHdBnMo3hjqYvVmzFc,1557
|
|
101
|
-
simo/core/controllers.py,sha256=
|
|
101
|
+
simo/core/controllers.py,sha256=Dsg3047IW_jxAS3AWnwTK7blLPAnr_w16R7HAI1d3gk,37709
|
|
102
102
|
simo/core/dynamic_settings.py,sha256=bUs58XEZOCIEhg1TigR3LmYggli13KMryBZ9pC7ugAQ,1872
|
|
103
103
|
simo/core/events.py,sha256=1_KIk5pJqdLPRQlCQ9xSyALst2Cn0b2lAEAJ3QjwIjE,4801
|
|
104
104
|
simo/core/filters.py,sha256=6wbn8C2WvKTTjtfMwwLBp2Fib1V0-DMpS4iqJd6jJQo,2540
|
|
@@ -108,7 +108,7 @@ simo/core/gateways.py,sha256=Y2BME6zSyeUq_e-hzEUF6gErCUCP6nFxedkLZKiLVOo,4141
|
|
|
108
108
|
simo/core/loggers.py,sha256=EBdq23gTQScVfQVH-xeP90-wII2DQFDjoROAW6ggUP4,1645
|
|
109
109
|
simo/core/managers.py,sha256=Ampwe5K7gfE6IJULNCV35V8ysmMOdS_wz7mRzfaLZUw,3014
|
|
110
110
|
simo/core/middleware.py,sha256=zX6N4P_KR7gG8N2-NcR7jKtuCEhCGRh51g4EktAhP7w,3272
|
|
111
|
-
simo/core/models.py,sha256=
|
|
111
|
+
simo/core/models.py,sha256=brZPs8clR49VKm_Uo1wgPgCbjkS0fTLvzz3rROBeob4,23211
|
|
112
112
|
simo/core/permissions.py,sha256=Ef4NO7QwwDd3Z-v61R0BeCBXxTOJz9qBvzRTIB5tHwI,2943
|
|
113
113
|
simo/core/routing.py,sha256=X1_IHxyA-_Q7hw1udDoviVP4_FSBDl8GYETTC2zWTbY,499
|
|
114
114
|
simo/core/serializers.py,sha256=adqe8oYP5f7hGFXcxa-Zmce2KOwy3hZOaWE3MaAFtpM,23157
|
|
@@ -10933,9 +10933,9 @@ simo/users/templates/invitations/expired_msg.html,sha256=47DEQpj8HBSa-_TImW-5JCe
|
|
|
10933
10933
|
simo/users/templates/invitations/expired_suggestion.html,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10934
10934
|
simo/users/templates/invitations/taken_msg.html,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10935
10935
|
simo/users/templates/invitations/taken_suggestion.html,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10936
|
-
simo-2.8.
|
|
10937
|
-
simo-2.8.
|
|
10938
|
-
simo-2.8.
|
|
10939
|
-
simo-2.8.
|
|
10940
|
-
simo-2.8.
|
|
10941
|
-
simo-2.8.
|
|
10936
|
+
simo-2.8.7.dist-info/LICENSE.md,sha256=M7wm1EmMGDtwPRdg7kW4d00h1uAXjKOT3HFScYQMeiE,34916
|
|
10937
|
+
simo-2.8.7.dist-info/METADATA,sha256=dVPIZL5FPgcXAwX71CPy_Kz3UPkuye75HRntaWsnm04,2005
|
|
10938
|
+
simo-2.8.7.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
|
|
10939
|
+
simo-2.8.7.dist-info/entry_points.txt,sha256=S9PwnUYmTSW7681GKDCxUbL0leRJIaRk6fDQIKgbZBA,135
|
|
10940
|
+
simo-2.8.7.dist-info/top_level.txt,sha256=GmS1hrAbpVqn9OWZh6UX82eIOdRLgYA82RG9fe8v4Rs,5
|
|
10941
|
+
simo-2.8.7.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|