1👍
✅
users_model
doesn’t reference NewUserModel
, it references User
. You need to access the related model in your template like so:
{% for item in users_model %}
<tr>
<td><a href="{% url 'profile' item.id %}">{{ item.username }}</a></td>
<td>{{ item.newusermodel.posts }}</td>
<td></td>
<td></td>
</tr>
{% endfor %}
Source:stackexchange.com