Skip to content

Commit 0860fd8

Browse files
Merge pull request #2560 from actiontech/fix_audit_plan_list_instance_id
Fix audit plan list instance id loss of precision
2 parents 5fa5cb3 + 1c21c03 commit 0860fd8

File tree

4 files changed

+10
-10
lines changed

4 files changed

+10
-10
lines changed

sqle/api/controller/v1/instance_audit_plan.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,7 @@ type GetInstanceAuditPlansResV1 struct {
437437

438438
type InstanceAuditPlanResV1 struct {
439439
InstanceAuditPlanId uint `json:"instance_audit_plan_id"`
440-
InstanceID uint64 `json:"instance_id"`
440+
InstanceID string `json:"instance_id"`
441441
InstanceName string `json:"instance_name"`
442442
Business string `json:"business"`
443443
InstanceType string `json:"instance_type"`
@@ -527,7 +527,7 @@ func GetInstanceAuditPlans(c echo.Context) error {
527527
inst := dms.GetInstancesByIdWithoutError(v.InstanceID)
528528
resData[i] = InstanceAuditPlanResV1{
529529
InstanceAuditPlanId: v.Id,
530-
InstanceID: inst.ID,
530+
InstanceID: strconv.FormatUint(inst.ID, 10),
531531
InstanceName: inst.Name,
532532
Business: inst.Business,
533533
InstanceType: v.DBType,

sqle/docs/docs.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10306,8 +10306,8 @@ var doc = `{
1030610306
"priority": {
1030710307
"type": "string",
1030810308
"enum": [
10309-
"high",
10310-
"''"
10309+
"",
10310+
"high"
1031110311
]
1031210312
},
1031310313
"remark": {
@@ -13070,7 +13070,7 @@ var doc = `{
1307013070
"type": "integer"
1307113071
},
1307213072
"instance_id": {
13073-
"type": "integer"
13073+
"type": "string"
1307413074
},
1307513075
"instance_name": {
1307613076
"type": "string"

sqle/docs/swagger.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10290,8 +10290,8 @@
1029010290
"priority": {
1029110291
"type": "string",
1029210292
"enum": [
10293-
"high",
10294-
"''"
10293+
"",
10294+
"high"
1029510295
]
1029610296
},
1029710297
"remark": {
@@ -13054,7 +13054,7 @@
1305413054
"type": "integer"
1305513055
},
1305613056
"instance_id": {
13057-
"type": "integer"
13057+
"type": "string"
1305813058
},
1305913059
"instance_name": {
1306013060
"type": "string"

sqle/docs/swagger.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -501,8 +501,8 @@ definitions:
501501
type: array
502502
priority:
503503
enum:
504+
- ""
504505
- high
505-
- ''''''
506506
type: string
507507
remark:
508508
type: string
@@ -2413,7 +2413,7 @@ definitions:
24132413
instance_audit_plan_id:
24142414
type: integer
24152415
instance_id:
2416-
type: integer
2416+
type: string
24172417
instance_name:
24182418
type: string
24192419
instance_type:

0 commit comments

Comments
 (0)