Now that bug is fixed.
This commit is contained in:
parent
cd98424fd3
commit
1167a1e8ac
@ -17,8 +17,12 @@ class DaqChannel:
|
|||||||
channel_metadata: str = ''
|
channel_metadata: str = ''
|
||||||
|
|
||||||
def __post_init__(self):
|
def __post_init__(self):
|
||||||
self._qty = SIQtys.default
|
if len(self.channel_metadata) > 0:
|
||||||
self._store('qty', self._qty)
|
meta = json.loads(self.channel_metadata)
|
||||||
|
for key,val in meta.items():
|
||||||
|
setattr(self, key, val)
|
||||||
|
else:
|
||||||
|
self._qty = SIQtys.default
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def qty(self):
|
def qty(self):
|
||||||
@ -27,7 +31,7 @@ class DaqChannel:
|
|||||||
@qty.setter
|
@qty.setter
|
||||||
def qty(self, newqty):
|
def qty(self, newqty):
|
||||||
self._qty = newqty
|
self._qty = newqty
|
||||||
self._store('qty', newqty)
|
self._store('_qty', newqty)
|
||||||
|
|
||||||
def _store(self, name, val):
|
def _store(self, name, val):
|
||||||
if len(self.channel_metadata) > 0:
|
if len(self.channel_metadata) > 0:
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
#!/usr/bin/env python3
|
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
import os, platform
|
import os, platform
|
||||||
import shelve
|
import shelve
|
||||||
|
Loading…
Reference in New Issue
Block a user