File tree Expand file tree Collapse file tree 6 files changed +37
-10
lines changed
javascript/frameworks/cap/test/models/cds/userdefinedservice Expand file tree Collapse file tree 6 files changed +37
-10
lines changed Original file line number Diff line number Diff line change 1+ const cds = require ( "@sap/cds" ) ;
2+
3+ class Service1 extends cds . ApplicationService { // ES6ApplicationServiceDefinition
4+ init ( ) {
5+ return super . init ( )
6+ }
7+ }
8+
9+ module . exports = Service1
Original file line number Diff line number Diff line change 11const cds = require ( "@sap/cds" ) ;
22
3- class BooksService extends cds . ApplicationService {
4- init ( ) {
5- return super . init ( )
6- }
7- }
8- module . exports = BooksService
9-
103module . exports = class LogService extends cds . Service {
114 init ( ) {
125 return super . init ( )
136 }
14- }
7+ }
Original file line number Diff line number Diff line change 1+ const cds = require ( "@sap/cds" ) ;
2+
3+ module . exports = cds . service . impl ( function ( ) { // ImplMethodCallApplicationServiceDefinition
4+ this . on ( "SomeEvent1" , ( req ) => {
5+ /* ... */
6+ } ) ;
7+ } ) ;
Original file line number Diff line number Diff line change 1+ const cds = require ( "@sap/cds" ) ;
2+
3+ module . exports = cds . service . impl ( ( srv ) => { // ImplMethodCallApplicationServiceDefinition
4+ this . on ( "SomeEvent1" , ( req ) => {
5+ /* ... */
6+ } ) ;
7+ } ) ;
8+
Original file line number Diff line number Diff line change 1+ const cds = require ( "@sap/cds" ) ;
2+
3+ module . exports = ( srv ) => { // ExportedClosureApplicationServiceDefinition
4+ srv . on ( "SomeEvent1" , ( req ) => {
5+ /* ... */
6+ } ) ;
7+ } ;
Original file line number Diff line number Diff line change 1- | userdefinedservice.js:3:1:7:1 | class B ... )\\n }\\n} |
2- | userdefinedservice.js:10:18:14:1 | class L ... )\\n }\\n} |
1+ | service1.js:3:1:7:1 | class S ... )\\n }\\n} |
2+ | service2.js:3:18:7:1 | class L ... )\\n }\\n} |
3+ | service3.js:3:18:7:2 | cds.ser ... });\\n}) |
4+ | service4.js:3:18:7:2 | cds.ser ... });\\n}) |
5+ | service5.js:3:18:7:1 | (srv) = ... });\\n} |
You can’t perform that action at this time.
0 commit comments