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

Using supporters entity #46

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion incidents-app
Submodule incidents-app updated 1 files
+12 −4 db/schema.cds
4 changes: 2 additions & 2 deletions samples/notifications/srv/processor-service.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ module.exports = class ProcessorService extends cds.ApplicationService {
})


const { Customers } = cds.entities
const { Customers, Supporters } = cds.entities
const customer4 = async incident => {
let customer = await SELECT.from (Customers, incident.customer_ID, c => {
c.firstName, c.lastName, c.email
Expand All @@ -53,7 +53,7 @@ module.exports = class ProcessorService extends cds.ApplicationService {
}

// Fake supporters for demo purposes
const supporters4 = () => [ cds.context.user.id ]
const supporters4 = () => SELECT('email').from(Supporters).then(each => each.email)

// return super.init()
}
Expand Down