diff --git a/src/components/Base/Modal/index.scss b/src/components/Base/Modal/index.scss index fe949acf..b30f259b 100644 --- a/src/components/Base/Modal/index.scss +++ b/src/components/Base/Modal/index.scss @@ -54,7 +54,7 @@ height: 32px; border-radius: 2px; background-color: $N0; - box-shadow: 0 1px 2px 0 rgba(109, 53, 195, 0.15); + // box-shadow: 0 1px 2px 0 rgba(109, 53, 195, 0.15); } & > textarea{ box-sizing: border-box; diff --git a/src/config/translation.js b/src/config/translation.js index f0b18041..9ab57353 100644 --- a/src/config/translation.js +++ b/src/config/translation.js @@ -50,6 +50,9 @@ const tsObj = { 'Runtime Selector missing value': '环境选择器缺失值', 'Invalid s3 url, should be like s3://s3.pek3a.qingstor.com/op-repo': '无效的s3网址,应该是这样: s3://s3.pek3a.qingstor.com/op-repo', + 'Information to be verified is incomplete!': '验证要求输入的信息不完整!', + 'Access key verification successfully': '访问密钥验证成功', + 'Access key verification fail': '访问密钥验证失败', 'Create repo successfully': '创建仓库成功', 'Modify repo successfully': '修改仓库成功', 'Delete repo successfully.': '删除仓库成功', diff --git a/src/pages/Admin/Repos/Add/index.jsx b/src/pages/Admin/Repos/Add/index.jsx index e0b43eaf..c66e5e84 100644 --- a/src/pages/Admin/Repos/Add/index.jsx +++ b/src/pages/Admin/Repos/Add/index.jsx @@ -37,11 +37,14 @@ export default class RepoAdd extends Component { } } - componentDidUpdate() { - if (get(this.store, 'repoCreated.repo_id') && !this.store.isLoading) { - history.back(); + handleSubmit = async e => { + const { repoCreateStore } = this.props; + const result = await repoCreateStore.handleSubmit(e); + + if (!(result && result.err)) { + setTimeout(() => history.back(), 1000); } - } + }; renderForm() { const { t } = this.props; @@ -61,7 +64,7 @@ export default class RepoAdd extends Component { } = this.store; return ( -