| | |
| | | * @return |
| | | */ |
| | | private boolean matchesDirectoryView(BorgFilesystemItem item) { |
| | | if (mode != Mode.TREE) { |
| | | return true; |
| | | } |
| | | String path = item.getPath(); |
| | | if (StringUtils.isEmpty(currentDirectory)) { |
| | | // root dir |
| | |
| | | } |
| | | |
| | | private void processFinishedFlag() { |
| | | if (mode == Mode.TREE) { |
| | | return; |
| | | } |
| | | if (maxResultSize > 0 && ++counter >= maxResultSize) { |
| | | this.finished = true; |
| | | } |
| | |
| | | /> |
| | | |
| | | <FormSelect |
| | | value={filter.mode} |
| | | name={'mode'} |
| | | onChange={changeFilter} |
| | | > |
| | | <FormOption value={'flat'} /> |
| | | <FormOption value={'tree'} /> |
| | | </FormSelect> |
| | | <FormSelect |
| | | value={filter.maxSize} |
| | | name={'maxSize'} |
| | | onChange={changeFilter} |
| | |
| | | fileList: undefined, |
| | | filter: { |
| | | search: '', |
| | | mode: undefined, |
| | | currentDirectory: '', |
| | | maxSize: '50' |
| | | } |
| | | }; |
| | |
| | | archiveId: this.props.archiveId, |
| | | force: forceReload, |
| | | searchString: this.state.filter.search, |
| | | mode: this.state.filter.mode, |
| | | currentDirectory: this.state.filter.currentDirectory, |
| | | maxResultSize: this.state.filter.maxSize |
| | | }), { |
| | | method: 'GET', |