1
0
mirror of https://github.com/Damillora/Altessimo synced 2024-11-23 22:27:32 +00:00

Add idol layout to frontend

This commit is contained in:
Damillora 2021-07-10 01:48:51 +07:00
parent 4c618458c3
commit caf7886567
3 changed files with 27 additions and 1 deletions

View File

@ -26,5 +26,8 @@ class Idol(models.Model):
objects = IdolManager()
class Meta:
ordering = [ 'romanized_name','name' ]
def __str__(self):
return self.romanized_name+" (CV: "+self.romanized_voice_actor_name+")"
return self.romanized_name+" "+"["+self.branch.acronym+"] "+" (CV: "+self.romanized_voice_actor_name+")"

View File

@ -27,6 +27,26 @@
</td>
</tr>
{% endif %}
{% if idol.voice_actor_name %}
<tr>
<th scope="row">
Voice Actor Name
</th>
<td>
{{ idol.voice_actor_name }}
</td>
</tr>
{% endif %}
{% if idol.romanized_voice_actor_name %}
<tr>
<th scope="row">
Romanized Voice Actor Name
</th>
<td>
{{ idol.romanized_voice_actor_name }}
</td>
</tr>
{% endif %}
</tbody>
</table>
{% endblock %}

View File

@ -30,6 +30,9 @@
<li class="nav-item">
<a class="nav-link" href="/songs">Songs</a>
</li>
<li class="nav-item">
<a class="nav-link" href="/idols">Idols</a>
</li>
<li class="nav-item">
<a class="nav-link" href="/artists">Artists</a>
</li>