List runners in queue
This commit is contained in:
parent
c3c597897c
commit
f3d646c8d5
10 changed files with 243 additions and 61 deletions
|
|
@ -7,9 +7,8 @@ use super::Base;
|
|||
#[derive(Template)]
|
||||
#[template(
|
||||
ext = "html",
|
||||
source = "
|
||||
source = "\
|
||||
{% import \"util.html\" as util %}
|
||||
|
||||
<a href=\"{{ root }}commit/{{ hash }}\"
|
||||
class=\"{% call util::commit_class(reachable) %}\"
|
||||
title=\"{% call util::commit_title(reachable) %}\">
|
||||
|
|
@ -34,3 +33,50 @@ impl CommitLink {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Template)]
|
||||
#[template(
|
||||
ext = "html",
|
||||
source = "\
|
||||
<a href=\"{{ root }}run/{{ id }}\">
|
||||
Run of {{ short }}
|
||||
</a>
|
||||
"
|
||||
)]
|
||||
pub struct RunLink {
|
||||
root: String,
|
||||
id: String,
|
||||
short: String,
|
||||
}
|
||||
|
||||
impl RunLink {
|
||||
pub fn new(base: &Base, id: String, hash: &str, message: &str) -> Self {
|
||||
Self {
|
||||
root: base.root.clone(),
|
||||
id,
|
||||
short: util::format_commit_short(hash, message),
|
||||
}
|
||||
}
|
||||
}
|
||||
#[derive(Template)]
|
||||
#[template(
|
||||
ext = "html",
|
||||
source = "\
|
||||
<a href=\"{{ root }}runner/{{ name }}\">
|
||||
{{ name }}
|
||||
</a>
|
||||
"
|
||||
)]
|
||||
pub struct RunnerLink {
|
||||
root: String,
|
||||
name: String,
|
||||
}
|
||||
|
||||
impl RunnerLink {
|
||||
pub fn new(base: &Base, name: String) -> Self {
|
||||
Self {
|
||||
root: base.root.clone(),
|
||||
name,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue