Any walkthrough / sample code for ASP.Net (MVC Model) reflecting the way to record the current user's id in a table, and later on accessing only reflecting the said data?
For example a simple model for a SQL table recording sales being made by more than 1 selling officer at the same time, with fields like:
- SalesDate
- SalesAmount
- SalesLocation
- SalesOfficer (Automatically recording the user's id or relevant data)
Thus, the fourth field in the sample model above recording the user's id in the background so as to retrieve the same relevant data, when either logged-in by the same user or the administrator next time.
Hopefully, the question is simple and clear enough.
Looking forward for your expert advice, guidance and references in this regard.
Thanks in advance.