Skip to content
This repository was archived by the owner on Aug 29, 2025. It is now read-only.

Commit ce75209

Browse files
authored
Merge pull request #290 from dinurp/main
Annotations for Admin.Book service
2 parents 8cc2db7 + e838f38 commit ce75209

2 files changed

Lines changed: 6 additions & 1 deletion

File tree

bookshop/srv/admin-service.cds

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,7 @@ service AdminService @(requires:'admin') {
33
entity Books as projection on my.Books;
44
entity Authors as projection on my.Authors;
55
}
6+
7+
//Since ID is computed, we can hide the popup for ID on Create
8+
annotate AdminService.Books with { ID @Core.Computed; }
9+
annotate AdminService.Authors with { ID @Core.Computed; }

fiori/app/admin/fiori-service.cds

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,8 @@ annotate AdminService.Books.texts with @(
8585

8686
// Add Value Help for Locales
8787
annotate AdminService.Books.texts {
88-
locale @ValueList:{entity:'Languages',type:#fixed}
88+
locale @ValueList:{entity:'Languages'};
89+
locale @Common.ValueListWithFixedValues:true; //show as drop down, not a dialog
8990
}
9091
// In addition we need to expose Languages through AdminService as a target for ValueList
9192
using { sap } from '@sap/cds/common';

0 commit comments

Comments
 (0)