@@ -7,9 +7,7 @@ using { TravelService } from '../../srv/travel-service';
77annotate TravelService.Travels with @ UI : {
88
99 Identification : [
10- { $Type : ' UI.DataFieldForAction ' , Action : ' TravelService.acceptTravel ' , Label : ' {i18n>AcceptTravel} ' },
11- { $Type : ' UI.DataFieldForAction ' , Action : ' TravelService.rejectTravel ' , Label : ' {i18n>RejectTravel} ' },
12- { $Type : ' UI.DataFieldForAction ' , Action : ' TravelService.deductDiscount ' , Label : ' {i18n>DeductDiscount} ' }
10+ { $Type : ' UI.DataFieldForAction ' , Action : ' TravelService.deductDiscount ' , Label : ' {i18n>DeductDiscount} ' },
1311 ],
1412
1513 HeaderInfo : {
@@ -34,9 +32,6 @@ annotate TravelService.Travels with @UI : {
3432 ],
3533
3634 LineItem : [
37-
38- { $Type : ' UI.DataFieldForAction ' , Action : ' TravelService.acceptTravel ' , Label : ' {i18n>AcceptTravel} ' },
39- { $Type : ' UI.DataFieldForAction ' , Action : ' TravelService.rejectTravel ' , Label : ' {i18n>RejectTravel} ' },
4035 { $Type : ' UI.DataFieldForAction ' , Action : ' TravelService.deductDiscount ' , Label : ' {i18n>DeductDiscount} ' },
4136
4237 { Value : ID , @ UI . Importance : # High },
@@ -50,8 +45,8 @@ annotate TravelService.Travels with @UI : {
5045 { Value : (Status . code ),
5146 Criticality : (
5247 Status . code == #Accepted ? 3 :
53- Status . code == #Open ? 2 :
54- Status . code == #Canceled ? 1 : 0
48+ Status . code == #Open OR Status . code == # InReview ? 2 :
49+ Status . code == #Canceled OR Status . code == # Blocked ? 1 : 0
5550 ),
5651 @UI.Importance : #High,
5752 @HTML5.CssDefaults: {width:'10em'}
@@ -74,8 +69,8 @@ annotate TravelService.Travels with @UI : {
7469 { Value : (Status.code),
7570 Criticality : (
7671 Status.code == #Accepted ? 3 :
77- Status.code == #Open ? 2 :
78- Status.code == #Canceled ? 1 : 0
72+ Status.code == #Open OR Status.code == #InReview ? 2 :
73+ Status.code == #Canceled OR Status.code == #Blocked ? 1 : 0
7974 ),
8075 },
8176 { Value : BeginDate },
0 commit comments