|
|
@ -1,7 +1,7 @@ |
|
|
|
<urban-filemanager> |
|
|
|
<div class="bucket-filemanager"> |
|
|
|
<div class="file-table"> |
|
|
|
<urban-filemanager-parent></urban-filemanager-parent> |
|
|
|
<urban-filemanager-parent handleClick={ handleParentClick } if={ state.path.length > 0 }></urban-filemanager-parent> |
|
|
|
<template each={ file in state.files }> |
|
|
|
<urban-filemanager-file |
|
|
|
if={ file.is_file } |
|
|
@ -52,12 +52,29 @@ |
|
|
|
/** |
|
|
|
* |
|
|
|
* |
|
|
|
* @param {object} event |
|
|
|
* |
|
|
|
*/ |
|
|
|
handleDirectoryClick(event, file) { |
|
|
|
handleParentClick(event) { |
|
|
|
this.state.path.pop() |
|
|
|
this.files() |
|
|
|
}, |
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* |
|
|
|
* |
|
|
|
*/ |
|
|
|
handleDirectoryClick(event, file) { |
|
|
|
this.state.path.push(file) |
|
|
|
this.files() |
|
|
|
}, |
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* |
|
|
|
*/ |
|
|
|
files() { |
|
|
|
axios.get('/api/file/' + this.props.id, { |
|
|
|
params: { |
|
|
|
path: this.state.path.join('/') |
|
|
@ -68,9 +85,13 @@ |
|
|
|
}) |
|
|
|
}, |
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
|
* |
|
|
|
*/ |
|
|
|
handleMarked() { |
|
|
|
console.log('ddd') |
|
|
|
} |
|
|
|
console.log('marked') |
|
|
|
}, |
|
|
|
} |
|
|
|
|
|
|
|
</script> |