Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
def user_agent(self):
return self.data.user_agent
+ @property
+ def size(self):
+ return sum((self.data.rtp_audio_in_raw_bytes or 0, self.data.rtp_audio_out_raw_bytes or 0))
+
+ @property
+ def mos(self):
+ return self.data.rtp_audio_in_mos
+
class Talk(Object):
def init(self):
<div class="card-body">
<h4>{{ _("Your Recent Calls") }}</h4>
- {% module TalkCDR(current_user, limit=5) %}
+ {% module TalkCDR(current_user, limit=20) %}
</div>
</div>
{% end block %}
<br>
<span class="small text-muted">
- {{ " - ".join((e for e in (c.codec, c.user_agent) if e)) }}
+ {% if c.mos %}
+ {% for i in range(1, 6) %}
+ {% if c.mos > (i + 0.5) %}
+ <span class="fas fa-star"></span>
+ {% elif c.mos > i %}
+ <span class="fas fa-star-half-alt"></span>
+ {% else %}
+ <span class="far fa-star"></span>
+ {% end %}
+ {% end %}
+
+ {{ "%.2f" % c.mos }}/5
+ {% end %}
</span>
</td>