File tree Expand file tree Collapse file tree 1 file changed +24
-5
lines changed
client/platform/desktop/frontend/components Expand file tree Collapse file tree 1 file changed +24
-5
lines changed Original file line number Diff line number Diff line change 11<script lang="ts">
22import { shell } from ' electron' ;
33import moment , { utc } from ' moment' ;
4- import { defineComponent , ref , onBeforeUnmount } from ' vue' ;
4+ import {
5+ defineComponent ,
6+ ref ,
7+ onBeforeUnmount ,
8+ watch ,
9+ } from ' vue' ;
510
6- import { DesktopJob } from ' platform/desktop/constants' ;
11+ import {
12+ DesktopJob ,
13+ isRunPipeline ,
14+ RunPipeline ,
15+ // isRunTraining,
16+ RunTraining ,
17+ } from ' platform/desktop/constants' ;
718
819import BrowserLink from ' ./BrowserLink.vue' ;
920import NavigationBar from ' ./NavigationBar.vue' ;
@@ -37,11 +48,19 @@ export default defineComponent({
3748 if (job .workingDir ) shell .openPath (job .workingDir );
3849 }
3950
51+ let queuedPipelineJobs: (RunPipeline | RunTraining )[] = [];
52+ function updatePendingJobs() {
53+ queuedPipelineJobs = gpuJobQueue .jobSpecs .filter ((spec ) => isRunPipeline (spec ));
54+ }
55+
56+ watch (recentHistory , updatePendingJobs );
57+
4058 return {
4159 clockDriver ,
4260 datasets ,
4361 recentHistory ,
4462 gpuJobQueue ,
63+ queuedPipelineJobs ,
4564 moment ,
4665 utc ,
4766 visibleOutput ,
@@ -238,10 +257,10 @@ export default defineComponent({
238257 Upcoming Jobs ({{ gpuJobQueue.length() }})
239258 </h1 >
240259 <v-card
241- v-for =" jobSpec in gpuJobQueue.jobSpecs "
242- :key =" jobSpec.datasetId? "
260+ v-for =" jobSpec in queuedPipelineJobs "
261+ :key =" jobSpec.datasetId"
243262 >
244- {{ jobSpec.datasetId? }}
263+ {{ jobSpec.datasetId }}
245264 </v-card >
246265 </v-col >
247266 </v-row >
You can’t perform that action at this time.
0 commit comments