Skip to content

Commit

Permalink
Resolved Major bug and also added username field in auth data (Fusion…
Browse files Browse the repository at this point in the history
…IIIT#1635)

* Made updated views for authentication, toggling notifications and removed dashboard view

* Made a view for updating a role

* migration files for changes made in extra_info model

* Health Center Contribution - PR201 (FusionIIIT#1625)

* All changes of health center module

* Redundancy bug fixes

* Minor bug fix
Patie0tn log form undefined behavior when changing radio field

* Guideline Configs

* Removed print statements according to guidelines

---------

Co-authored-by: ChallaBharadwajReddy <[email protected]>

* fix: Resolved System Check errors (FusionIIIT#1630)

- fix: Changed one line bugs
* Resolved system check errors
* Changed some fields in IWD Module
* Fixes creation of unwanted migration files

- chore: migration files for the previous commit changes

* fix: Resolved major bug and also added username field in auth data.

---------

Co-authored-by: ramGopal <[email protected]>
Co-authored-by: ChallaBharadwajReddy <[email protected]>
  • Loading branch information
3 people authored and dvjsharma committed Nov 22, 2024
1 parent 9922224 commit fa3cdd5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion FusionIIIT/applications/globals/api/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ def logout(request):
def auth_view(request):
user=request.user
name = request.user.first_name +"_"+ request.user.last_name
roll_no = request.user.username

extra_info = get_object_or_404(ExtraInfo, user=user)
last_selected_role = extra_info.last_selected_role
Expand All @@ -86,10 +87,11 @@ def auth_view(request):
name_ = get_object_or_404(Designation, id = id)
designation_info.append(str(name_.name))

print(designation_info)
accessible_modules = {}

for designation in designation_info:
module_access = ModuleAccess.objects.filter(designation=designation).first()
module_access = ModuleAccess.objects.filter(designation__iexact=designation).first()
if module_access:
filtered_modules = {}

Expand All @@ -103,6 +105,7 @@ def auth_view(request):
resp={
'designation_info' : designation_info,
'name': name,
'roll_no': roll_no,
'accessible_modules': accessible_modules,
'last_selected_role': last_selected_role
}
Expand Down

0 comments on commit fa3cdd5

Please sign in to comment.