From 647b3ac11acb4e6ba01e6a42b626814efc56dcd0 Mon Sep 17 00:00:00 2001
From: Jared Hancock <jared@osticket.com>
Date: Fri, 22 Aug 2014 08:52:37 -0500
Subject: [PATCH] forms: Add print and export for the upload field

---
 include/class.forms.php | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/include/class.forms.php b/include/class.forms.php
index 69a69c3e9..1688e5fd7 100644
--- a/include/class.forms.php
+++ b/include/class.forms.php
@@ -1353,6 +1353,14 @@ class FileUploadField extends FormField {
         }
         return implode('<br/>', $links);
     }
+
+    function toString($value) {
+        $files = array();
+        foreach ($this->getFiles() as $f) {
+            $files[] = $f['name'];
+        }
+        return implode(', ', $files);
+    }
 }
 
 class Widget {
-- 
GitLab