**Changes:**
1. Module Icon Fix
- Changed 'images' key to 'icon' in __manifest__.py
- Removed list brackets (icon value is string, not list)
- Now icon will display correctly in Apps menu
- Path: static/description/icon5.png
2. Sponsor Phone Field Visibility
- Added 'invisible' attrs to sponsor_phone field
- Field now ONLY visible for 'unknown' (فاعل خير) type
- Hidden for 'registered' and 'new_sponsor' types
- Reason: sponsor_id Many2one already displays phone number
- Prevents duplicate phone display in form
**Field Behavior After Fix:**
| Sponsor Type | sponsor_id Field | sponsor_phone Field |
|--------------|------------------|---------------------|
| مشترك بالنظام | ✅ Visible (shows name + phone) | ❌ Hidden |
| مشترك جديد | ✅ Visible (shows name + phone) | ❌ Hidden |
| فاعل خير | ❌ Hidden | ✅ Visible & Editable |
**Technical Details:**
XML attrs for sponsor_phone:
```xml
'invisible': ['|',
'&', ('record_type','=','donation'), ('sponsor_or_donor_type','!=','unknown'),
'&', ('record_type','=','sponsorship'), ('sponsor_donor_type','!=','unknown')
],
'readonly': [('state','!=','draft')]
```
Logic:
- Invisible if: (donation AND NOT unknown) OR (sponsorship AND NOT unknown)
- Visible only when: unknown (فاعل خير) type selected
- Editable only in draft state
**User Experience:**
- No more duplicate phone number display
- Cleaner form layout
- Phone field only appears when actually needed (unknown sponsor)
- Module icon now displays correctly
Odoo 14 Compatible. XML validated.
Synced with latest dev_odex25_ensan on Wed Nov 12 03:35:11 +03 2025