Details
-
Type: Bug
-
Status: Open
-
Priority: Trivial
-
Resolution: Unresolved
-
Affects Version/s: 4.7.7
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
-
Versioning Impact:Patch (backwards-compatible bug fixes)
-
Documentation Required?:None
-
Funding Source:Contributed Code
Description
issue 1 - Multiple custom field File display
- Create a custom set with following options
– Used For - Contacts
– Does this Custom Field Set allow multiple records? - ticked
– Display Style - Tab
- Create a custom field for above set with following option
- Data and Input Field Type - File
- Attach more than one file to above custom field
- Check display after save
You will see all attached files having same name though attached different files and links will be missing to those files too.
Issue 2 - Edit multiple custom field
- Click edit for above custom field
It shows only one file information. It showed all files information in previous version of CiviCRM.
- Click add Another button
It brings another attached file information instead to attach new file screen. If we have 30 files attached for this custom field then we have to click 30 times this add button to attach new file
Fixes-
Issue 1 - multiple custom field file display
Added following code to Line 1928 in CRM / Core / BAO / CustomGroup.php
if (strtolower($properties['data_type']) == 'file' &&
!empty($values['data']) && !empty($values['fid']))
issue 2 - Edit multiple custom field
Replaced following tpl file with 4.6 version of civicrm
templates\CRM\common\customData.tpl
However replacing this breaks in other part of civi.
Example - add new contribution
Added condition to pick 4.6 version of above tpl when viewing multiple custom fields otherwise to pick 4.7 version of tpl