Merge pull request #4223 from expsa/younes_dev_odex25_ensan

IMP benefit
This commit is contained in:
kchyounes19 2025-08-18 09:49:18 +01:00 committed by GitHub
commit bb4d699745
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -619,7 +619,7 @@ class GrantBenefitProfile(models.Model):
for rec in self:
if not rec.owner_identity_attachment_ids and rec.is_family_member == False and rec.state == 'first_approve':
raise ValidationError(_("Account Holder Identity Attachment is required."))
if not rec.family_approval_attachment_ids and rec.is_family_member == False and rec.state != 'draft':
if not rec.family_approval_attachment_ids and rec.is_family_member == False and rec.state == 'first_approve':
raise ValidationError(_("Family approval of transfer Attachment is required."))
def _validate_required_attachments(self):