-
Notifications
You must be signed in to change notification settings - Fork 32
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
Implemented: code to add functionality to subscribe or unsubscribe a webhook(#2ftb11u) #191
Conversation
…e logic on products view job manager app
…vices for subscription and unsubscription
…gle does'nt switch back to previous state
…tate type to any(#2ftb11u)
… of webhook(#2ftb11u)
…ding action mapping and then using the same when calling the action(#2ftb11u)
…efined a mapping having id and correspoding service(#2ftb11u)
…instead of data property or methods(#2ftb11u)
…e to unsubscribeWebhook and added error handling in the unsubscribe action logic(#2ftb11u)
@@ -0,0 +1,7 @@ | |||
export default interface WebhookState { | |||
cached: any | |||
key: { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could remove this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sir, removed unwanted state
src/views/InitialLoad.vue
Outdated
}), | ||
fileStatusUpdateWebhook(): boolean { | ||
const webhookTopic = this.webhookEnums['BULK_OPERATIONS_FINISH'] | ||
return this.getCachedWebhook[webhookTopic]?.topic === webhookTopic |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we have topic as key, I think we could skip the comparison
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done Sir
…g service methods(#2ftb11u)
src/store/modules/webhook/actions.ts
Outdated
if (resp.status == 200 && resp.data.webhooks?.length > 0 && !hasError(resp)) { | ||
const webhooks = resp.data.webhooks; | ||
const topics: any = {} | ||
webhooks.map((topic: any) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
webhooks.map((topic: any) => { | |
webhooks.map((webhook: any) => { |
Related Issues
Dependent on #178
Closes #175
Short Description and Why It's Useful
Screenshots of Visual Changes before/after (If There Are Any)
IMPORTANT NOTICE - Remember to add changelog entry
Contribution and Currently Important Rules Acceptance