Index: /main/waeup.kofa/trunk/src/waeup/kofa/applicants/applicant.py
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/applicants/applicant.py	(revision 10088)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/applicants/applicant.py	(revision 10089)
@@ -278,7 +278,9 @@
         as parent name.
 
-        The `attr` parameter is not taken into account for
-        :class:`Applicant` context as the single passport image is the
-        only file we store for applicants.
+        In the beginning the `attr` parameter was not taken into account for
+        :class:`Applicant` context as the single passport image was the
+        only file we store for applicants. Meanwhile FUTMinna requires
+        uploads of other documents too. Now we store passport image
+        files without attribute but all other documents with.
 
         """
@@ -286,7 +288,13 @@
             getattr(self.context, '__parent__', None),
             '__name__', '_default')
-        marked_filename = '__%s__%s/%s.jpg' % (
-            APPLICANT_IMAGE_STORE_NAME,
-            parent_name, self.context.applicant_id)
+        if attr is None or attr == 'passport.jpg':
+            marked_filename = '__%s__%s/%s.jpg' % (
+                APPLICANT_IMAGE_STORE_NAME,
+                parent_name, self.context.applicant_id)
+        else:
+            basename, ext = os.path.splitext(attr)
+            marked_filename = '__%s__%s/%s_%s%s' % (
+                APPLICANT_IMAGE_STORE_NAME,
+                parent_name, self.context.applicant_id, basename, ext)
         return marked_filename
 
Index: /main/waeup.kofa/trunk/src/waeup/kofa/applicants/tests/test_applicant.py
===================================================================
--- /main/waeup.kofa/trunk/src/waeup/kofa/applicants/tests/test_applicant.py	(revision 10088)
+++ /main/waeup.kofa/trunk/src/waeup/kofa/applicants/tests/test_applicant.py	(revision 10089)
@@ -144,4 +144,17 @@
         return
 
+    def test_name_chooser_applicant_nonpassport_w_container(self):
+        fake_container = grok.Container()
+        fake_container.__name__ = 'folder'
+        fake_container.code = 'folder'
+        appl = Applicant()
+        appl.applicant_id = u'folder_123456'
+        appl.__parent__ = fake_container
+        chooser = IFileStoreNameChooser(appl)
+        result = chooser.chooseName(attr='any.pdf')
+        self.assertEqual(
+            result, '__img-applicant__folder/%s_any.pdf' % appl.applicant_id)
+        return
+
     def test_name_chooser_check_name(self):
         # we can check file ids for applicants
