Fix(booking-controller): Fixed fetching of bookings
All checks were successful
ktm-booking-bot/ktm-booking-bot/pipeline/head This commit looks good

This commit is contained in:
2022-09-27 20:29:46 +08:00
parent 51b539fe7a
commit 0ea75f6211
6 changed files with 61 additions and 31 deletions

View File

@@ -472,13 +472,16 @@ const docTemplate = `{
],
"properties": {
"backToSg": {
"type": "boolean"
"type": "boolean",
"example": false
},
"contact": {
"type": "string"
"type": "string",
"example": "+6512345678"
},
"gender": {
"type": "string"
"type": "string",
"example": "M"
},
"id": {
"type": "string"
@@ -490,16 +493,19 @@ const docTemplate = `{
"type": "string"
},
"passportExpiry": {
"type": "string"
"type": "string",
"format": "date-time"
},
"status": {
"type": "string"
},
"timeCode": {
"type": "string"
"type": "string",
"example": "1300"
},
"travelDate": {
"type": "string"
"type": "string",
"format": "date-time"
}
}
},
@@ -571,12 +577,14 @@ const docTemplate = `{
],
"properties": {
"password": {
"type": "string"
"type": "string",
"example": "password"
},
"username": {
"type": "string",
"maxLength": 100,
"minLength": 2
"minLength": 2,
"example": "user"
}
}
},
@@ -590,12 +598,14 @@ const docTemplate = `{
"password": {
"type": "string",
"maxLength": 100,
"minLength": 6
"minLength": 6,
"example": "password"
},
"username": {
"type": "string",
"maxLength": 100,
"minLength": 2
"minLength": 2,
"example": "user"
}
}
},

View File

@@ -464,13 +464,16 @@
],
"properties": {
"backToSg": {
"type": "boolean"
"type": "boolean",
"example": false
},
"contact": {
"type": "string"
"type": "string",
"example": "+6512345678"
},
"gender": {
"type": "string"
"type": "string",
"example": "M"
},
"id": {
"type": "string"
@@ -482,16 +485,19 @@
"type": "string"
},
"passportExpiry": {
"type": "string"
"type": "string",
"format": "date-time"
},
"status": {
"type": "string"
},
"timeCode": {
"type": "string"
"type": "string",
"example": "1300"
},
"travelDate": {
"type": "string"
"type": "string",
"format": "date-time"
}
}
},
@@ -563,12 +569,14 @@
],
"properties": {
"password": {
"type": "string"
"type": "string",
"example": "password"
},
"username": {
"type": "string",
"maxLength": 100,
"minLength": 2
"minLength": 2,
"example": "user"
}
}
},
@@ -582,12 +590,14 @@
"password": {
"type": "string",
"maxLength": 100,
"minLength": 6
"minLength": 6,
"example": "password"
},
"username": {
"type": "string",
"maxLength": 100,
"minLength": 2
"minLength": 2,
"example": "user"
}
}
},

View File

@@ -57,10 +57,13 @@ definitions:
ktmtrainbot.BookingResponse:
properties:
backToSg:
example: false
type: boolean
contact:
example: "+6512345678"
type: string
gender:
example: M
type: string
id:
type: string
@@ -69,12 +72,15 @@ definitions:
passport:
type: string
passportExpiry:
format: date-time
type: string
status:
type: string
timeCode:
example: "1300"
type: string
travelDate:
format: date-time
type: string
required:
- backToSg
@@ -123,8 +129,10 @@ definitions:
user.UserLoginRequest:
properties:
password:
example: password
type: string
username:
example: user
maxLength: 100
minLength: 2
type: string
@@ -135,10 +143,12 @@ definitions:
user.UserRegisterRequest:
properties:
password:
example: password
maxLength: 100
minLength: 6
type: string
username:
example: user
maxLength: 100
minLength: 2
type: string