Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: 模板文件支持展示最新部署及版本列表兼容非语义化版本 #3517

Merged
merged 2 commits into from
Oct 9, 2024

Conversation

LidolLxf
Copy link
Contributor

feat: 模板文件支持展示最新部署及版本列表兼容非语义化版本

@tencentblueking-adm
Copy link

tencentblueking-adm commented Sep 13, 2024

CLA assistant check
All committers have signed the CLA.

Copy link
Contributor

@adevjoe adevjoe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lint 问题处理一下

@@ -279,12 +279,16 @@ func (t *TemplateAction) Create(ctx context.Context, req *clusterRes.CreateTempl
VersionMode: 0,
Version: req.GetVersion(),
IsDraft: req.GetIsDraft(),
LatestVersion: req.GetVersion(),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

改成 LatestDeployVersion

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

部署人改成 LatestDeployer

@@ -212,6 +226,11 @@ func (t *TemplateVersionAction) Create(ctx context.Context, req *clusterRes.Crea
}

userName := ctxkey.GetUsernameFromCtx(ctx)
// 更新最新版本及部署人
updateTemplate := entity.M{
"latestVersion": req.Version,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

db 字段名相应调整

@@ -31,6 +31,7 @@ type TemplateVersion struct {
CreateAt int64 `json:"createAt" bson:"createAt"`
Latest bool `json:"latest" bson:"-"` // 是否是最新版本,不存储在数据库
Draft bool `json:"draft" bson:"-"`
LatestVersion string `json:"latestVersion" bson:"-"`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LatestDeployVersion

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里没添加部署人

@@ -212,6 +229,11 @@ func (t *TemplateVersionAction) Create(ctx context.Context, req *clusterRes.Crea
}

userName := ctxkey.GetUsernameFromCtx(ctx)
// 更新最新版本及部署人
updateTemplate := entity.M{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里是部署版本,不是最新版本,只在部署是更新 latestDeployVersionlatestDeployer

@ifooth ifooth merged commit 2294879 into TencentBlueKing:master Oct 9, 2024
14 checks passed
evanlixin added a commit that referenced this pull request Oct 9, 2024
* github-bk-bcs/master:
  feat: 模板文件支持展示最新部署及版本列表兼容非语义化版本 (#3517)
  fix: 修复创建服务时某个字段为空错误 (#3550)
  feat: 配置示例新增 配置文件筛选功能--story=119697737 (#3544)
  feat: bcs-task manager add ListTask (#3545)
  fix: 上传压缩文件后进度达到100%后没有解压提示--bug=131494557 (#3543)
  fix: 修复批量导入过多文件时报错 (#3541)
  fix: last consumed time默认设置为空 (#3542)
  fix: 同目录下上传2500个文件,页面崩溃 (#3539)
  chore: bcs-task mysql store step message use text type (#3522)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants