0% found this document useful (0 votes)
19 views53 pages

Reading

Uploaded by

GuruPrasad Durai
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views53 pages

Reading

Uploaded by

GuruPrasad Durai
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 53

367.book Seite 3 Montag, 3.

Oktober 2011 6:08 18

Thomas Schneider

SAP® Business ByDesign Studio—


Application Development

Bonn  Boston
367.book Seite 5 Montag, 3. Oktober 2011 6:08 18

Contents at a Glance

1 Getting Started .................................................................. 37

2 Architecture Overview ....................................................... 47

3 Business Object Modeling ................................................. 75

4 User Interface .................................................................... 131

5 Business Object Implementation ...................................... 209

6 Business Configuration ...................................................... 267

7 Business Object and User Interface Extensions ................ 285

8 Business Analytics ............................................................. 327

9 Service Integration ............................................................. 355

10 SAP Business ByDesign Platform Objects and Services .... 413

11 Lifecycle Management ....................................................... 435


367.book Seite 7 Montag, 3. Oktober 2011 6:08 18

Contents

Foreword ......................................................................................... 15
About This Book ............................................................................... 17
Introduction ..................................................................................... 21

1 Getting Started ............................................................ 37


1.1 Introducing Site Management ........................................ 37
1.2 Introducing SAP Business ByDesign Studio ..................... 42
1.3 The First Development Project ........................................ 43
1.4 Summary ........................................................................ 46

2 Architecture Overview .................................................. 47


2.1 Architecture Overview .................................................... 47
2.2 Repository ...................................................................... 54
2.3 Business Object Engine ................................................... 56
2.4 User Interface Engine ...................................................... 60
2.5 Search Engine ................................................................. 64
2.6 Integration of Add-ons with SAP Business ByDesign ....... 66
2.6.1 Component Model ............................................. 68
2.6.2 Public Model ..................................................... 71
2.7 Summary ........................................................................ 73

3 Business Object Modeling ........................................... 75


3.1 Introduction to Business Objects .................................... 76
3.2 Defining Business Objects, Nodes, and Associations ....... 79
3.2.1 Defining Business Objects .................................. 79
3.2.2 Defining Business Object Nodes ......................... 80
3.2.3 Defining Object Relationships ............................ 81
3.3 Defining Elements and Data Types .................................. 88
3.3.1 Core Data Type .................................................. 89
3.3.2 Global Data Types .............................................. 90
3.3.3 Important Data Types ........................................ 92
3.4 Adjusting Business Object Data for the User Interface
and Other Consumers ..................................................... 98

7
367.book Seite 8 Montag, 3. Oktober 2011 6:08 18

Contents

3.5 Defining Actions ............................................................. 100


3.5.1 Defining the Status and Action Management ...... 101
3.5.2 Site Reservation: Status and Action Model ......... 103
3.5.3 Defining Actions that Do Not Belong to
Status and Action Management .......................... 110
3.6 Defining Queries ............................................................. 111
3.7 Defining Messages .......................................................... 117
3.8 Example: Sales Order ...................................................... 118
3.9 Naming Conventions and Useful Guidelines .................... 122
3.9.1 Naming Conventions for Business Objects and
Nodes ................................................................ 124
3.9.2 Naming Conventions for Business Object Node
Elements ............................................................ 125
3.9.3 Naming Convention for Data Types .................... 126
3.9.4 Naming Convention for Queries ......................... 127
3.9.5 Order of Elements in a Business Object Node ..... 127
3.9.6 Messages ........................................................... 127
3.10 Summary ........................................................................ 128

4 User Interface ............................................................... 131


4.1 User Interface Fundamentals ........................................... 131
4.1.1 Floorplan Types .................................................. 131
4.1.2 Generation and Configuration of Screens ............ 133
4.1.3 UI Model View ................................................... 137
4.1.4 Data Model ........................................................ 140
4.1.5 Controller ........................................................... 141
4.2 Configuring a Form Pane ................................................. 143
4.2.1 Configuring Field Properties and Action
Properties .......................................................... 143
4.2.2 Adding a User Interface Field or a Button
to a Form ........................................................... 150
4.2.3 Adding and Removing Panes .............................. 153
4.2.4 Configuring the Identification Region ................. 154
4.3 Configuring a List Pane ................................................... 154
4.3.1 Configuring a Preview Pane ................................ 158
4.3.2 Defining Query and Default Set .......................... 159
4.3.3 Configuring Find Form and List Pane Variant ...... 164

8
367.book Seite 9 Montag, 3. Oktober 2011 6:08 18

Contents

4.4 Using Frontend Scripting ................................................ 165


4.4.1 Implementing Dynamic Properties ..................... 166
4.4.2 Filling Data Lists ................................................. 169
4.5 Configuring Object-Based Navigation ............................. 171
4.5.1 Configuring a Create Scenario ............................ 174
4.5.2 Configuring a Show Details Scenario .................. 175
4.5.3 Configuring a Create with Reference Scenario .... 177
4.5.4 OBN Troubleshooting ........................................ 181
4.6 Configuring Work Center and Work Center View ............ 182
4.7 Defining Authorizations .................................................. 185
4.7.1 Authorization Fundamentals .............................. 185
4.7.2 Defining an Authorization Check ........................ 188
4.7.3 Defining an Instance Authorization Check .......... 190
4.7.4 Defining Segregation of Duties ........................... 194
4.8 Configuring Embedded Components ............................... 195
4.9 Mobile User Interfaces .................................................... 201
4.10 Analyzing Issues in User Interfaces .................................. 202
4.11 Summary ........................................................................ 207

5 Business Object Implementation ................................. 209


5.1 SAP Business ByDesign Scripting Language ..................... 209
5.1.1 Scripting Language Syntax Basics ........................ 210
5.1.2 Write Access to Business Objects ....................... 219
5.1.3 Read Access to Business Objects ........................ 226
5.1.4 Messages ........................................................... 232
5.1.5 Functions ........................................................... 233
5.2 Implementing a Business Object—Fundamentals ............ 234
5.2.1 Transaction ........................................................ 234
5.2.2 Locks ................................................................. 237
5.3 Implementing a Business Object—Example ..................... 239
5.3.1 Event: AfterModify ............................................ 239
5.3.2 Action: Check .................................................... 242
5.3.3 Action: Copy ...................................................... 244
5.3.4 Status Action: Release ........................................ 245
5.3.5 Status Action: Start Sales Processing .................. 246
5.3.6 Status Action: Confirm Sales Processing ............. 247
5.3.7 Action: GetAvailableSites ................................... 249

9
367.book Seite 10 Montag, 3. Oktober 2011 6:08 18

Contents

5.3.8 Action: Pick ........................................................ 250


5.3.9 Action: MaintainSalesOrder ................................ 251
5.3.10 Event: BeforeSave ............................................... 255
5.4 Recording and Evaluating a Trace .................................... 256
5.5 Implementing a Number Range ...................................... 260
5.6 Summary ........................................................................ 264

6 Business Configuration ................................................ 267


6.1 Business Configuration Fundamentals ............................. 267
6.1.1 Business Configuration Implementation and
Change Project ................................................... 267
6.1.2 Business Configuration Architecture ................... 269
6.1.3 Business Configuration Use Cases for
Add-On Solutions .............................................. 271
6.2 Defining Business Adaptation Content ............................ 274
6.3 Defining Business Configuration Sets (BC Sets) ................ 278
6.3.1 Business Configuration Sets Based on
New BCOs .......................................................... 278
6.3.2 Business Configuration Sets Based on
BCOs from SAP .................................................. 280
6.4 Defining Scoping Rules ................................................... 281
6.5 Defining an Implementation Project Template ................ 282
6.6 Summary ........................................................................ 283

7 Business Object and User Interface Extensions .......... 285


7.1 Extensibility Fundamentals .............................................. 285
7.2 Adding Extension Fields .................................................. 290
7.2.1 Adding an Extension Field to a
Business Object .................................................. 290
7.2.2 Adding Extension Fields to User Interfaces ......... 293
7.3 Implementing Business Logic Extensions ......................... 297
7.4 Adding Embedded Components and Mashups to User
Interfaces ........................................................................ 302
7.4.1 Adding Embedded Components ......................... 302
7.4.2 Developing a Supplemental Business Object ...... 304
7.4.3 Configuring a Mashup ........................................ 310

10
367.book Seite 11 Montag, 3. Oktober 2011 6:08 18

Contents

7.5 Other User Interface Extensions ...................................... 320


7.5.1 Renaming a Label or Hiding a UI Element .......... 320
7.5.2 Adapting Work Centers ...................................... 321
7.5.3 Adapting Work Center Views ............................. 322
7.6 Summary ........................................................................ 324

8 Business Analytics ........................................................ 327


8.1 Business Analytics Fundamentals .................................... 327
8.2 Defining Basic Data Sources ............................................ 332
8.3 Defining Reports ............................................................ 336
8.3.1 Defining a Report ............................................... 336
8.3.2 Key Figures ........................................................ 337
8.3.3 Characteristics .................................................... 344
8.3.4 Report Assignment ............................................. 345
8.4 Adjusting Business Object Data for Analytics .................. 345
8.5 Defining Joined and Combined Data Sources .................. 346
8.5.1 Defining a Joined Data Source ........................... 347
8.5.2 Defining a Combined Data Source (Union) ......... 350
8.6 Adding Extension Fields to Data Sources and Reports ..... 351
8.7 Summary ........................................................................ 352

9 Service Integration ....................................................... 355


9.1 Output Management ...................................................... 358
9.1.1 Output Management Fundamentals ................... 358
9.1.2 Installing Adobe LiveCycle Designer ................... 360
9.1.3 Creating a Print Form for a
New Business Object ......................................... 361
9.1.4 Adopting Existing Form Templates ..................... 366
9.1.5 Adding Extension Fields to Existing Form
Templates .......................................................... 368
9.1.6 Extending an Existing Form Data Type ............... 369
9.2 Business Task Management ............................................ 370
9.2.1 Business Task Management Fundamentals ......... 370
9.2.2 Implementing an Approval Scenario ................... 372
9.3 Internal Communication ................................................. 378
9.3.1 Internal Communication Fundamentals .............. 378

11
367.book Seite 12 Montag, 3. Oktober 2011 6:08 18

Contents

9.3.2 Defining the Interaction Structure


and Mapping ...................................................... 382
9.3.3 Implementing the Process Integration
Choreography .................................................... 388
9.3.4 Defining the Conflict and Error Handling and
Monitoring ......................................................... 394
9.3.5 Adding Extension Fields to an Existing Process
Integration ......................................................... 397
9.4 External Web Services ..................................................... 398
9.4.1 Defining an External Web Service ....................... 399
9.4.2 Defining Authorizations for a Web Service ......... 400
9.4.3 Using Web Services ............................................ 403
9.4.4 Implementing Conflict and Error Handling .......... 407
9.5 File Input ........................................................................ 409
9.6 Summary ........................................................................ 410

10 SAP Business ByDesign Platform Objects and


Services ........................................................................ 413
10.1 SAP Business ByDesign Platform Overview ...................... 413
10.2 Business Partner, Organizational Unit, Party,
and Identity .................................................................... 417
10.2.1 Business Partner ................................................. 417
10.2.2 Organizational Unit ............................................ 419
10.2.3 Party .................................................................. 422
10.2.4 Employee and Manager Assignment ................... 422
10.2.5 Identity .............................................................. 424
10.2.6 Summary ............................................................ 424
10.3 Reuse Services for Address, Text, and Attachment .......... 425
10.3.1 Managing Addresses .......................................... 425
10.3.2 Managing Texts .................................................. 428
10.3.3 Managing Attachments ...................................... 430
10.4 Cost Objects ................................................................... 431
10.5 Summary ........................................................................ 433

12
367.book Seite 13 Montag, 3. Oktober 2011 6:08 18

Contents

11 Lifecycle Management ................................................. 435


11.1 Preparation Phase ........................................................... 436
11.1.1 Getting Detailed Information on
SAP Business ByDesign and SAP Business
ByDesign Studio ................................................. 436
11.1.2 Deciding on the Solution Type ........................... 438
11.1.3 Designing a Solution .......................................... 440
11.1.4 Installing SAP Business ByDesign Studio ............. 441
11.1.5 Creating Users and Test Data ............................. 442
11.2 Development Phase ........................................................ 445
11.2.1 Creating a Solution ............................................ 445
11.2.2 Getting Support ................................................. 445
11.3 Deployment Phase ......................................................... 447
11.3.1 Testing the Solution (Test Deployment) ............. 449
11.3.2 Quality Review .................................................. 450
11.3.3 Listing the Solution in the SAP Store .................. 451
11.3.4 Deploying Customer-Specific Solutions .............. 453
11.4 Operation and Support Phase ......................................... 454
11.4.1 Purchasing and Activating a Solution ................. 454
11.4.2 Working with Customer Incidents ...................... 455
11.5 Continuous Improvement Phase ..................................... 456
11.6 Summary ........................................................................ 458

Appendices ......................................................................... 461


A Information Sources .................................................................. 461
B Glossary .................................................................................... 469

Index ................................................................................................ 475

13
367.book Seite 234 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

왘 Context
Provides context information, such as the current time in the time
zone of the user, the language, or the Identity UUID of the user that is
currently logged on.
왘 Date, GlobalDateTime, LocalDateTime, Duration
Contain functions for comparing and for simple calculations and
some other useful functionality for dates, global and local time points,
and durations.
왘 CurrencyConversion, QuantityConversion
Contain functions for simple calculations, for comparing and for con-
verting currency-based amounts and quantities.
왘 Numeric, Boolean, ID, Code, UUID, Binary
Provide functions such as a check if a value is initial and a conversion
to/from string.

5.2 Implementing a Business Object—Fundamentals


In a multiuser IT system, many users can simultaneously read the con-
tents of business objects. However, for changes to the dataset, you must
ensure that only one user at a time can change a particular object’s con-
tent consistently. For this purpose, content is managed in a transaction.
Transactions process data compliant with the ACID principles (atomic-
ity, consistency, isolation, and durability) over multiple user interaction
steps.

5.2.1 Transaction
A transaction consists of two phases: During the interaction phase, data
is retrieved and entered, and actions are executed on the business
object. In the save phase, the system performs last determinations and
checks and writes the changed data to the database.

Interaction phase Figure 5.1 shows the process flow of user activities that are triggered in
the interaction phase. If the UI triggers a query, the data is read directly
from the database and search engine. For a retrieve operation, the busi-
ness object buffer is checked first, before data is retrieved from the data-
base and search engine.

234
367.book Seite 235 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Fundamentals 5.2

If data is changed via an action triggered by the UI, the business object
framework acquires a lock for the business object instance, and the
AfterModify and/or the action coding is processed. The AfterModify
event is processed after an action if the coding of the action changed
data of the business object. If data is changed on the UI and an action is
triggered, the AfterModify event is called before and after the action
coding.

Business Object Engine


User Interface Database and
BO-specific Service Engine
(Service Consumer) Framework Search Engine
Implementation

Retrieve
or Query
Check Buffer
(Retrieve)
Retrieve
or Query
Change Buffer
(Retrieve)
Display Data

Change Data,
or Action
Acquire Lock

Change Buffer
After Modify,
or Action
Change Buffer
Display Data

Figure 5.1 Sequence Diagram for a Transaction, Part 1: Interaction Phase

Figure 5.2 shows the save phase of a transaction’s lifecycle. In the Before- Save phase
Save event, business objects can still call other services that may change
the state.

The CheckBeforeSave event performs all checks required to ensure data


consistency from the business point of view. At this point in the save
phase, to ensure a consistent view for all checks, no further changes are
allowed. The service provider can either accept or reject the request. The
result of CheckBeforeSave is that either all changes are released, which

235
367.book Seite 236 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

allows them to be written to the database, or the save process is inter-


rupted. If any check is unsuccessful, the entire save process is stopped
and error handling is started. However, an error does not abort the
transaction. The business object framework sets the transaction back
into a state in which user interaction can be accepted once again.

We recommend using the option to stop the save sequence with care
and only in cases of a severe inconsistency. Instead, a business object
should be saved even in an inconsistent, draft, or “prima nota” status.

Business Object Engine


User Interface Database and
BO-specific Service Engine
(Service Consumer) Framework Search Engine
Implementation

Save

Loop at Objects

BeforeSave

Loop at Objects
CheckBeforeSave
Save Not
Possible Loop at Objects
Outbound Processing:
Display Error Loop at Objects
Message
Condition Evaluation
Outbound Processing:
Compile XML Messages
Trigger Database Save
Save and
Commit
Release Locks
Data Saved

Figure 5.2 Sequence Diagram for a Transaction, Part 2: Save Phase

Events The business object framework provides the following events that can
be implemented with script coding:

왘 Determination event AfterModify


This event is executed whenever a consumer call or an action modi-
fies a business object, in particular, if a business object node is cre-
ated, updated, or deleted. In this event determination logic is imple-

236
367.book Seite 237 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Fundamentals 5.2

mented, for example, the calculation of default values and consis-


tency checks.
왘 Action event
For each application-specific action an event is provided for the
implementation of action-specific validations (action precondition)
and result determination.
왘 Determination event BeforeSave
This event is executed whenever a consumer calls the save operation
of a business object. In this event determination logic can be imple-
mented before the business object is saved on the database. In this
event modifications to the own business object and to other business
objects are possible.
왘 Validation event CheckBeforeSave
This event is executed as part of the save sequence after the Before-
Save determination event and before the business objects are saved
on the database. In this event validation logic can be processed and
the save sequence can be stopped and messages can be raised. The
CheckBeforeSave event is not released for business objects created
with SAP Business ByDesign studio in version 3.0.

It is possible to enable script files for mass-processing. For mass-enabled


script files the this operator represents a collection of business object
node references. The decision about if a script file will be mass-enabled
has to be made when the script file is created. To create a mass-enabled
script file the mass-enabled indicator has to be set in the script file cre-
ation dialog. This indicator can only be set during the creation of the
script file; later on this decision cannot be changed.

5.2.2 Locks
Locks are required to ensure that only one user at a time can change a
particular objects’ content consistently.

To book a vacation, you must check that all necessary components are Example
available: flights, hotels, bus or boat transfers, and so on. The “all or
nothing” principle applies: If no flights are available, you will not need
a hotel room and so on. Since you usually check the availability of the
various components one after the other, you want to be certain that

237
367.book Seite 238 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

another user doesn’t change any of the items in the sequence before the
entire booking is completed.

Database locks When we are talking about transactions and locks in this section, we
refer to transactions and locks that are managed by the business object
engine of SAP Business ByDesign. The database system also manages
transactions and locks, but these are only used during a very short time
frame when the business object engine saves the business object
changes on the database in the save phase. Database locks are never used
to lock objects through several user interaction steps.

Application locks To lock business object instances through several user transaction steps,
the business object engine of SAP Business ByDesign manages locks
using a central lock server (also called enqueue server) that serves lock
requests for all application servers.

Rules for The following rules apply for transaction and lock handling:
transaction and
lock handling 왘 Queries are always directly served by the database and search engine.
Changes that are made on the business object buffer are not reflected
in the result of a query. This rule applies not only for different trans-
actions, but also within a transaction.
왘 Object-based navigation opens a new transaction. Data that has not
been saved on the database is not visible in the new transaction. In
the site reservation example, a sales order is created when the site res-
ervation is released. If you open the sales order link without saving
the site reservation first, the newly created sales order is not found;
the sales order UI will not terminate but will be empty. You can avoid
this behavior, which users might recognize as an error: Using fron-
tend scripting in the UI allows you to dynamically deactivate the link
if the site reservation is not saved.
왘 The lock behavior is determined by the UI:
왘 The default lock behavior for UIs is the optimistic locking. Objects
are locked as soon as the first round-trip with changed data is pro-
cessed. Opening an object in edit mode does not lock an object. If
you open a site reservation by clicking Edit on the object work
list, it is not yet locked. If you or a second user opens the same
reservation and changes data, the lock will be granted to the sec-
ond transaction. If you as the first user, having opened the site

238
367.book Seite 239 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

reservation without changing it, try to change the object now, the
lock handler raises an error.
왘 You can also set the lock behavior in the UI (property LockBehav-
ior of a data list) to “exclusive.” In this case, the lock will be set as
soon as the object is read the first time.
왘 If the lock behavior in the UI is set to “read-only,” no change locks
are set and therefore no change operations can be performed.
왘 Locks are set on the object level. If a site reservation is locked, you
cannot add a new instance of the subnode Additional Services from
another transaction. There are some exceptions to this rule for SAP-
delivered business objects.

5.3 Implementing a Business Object—Example


This section explains how to implement the event coding for a business
object for the site management example.

5.3.1 Event: AfterModify


Let’s have a look at the AfterModify event of the Site Reservation busi-
ness object:

import ABSL;
// initialization sequence
if ( this.ReleaseStatusCode.IsInitial()) {
this.ReleaseStatusCode = "1";
this.SalesProcessingStatusCode = "1";

if ( this.OriginSiteReservationID.IsInitial() ) {
// (1) normal creation (no copy)
this.ArrivalDate = Context.GetCurrentUserDate();
this.DepartureDate = this.ArrivalDate.
AddDuration(Duration.ParseFromString("P1D"));
}
else {
// (2) Copy
this.Copy();
}
}

239
367.book Seite 240 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

// (3) call check action


this.Check();
// (4) update sales order
if ( this.ConsistencyStatusCode == "3" && (
this.SalesProcessingStatusCode == "2" ||
this.SalesProcessingStatusCode == "5" )) {
this. MaintainSalesOrder();
}
// (5) set name
this.Name = "Reservation: ".
Concatenate(this.ArrivalDate.ToString());
if ( this.ToAccount.IsSet() ) {
this.Name = this.Name.Concatenate(this.ToAccount.
CurrentCommon.BusinessPartnerFormattedName);
}
// (6) set UI status
switch (this.ReleaseStatusCode) {
case "1" {
switch (this.ConsistencyStatusCode) {
case "2" {this.SiteResStatusCode.content = "1"; }
case "3" {this.SiteResStatusCode.content = "2"; }
default {}
}
}
case "3" {
< ... >
}
case "5" {this.SiteResStatusCode.content = "9"; }
default {}
}

Listing 5.8 Implementation of the AfterModify Event (Excerpt)

The coding starts with the import of the namespaces of the SAP Business
ByDesign Scripting Language tools library (import ABSL).

The next coding part is the initialization sequence. It starts with the
statement if (this.ReleaseStatusCode.IsInitial()) and continues
with statements for setting the default values for the status variables.

Copy sequence In Section 4.5.3, “Configuring a Create With Reference Scenario,” we


describe the implementation the UI part of the copy use case. For a
copy, the element OriginSiteReservationID is filled. The statement if (

240
367.book Seite 241 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

this.OriginSiteReservationID.IsInitial() ) checks if OriginSite-


ReservationID is filled. If this is the case, the coding continues with the
else statement, followed by the execution of the Copy action in the Site
Reservation business object 2.

If OriginSiteReservationID is not filled, the coding continues with the


regular initialization sequence 1 and sets default values for arrival and
departure date.

After the initialization sequence, the coding calls the Check action 3. It Checks
is assumed that every business object has a basic set of checks. During
modify, all “local” checks are performed on the nodes that are changed
or change as a side effect. However, checks that are performance critical
are usually not performed in this event. These checks are usually per-
formed in a separate Check action, for example, before an object is
released. In our example, we do not distinguish between performance-
critical and non-critical checks. The Check action is executed in every
AfterModify event.

If the site reservation is consistent and the sales process is in process or


interrupted, the sales order is updated 4.

The next coding block 5 sets the name of the site reservation. The last
part of the coding 6 determines the SiteReservationStatus (also intro-
duced as UI status in Section 3.5.2; see also Table 3.1).

Before Image
The implementation of the AfterModify event as presented in Listing 5.8 has
two disadvantages:

왘 “Expensive” activities, such as the Check action and the update of the sales
order (MaintainSalesOrder action) are executed even if the relevant
input data did not change. This may lead to a performance impact.
왘 The business object itself cannot reject input data, such as a change of the
arrival and departure date after the confirmation of the reservation.

To overcome these disadvantages, you may implement a before image of the


site reservation. In the current version of SAP Business ByDesign studio, this is
not a supported feature. Therefore, you have to implement it using the fol-
lowing workaround:

241
367.book Seite 242 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

1. Define business elements for all input fields that are relevant for the before
image (in our example, for arrival and departure data, site ID, and account
ID).

2. In the AfterModify event, compare the “current” elements with the before
image elements (if (this.ArrivalDate != this.ArrivalDateBe-
fore)). If the current image and the before image are equal, no action has
to be taken. If they differ, the implementation must:

– Call the Check and the MaintainSalesOrder actions.


– Check if the SalesProcessingStatus is already completed. Because in this
case no change to the site reservation is allowed, overwrite the ele-
ments of the current image with the before image and raise an error
message.

5.3.2 Action: Check


The following listing shows the implementation of the Check action.

import ABSL;
import AP.FO.BusinessPartner.Global;
var qySiteRes = SiteReservation.QueryByElements;
var selParSiteRes = qySiteRes.CreateSelectionParams();
var found;
var customer;
// (1) set default: consistency status = Consistent (3)
this.ConsistencyStatusCode = "3";
// (2) check date
if ( this.ArrivalDate.IsInitial() ||
this.DepartureDate.IsInitial() ||
this.ArrivalDate.GreaterEquals(this.DepartureDate)) {
this.ConsistencyStatusCode = "2";
raise NoValidPeriod.Create("E");
}
// (3) check site
if ( !this.ToSite.IsSet() ) {
this.ToSite.Reset();
this.ConsistencyStatusCode = "2";
raise NoValidSite.Create("E");
}
// (4) map & check account
if ( !this.MaintenanceIndicator ) {

242
367.book Seite 243 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

found = false;
if (this.AccountID != "") {
customer = Customer.Retrieve(this.AccountID);
if (customer.IsSet()) {
this.ToAccount = customer; found = true;
}
else {
this.ToAccount.Reset(); found = false;
}
}
else {
this.ToAccount.Reset();
}
}
if ( this.AccountID == "" || !found ) {
this.ConsistencyStatusCode = "2";
raise NoValidAccount.Create("E");
this.AccountID = "";
}
// (5) check site availability
if ( this.ConsistencyStatusCode == "3" ) {
selParSiteRes.Add(qySiteRes.ToSite, this.ToSite);
selParSiteRes.Add(qySiteRes.ReleaseStatusCode, "I", "EQ",
"3");
selParSiteRes.Add(qySiteRes.ArrivalDate, "E", "GE",
this.DepartureDate);
selParSiteRes.Add(qySiteRes.DepartureDate, "E", "LE",
this.ArrivalDate);
selParSiteRes.Add(qySiteRes.ID, "E", "EQ", this.ID);
if (qySiteRes.Execute(selParSiteRes).Count() > 0){
this.ConsistencyStatusCode = "2";
raise SiteAlreadyReserved.Create("E");
}
}

Listing 5.9 Implementation of the Check Action (Excerpt)

The coding starts with imports of the namespaces of the SAP Business
ByDesign Scripting Language tools library (import ABSL) and of the SAP
business partner and identity management. The next lines are defini-
tions of the required variables.

243
367.book Seite 244 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

In section 1, the consistency status is set to “Consistent (3).” If inconsis-


tent behavior of the business object instance is detected by the subse-
quent coding, the value will change to “Inconsistent (2).”

Check of arrival The next part of the coding 2 checks if arrival and departure data are
and departure data entered correctly.

Site ID check The following coding block 3 is the ID check for the site. The business
object Site exposes a human-readable ID as an alternative key. This
means the association to the site can be set directly by the consumer, by
exposing the element SAP_ToSite as an input field on the UI. The valida-
tion of the input is done by the statement if (this.ToSite.IsSet()).
This statement checks if a site with the ID that has been specified in the
input field really exists. If not, the association ToSite is cleared and a
message is raised.

Account ID check The next coding block 4 is the ID mapping and check for the account.
Please look at the differences between this coding block and the previ-
ous check for the site: The human-readable ID of the Customer business
object (InternalID) is not exposed as a stable alternative key, so it can-
not be used to define the association directly. Instead, a separate ele-
ment (AccountID) is used as an input field on the UI that contains the
human-readable ID of the account. In the coding the input needs to be
verified. For this purpose, a Retrieve is performed. If a result is found,
the association to the respective instance of the customer business
object is set. If no matching customer is found, the element AccountID is
cleared and a message is raised.

Site Availability The last coding block 5 checks if a selected site is actually free. The cod-
Check ing is very similar to the coding used in the action GetAvailableSites.
We will explain this coding in the section on this action below (see Sec-
tion 5.3.5, “Status Action: Start Sales Processing“).

5.3.3 Action: Copy


The copy action performs a Retrieve operation to read the origin site
reservation and copies the account ID and arrival date and time to the
new site reservation:

var originSiteRes =
SiteReservation.Retrieve(this.OriginSiteReservationID);

244
367.book Seite 245 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

if (originSiteRes.IsSet()) {
this.AccountID = originSiteRes.AccountID;
this.ArrivalDate = originSiteRes.ArrivalDate;
this.DepartureDate = originSiteRes.DepartureDate;
}
else {
// code block: error handling
<...>
}

Listing 5.10 Implementation of the Copy Action (Excerpt)

5.3.4 Status Action: Release


The implementation of an action consist of two parts: The first part
checks the preconditions of the action. If the preconditions are not met,
the second part, which contains the execution of the action, is skipped.

The implementation of the Release action of the Site Reservation busi- Release action
ness object is very simple. It looks like:

var preconditionOkay = false;


// (1) check precondition
if ( this.ConsistencyStatusCode == "3" &&
this.ReleaseStatusCode == "1" ){
preconditionOkay = true;
}
if ( preconditionOkay ) {
// (2) execute action
this.ReleaseStatusCode = "3"; // Released
}
else {
// (3) raise messages
if ( this.ConsistencyStatusCode != "3" ) {
this.Check();
}
if ( this.ReleaseStatusCode != "1" ) {
raise ReservationAlreadyReleased.Create("E");
}
}

Listing 5.11 Implementation of the Release Action

245
367.book Seite 246 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

The precondition check 1 evaluates the values of the consistency and the
release status as defined in the status and action model (Chapter 3, Figure
3.5). In the second (execution) part 2, the release status is set to
“Released (3).” If the precondition is not fulfilled, appropriate error mes-
sages have to be raised. If the site reservation is not consistent, the easiest
solution is to execute the Check action, which will raise the appropriate
error message. If the release status is not “Released,” an appropriate mes-
sage has to be defined.

5.3.5 Status Action: Start Sales Processing


StartSales- The following listing shows the coding of the StartSalesProcessing
Processing action action:

var preconditionOkay = false;


// (1) check precondition
if ( this.SalesProcessingStatusCode == "1" &&
this.ReleaseStatusCode == "3" ){
preconditionOkay = true;
}
if ( preconditionOkay ) {
// (2) execute action
if ( this.MaintenanceIndicator == true ) {
this.SalesProcessingStatusCode = "4"; // Not relevant
}
else {
this.MaintainSalesOrder();
if ( !this.ToSalesOrder.IsSet() ) {
this.SalesProcessingStatusCode = "5"; //Interrupted
}
else {
this.ToSalesOrder.Release();
if ( this.ToSalesOrder.Status.ConsistencyStatusCode
!= "3" ||
this.ToSalesOrder.Status.ReleaseStatusCode
!= "3" ) {
this.SalesProcessingStatusCode = "5";
//Interrupted
}
else {

246
367.book Seite 247 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

this.SalesProcessingStatusCode = "2";
// In process
}
}
}
}
else {
// (3) raise messages
< ...>
}

Listing 5.12 Implementation of StartSalesProcessing Action

The action evaluates the preconditions as defined in the status and


action model in Chapter 3, Figure 3.5.

If the preconditions are fulfilled, the action implementation checks if the


reservation is made for site maintenance. If yes, it sets the sales process-
ing status to “Not Relevant.” No sales order is created in this case. If no,
a sales order is created or updated by calling the MaintainSalesOrder
action and released by calling the Release action on the Sales Order. If
the creation and release is successful, the sales processing status is set to
“In Process.” If an error occurs, the status goes to “Interrupted.”

If the preconditions are not fulfilled, error messages must be provided.

5.3.6 Status Action: Confirm Sales Processing


The following listing shows the ConfirmSalesProcessing action: ConfirmSales-
Processing action
var preconditionOkay = false;
// (1) check precondition
if ( ( this.SalesProcessingStatusCode == "2" ||
this.SalesProcessingStatusCode == "5" ) &&
this.ReleaseStatusCode == "3" ){
preconditionOkay = true;
}
if ( preconditionOkay ) {
// (2) execute action
if ( !this.ToSalesOrder.IsSet() ) {
this.SalesProcessingStatusCode = "5"; // Interrupted
}

247
367.book Seite 248 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

else {
this.MaintainSalesOrder();
this.ToSalesOrder.
FinishFulfilmentProcessingOfAllItems();
if ( this.ToSalesOrder.Status.ConsistencyStatusCode !=
"3" || this.ToSalesOrder.Status.
ItemListFulfilmentProcessingStatusCode != "3" ) {
this.SalesProcessingStatusCode = "5";
// Interrupted
}
else {
this.SalesProcessingStatusCode = "3"; // Finished
}
}
if ( this.SalesProcessingStatusCode == "5" ) {
raise SalesOrderCreationError.Create("E");
}
}
else {
// (3) raise messages
< ...>
}

Listing 5.13 Implementation of ConfirmSalesProcessing Action

The action implementation updates the sales order by calling the action
MaintainSalesOrder and calls the action FinishFulfilmentProcessing-
OfAllItems on the Sales Order. This action sets the fulfillment process-
ing status of all items in the sales order to “Finished.” If the processing
was successful, the sales processing status of the site reservation is set to
“Finished,” too. If an error occurs, the status is set to “Interrupted.”

Implementation In Section 3.5, “Defining Actions,” we have already differentiated


pattern for status between requiring preconditions, enabling preconditions, and inhibit-
actions
ing preconditions. The different preconditions can be translated into
coding using the following pattern:

var preconditionOkay = false;


// check precondition
if ( < requiring precondition 1 > &&
< requiring precondition 2 > &&
...
< requiring precondition n > &&

248
367.book Seite 249 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

( ! < inhibiting precondition 1 > ) &&


( ! < inhibiting precondition 2 > ) &&
...
( ! < inhibiting precondition n > ) &&
( < enabling precondition 1 > ||
< enabling precondition 2 > ||
...
< enabling precondition n > ) ) {
var preconditionOkay = true;
}

Listing 5.14 Implementation Pattern for Prerequisites

5.3.7 Action: GetAvailableSites


The actions GetAvailableSites, Pick, and MaintainSalesOrder are not
related to the status and action model.

The action GetAvailableSites fills the node Available Site based on the
arrival and departure date specified in the site reservation:

import ABSL;
var allSites;
var reservations;
var newSite;
var qySiteRes = SiteReservation.QueryByElements;
var selParSiteRes = qySiteRes.CreateSelectionParams();
var found;
// (1) check date
if ( this.ArrivalDate.IsInitial() ||
this.DepartureDate.IsInitial() ||
this.ArrivalDate.GreaterEquals(this.DepartureDate)) {
raise NoValidPeriod.Create("E"); }
else {
// (2) delete AvailableSites nodes
foreach ( site in this.AvailableSites ) {
site.Delete();
}
// (3) get all sites
allSites = Site.QueryByElements.Execute();
// (4) get all reservations in booking period
selParSiteRes.Add(qySiteRes.ReleaseStatusCode, "I", "EQ",
"3");

249
367.book Seite 250 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

selParSiteRes.Add(qySiteRes.ArrivalDate, "E", "GE",


this.DepartureDate);
selParSiteRes.Add(qySiteRes.DepartureDate, "E", "LE",
this.ArrivalDate);
selParSiteRes.Add(qySiteRes.ID, "E", "EQ", this.ID);
reservations = qySiteRes.Execute(selParSiteRes);

foreach ( site2 in allSites ) {


found = false;
// check if site is already booked
foreach ( reservation in reservations ) {
if ( reservation.ToSite.IsSet() ){
if ( site2.ID == reservation.ToSite.ID ) {
found = true; break;
}
}
}
if ( !found ) {
newSite = this.AvailableSites.Create();
newSite.SiteID = site2.ID;
newSite.ToAvailableSite = site2;
}
}
}

Listing 5.15 Implementation of GetAvailableSites Action (Excerpt)

After checking the validity of the date period 1, the next coding block
2 deletes the instances of the Available Site node.

The availability check follows. The first step of the availability check
(coding block 3) reads all sites into the variable allSites. The next step
4 checks for released site reservations in the time period between the
arrival and the departure date. If no reservation is found, the site is free
and is added to the node Available Site.

5.3.8 Action: Pick


The Pick action, which is defined on the Available Site node, ensures the
transfer of the ID of a selected site from the list of available sites to the
root node of the site reservation. It consists of exactly one line:

this.ToParent.ToSite = this.ToAvailableSite;

250
367.book Seite 251 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

This statement makes use of the ToParent association, which is implic-


itly defined on every subordinate node. It transfers the site that is
selected from the Available Site node to the association ToSite on the
root level of the Site Reservation.

5.3.9 Action: MaintainSalesOrder


The action MaintainSalesOrder is used to create or modify a sales order
based on the data of the site reservation. The code consists of two
branches: The first branch creates a sales order. The second branch is
executed if a sales order is already associated; it ensures the update of
the sales order.

import ABSL;
import AP.CRM.Global;
var elSO : elementsof SalesOrder;
var newSO;
var newSOItem;
var elSOItem : elementsof SalesOrder.Item;
var quantity;
// (1) check if consistent
if ( this.ConsistencyStatusCode == "3" &&
( this.SalesProcessingStatusCode == "1" ||
this.SalesProcessingStatusCode == "2" ||
this.SalesProcessingStatusCode == "5" ) &&
!this.MaintenanceIndicator ) {
// (2) check service product
if ( this.ToSite.ToSiteCategory.IsSet() ) {
if ( this.ToSite.ToSiteCategory.
ToDefaultServiceProduct.IsSet()) ){
// (3) check if SO is already created
if ( !this.ToSalesOrder.IsSet() ) {
// (4) create sales order
elSO.Name.content = this.Name;
newSO = SalesOrder.Create(elSO);
if ( newSO.IsSet() ) {
this.ToSalesOrder = newSO;
raise SalesOrderCreated.Create("S",
this.ToSalesOrder.ID);
// (5) party node is created automatically
// – maintain buyer party (account)

251
367.book Seite 252 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

newSO.BuyerParty.PartyKey.PartyID.content =
this.AccountID;
// (6) create item node, enter item product
elSOItem.Description.content = "MAIN";
newSOItem=this.ToSalesOrder.Item.Create(elSOItem);
newSOItem.ItemProduct.ProductKey.ProductID.content
= this.ToSite.ToSiteCategory.
ToDefaultServiceProduct.InternalID.content;
// (7) enter quantity
if ( newSOItem.
FirstRequestedItemScheduleLine.IsSet()) {
quantity = Date.Delta(this.DepartureDate,
this.ArrivalDate).ConvertToDays();
newSOItem.FirstRequestedItemScheduleLine.
Quantity.content = quantity;
}
// (8) enter service duration
if (newSOItem.ItemServiceTerms.IsSet()){
newSOItem.ItemServiceTerms.
ServicePlannedDuration = Duration.
ParseFromString( (quantity * 24).ToString());
}
}
}
else {
// (9) update existing sales order
<...>
}
// (10) check the sales order´s consistency
if ( this.ToSalesOrder.Status.ConsistencyStatusCode
!= "3") {
raise SalesOrderCreationError.Create("E");
}
}
}
else {
// (11) raise error msg: no service product / resource
}
}
else {
// (12) raise error msg: site reservation not consistent
}

Listing 5.16 Implementation of the MaintainSalesOrder Action (Excerpt)

252
367.book Seite 253 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

The initial if clause 1 checks the consistency and the sales processing Initial checks
status of the site reservation. If the object is not consistent or the sales
processing is already completed, the remaining coding is not processed.
It also checks 2 that the category of the selected site is set and has a ser-
vice product and a resource assigned, which is required to fill the sales
order, and that the site reservation is not created for maintenance pur-
poses.

Note
Please note that for a statement with chained associations
(<...>.ToSite.ToSiteCategory.ToDefaultServiceProduct.<...>) you
have to check the existence of the association at runtime on each level. If one
of the associations is not set, the program will terminate. The IsSet method
checks the existence of only the last association in the chain.

The statement if ( newSalesOrder.IsSet() ) 3 opens the two branches Five steps of Sales
(code blocks 4 and 9) for creation and update of the sales order. The Order creation

creation of the sales order consists of five steps:

1. Creation of the sales order 4


Before creating the sales order, we fill the structure elSO to hand over
the name of the sales order in the Create operation.
2. Enter account 5
On creation of the sales order, the service provider class of the Sales
Order automatically creates subnodes, for example, the Party node.
The account, which is called Buyer in the Sales Order, is entered into
the Party node using the association BuyerParty (see also Section 3.8,
“Example: Sales Order”).
3. Create the Item node and enter service product 6
On creation of the Item node, the subnode Item Product is automati-
cally created. The service product that is assigned to the site category
of the selected site is entered into this node.
4. Enter quantity 7
On creation of the Item node, the subnode Item Schedule Line is cre-
ated. The association FirstRequestedItemScheduleLine is used to fill
the quantity, which is calculated from the booking period.

253
367.book Seite 254 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

5. Enter service duration 8


On creation of the Item node, the subnode Item Service Terms is auto-
matically created. The service duration is entered into this node.

Note
You can see from this example that the business object service provider auto-
matically creates subnode instances on creation of a super-ordinate node
instance, in our example, the Party, the Item Product and the Item Schedule
Line node. In this case you must not create these node instances with a Cre-
ate operation—this would lead to a corrupt object. On the other hand, you
need to check if the expected instance is really created using the IsSet oper-
ation on the association. In case of an error, the service provider may not cre-
ate the subnode instance automatically. Accessing a nonexistent node
instance from your coding will lead to a program termination.

Sales Order update The update branch 9, which is not shown in the listing, consists of three
steps:

1. Synchronization of the account (buyer)


If the account changes in the site reservation, the buyer is changed in
the sales order.
2. Synchronization of the service product
If the site category and the related service product change in the site
reservation, the service product is changed in the sales order.
3. Synchronization of the quantity
If the booking period changes in the site reservation, the quantity is
changed in the sales order.

Finally the action checks the consistency of the sales order j. If the sales
order is not consistent, the sales processing status is set to error status 5
(Interrupted) and messages are raised k, l.

Master Data Maintenance


The creation and processing of a sales order requires only very few input data
(account, product, and quantity). However, some master data are a prerequi-
site for the successful creation and processing of a sales order.

For the account, maintain the following data:

254
367.book Seite 255 Montag, 3. Oktober 2011 6:08 18

Implementing a Business Object—Example 5.3

왘 Communication: Address (minimum required: country, zip code)


왘 Relationship: Employee Responsible
왘 Sales Data: Sales Organization with distribution channel, incoterms (e.g.,
Free on board), payment terms (e.g., Payable immediately due net), cur-
rency
왘 Financial Data: Company and Account Determination Group (Domestic,
third party)

For the service product, maintain the following data:

왘 Sales Data: Item Group (Service—fixed price without actuals)


왘 Create a price list and assign the service to the list

The booking period must be open (see work center General Ledger, function
Open and Close Booking Periods).

The action FinishFulfilmentProcessingOfAllItems confirms the service


delivery and starts the invoice processing. The sales order appears in the
Invoice Requests view of the Customer Invoicing work center. A background
job will automatically create an invoice. Alternatively, you can trigger the
invoice in the Invoice Requests view manually.

5.3.10 Event: BeforeSave


The BeforeSave event is processed as part of the save sequence that is
triggered whenever a consumer of a business object calls the save oper-
ation. It allows modifications to business objects before the data are per-
sisted on the database.

import ABSL;
import AP.PC.IdentityManagement.Global;
var identity;
var datetime;
// (1) delete AvailableSites nodes
foreach ( site in this.AvailableSites ) {
site.Delete();
}
identity =
Identity.Retrieve(Context.GetCurrentIdentityUUID());
datetime = Context.GetCurrentSystemDateTime()
.ConvertToGlobalDateTime();

255
367.book Seite 256 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

if ( this.CreationDateTime.IsInitial() ) {
// (2) Creation date/time, user
this.CreationDateTime = datetime;
if ( identity.IsSet() ) {
this.CreationIdentity = identity; }
}
else {
// (3) Last changed date, time, user
this.LastChangedDateTime = datetime;
if ( identity.IsSet() ) {
this.ToLastChangedIdentity = identity; }
}
if ( !identity.IsSet() ) {
// error handling
}

Listing 5.17 Implementation of the BeforeSave Event (Excerpt)

The first code block 1 deletes the instances of the transient Available
Site node.

The second and third coding blocks set the information about the
creation date/time and user 2 or about the last changed date/time and
user 3.

5.4 Recording and Evaluating a Trace


SAP Business ByDesign Scripting Language is supported by a trace that
can help to analyze unexpected behavior in three situations:

Trace types 왘 Developer trace


You can start the trace as developer directly in SAP Business ByDesign
studio for your development user.
왘 Trace for a test user
You can start the trace as developer in SAP Business ByDesign studio
for a test user (business user) who is logged on to the SAP Business
ByDesign UI.
왘 Incident trace
In a production system, a user can start a trace and attach it to an inci-
dent and send the incident to SAP. SAP will forward the trace file to

256
367.book Seite 257 Montag, 3. Oktober 2011 6:08 18

Recording and Evaluating a Trace 5.4

the add-on developer, who can analyze the trace file in SAP Business
ByDesign studio.

The trace will help you to answer the following questions: Trace features

왘 Has a particular script been executed at all, and have the scripts
been executed in the expected order?
The trace automatically logs the execution of each script. This may be
helpful, especially in case of nested action calls and when scripts on
different nodes are involved in a round-trip.
왘 What was the instance a script was executed on?
The trace logs the identifier (UUID) or—if available—the alternative
key of the node that is represented by the this pointer in a script.
왘 Which messages have been raised during execution?
Every message that is raised by a business object operation that is
called during processing is logged. This is especially important when
working with SAP business objects.
왘 What was the result of a retrieve operation?
The trace logs the UUID or—if available—the alternative key of the
result of a retrieve operation.
왘 Which associations has the script accessed?
For every association that is accessed, the trace logs the identifier
(UUID) or—if available—the alternative key of the accessed node.
왘 What was the result of a query?
The number of records that were returned by a query execution is
logged in the trace. This information gives you a hint that something
might have gone wrong if you expect a result from the query and
nothing was returned or if you expected exactly one result record, but
many have been delivered.

All this information is automatically logged if the trace is started. But


you can also add specific information, for example, the information that
a certain branch in your coding is executed, or you can report the value
of a variable. For this purpose, you can use the Trace class of the ABSL
library:

import ABSL;
Trace.Error(“Creation failed”);

257
367.book Seite 258 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

Trace.Error(“Creation failed:”, this.ID);


Trace.Info(“Initialization of status elements”);
Trace.Info(“Amount =”, this.Amount.Content.ToString());

The Trace class has two methods: the Error method reports an error to
the trace; the Info method indicates information. In brackets, you can
provide one or two arguments of type String.

Data Volume of a Trace


Tracing can record a potentially large amount of information; therefore, we
recommend activating traces for limited periods of time. Otherwise, the
amount of data recorded by the trace may become unmanageable. Traces are
automatically deactivated if they are left running.

Tutorial: Creating To create a trace for your development user and to analyze the trace,
and analyzing a proceed as follows:
trace
1. Enable the Trace Explorer.
In the SAP Business ByDesign studio menu, select View  Toolbars 
Trace Explorer. The Trace Explorer toolbar appears.
2. Activate the trace.
In the Trace Explorer toolbar, click Activate Trace. Execute the UI
that you want to test.
3. Deactivate the trace.
In the Trace Explorer toolbar, click Deactivate Trace.
4. Open the Trace Explorer window.
In the Trace Explorer toolbar, click Show Trace Explorer. The Trace
Explorer appears in the side window (see Figure 5.3).
5. Open a trace.
In the Trace Explorer window, navigate to the Local Traces tab, and
click Refresh Traces. The list of traces that are available in the tenant
is displayed, identified by the time the trace was started and the ID of
the user executing the UI (see Figure 5.3). Select a trace and click Get
Trace Details.
6. Analyze the sequence of events.
In the lower window of the Trace Explorer, labeled as Sequence
Explorer in Figure 5.3, the sequence of the traversed events is dis-
played in a hierarchical tree. Figure 5.3 shows the sequence of the

258
367.book Seite 259 Montag, 3. Oktober 2011 6:08 18

Recording and Evaluating a Trace 5.4

Release action. In the first step of the sequence, the AfterModify


event of the root node of the SiteReservation business object is trig-
gered, because data has been modified in the UI. The second step is
the StartSalesProcessing action that calls the MaintainSalesOrder
action. Finally the AfterModify event is called again. A red alert icon
indicates that an error occurred in the action.
7. Analyze the details of an event.
Click an event. The trace records and messages that have been logged
during the execution of the event are displayed in the Sequence
Details window. This window has two tabs, the Trace Details tab
that shows the trace records and the Messages tab that shows the
messages. Figure 5.3 shows the trace details of the Check action (see
Listing 5.9 in Section 5.3.2). The trace for this event has four entries.
The first entry indicates the value of the this pointer (Number col-
umn: 1). This entry is available for each event. The additional three
entries show the result of the retrieve operation on the Customer
business object (value 2 in the Number column), the result of the
retrieve by association to the Site business object (3), and the result
of the query to the Site Reservation business object (4).

Trace Toolbar Trace Selection

Sequence Details Sequence Explorer

Figure 5.3 Trace Toolbar and Trace Explorer

259
367.book Seite 260 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

Enable tracing for a Tracing can be enabled for another business user. This can be necessary
business user when a sequence should be traced for a user who has no access to SAP
Business ByDesign studio but is used for testing the SAP Business ByDe-
sign UI in the final work center. To enable the trace for another user, in
the SAP Business ByDesign studio menu select Tools  Options  SAP 
General. Navigate to the Tracing tab. Enable the tracing for a business
user by entering the business user’s name.

5.5 Implementing a Number Range


Universally unique With many business objects, it is necessary to be able to directly access
identifier individual objects. You do this with a unique identifier. The business
object engine automatically assigns a universally unique identifier
(UUID) to every business object node. This UUID is used internally, for
example, if you access a business object traversing an association or
from a result set of a query. The computer provides the UUID directly
based on data such as the serial number of the processor and a submi-
crosecond time stamp. The disadvantage of the UUID provisioning pro-
cess is the hardly human-readable UUID; a UUID cannot be used for
communication between people.

In many cases it is necessary to have a human-readable identifier for a


business object. In some cases this identifier is expected to be entered
manually by the users; in our example, this is the case for the Site busi-
ness object. In other cases you can take over a human-readable ID from
another business object. In a third case, you expect the system to pro-
vide a serial number as a human-readable ID.

Number range Number ranges assign a serial number that forms a unique human-read-
able key, either alone or with supplementary information (such as an
organization or a fiscal year). A number range assures that previously
assigned numbers are not reissued. A number range contains a number
range interval with a set of permitted characters. The number range
interval is made up of numerical or alphanumeric characters and is lim-
ited by the From-Number and To-Number fields.

260
367.book Seite 261 Montag, 3. Oktober 2011 6:08 18

Implementing a Number Range 5.5

A reuse service for number ranges is not supported in version FP3.0 of Implementation of
SAP Business ByDesign studio. The following workaround may be used. a Number Range
object
The implementation of a number range service consists of the following
steps:

1. Define a new Number business object.


2. Implement the GetNext action and BeforeSave event of the Number
object.
3. Implement the call to the Number object in the consumer business
object.

For the definition of the Number business object, you may use the fol-
lowing coding:

import AP.Common.GDT as apCommonGDT;


businessobject Number {
[AlternativeKey] element RangeIntervalName :
LANGUAGEINDEPENDENT_EXTENDED_Name;
element NextNumberValue : NumberValue;
element NextID : ID;
element Changed : Indicator;
action GetNext;
}

Listing 5.18 Definition of the Number Business Object

The business object definition consists of: Number Range


business object
왘 RangeIntervalName element definition
This element is a key of the business object. The Number business
object supports multiple number range intervals. Usually, you will
define one interval per business object, but it is also possible to share
the same interval between different objects or to use multiple inter-
vals for one business object, for example, by type, organization, or
fiscal year. In the latter case, the key is the concatenation of the type,
organization, or fiscal year and the number retrieved from the num-
ber range interval.
왘 NextNumberValue element
This element represents the next free number in the interval.

261
367.book Seite 262 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

왘 NextID element
This element represents the next free number in the interval con-
verted to an element of type ID.
왘 Changed element
This is the indicator for internal processing (see explanation below).
왘 GetNext action
This action increases the number range counter.

You can extend the Number business object, for example, by elements
that define the first value in a number range, that define a prefix, and so
on.

GetNext action The following listing shows the implementation of the GetNext action of
the Number business object:

// Action: GetNext
import ABSL;
this.NextNumberValue = this.NextNumberValue + 1;
this.NextID = this.NextNumberValue.ToString();

Listing 5.19 Implementation of the GetNext Action of the Number Business Object

BeforeSave event The following listing shows the implementation of the BeforeSave event
of the Number business object:

// Event: BeforeSave
this.Changed = false;

Listing 5.20 Implementation of the BeforeSave Event of the Number Business Object

Coding in the The following listings show the implementation of the BeforeSave event
consumer of the consumer business object, in our example the Site Reservation:
business object
// get number
var qyNumber = Number.QueryByElements;
var selParNumber = qyNumber.CreateSelectionParams();
var number;
var found = false;
// (1) check is ID is initial
if (this.ID.IsInitial()) {
selParNumber.Add(qyNumber.RangeIntervalName, "I", "EQ",
"SITERESERVATION");
number = qyNumber.Execute(selParNumber).GetFirst();

262
367.book Seite 263 Montag, 3. Oktober 2011 6:08 18

Implementing a Number Range 5.5

if ( !number.IsSet() ) {
// (2) number range interval does not exist -> create
number = Number.Create();
number.RangeIntervalName = "SITERESERVATION";
}
if ( number.IsSet() ) {
// (3) number range interval exists -> check if locked
number.Changed = true;
this.Flush();
if ( number.Changed ) {
// (4) successful -> get new number
number.GetNext();
this.ID = number.NextID;
}
else {
// (5) not successful -> raise message
raise NumberRangeLocked.Create("E");
}
}
else {
// (6) error message: No number range interval found
}
}

Listing 5.21 Implementation of the BeforeSave Event of the Consumer Business Object
(Site Reservation)

If the ID of the site reservation is initial (code block 1), a query is exe-
cuted to retrieve the instance of the Number business object that repre-
sents the number range interval that belongs to the Site Reservation busi-
ness object. If no interval is found 2, it is assumed that the number range
interval is not yet created, and the program tries to create a new one.

If an interval is found, the program checks if the number range is locked


3. If so, it sets the Changed element to “true,” triggers a flush to the
Number business object, and checks if the Number business object has
accepted the change. If this is the case, we can be sure that the Number
business object is exclusively locked, and we can let the program get the
next number and assign it to the ID of the Site Reservation business
object 4. If the update of the Changed element is not successful, we can
assume that the number range interval is locked by another session 5.

263
367.book Seite 264 Montag, 3. Oktober 2011 6:08 18

5 Business Object Implementation

It is possible to implement the get number sequence either in the Before-


Save event or in the AfterModify event.

Late versus early If you implement the get number sequence at the end of the BeforeSave
locking of the event, it is very unlikely that a locking conflict occurs, because the time
number range
period between the lock acquisition in the BeforeSave event and the
release of the lock after the physical save on the database is very short.
We call this late locking. If you implement the get number sequence in
the AfterModify event, the number range interval will be locked for
other user sessions until the document is saved.

To complete the implementation of the number range, do not forget to


set the ID field to read-only in the UI Designer to prevent a user from
filling the ID manually.

5.6 Summary
With SAP Business ByDesign Scripting Language, you can implement
business logic in business objects. It therefore refers to the global data
type system and to the business object model of SAP Business ByDesign.

The “atoms” of the language are literals, local variables, and static or
instance references to business objects. Path expressions explore the
hierarchy of a business object model (including associations between
business objects) or a structured data type. Based on these “atoms,”
assignment operations, arithmetic, logical, and conditional operations
can be defined. Control and loop statements are supported as well.

The generated service provider class provides common features of a


business object, such as the management of the database tables (object-
relationship mapping), locking and transaction handling, and main
memory buffering. The following events can be used for implementing
application-specific business logic:

왘 AfterModify event
왘 BeforeSave event
왘 Application-specific actions

264
367.book Seite 265 Montag, 3. Oktober 2011 6:08 18

Summary 5.6

SAP Business ByDesign scripting language provides tracing capabilities


for error analysis. The tracing can be used in the development environ-
ment as well as in the production environment of a customer system.

265
367.book Seite 475 Montag, 3. Oktober 2011 6:08 18

Index

500 Internal Server Error 408 Application and User Management work
center 360
A Application error 408
Application-specific query 75, 115, 129
Access rules 414 Approval scenario implementation 373
Account ID check 244 Approval task 372
ACID principle 234, 469 Approval Task Wizard 373
Action 101, 129 Arithmetic operations 338
Check 110 Assigned object, maintaining 190
Confirm Sales Processing 107 Assignment 213
Copy 110 Association 77, 85, 469
GetAvailableSites 110 Composition 77
Instance-based 221 Features 231
MaintainSalesOrder 106, 110 ToParent 251
Mass-enabled 221 ToSite 251
Nested 222 Asynchronous message-based communi-
Parameter 222 cation 69, 378, 379, 394
Pick in the Available Site 110 ATP check 70
Start Sales Processing 106 Attachment management 430
Submit for Approval (Cancel) 107 Authorization
Action evaluation 393 Read and write access 187
Activity diagram 105 Role-based 185
Activity list 267 Authorization check 188, 393, 400
Ad hoc output 358 Instance 188, 190, 191
Adaptation content 269 Instance implementation 191
Add-on solution 48, 66, 274, 283, 288, Start 188
327, 331, 352, 368, 431, 438, 458, 469 Authorization concept 208
Adaptation mode 290 Authorization policy 186, 188
Address data 426 Authorization profile 324
Address Snapshot business object 426 Avoiding a division by zero error 339
Administrator toolbar 466
Administrator user 442 B
Adobe LiveCycle Designer 48, 360, 465
Integrated version 367, 368 B2B (business to business) 54
Adobe Reader 50 B2B service 355
Adopting existing form templates 366 Background process 78
Analytical application 327 Background Processing 52, 53
Analytical data model 327 Basic find 113
Analytics 22 BC option 360
Analytics enabling node 346 BC set 270, 278, 283, 360
Analytics enabling object 346 Block 65
Analytics engine 51 Boolean and conditional operations 339

475
367.book Seite 476 Montag, 3. Oktober 2011 6:08 18

Index

Browser 469 Business object (Cont.)


Buffering 224 Action 75
Business Adaptation Catalog 269 Backend protection 168
Business administration object (BAO) 78 Creation 43
Business analytics 327, 464 Data model 75
Business analytics tutorial Define 79
Creating a restricted or calculated key Define and activate 44
figure 337 Definition 427, 430
Defining a data source 332 Definition file 291
Defining a joined data source 348 Deriving data source 329
Defining a report 336 Design 128
Business Analytics work center 327, 336 Element 77, 88
Business application 50 Engine 55
Business area 269 Extensible 464
Business character 417, 419 Extension 286
Company 419 Framework 57
Functional unit 420 Implementation 75
Permanent establishment 419 Implementing organizational unit 421
Profit center 420 Instance 77
Program 420 Key 84
Reporting line unit 420 Node 77
Segment 419 Precondition 75
Business concept 76 Relationship 82
Business configuration 28, 51, 267, 272, Status variable 75
382, 463, 469 Strong relationship 84, 85
Use cases 271 Text 428
Business configuration architecture 269 Value 75
Business configuration content 270 Weak relationship 84
Business configuration object (BCO) 51, Business object model 38, 75, 76
78, 270, 283 Business object node 470
Business configuration tutorial Business option 269, 274, 283
Defining a BC set and BCO 278 Properties 275
Defining a BC set on an existing BCO Business package 269
280 Business partner 417, 466
Defining a business option 276 Business Partner business object 418
Defining a business topic 277 Business process 52
Defining a scoping rule 282 Business process documentation 438
Defining an implementation project tem- Business scenario 50
plate 282 Business task engine 51
Business Configuration Wizard 276 Business Task Management 29, 370,
Business Configuration work center 411, 465, 470
267, 283 Architecture 371
Business logic extension 297, 300 Business task service 54
Business object 49, 50, 56, 73, 76, 168, Business task type 371
191, 285, 413, 433, 469 Business task UI 396
Access-controlled 193 Business Task Wizard 373

476
367.book Seite 477 Montag, 3. Oktober 2011 6:08 18

Index

Business topic 269, 274 Consumer-independent software imple-


Business transaction document 77, 86, mentation 76
122 Consuming object 380
Business user 400, 443 Content classification 439
businessobject statement 87 Control center 131
Button 469 Controller implementation 306
Controls 62
C Copy action 244
Copy sequence 240
Calculated element 98 Core data type 89
Calculation 75 Code 92
Price 105 Indicator 93
Cardinality 81, 100 Core Service 씮 Service
CCTS representation type 147 Cost object 431
Change project 268 Create a solution 43
Characteristic 328, 334 Create operation 219, 403
Selecting 331 Create Screens dialog box 44
Characteristic property Create Screens Wizard 177
Display setting 344 Create script files 44
Hierarchy setting 344 Create Solution dialog box 43
Label 344 Create user interfaces 44
Value selection 344 Creating a solution 445
Check action 241 CRUD service 58, 59
Check, initial 253 Crystal Reports 48, 50
Child node 77 Currency conversion 343
Clearing House business object 418 Customer 418
Client compatibility 407 Customer invoice 80
Client monitor (HTTP trace) 202 Customer invoice processing 382
Cloud 21, 33, 49 Customer-specific reporting 327
Code completion 212 Customer-specific solution 30, 438, 448,
Code value 229 455, 458
Co-innovation 30
Collaboration 29 D
Collection 216
Collection, method 216 Data binding 140
Comment 210 Data model browser 202, 206
Communication pattern 70, 71 Data source 328, 470
Compiler 49, 54 Data structure 328
Compound Service 씮 Service Display setting 328
Configuration content 270 Extension field 351
Conflict and error handling 394 Field-to-field mapping 328
Implementation 407 Inner join 347
Conflict and error monitoring 395 Join 347
Conflict and error resolution strategies Join condition 347, 350
394 Left outer join 347
Constraint 270 Partner Report 345

477
367.book Seite 478 Montag, 3. Oktober 2011 6:08 18

Index

Data source (Cont.) Embedded component (Cont.)


Report 328 Use case 195
Report assignment 345 Employee business object 418, 419
Union 350 Enterprise service 470
Data source operation Entity 470
Drill-down 331 Error handling 357, 407
Pivoting 331 Error list 43
Rollup 331 Event 236
Slice and dice 331 Action event 237
Data Source Wizard 332, 350 BeforeSave 255, 262
Data structure 358 Determination event AfterModify 236
Decoupling 26 Determination event BeforeSave 237
Define a status schema 102 Validation event CheckBeforeSave 237
Define the action 102 Event handler 141, 169
Define the precondition 102 Exactly once request execution 404
Define the status variable 102 Exception aggregation 341
Define the synchronizer 102 Execute operation 227
Delete operation 221 Extending a form message type 368
Deleting a solution 445 Extending the Customer Invoice Request
Deployment 270 384
Deployment unit 53, 68, 74, 378, 382, Extending the Site Reservation 383
414, 470 Extensibility 26, 285, 324, 464
Deprecation 72 Extensibility Explorer 293
Period 73 Change transaction 293
Design document 440 Stable anchor 293
Design time tool 47 Extensibility tutorial
Detailed design 85 Adding a common task to a work center
Determinations 59 view 323
Developer user 442 Adding a mashup to a UI 319
Development guideline 467 Adding an embedded component to a UI
Development object 54, 55, 285 302
Device-specific software 201 Adding an extension field to a business
Document address 425 object 290
Document window 42 Adding an extension field to a UI 293
Domain-specific language 209 Adding an extension field to enterprise
Dot notation 445 search 297
Changing the work center order 322
E Defining a data mashup 317
Defining a web service 316
Easy Form Editor 360, 367, 368 Extending a result list 296
Element statement 87 Extending a selection parameter struc-
Element, transient 99 ture 297
Embedded analytics 29 Hiding a button 321
Embedded component 195, 199, 208 Implementing a business object extension
Reuse UI 427 298
Test 310

478
367.book Seite 479 Montag, 3. Oktober 2011 6:08 18

Index

Extensibility tutorial (Cont.) Frontend print scenario 361


Implementing the controller for a supple- Frontend scripting 165, 168, 207
mental business object 307 Trace 202, 206
Renaming a label or hiding a UI field Function
320 Instance-based 233
Extensible Markup Language (XML) 473 Static 233
Extension Functional unit, role 420
Access 298
Data type 292 G
Eventing 298
Features 298 GetNext action 262
Scripting language 298 Global data type 88, 90, 470
Sequence of events 300 Aggregated 90, 126
Extension field 285, 292, 324 Basic 126
Label change 296 Global Data Type Catalog 462
With business partners 293 Go-live activity list 273
Extension field calculation 286, 297 Graphical user interface (GUI) 473
External namespace 445 Guided activity floorplan (GAF) 132
External web service 355, 399, 412
H
F
Help desk cost 435
Fact sheet (FS) 132 House Bank business object 418
Field extensibility 285, 413 HTTP error and fault message 407
Field-to-field mapping 359 HTTP notation 445
File input 412, 466 Human-readable identifier 83, 244, 260
File Input Run 409
Filtering 51 I
Find form 164
Fine-tuning 273, 283 Idempotency 404
Flat database table 329 Identity 424
Flexibility 26 If-else statement 214
Flexibility change log 290 Implementation Manager toolbar 453
Floorplan 470 Implementation project 267
Form data type 358 Implementation project template 282,
Form rendering 360 284
Form template 359 Import 210
Form template group 359 Import statement 87
Form Template Maintenance 358, 366 Inbound processing 53, 69, 381
Form template variant 359 Error 410
Configuration 361 Inbound service 391
Extension field 368 Interface 410
Form Template Wizard 361 Incident 446
Form-based document 358 Content 455
Forms 465 Handling by key users 446
Foundation 68, 470 Report 454

479
367.book Seite 480 Montag, 3. Oktober 2011 6:08 18

Index

Incident (Cont.) Lifecycle management (Cont.)


Report from Business Center 447 De-provisioning phase 436
Incident management 34 Development phase 435, 445
Inport 143, 306, 471 Operation and deployment phase 454
Input parameter 100 Operation and support phase 435
Input processing 356 Preparation phase 435, 436
Insight-to-action 29 Lifecycle management tutorial
Installation 466 Analyzing an incident trace 456
Instance identification 391 Creating new users 443
Integration 66 Deploying a customer-specific solution
Integration concept 431 453
Integration scenario 38 Search for known problems 446
Internal communication 356, 385, 411 Literal 211
Internal namespace 445 Lock 234, 237, 471
ISO 11179 123 Application lock 238
IsSet check 232 Database lock 238
IsSet operation 220 Late locking 264
Lock handling 58
J Locking 79
Logical and conditional operation 213
Job business object 422 Logical unit of work (LUW) 471
Join 58, 111 Loop statement 215
Logic 58 Loose coupling 195

K M
Key figure 328, 334 Main memory buffer 58
Basic 329 Main node semantic 124
Calculated 329, 337, 338 Mashup 50, 310, 325, 471
Calculation editor 338 Architecture 310
Counter 337 Category 311
Restricted 329, 337, 343 Configuration and integration 315
Selecting 329 Development 315
Key Figure Wizard 337, 343 Integrated authoring tool 314
Type 310
L Write-back 311
Mashups 31, 464
Lambda expression 217 Mass data run object (MDRO) 53, 78
LAN 471 Master data address 425
Leading business object 140 Master data object (MDO) 78
Learning Center 461 Master data, maintenance 254
Lifecycle management 34, 56, 435, 438, Mathematical operator 213
467 Message 75
Continuous improvement phase 435, Message-based communication 68, 378,
456 382, 414
Deployment phase 435, 447 Method tool tip 222

480
367.book Seite 481 Montag, 3. Oktober 2011 6:08 18

Index

Microsoft Silverlight 50, 60 O


Mobile strategy 201
Mobile UI 208 Object instance floorplan (OIF) 132
Mobility 21, 29 Object relation mapping 57
Mockup 41 Object value selector (OVS) 133
Model View Controller (MVC) 74 Object work list (OWL) 53, 132
Design pattern 61 floorplan 296
Multiple selection parameter 228 Object-based navigation 133, 171, 207,
Multiplicity 80, 128 238
Configuration 177, 180
N Implementation 172
Troubleshooting 181
Naming Conventions and Useful Guideli- Use case 171
nes 421 Offering object 380
Naming rules 123 On-demand service 21
Capitalization 124 On-demand strategy 23
Object class 126 Operation 142, 143
Property 126 Organizational function 420
Representation 126 Organizational structure 419
Node 75 Organizational unit 419
Action 100 Hierarchy 421
Additional Service 87 Organizational unit template 421
Administrative 127 Outbound processing 53, 69, 357, 389,
Aggregation 105 390
Category 127 Outbound service 371
Classification 127 Outport 143, 472
Delegation 105 Parameter 303
Extendable 291 Output management 358, 410
ID 127 Output management architecture 358
Invoice Reference 87
Key 127 P
Lockable 80
Processing 127 Pace of innovation 22
Property 127 Pane 153
Reference 127 Adding and removing 153
Root 77 Advanced List Pane (ALP) 154
Status 127 Features 155
Subnode 82 Newspaper format 153
Transient 75, 99 Party 422
Notification 70 Role 422
Notification communication pattern Patch 450, 454
393 Path 124
Notification task 372 Path expression 212
Number range 260 Pattern 472
Interval 260 Pick action 250

481
367.book Seite 482 Montag, 3. Oktober 2011 6:08 18

Index

Platform tutorial R
Including the Address Snapshot 427
Including the Attachment Folder 430 Real-time analytics 327
Including the text collection 428 Relationship 39, 128
Port type package 133, 177, 312 Release action 245
Position business object 422 Relevance condition 357, 389
Precondition 101 Report Wizard 336, 346
Enabling 103, 248 Repository 48, 54, 74
Inhibiting 103, 248 View 42, 43
Required 104 Request business object 381
Requiring 248 Request/confirmation pattern 70, 393
Primary service provider 49 Reserved word 210
Primitive data type 89 Reset method 232
Process (or document) flow 38 Responsible manager 423
Process automation 27 REST (Representational State Transfer)
Process Communication Error 397 315
Process integration 53, 382, 388, 465 Result list 111
Definition 392 Retrieve method 226
Persistence 379 Retrieve operation 244
Process scenario, extensible 465 Reuse service 425, 433
Process variant 271 Rich Internet application (RIA) 50
Process-integrated output 358 RootQuantity 342
Programming language 209 RSS (Really Simple Syndication) 315
Properties window 43 Rules for transaction and lock handling
Prototype 40 238
Advanced prototype 41 Runtime tool 47
UI prototype 40
Public model 56, 71, 413, 466 S
Q Sales order 80, 383
Creation 253
Qualifier 124 Item 118
Quality review 450 Party 120
Request 451 Party role 120
Quality Review Questionnaire 450 Schedule line 119, 120
Query 111, 227, 238 UI 305
Default set 159 Update 254
Extension 296 Sandbox solution 439
Query operation 59, 405 SAP BI OnDemand 24
Query/response pattern 70 SAP Business ByDesign 23, 42, 53, 79,
Quick Activity Floorplan (QAF) 45, 63, 99, 107, 131, 165, 185, 207, 327, 413,
132 425, 436, 472
Architecture 286
Environment 437
Platform 433
Studio frontend 47, 54, 55

482
367.book Seite 483 Montag, 3. Oktober 2011 6:08 18

Index

SAP Business ByDesign (Cont.) Service 56, 470, 472


Version N 72 on-demand 21
Version N+1 72 Service adaptation 50, 74
SAP Business ByDesign Business Center Service Consumer 473
437, 458, 461 Service integration 355
Forum 437 Service integration tutorial
SAP Business ByDesign for Subsidiaries Adding an extension field to a form
23 template 369
SAP Business ByDesign Library 438, 461 Adding extension fields to an existing
SAP Business ByDesign Repository 55 process integration 397
SAP Business ByDesign Scripting Langu- Adopting an existing form template 368
age 209, 223, 256, 346 Configuring a form template variant
Tools library 240, 243 with Adobe LiveCycle Designer 363
SAP Business ByDesign studio Library Defining a web service authorization
438, 461 profile 402
SAP Business ByDesign studio Wiki 437 Defining an approval scenario 373
SAP BusinessObjects 470 Defining an external web service 399
SAP Carbon Impact OnDemand 24 Defining the interaction structure and
SAP Career OnDemand 24 mapping for an internal communica-
SAP Cloud Infrastructure 34 tion 385
SAP Global Data Type Catalog 462 Finalizing the approval scenario 375
SAP namespace 81 Implementing the process integration
SAP Sales OnDemand 23 conditions 390
SAP Sales Order 76, 118 Installing Adobe LiveCycle Designer 360
SAP solution adviser 267 Service Integration Wizard 385
SAP Sourcing OnDemand 24 Service interface 356, 358, 410
SAP Store 32, 448, 451, 472 Service operation 357
Access 451 Service orientation 26
Features 452 Service Provider 473
SAP Streamwork 24 Service provider class 49, 56, 57
SAP Support 447 Signature 473
Application sharing 447 Silverlight 463
SAP Travel OnDemand 23 Simplicity 26
Scalable solution 30 Site 81
Scoping 267 Site availability check 244
Scoping question 275 Site category 81
Scoping rules 272, 281 Site ID check 244
Scoping status 272 Site Management 37
Scoping workshop 267 Site reservation 81, 105, 382
Screen Creation Wizard 133 Cancellation 372
Scripting Language, syntax documenta- Work center view 182
tion 462, 463 Site Reservation business object 103,
Search engine 65 108, 110, 114, 168
SearchText element 113 Site Reservation Object Work List (OWL)
Selection parameter 111, 227 45
Self-enablement system 437 Snippet 59

483
367.book Seite 484 Montag, 3. Oktober 2011 6:08 18

Index

SOAP (Simple Object Access Protocol) System message (Cont.)


315 Text 118
Software layer 288 System-to-system communication 357
Solution 473
Solution design 441 T
Solution Documentation 441, 450
Solution Explorer 42 Task type 370
Tool window 43 Category 370
Solution implementation, troubleshoot Tax Authority business object 418
454 Technical and Support Documentation
Solution profile 51, 269, 270 450
Solution purchasing and activation 454 Technical objects (TecO) 78
Solution search 446 Technical support cost 435
Special-purpose web service 356 Technical user 400
Stable anchor 72 Template/projection concept 418
Standard function library 233 Tenant 48, 49
Standards and criteria 450 Test deployment 449
Documentation 450 Test user 443
Functional correctness 450 Text search 112
Performance 450 Tight coupling 195
Security 450 Total cost of ownership 435
Usability 450 Trace
Start condition 357, 390 Data volume 258
Statement 210 Developer 256
Status and action management 101 Enable for a business user 260
Status schema 101 Features 257
Status transition 101 For test users 256
Status value 101, 103 Incident 256
Status variable 101, 103 Transaction 234, 473
Cancellation Approval Status 109 Interaction phase 234
Consistency Status 109 Save phase 235
Release Status 109 Transactional behavior 58
Sales Processing Status 109 Transactional RFC 473
Site Reservation Status 109 Transformation 51
Supplemental business object 286, 305, Transformation rules 331
325 TREX 473
Definition 305 Trigger test deployment 449
Supplier business object 418 Button 450
Support 34 Type inference 212
Switch statement 214 Type system 211
Synchronizer 102, 104
Synchronous call-based communication U
379
Synchronous web service 399, 407 UI Designer 48, 64, 135, 207, 462, 473
System message 117 BO Browser/Data Model 136
Message ID 118 Configuration Explorer 136

484
367.book Seite 485 Montag, 3. Oktober 2011 6:08 18

Index

UI Designer (Cont.) User interface tutorial (Cont.)


Drag-and-drop 136 Adding a common task to a work center
Extensibility Explorer 136 view 184
Preview mode 137 Adding a field to a form 150
Properties 136 Adding a work center view to an SAP
Toolbox 136 work center 183
UI extension 287, 320 Adding an embedded component to a
Key user tool 289 floorplan 199
Lifecycle stability 288 Assigning a work center view to a work
UI pattern center 182
Advanced find form 113 Configuring a preview pane 158
Basic find form 113 Configuring the find form 164
Find form 113 Creating a data list for a code list 170
UI 씮 User interface Creating a list pane 156
UI Style Guide 462 Creating an embedded component 196
Unified modeling methodology (UMM) Creating screens for a business object
70 133
Uniform Resource Locator (URL) 473 Defining a segregation of duties conflict
Unit conversion 343 194
Universal Unique Identifier (UUID) 83, Defining a value set and the default value
260, 473 set mapping 163
Update development 457 Defining an OBN create scenario 174
User 424 Defining an OBN create with reference
User interface 473 scenario 178, 180
Architecture 60 Defining an OBN Show Details scenario
Code data type 149 175
Controller engine 51 Defining dynamic behavior of an action
Data model 140 button 166
Data type identifier 148 Defining the screen title 154
Dedicated interaction paradigm 131 Filling a list with data from a query 159
Development 48, 463 Implementing an instance authorization
Display type 144 check 192
Embedded component 302 User-to-system communication 357
Engine 55, 60 UUID 473
Extension type 287
Floorplan 62, 131, 137, 181, 201, 207, V
287, 312
Model controller 141 Variable 210
Pattern engine 61 First assignment 211
Pattern hierarchy 137
Pattern-based 131, 207 W
Property 145
Reusable building blocks 131 WAN 473
Site map 134 Web report 331
User interface tutorial Web service 53, 355, 473
Adding a button to a form 151 Web service authorization 403

485
367.book Seite 486 Montag, 3. Oktober 2011 6:08 18

Index

Web service definition language 403 Work center view 132, 183, 444
Web service endpoint 403, 408 Adding or removing 321
Web service engine 51 Authorization 401
Web service interface operation 409 Extension 322, 323
Web Service Provisioning Wizard 399 World Wide Web (WWW) 473
Web Service Reliable Messaging 404
While loop 215 X
Whitespace character 210
Wide area network (WAN) 473 Xcelsius 48
Wireframe 40 XML 473
Wiring 382 XML-based message 357
Work center 53, 131, 183, 208, 444

486

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy