This commit is contained in:
Christian Georgi
2022-03-23 20:30:02 +01:00
parent 7f9474244b
commit 1f8a78fe8a
11 changed files with 1872 additions and 45 deletions

View File

@@ -0,0 +1,11 @@
@requires : 'authenticated-user'
service UserService {
@odata.singleton
entity User {
ID : String;
locale : String;
tenant : String;
}
}

View File

@@ -0,0 +1,11 @@
const cds = require('@sap/cds');
module.exports = cds.service.impl((srv) => {
srv.on('READ', 'User', ({ user }) => {
return {
ID: user.id,
locale: user.locale,
tenant: user.tenant,
};
});
});