File tree 3 files changed +45
-6
lines changed
src/routes/copilotOpportunityApply
3 files changed +45
-6
lines changed Original file line number Diff line number Diff line change @@ -149,7 +149,7 @@ workflows:
149
149
context : org-global
150
150
filters :
151
151
branches :
152
- only : ['develop', 'migration-setup', 'PM-577' ]
152
+ only : ['develop', 'migration-setup']
153
153
- deployProd :
154
154
context : org-global
155
155
filters :
Original file line number Diff line number Diff line change @@ -487,9 +487,9 @@ paths:
487
487
$ref : " #/definitions/ApplyCopilotOpportunity"
488
488
responses :
489
489
" 200 " :
490
- description : " The copilot opportunity"
490
+ description : " The copilot opportunity application "
491
491
schema :
492
- $ref : " #/definitions/CopilotOpportunity "
492
+ $ref : " #/definitions/CopilotOpportunityApplication "
493
493
" 401 " :
494
494
description : " Unauthorized"
495
495
schema :
@@ -6013,6 +6013,46 @@ definitions:
6013
6013
format : int64
6014
6014
description : READ-ONLY. User that last updated this task
6015
6015
readOnly : true
6016
+ CopilotOpportunityApplication :
6017
+ type : object
6018
+ properties :
6019
+ id :
6020
+ description : unique identifier
6021
+ type : integer
6022
+ format : int64
6023
+ notes :
6024
+ description : notes regarding the application
6025
+ type : string
6026
+ opportunityId :
6027
+ description : copilot request id
6028
+ type : integer
6029
+ createdAt :
6030
+ type : string
6031
+ description : Datetime (GMT) when task was created
6032
+ readOnly : true
6033
+ createdBy :
6034
+ type : integer
6035
+ format : int64
6036
+ description : READ-ONLY. User who created this task
6037
+ readOnly : true
6038
+ updatedAt :
6039
+ type : string
6040
+ description : READ-ONLY. Datetime (GMT) when task was updated
6041
+ readOnly : true
6042
+ updatedBy :
6043
+ type : integer
6044
+ format : int64
6045
+ description : READ-ONLY. User that last updated this task
6046
+ readOnly : true
6047
+ deletedAt :
6048
+ type : string
6049
+ description : READ-ONLY. Datetime (GMT) when task was deleted
6050
+ readOnly : true
6051
+ deletedBy :
6052
+ type : integer
6053
+ format : int64
6054
+ description : READ-ONLY. User that deleted this task
6055
+ readOnly : true
6016
6056
Project :
6017
6057
type : object
6018
6058
properties :
Original file line number Diff line number Diff line change @@ -60,9 +60,8 @@ module.exports = [
60
60
} ) ;
61
61
62
62
if ( existingApplication ) {
63
- const err = new Error ( 'User already applied for this opportunity' ) ;
64
- err . status = 400 ;
65
- return next ( err ) ;
63
+ res . status ( 200 ) . json ( existingApplication ) ;
64
+ return Promise . resolve ( ) ;
66
65
}
67
66
68
67
return models . CopilotApplication . create ( data )
You can’t perform that action at this time.
0 commit comments