From 54bfad3c25617167eb085b4c9a44596ef15d2cdc Mon Sep 17 00:00:00 2001 From: zhuangchong <37063904+zhuangchong@users.noreply.github.com> Date: Wed, 28 Jul 2021 11:01:06 +0800 Subject: [PATCH] create token parameter validation. (#5903) --- .../conf/home/pages/user/pages/token/_source/createToken.vue | 4 ++++ dolphinscheduler-ui/src/js/module/i18n/locale/en_US.js | 1 + dolphinscheduler-ui/src/js/module/i18n/locale/zh_CN.js | 1 + 3 files changed, 6 insertions(+) diff --git a/dolphinscheduler-ui/src/js/conf/home/pages/user/pages/token/_source/createToken.vue b/dolphinscheduler-ui/src/js/conf/home/pages/user/pages/token/_source/createToken.vue index 57aa660d0c..29e143188e 100644 --- a/dolphinscheduler-ui/src/js/conf/home/pages/user/pages/token/_source/createToken.vue +++ b/dolphinscheduler-ui/src/js/conf/home/pages/user/pages/token/_source/createToken.vue @@ -101,6 +101,10 @@ this.$message.warning(`${i18n.$t('Please generate token')}`) return false } + if (!this.expireTime) { + this.$message.warning(`${i18n.$t('Please Select token')}`) + return false + } return true }, _submit () { diff --git a/dolphinscheduler-ui/src/js/module/i18n/locale/en_US.js b/dolphinscheduler-ui/src/js/module/i18n/locale/en_US.js index 4af6644af8..83b5757bf2 100755 --- a/dolphinscheduler-ui/src/js/module/i18n/locale/en_US.js +++ b/dolphinscheduler-ui/src/js/module/i18n/locale/en_US.js @@ -550,6 +550,7 @@ export default { 'There is no data for this period of time': 'There is no data for this period of time', 'Worker addresses cannot be empty': 'Worker addresses cannot be empty', 'Please generate token': 'Please generate token', + 'Please Select token': 'Please select the expiration time of token', 'Spark Version': 'Spark Version', TargetDataBase: 'target database', TargetTable: 'target table', diff --git a/dolphinscheduler-ui/src/js/module/i18n/locale/zh_CN.js b/dolphinscheduler-ui/src/js/module/i18n/locale/zh_CN.js index 90b1eca162..a120953070 100755 --- a/dolphinscheduler-ui/src/js/module/i18n/locale/zh_CN.js +++ b/dolphinscheduler-ui/src/js/module/i18n/locale/zh_CN.js @@ -550,6 +550,7 @@ export default { 'There is no data for this period of time': '该时间段无数据', 'Worker addresses cannot be empty': 'Worker地址不能为空', 'Please generate token': '请生成Token', + 'Please Select token': '请选择Token失效时间', 'Spark Version': 'Spark版本', TargetDataBase: '目标库', TargetTable: '目标表',