Browse Source

[Feature][UI] Disabled statistics. (#9935)

* [Feature][UI] Disabled statistics.

* [Feature][UI] Disabled statistics.

* [Feature][UI] Disabled statistics.
3.0.0/version-upgrade
songjianet 3 years ago committed by GitHub
parent
commit
1f8c59b3b4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      dolphinscheduler-ui/src/locales/modules/en_US.ts
  2. 4
      dolphinscheduler-ui/src/locales/modules/zh_CN.ts
  3. 27
      dolphinscheduler-ui/src/views/monitor/statistics/statistics/index.tsx
  4. 4
      dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-http.ts

4
dolphinscheduler-ui/src/locales/modules/en_US.ts

@ -180,9 +180,7 @@ const monitor = {
statistics: { statistics: {
command_number_of_waiting_for_running: command_number_of_waiting_for_running:
'Command Number Of Waiting For Running', 'Command Number Of Waiting For Running',
failure_command_number: 'Failure Command Number', failure_command_number: 'Failure Command Number'
tasks_number_of_waiting_running: 'Tasks Number Of Waiting Running',
task_number_of_ready_to_kill: 'Task Number Of Ready To Kill'
}, },
audit_log: { audit_log: {
user_name: 'User Name', user_name: 'User Name',

4
dolphinscheduler-ui/src/locales/modules/zh_CN.ts

@ -178,9 +178,7 @@ const monitor = {
}, },
statistics: { statistics: {
command_number_of_waiting_for_running: '待执行的命令数', command_number_of_waiting_for_running: '待执行的命令数',
failure_command_number: '执行失败的命令数', failure_command_number: '执行失败的命令数'
tasks_number_of_waiting_running: '待运行任务数',
task_number_of_ready_to_kill: '待杀死任务数'
}, },
audit_log: { audit_log: {
user_name: '用户名称', user_name: '用户名称',

27
dolphinscheduler-ui/src/views/monitor/statistics/statistics/index.tsx

@ -21,7 +21,6 @@ import { useStatistics } from './use-statistics'
import { useI18n } from 'vue-i18n' import { useI18n } from 'vue-i18n'
import Card from '@/components/card' import Card from '@/components/card'
import styles from './index.module.scss' import styles from './index.module.scss'
import type { TaskQueueRes } from '@/service/modules/projects-analysis/types'
const statistics = defineComponent({ const statistics = defineComponent({
name: 'statistics', name: 'statistics',
@ -36,7 +35,7 @@ const statistics = defineComponent({
const { t, statisticsRef } = this const { t, statisticsRef } = this
return ( return (
<NGrid x-gap='12' y-gap='8' cols='2 xl:4' responsive='screen'> <NGrid x-gap='12' y-gap='8' cols='2' responsive='screen'>
<NGi> <NGi>
<Card <Card
title={t( title={t(
@ -69,30 +68,6 @@ const statistics = defineComponent({
</div> </div>
</Card> </Card>
</NGi> </NGi>
<NGi>
<Card title={t('monitor.statistics.tasks_number_of_waiting_running')}>
<div class={styles.connections}>
{Object.keys(statisticsRef.task).length > 0 && (
<NNumberAnimation
from={0}
to={(statisticsRef.task as TaskQueueRes).taskQueue}
/>
)}
</div>
</Card>
</NGi>
<NGi>
<Card title={t('monitor.statistics.task_number_of_ready_to_kill')}>
<div class={styles.connections}>
{Object.keys(statisticsRef.task).length > 0 && (
<NNumberAnimation
from={0}
to={(statisticsRef.task as TaskQueueRes).taskKill}
/>
)}
</div>
</Card>
</NGi>
</NGrid> </NGrid>
) )
} }

4
dolphinscheduler-ui/src/views/projects/task/components/node/fields/use-http.ts

@ -55,7 +55,9 @@ export function useHttp(model: { [field: string]: any }): IJsonItem[] {
if (!value) { if (!value) {
return new Error(t('project.node.http_url_tips')) return new Error(t('project.node.http_url_tips'))
} }
if (value.search(new RegExp('http[s]{0,1}:\/\/([\w.]+\/?)\S*', 'i'))) { if (
value.search(new RegExp(/http[s]{0,1}:\/\/([\w.]+\/?)\S*/, 'i'))
) {
return new Error(t('project.node.http_url_validator')) return new Error(t('project.node.http_url_validator'))
} }
} }

Loading…
Cancel
Save