def handle(self, *args, **options): #if not os.path.exists(CONFIGDB_PATH): # os.mkdir(CONFIGDB_PATH) for d in ConfigDBLoadingDir.objects.all(): self.stdout.write("Scanning directory: %s" % d.folder) scan_configdb_dir(d.folder, d.force_overwrite)
def scan_dir(self, request, queryset): for d in queryset.all(): scan_configdb_dir(d.folder, d.force_overwrite)