format, rename author to authorName

This commit is contained in:
Gregor Wolf
2021-11-12 21:28:23 +01:00
parent d376e6e063
commit 597afeb3d8

View File

@@ -4,47 +4,54 @@ using CatalogService from '@capire/bookshop';
// //
// Books Object Page // Books Object Page
// //
annotate CatalogService.Books with @( annotate CatalogService.Books with @(UI : {
UI: { HeaderInfo : {
HeaderInfo: { TypeName : 'Book',
TypeName: 'Book', TypeNamePlural : 'Books',
TypeNamePlural: 'Books', Description : {Value : authorName}
Description: {Value: author}
}, },
HeaderFacets: [ HeaderFacets : [{
{$Type: 'UI.ReferenceFacet', Label: '{i18n>Description}', Target: '@UI.FieldGroup#Descr'}, $Type : 'UI.ReferenceFacet',
], Label : '{i18n>Description}',
Facets: [ Target : '@UI.FieldGroup#Descr'
{$Type: 'UI.ReferenceFacet', Label: '{i18n>Details}', Target: '@UI.FieldGroup#Price'}, }, ],
], Facets : [{
FieldGroup#Descr: { $Type : 'UI.ReferenceFacet',
Data: [ Label : '{i18n>Details}',
{Value: descr}, Target : '@UI.FieldGroup#Price'
] }, ],
FieldGroup #Descr : {Data : [{Value : descr}, ]},
FieldGroup #Price : {Data : [
{Value : price},
{
Value : currency.symbol,
Label : '{i18n>Currency}'
}, },
FieldGroup#Price: { ]},
Data: [ });
{Value: price},
{Value: currency.symbol, Label: '{i18n>Currency}'},
]
},
}
);
//////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////
// //
// Books Object Page // Books Object Page
// //
annotate CatalogService.Books with @( annotate CatalogService.Books with @(UI : {
UI: { SelectionFields : [
SelectionFields: [ ID, price, currency_code ], ID,
LineItem: [ price,
{Value: title}, currency_code
{Value: author, Label:'{i18n>Author}'}, ],
{Value: genre.name}, LineItem : [
{Value: price}, {Value : title},
{Value: currency.symbol, Label:' '}, {
] Value : authorName,
Label : '{i18n>Author}'
}, },
); {Value : genre.name},
{Value : price},
{
Value : currency.symbol,
Label : ' '
},
]
}, );