Watch folders: Add support for subfolders

Add support for subfolder scanning to watch folders. Closes
GitLab issue #498.

This commit adds a new field to watch folders called
"include_subdirectories".

The directory walk was also updated to use pathlib2.

Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com>
This commit is contained in:
Roberto Rosario
2018-11-28 04:00:15 -04:00
parent d973a20c30
commit f9a0fb2e79
7 changed files with 124 additions and 47 deletions
+1 -1
View File
@@ -137,6 +137,6 @@ class WatchFolderSetupForm(forms.ModelForm):
class Meta:
fields = (
'label', 'enabled', 'interval', 'document_type', 'uncompress',
'folder_path'
'folder_path', 'include_subdirectories'
)
model = WatchFolderSource