Skip to content

Commit

Permalink
Fix/RR-1362 set fields readonly in the customer response section (#5357)
Browse files Browse the repository at this point in the history
* Set few lead officer fields to readonly

* Remove unnecessary codes
  • Loading branch information
ince-dbt authored Apr 11, 2024
1 parent 235d957 commit 081d971
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions datahub/export_win/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class BaseTabularInline(admin.TabularInline):

extra = 0
can_delete = False
exclude = ('is_deleted', 'id')
exclude = ('id',)


class BreakdownInlineForm(ModelForm):
Expand Down Expand Up @@ -77,7 +77,7 @@ class BaseStackedInline(admin.StackedInline):
inline_classes = ('grp-collapse grp-open',)
extra = 0
can_delete = False
exclude = ('is_deleted', 'created_by', 'modified_by')
exclude = ('created_by', 'modified_by')


class CustomerResponseInlineForm(ModelForm):
Expand All @@ -104,7 +104,11 @@ class CustomerResponseInline(BaseStackedInline):

model = CustomerResponse
form = CustomerResponseInlineForm
extra = 0
readonly_fields = (
'lead_officer_email_notification_id',
'lead_officer_email_delivery_status',
'lead_officer_email_sent_on',
)


class WinAdminForm(ModelForm):
Expand Down

0 comments on commit 081d971

Please sign in to comment.