-
Notifications
You must be signed in to change notification settings - Fork 428
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve hooks infos #3314
Improve hooks infos #3314
Conversation
CDS Report build-engine-cli-tools#5894.0 ✘
|
engine/api/router_util.go
Outdated
return false | ||
} | ||
|
||
func SortCompareInt(i, j int, o SortOrder) bool { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
doc
f811b42
to
e363ffd
Compare
CDS Report ut-engine#5949.0 ✘
|
CDS Report build-ui#5961.0 ✘
|
7c541a4
to
98c7728
Compare
</tr> | ||
</tbody> | ||
<tbody *ngIf="!loading && data.length > 0"> | ||
<tr *ngFor="let d of getDataForCurrentPage()"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
try to not call function in template
name: '', | ||
selector: d => { | ||
if (d.status === HookStatus.DONE) { | ||
return '<i class="check green icon"></i>'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't feel very comfortable with the fact that we write HTML in typescript. Maybe we can find a better way to do this kind of code ?
<Column>{ | ||
type: ColumnType.HTML, | ||
name: '', | ||
selector: d => d.stopped ? '<i class="stop red icon"></i>' : '<i class="play green icon"></i>', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same here
ui/src/assets/i18n/fr.json
Outdated
"hook_task_cron": "CRON", | ||
"hook_task_execs_todo": "Exécutions planifiées", | ||
"hook_task_execs_total": "Total des exécutions", | ||
"hook_task_repo_fullname": "Nom du repository", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/repository/dépôt
engine/hooks/hooks_handlers.go
Outdated
@@ -146,28 +146,62 @@ func (s *Service) postTaskHandler() service.Handler { | |||
} | |||
} | |||
|
|||
const ( | |||
sortKeyNbExecutionsTotal string = "nb_executions_total" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need to specify the type
I removed the HTML column type and created a Icon one. I also add optional filter to the table component and used it hook tasks page. |
@@ -16,17 +25,19 @@ | |||
</td> | |||
</tr> | |||
</tbody> | |||
<tbody *ngIf="!loading && data.length == 0"> | |||
<tbody *ngIf="!loading && dataForCurrentPage.length == 0"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
strict equals ===
@ovh/cds