• Type: New Feature
    • Status: Done/Fixed
    • Priority: Major
    • Resolution: Fixed/Completed
    • Affects Version/s: None
    • Fix Version/s: 1.5
    • Component/s: None
    • Labels:


      Implement a new type of custom field called "File". This will be used when folks want to attach

      Rather than storing the "data values" for this special custom field type in civicrm_custom_value, we've create a new table/class in Core - just for these data "values" - civicrm_file. (The schema has been created and checked in as of today.)

      Eventually, the site admin will be able to configure whether these "files" are uploaded/stored in the file system, or uploaded and stored within the DB. For now- we'll just implement the file system storage - which means we will store a "uri" pointer to the file as a string (in civicrm_file.uri).

      In edit mode, we'll present the custom field label and an HTML file input element (e.g. browse button, etc.). During the upload we need to identify the mimetype of the file and store info that in civicrm_file.mime_type.

      Please review the existing code for CiviContribute Product image/thumbnail handling and upload and generalize it so it can be shared with this new functionality.

      When displaying a contact (or other entity) with a file-type custom field, we'll simply provide a link with the file name as the link text. Clicking on the link should load the file in a new (pop-up) window with the mime-type passed. So, if the file is a PDF for example, it will show up properly in the browser with the acrobat helper...




            • Assignee:
              anil Anil Kokitkar
              dgg David Greenberg
            • Votes:
              0 Vote for this issue
              0 Start watching this issue


              • Created: