diff --git a/backend/app/service/helper.go b/backend/app/service/helper.go index f95e80b43..d498ec1b6 100644 --- a/backend/app/service/helper.go +++ b/backend/app/service/helper.go @@ -12,13 +12,3 @@ func getTxAndContext() (tx *gorm.DB, ctx context.Context) { ctx = context.WithValue(context.Background(), constant.DB, tx) return } - -func getTxByContext(ctx context.Context) (*gorm.DB, context.Context) { - tx, ok := ctx.Value(constant.DB).(*gorm.DB) - if ok { - return tx, ctx - } - tx = global.DB.Begin() - ctx = context.WithValue(context.Background(), constant.DB, tx) - return tx, ctx -} diff --git a/frontend/src/lang/modules/zh.ts b/frontend/src/lang/modules/zh.ts index 709da95a9..0f94b3569 100644 --- a/frontend/src/lang/modules/zh.ts +++ b/frontend/src/lang/modules/zh.ts @@ -108,7 +108,7 @@ export default { imageName: '支持英文、中文、数字、:.-_,长度1-30', complexityPassword: '请输入 8 位以上、必须含有字母、数字、特殊符号的密码', commonPassword: '请输入 6 位以上长度密码', - linuxName: '支持英文、数字、._长度1-30', + linuxName: '支持英文、数字、._-长度1-30', email: '请输入正确的邮箱', number: '请输入正确的数字', ip: '请输入正确的 IP 地址', diff --git a/frontend/src/views/app-store/detail/install/index.vue b/frontend/src/views/app-store/detail/install/index.vue index 4b84dff82..21613d928 100644 --- a/frontend/src/views/app-store/detail/install/index.vue +++ b/frontend/src/views/app-store/detail/install/index.vue @@ -46,7 +46,7 @@ const installData = ref({ let open = ref(false); let form = ref<{ [key: string]: any }>({}); let rules = ref({ - NAME: [Rules.simpleName], + NAME: [Rules.linuxName], }); let loading = false; const paramForm = ref();