mirror of
https://github.com/YunoHost/yunorunner.git
synced 2024-09-03 20:05:52 +02:00
Repo app name / state from views
This commit is contained in:
parent
a80501208b
commit
c4b9fcf554
2 changed files with 2 additions and 2 deletions
2
run.py
2
run.py
|
@ -161,7 +161,7 @@ def set_random_day_for_monthy_job():
|
||||||
|
|
||||||
async def create_job(app_id, app_list_name, repo, job_command_last_part):
|
async def create_job(app_id, app_list_name, repo, job_command_last_part):
|
||||||
if isinstance(job_command_last_part, str):
|
if isinstance(job_command_last_part, str):
|
||||||
job_name = f"{app_id} ({app_list_name})" + job_command_last_part
|
job_name = f"{app_id} " + job_command_last_part
|
||||||
|
|
||||||
# avoid scheduling twice
|
# avoid scheduling twice
|
||||||
if Job.select().where(Job.name == job_name, Job.state == "scheduled").count() > 0:
|
if Job.select().where(Job.name == job_name, Job.state == "scheduled").count() > 0:
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
</thead>
|
</thead>
|
||||||
<template v-if="apps.length > 0">
|
<template v-if="apps.length > 0">
|
||||||
<tr v-for="(app, index) in apps" :id="app.id" v-bind:class="[app.job_state + 'Job']">
|
<tr v-for="(app, index) in apps" :id="app.id" v-bind:class="[app.job_state + 'Job']">
|
||||||
<td><a v-bind:href="app.name + '/'">{{app.name}}</a> <small>{{app.app_list}}</small> <span v-bind:class="['tag', appStateTagClass(app.state)]">{{app.state}}</span> <a target="_blank" v-bind:href="app.url">↪</a></td>
|
<td><a v-bind:href="app.name + '/'">{{app.name}}</a> (<a target="_blank" v-bind:href="app.url">repo</a><)/td>
|
||||||
<td><a v-bind:href="'<{ relative_path_to_root }>job/' + app.job_id">#{{app.job_id}}</a> <span v-bind:class="['tag', jobStateTagClass(app.job_state)]">{{app.job_state}}</span></td>
|
<td><a v-bind:href="'<{ relative_path_to_root }>job/' + app.job_id">#{{app.job_id}}</a> <span v-bind:class="['tag', jobStateTagClass(app.job_state)]">{{app.job_state}}</span></td>
|
||||||
<td>{{timestampToDate(app.created_time)}}</td>
|
<td>{{timestampToDate(app.created_time)}}</td>
|
||||||
<td>{{timestampToDate(app.started_time)}}</td>
|
<td>{{timestampToDate(app.started_time)}}</td>
|
||||||
|
|
Loading…
Add table
Reference in a new issue