Show task name before enabled state
This commit is contained in:
+1
-1
@@ -37,7 +37,7 @@ export function hostCard(entry) {
|
||||
const kind = !current || unknown || result === undefined ? 'unknown' : result === 1 ? 'normal' : 'error';
|
||||
const stateLabel = kind === 'normal' ? text('正常', 'Normal') : kind === 'error' ? text('失败', 'Failed') : text('待确认', 'Unconfirmed');
|
||||
const title = /轮播/.test(resource.name || '') ? text('轮播任务', 'Slideshow task') : resource.name || text('任务', 'Job');
|
||||
return [card(title, enabled ? text('启用', 'Enabled') : text('停用', 'Disabled'), status(kind, stateLabel))];
|
||||
return [card(title, `${resource.name || text('任务', 'Job')} · ${enabled ? text('启用', 'Enabled') : text('停用', 'Disabled')}`, status(kind, stateLabel))];
|
||||
}
|
||||
return metrics.filter(m => m.resource_id === resource.id).map(metric => {
|
||||
const title = label(metric);
|
||||
|
||||
Reference in New Issue
Block a user