-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9172 from hashicorp/b-ui/logs-for-fails
UI: Always show the file browser for allocations and tasks.
- Loading branch information
Showing
5 changed files
with
55 additions
and
106 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,47 +1,38 @@ | ||
<section class="section is-closer {{if this.isFile "is-full-width"}}"> | ||
{{#if this.model.isRunning}} | ||
{{#if this.isFile}} | ||
<Fs::File @allocation={{this.allocation}} @taskState={{this.taskState}} @file={{this.path}} @stat={{this.stat}} @class="fs-explorer"> | ||
{{#if this.isFile}} | ||
<Fs::File @allocation={{this.allocation}} @taskState={{this.taskState}} @file={{this.path}} @stat={{this.stat}} @class="fs-explorer"> | ||
<Fs::Breadcrumbs @allocation={{this.allocation}} @taskState={{this.taskState}} @path={{this.path}} /> | ||
</Fs::File> | ||
{{else}} | ||
<div class="fs-explorer boxed-section"> | ||
<div class="boxed-section-head"> | ||
<Fs::Breadcrumbs @allocation={{this.allocation}} @taskState={{this.taskState}} @path={{this.path}} /> | ||
</Fs::File> | ||
{{else}} | ||
<div class="fs-explorer boxed-section"> | ||
<div class="boxed-section-head"> | ||
<Fs::Breadcrumbs @allocation={{this.allocation}} @taskState={{this.taskState}} @path={{this.path}} /> | ||
</div> | ||
{{#if this.directoryEntries}} | ||
<ListTable | ||
@source={{this.sortedDirectoryEntries}} | ||
@sortProperty={{this.sortProperty}} | ||
@sortDescending={{this.sortDescending}} | ||
@class="boxed-section-body is-full-bleed is-compact" as |t|> | ||
<t.head> | ||
<t.sort-by @prop="Name" @class="is-two-thirds">Name</t.sort-by> | ||
<t.sort-by @prop="Size" @class="has-text-right">File Size</t.sort-by> | ||
<t.sort-by @prop="ModTime" @class="has-text-right">Last Modified</t.sort-by> | ||
</t.head> | ||
<t.body as |row|> | ||
<Fs::DirectoryEntry @path={{this.path}} @allocation={{this.allocation}} @taskState={{this.taskState}} @entry={{row.model}} /> | ||
</t.body> | ||
</ListTable> | ||
{{else}} | ||
<div class="boxed-section-body"> | ||
<div data-test-empty-directory class="empty-message"> | ||
<h3 data-test-empty-directory-headline class="empty-message-headline">No Files</h3> | ||
<p data-test-empty-directory-body class="empty-message-body"> | ||
Directory is currently empty. | ||
</p> | ||
</div> | ||
</div> | ||
{{/if}} | ||
</div> | ||
{{/if}} | ||
{{else}} | ||
<div data-test-not-running class="empty-message"> | ||
<h3 data-test-not-running-headline class="empty-message-headline">{{capitalize this.type}} is not Running</h3> | ||
<p data-test-not-running-body class="empty-message-body"> | ||
Cannot access files of a{{if this.allocation 'n'}} {{this.type}} that is not running. | ||
</p> | ||
{{#if this.directoryEntries}} | ||
<ListTable | ||
@source={{this.sortedDirectoryEntries}} | ||
@sortProperty={{this.sortProperty}} | ||
@sortDescending={{this.sortDescending}} | ||
@class="boxed-section-body is-full-bleed is-compact" as |t|> | ||
<t.head> | ||
<t.sort-by @prop="Name" @class="is-two-thirds">Name</t.sort-by> | ||
<t.sort-by @prop="Size" @class="has-text-right">File Size</t.sort-by> | ||
<t.sort-by @prop="ModTime" @class="has-text-right">Last Modified</t.sort-by> | ||
</t.head> | ||
<t.body as |row|> | ||
<Fs::DirectoryEntry @path={{this.path}} @allocation={{this.allocation}} @taskState={{this.taskState}} @entry={{row.model}} /> | ||
</t.body> | ||
</ListTable> | ||
{{else}} | ||
<div class="boxed-section-body"> | ||
<div data-test-empty-directory class="empty-message"> | ||
<h3 data-test-empty-directory-headline class="empty-message-headline">No Files</h3> | ||
<p data-test-empty-directory-body class="empty-message-body"> | ||
Directory is currently empty. | ||
</p> | ||
</div> | ||
</div> | ||
{{/if}} | ||
</div> | ||
{{/if}} | ||
</section> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters