I have starting trying to implement users on a website I am working on. Perhaps this is not a good method as I am new to django; what I have so far is a simple template check to provide different links to different people:
{% extends 'base.htm' %}
{% block content %}
{% if user.username == 'user1' %}
<p>User 1 Downloads</p>
{% elif user.username == 'user2' %}
<p>User 2 Downloads</p>
{% else %}
<p>There are no Downloads for this User</p>
{% endif %}
{% endblock %}
This is a new site for my company and I expect to have maybe 20 users at most and while I could if/case through them there is probably a better way to do this. In addition I would like to be able to have for example: user1 to user5 have access to download 1, user6 to user10 have access to download 2, etcetera. Is this something already accounted for in django that I can implement or do I need to make my own users table with an "access" column with an id to be used for what they can see, rather than using the username?