|
@@ -17,10 +17,11 @@ class Rating():
|
|
self.text_fields['marker'].set_text('')
|
|
self.text_fields['marker'].set_text('')
|
|
return
|
|
return
|
|
current = None if None in (price, quantity or None) else float(price/quantity)
|
|
current = None if None in (price, quantity or None) else float(price/quantity)
|
|
-
|
|
|
|
|
|
+
|
|
chars = ['|', *['-']*(self.size - 2), '|' ]
|
|
chars = ['|', *['-']*(self.size - 2), '|' ]
|
|
rating = [' ']*len(chars)
|
|
rating = [' ']*len(chars)
|
|
_min, _max = min(_min, current or _min), max(_max, current or _max)
|
|
_min, _max = min(_min, current or _min), max(_max, current or _max)
|
|
|
|
+ _avg = max(_avg, 0.0001)
|
|
ls = np.linspace(_min, _max, len(chars))
|
|
ls = np.linspace(_min, _max, len(chars))
|
|
if current is not None and _avg is not None:
|
|
if current is not None and _avg is not None:
|
|
if current <= _avg:
|
|
if current <= _avg:
|