From 927a055aa9d049984166e876bd6f33ec0815576d Mon Sep 17 00:00:00 2001 From: Shijun Sun <30999793+AllForNothing@users.noreply.github.com> Date: Wed, 30 Nov 2022 14:35:01 +0800 Subject: [PATCH] Update i18n for group filter and schedule list (#17884) Fixes #17868 and #17853 Signed-off-by: AllForNothing Signed-off-by: AllForNothing --- .../schedule-list.component.html | 23 ------------------- .../schedule-list/schedule-list.component.ts | 12 ---------- .../worker-list/worker-list.component.html | 16 ------------- .../worker-list/worker-list.component.scss | 4 ---- .../worker-list/worker-list.component.ts | 7 ------ src/portal/src/i18n/lang/de-de-lang.json | 7 ++---- src/portal/src/i18n/lang/en-us-lang.json | 7 ++---- src/portal/src/i18n/lang/es-es-lang.json | 7 ++---- src/portal/src/i18n/lang/fr-fr-lang.json | 7 ++---- src/portal/src/i18n/lang/pt-br-lang.json | 7 ++---- src/portal/src/i18n/lang/tr-tr-lang.json | 7 ++---- src/portal/src/i18n/lang/zh-cn-lang.json | 7 ++---- src/portal/src/i18n/lang/zh-tw-lang.json | 7 ++---- 13 files changed, 16 insertions(+), 102 deletions(-) diff --git a/src/portal/src/app/base/left-side-nav/job-service-dashboard/schedule-list/schedule-list.component.html b/src/portal/src/app/base/left-side-nav/job-service-dashboard/schedule-list/schedule-list.component.html index ad6734cc8..24c45f94f 100644 --- a/src/portal/src/app/base/left-side-nav/job-service-dashboard/schedule-list/schedule-list.component.html +++ b/src/portal/src/app/base/left-side-nav/job-service-dashboard/schedule-list/schedule-list.component.html @@ -18,12 +18,6 @@ {{ 'JOB_SERVICE_DASHBOARD.CRON' | translate }} - {{ - 'JOB_SERVICE_DASHBOARD.CRON_TYPE' | translate - }} - {{ - 'JOB_SERVICE_DASHBOARD.EXTRA_ATTR' | translate - }} {{ 'REPLICATION.UPDATE_TIME' | translate }} @@ -35,23 +29,6 @@ {{ p.vendor_type }} {{ p.vendor_id }} {{ p.cron }} - {{ toI18nString(p.cron_type) | translate }} - - - {{ - p.extra_attrs - }} - -

-                
-
-
{{ p.update_time | harborDatetime }} diff --git a/src/portal/src/app/base/left-side-nav/job-service-dashboard/schedule-list/schedule-list.component.ts b/src/portal/src/app/base/left-side-nav/job-service-dashboard/schedule-list/schedule-list.component.ts index 120dd392d..53014ab46 100644 --- a/src/portal/src/app/base/left-side-nav/job-service-dashboard/schedule-list/schedule-list.component.ts +++ b/src/portal/src/app/base/left-side-nav/job-service-dashboard/schedule-list/schedule-list.component.ts @@ -15,7 +15,6 @@ import { } from '../../../../services/event-service/event.service'; import { Subscription } from 'rxjs'; import { ScheduleService } from '../../../../../../ng-swagger-gen/services/schedule.service'; -import { CronTypeI18nMap } from '../job-service-dashboard.interface'; @Component({ selector: 'app-schedule-list', @@ -90,15 +89,4 @@ export class ScheduleListComponent implements OnInit, OnDestroy { }, }); } - - json(v: string): object { - if (v) { - return JSON.parse(v); - } - return null; - } - - toI18nString(v: string): string { - return CronTypeI18nMap[v] ? CronTypeI18nMap[v] : v; - } } diff --git a/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.html b/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.html index 1ae887757..48e5b57da 100644 --- a/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.html +++ b/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.html @@ -99,9 +99,6 @@ {{ 'JOB_SERVICE_DASHBOARD.JOB_ID' | translate }} - {{ - 'JOB_SERVICE_DASHBOARD.JOB_PARAM' | translate - }} {{ 'JOB_SERVICE_DASHBOARD.START_AT' | translate }} @@ -115,19 +112,6 @@ {{ w.id }} {{ w.job_name }} {{ w.job_id }} - - - {{ - w.args - }} - -

-                    
-
-
{{ w.start_at | harborDatetime }} {{ w.checkin_at | harborDatetime }} diff --git a/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.scss b/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.scss index 04b75b339..603ba8daf 100644 --- a/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.scss +++ b/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.scss @@ -6,10 +6,6 @@ text-transform: unset; } -.flex { - display: flex; -} - .action-bar { display: flex; justify-content: right; diff --git a/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.ts b/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.ts index 04c1efcdd..ad5c8a1a3 100644 --- a/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.ts +++ b/src/portal/src/app/base/left-side-nav/job-service-dashboard/worker-list/worker-list.component.ts @@ -232,11 +232,4 @@ export class WorkerListComponent implements OnInit, OnDestroy { }, }); } - - json(v: string): object { - if (v) { - return JSON.parse(v); - } - return null; - } } diff --git a/src/portal/src/i18n/lang/de-de-lang.json b/src/portal/src/i18n/lang/de-de-lang.json index 8bc98de1c..2314cde1b 100644 --- a/src/portal/src/i18n/lang/de-de-lang.json +++ b/src/portal/src/i18n/lang/de-de-lang.json @@ -963,7 +963,7 @@ "OIDC_ADMIN_GROUP": "OIDC Administratorengruppe", "OIDC_ADMIN_GROUP_INFO": "Spezifiziere den Namen einer OIDC Administratorengruppe. Alle Mitglieder dieser Gruppe haben in Harbor administrative Berechtigungen. Falls dies nicht gewünscht ist, kann das Feld leer gelassen werden.", "OIDC_GROUP_FILTER": "OIDC Group Filter", - "OIDC_GROUP_FILTER_INFO": "Exclude OIDC groups who match the provided regular expression." + "OIDC_GROUP_FILTER_INFO": "Filter OIDC groups who match the provided regular expression.Keep it blank to match all the groups." }, "SCANNING": { "STOP_SCAN_ALL_SUCCESS": "Alle Scans erfolgreich zum Anhalten aufgefordert!", @@ -1804,7 +1804,6 @@ "RESUME_ALL_SUCCESS": "Alle Pläne erfolgreich fortgesetzt", "VENDOR_TYPE": "Hersteller Typ", "VENDOR_ID": "Hersteller ID", - "EXTRA_ATTR": "Extra Attribute", "NO_SCHEDULE": "Es konnte kein Plan gefunden werden", "WORKERS": "Arbeiter", "FREE_ALL": "Alle befreien", @@ -1824,7 +1823,6 @@ "FREE": "Frei", "WORKER_ID": "Arbeiter-ID", "JOB_ID": "Job-ID", - "JOB_PARAM": "Job-Parameter", "CHECK_IN_AT": "Eingecheckt um", "NO_WORKER": "Es konnte kein Arbeiter gefunden werden", "JOB_QUEUE": "Job-Warteschlange", @@ -1843,7 +1841,6 @@ "SCHEDULE_PAUSE_BTN_INFO": "PAUSIEREN — Pausiert die Ausführung aller Pläne.", "SCHEDULE_RESUME_BTN_INFO": "FORTSETZEN — Setzt die Ausführung aller Pläne fort.", "WORKER_FREE_BTN_INFO": "Halte den aktuell laufenden Job an um den Arbeiter zu befreien.", - "CRON": "Cron", - "CRON_TYPE": "Cron Type" + "CRON": "Cron" } } diff --git a/src/portal/src/i18n/lang/en-us-lang.json b/src/portal/src/i18n/lang/en-us-lang.json index e2576aa5c..4dcea5163 100644 --- a/src/portal/src/i18n/lang/en-us-lang.json +++ b/src/portal/src/i18n/lang/en-us-lang.json @@ -963,7 +963,7 @@ "OIDC_ADMIN_GROUP": "OIDC Admin Group", "OIDC_ADMIN_GROUP_INFO": "Specify an OIDC admin group name. All OIDC users in this group will have harbor admin privilege. Keep it blank if you do not want to.", "OIDC_GROUP_FILTER": "OIDC Group Filter", - "OIDC_GROUP_FILTER_INFO": "Exclude OIDC groups who match the provided regular expression." + "OIDC_GROUP_FILTER_INFO": "Filter OIDC groups who match the provided regular expression.Keep it blank to match all the groups." }, "SCANNING": { "STOP_SCAN_ALL_SUCCESS": "Trigger stopping scan all successfully!", @@ -1804,7 +1804,6 @@ "RESUME_ALL_SUCCESS": "Resumed all the schedules successfully", "VENDOR_TYPE": "Vendor Type", "VENDOR_ID": "Vendor ID", - "EXTRA_ATTR": "Extra Attribute", "NO_SCHEDULE": "We could not find any schedule", "WORKERS": "Workers", "FREE_ALL": "Free all", @@ -1824,7 +1823,6 @@ "FREE": "Free", "WORKER_ID": "Worker ID", "JOB_ID": "Job ID", - "JOB_PARAM": "Job Parameter", "CHECK_IN_AT": "Checked In At", "NO_WORKER": "We could not find any worker", "JOB_QUEUE": "Job Queues", @@ -1843,7 +1841,6 @@ "SCHEDULE_PAUSE_BTN_INFO": "PAUSE — Pause all schedules to execute.", "SCHEDULE_RESUME_BTN_INFO": "RESUME — Resume all schedules to execute.", "WORKER_FREE_BTN_INFO": "Stop the current running job to free the worker", - "CRON": "Cron", - "CRON_TYPE": "Cron Type" + "CRON": "Cron" } } diff --git a/src/portal/src/i18n/lang/es-es-lang.json b/src/portal/src/i18n/lang/es-es-lang.json index 46d303e1a..45f76d039 100644 --- a/src/portal/src/i18n/lang/es-es-lang.json +++ b/src/portal/src/i18n/lang/es-es-lang.json @@ -964,7 +964,7 @@ "OIDC_ADMIN_GROUP": "OIDC Admin Group", "OIDC_ADMIN_GROUP_INFO": "Specify an OIDC admin group name. All OIDC users in this group will have harbor admin privilege. Keep it blank if you do not want to.", "OIDC_GROUP_FILTER": "OIDC Group Filter", - "OIDC_GROUP_FILTER_INFO": "Exclude OIDC groups who match the provided regular expression." + "OIDC_GROUP_FILTER_INFO": "Filter OIDC groups who match the provided regular expression.Keep it blank to match all the groups." }, "SCANNING": { "STOP_SCAN_ALL_SUCCESS": "Trigger stopping scan all successfully!", @@ -1803,7 +1803,6 @@ "RESUME_ALL_SUCCESS": "Resumed all the schedules Successfully", "VENDOR_TYPE": "Vendor Type", "VENDOR_ID": "Vendor ID", - "EXTRA_ATTR": "Extra Attribute", "NO_SCHEDULE": "We could not find any schedule", "WORKERS": "Workers", "FREE_ALL": "Free all", @@ -1823,7 +1822,6 @@ "FREE": "Free", "WORKER_ID": "Worker ID", "JOB_ID": "Job ID", - "JOB_PARAM": "Job Parameter", "CHECK_IN_AT": "Checked In At", "NO_WORKER": "We could not find any worker", "JOB_QUEUE": "Job Queues", @@ -1842,7 +1840,6 @@ "SCHEDULE_PAUSE_BTN_INFO": "PAUSE — Pause all schedules to execute.", "SCHEDULE_RESUME_BTN_INFO": "RESUME — Resume all schedules to execute.", "WORKER_FREE_BTN_INFO": "Stop the current running job to free the worker", - "CRON": "Cron", - "CRON_TYPE": "Cron Type" + "CRON": "Cron" } } diff --git a/src/portal/src/i18n/lang/fr-fr-lang.json b/src/portal/src/i18n/lang/fr-fr-lang.json index 092c36281..d85c18014 100644 --- a/src/portal/src/i18n/lang/fr-fr-lang.json +++ b/src/portal/src/i18n/lang/fr-fr-lang.json @@ -936,7 +936,7 @@ "OIDC_ADMIN_GROUP": "OIDC Admin Group", "OIDC_ADMIN_GROUP_INFO": "Specify an OIDC admin group name. All OIDC users in this group will have harbor admin privilege. Keep it blank if you do not want to.", "OIDC_GROUP_FILTER": "OIDC Group Filter", - "OIDC_GROUP_FILTER_INFO": "Exclude OIDC groups who match the provided regular expression." + "OIDC_GROUP_FILTER_INFO": "Filter OIDC groups who match the provided regular expression.Keep it blank to match all the groups." }, "SCANNING": { "STOP_SCAN_ALL_SUCCESS": "Déclenchement avec succès de l'arrêt de l'analyse globale !", @@ -1773,7 +1773,6 @@ "RESUME_ALL_SUCCESS": "Resumed all the schedules Successfully", "VENDOR_TYPE": "Vendor Type", "VENDOR_ID": "Vendor ID", - "EXTRA_ATTR": "Extra Attribute", "NO_SCHEDULE": "We could not find any schedule", "WORKERS": "Workers", "FREE_ALL": "Free all", @@ -1793,7 +1792,6 @@ "FREE": "Free", "WORKER_ID": "Worker ID", "JOB_ID": "Job ID", - "JOB_PARAM": "Job Parameter", "CHECK_IN_AT": "Checked In At", "NO_WORKER": "We could not find any worker", "JOB_QUEUE": "Job Queues", @@ -1812,7 +1810,6 @@ "SCHEDULE_PAUSE_BTN_INFO": "PAUSE — Pause all schedules to execute.", "SCHEDULE_RESUME_BTN_INFO": "RESUME — Resume all schedule to execute.", "WORKER_FREE_BTN_INFO": "Stop the current running job to free the worker", - "CRON": "Cron", - "CRON_TYPE": "Cron Type" + "CRON": "Cron" } } diff --git a/src/portal/src/i18n/lang/pt-br-lang.json b/src/portal/src/i18n/lang/pt-br-lang.json index 913ef3c04..e24f932e1 100644 --- a/src/portal/src/i18n/lang/pt-br-lang.json +++ b/src/portal/src/i18n/lang/pt-br-lang.json @@ -959,7 +959,7 @@ "OIDC_ADMIN_GROUP": "Grupo Administrativo", "OIDC_ADMIN_GROUP_INFO": "Informe o nome do grupo OIDC que será considerado administrativo. Todos os usuários deste grupo obterão privilégios de adiministração no Harbor. Deixe vazio para ser ignorado.", "OIDC_GROUP_FILTER": "OIDC Group Filter", - "OIDC_GROUP_FILTER_INFO": "Exclude OIDC groups who match the provided regular expression." + "OIDC_GROUP_FILTER_INFO": "Filter OIDC groups who match the provided regular expression.Keep it blank to match all the groups." }, "SCANNING": { "STOP_SCAN_ALL_SUCCESS": "Todos os exames foram interrompidos!", @@ -1800,7 +1800,6 @@ "RESUME_ALL_SUCCESS": "Resumed all the schedules Successfully", "VENDOR_TYPE": "Vendor Type", "VENDOR_ID": "Vendor ID", - "EXTRA_ATTR": "Extra Attribute", "NO_SCHEDULE": "We could not find any schedule", "WORKERS": "Workers", "FREE_ALL": "Free all", @@ -1820,7 +1819,6 @@ "FREE": "Free", "WORKER_ID": "Worker ID", "JOB_ID": "Job ID", - "JOB_PARAM": "Job Parameter", "CHECK_IN_AT": "Checked In At", "NO_WORKER": "We could not find any worker", "JOB_QUEUE": "Job Queues", @@ -1839,7 +1837,6 @@ "SCHEDULE_PAUSE_BTN_INFO": "PAUSE — Pause all schedules to execute.", "SCHEDULE_RESUME_BTN_INFO": "RESUME — Resume all schedule to execute.", "WORKER_FREE_BTN_INFO": "Stop the current running job to free the worker", - "CRON": "Cron", - "CRON_TYPE": "Cron Type" + "CRON": "Cron" } } diff --git a/src/portal/src/i18n/lang/tr-tr-lang.json b/src/portal/src/i18n/lang/tr-tr-lang.json index 313e1a535..890bf8267 100644 --- a/src/portal/src/i18n/lang/tr-tr-lang.json +++ b/src/portal/src/i18n/lang/tr-tr-lang.json @@ -963,7 +963,7 @@ "OIDC_ADMIN_GROUP": "OIDC Admin Group", "OIDC_ADMIN_GROUP_INFO": "Specify an OIDC admin group name. All OIDC users in this group will have harbor admin privilege. Keep it blank if you do not want to.", "OIDC_GROUP_FILTER": "OIDC Group Filter", - "OIDC_GROUP_FILTER_INFO": "Exclude OIDC groups who match the provided regular expression." + "OIDC_GROUP_FILTER_INFO": "Filter OIDC groups who match the provided regular expression.Keep it blank to match all the groups." }, "SCANNING": { "STOP_SCAN_ALL_SUCCESS": "Trigger stopping scan all successfully!", @@ -1804,7 +1804,6 @@ "RESUME_ALL_SUCCESS": "Resumed all the schedules Successfully", "VENDOR_TYPE": "Vendor Type", "VENDOR_ID": "Vendor ID", - "EXTRA_ATTR": "Extra Attribute", "NO_SCHEDULE": "We could not find any schedule", "WORKERS": "Workers", "FREE_ALL": "Free all", @@ -1824,7 +1823,6 @@ "FREE": "Free", "WORKER_ID": "Worker ID", "JOB_ID": "Job ID", - "JOB_PARAM": "Job Parameter", "CHECK_IN_AT": "Checked In At", "NO_WORKER": "We could not find any worker", "JOB_QUEUE": "Job Queues", @@ -1843,7 +1841,6 @@ "SCHEDULE_PAUSE_BTN_INFO": "PAUSE — Pause all schedules to execute.", "SCHEDULE_RESUME_BTN_INFO": "RESUME — Resume all schedule to execute.", "WORKER_FREE_BTN_INFO": "Stop the current running job to free the worker", - "CRON": "Cron", - "CRON_TYPE": "Cron Type" + "CRON": "Cron" } } diff --git a/src/portal/src/i18n/lang/zh-cn-lang.json b/src/portal/src/i18n/lang/zh-cn-lang.json index 9e57987ee..10ec71713 100644 --- a/src/portal/src/i18n/lang/zh-cn-lang.json +++ b/src/portal/src/i18n/lang/zh-cn-lang.json @@ -964,7 +964,7 @@ "OIDC_ADMIN_GROUP": "OIDC管理员组", "OIDC_ADMIN_GROUP_INFO": "OIDC管理员组名称。所有该组内用户都会有管理员权限,此属性可以为空。", "OIDC_GROUP_FILTER": "OIDC 组过滤器", - "OIDC_GROUP_FILTER_INFO": "该过滤器将会过滤掉不匹配此项正则表达式的 OIDC 组" + "OIDC_GROUP_FILTER_INFO": "该过滤器将会过滤掉不匹配此项正则表达式的 OIDC 组。若不填,则表示匹配所有。" }, "SCANNING": { "STOP_SCAN_ALL_SUCCESS": "停止扫描所有镜像任务成功!", @@ -1802,7 +1802,6 @@ "RESUME_ALL_SUCCESS": "重启所有定时任务成功", "VENDOR_TYPE": "供应商类型", "VENDOR_ID": "供应商 ID", - "EXTRA_ATTR": "其他属性", "NO_SCHEDULE": "未发现任何定时任务", "WORKERS": "工作者", "FREE_ALL": "停下全部", @@ -1822,7 +1821,6 @@ "FREE": "停下", "WORKER_ID": "工作者 ID", "JOB_ID": "任务 ID", - "JOB_PARAM": "任务参数", "CHECK_IN_AT": "检查时间", "NO_WORKER": "未发现任何工作者", "JOB_QUEUE": "任务栈", @@ -1841,7 +1839,6 @@ "SCHEDULE_PAUSE_BTN_INFO": "暂停 — 暂停所有定时任务,暂停中的定时任务将不会被执行。", "SCHEDULE_RESUME_BTN_INFO": "重启 — 重启所有定时任务,定时任务在触发时会正常执行。", "WORKER_FREE_BTN_INFO": "停下选中的工作者当前正在执行的任务以便释放该工作者,被释放的工作者会继续执行其他任务。", - "CRON": "Cron", - "CRON_TYPE": "Cron 类型" + "CRON": "Cron" } } diff --git a/src/portal/src/i18n/lang/zh-tw-lang.json b/src/portal/src/i18n/lang/zh-tw-lang.json index 6fb7e0f37..6502d9e1e 100644 --- a/src/portal/src/i18n/lang/zh-tw-lang.json +++ b/src/portal/src/i18n/lang/zh-tw-lang.json @@ -959,7 +959,7 @@ "OIDC_ADMIN_GROUP": "OIDC Admin Group", "OIDC_ADMIN_GROUP_INFO": "Specify an OIDC admin group name. All OIDC users in this group will have harbor admin privilege. Keep it blank if you do not want to.", "OIDC_GROUP_FILTER": "OIDC Group Filter", - "OIDC_GROUP_FILTER_INFO": "Exclude OIDC groups who match the provided regular expression." + "OIDC_GROUP_FILTER_INFO": "Filter OIDC groups who match the provided regular expression.Keep it blank to match all the groups." }, "SCANNING":{ "STOP_SCAN_ALL_SUCCESS": "Trigger stopping scan all successfully!", @@ -1795,7 +1795,6 @@ "RESUME_ALL_SUCCESS": "Resumed all the schedules Successfully", "VENDOR_TYPE": "Vendor Type", "VENDOR_ID": "Vendor ID", - "EXTRA_ATTR": "Extra Attribute", "NO_SCHEDULE": "We could not find any schedule", "WORKERS": "Workers", "FREE_ALL": "Free all", @@ -1815,7 +1814,6 @@ "FREE": "Free", "WORKER_ID": "Worker ID", "JOB_ID": "Job ID", - "JOB_PARAM": "Job Parameter", "CHECK_IN_AT": "Checked In At", "NO_WORKER": "We could not find any worker", "JOB_QUEUE": "Job Queues", @@ -1834,7 +1832,6 @@ "SCHEDULE_PAUSE_BTN_INFO": "PAUSE — Pause all schedules to execute.", "SCHEDULE_RESUME_BTN_INFO": "RESUME — Resume all schedule to execute.", "WORKER_FREE_BTN_INFO": "Stop the current running job to free the worker", - "CRON": "Cron", - "CRON_TYPE": "Cron Type" + "CRON": "Cron" } }