forked from rDrama/rDrama
1
0
Fork 0

show vote time

master
Aevann1 2022-06-27 06:10:10 +02:00
parent 3aa6a838cb
commit ab5078f313
2 changed files with 15 additions and 3 deletions

View File

@ -45,6 +45,10 @@ class Vote(Base):
return data
@property
def created_datetime(self):
return str(time.strftime("%d/%B/%Y %H:%M:%S UTC", time.gmtime(self.created_utc)))
class CommentVote(Base):
@ -84,4 +88,8 @@ class CommentVote(Base):
data["user"]=self.user.json_core
data["comment"]=self.comment.json_core
return data
return data
@property
def created_datetime(self):
return str(time.strftime("%d/%B/%Y %H:%M:%S UTC", time.gmtime(self.created_utc)))

View File

@ -28,7 +28,8 @@
<thead class="bg-primary text-white">
<tr>
<th>User</th>
<th role="button" onclick="sort_table(1)">User truescore</th>
<th role="button" onclick="sort_table(1)">User Truescore</th>
<th role="button" onclick="sort_table(2)">Vote Time</th>
</tr>
</thead>
@ -43,6 +44,7 @@
</a>
</td>
<td>{{vote.user.truecoins}}</td>
<td>{{vote.created_datetime}}</td>
</tr>
{% endfor %}
</table>
@ -54,7 +56,8 @@
<thead class="bg-primary text-white">
<tr>
<th>User</th>
<th role="button" onclick="sort_table(1)">User truescore</th>
<th role="button" onclick="sort_table(1)">User Truescore</th>
<th role="button" onclick="sort_table(2)">Vote Time</th>
</tr>
</thead>
@ -69,6 +72,7 @@
</a>
</td>
<td>{{vote.user.truecoins}}</td>
<td>{{vote.created_datetime}}</td>
</tr>
{% endfor %}
</table>