Entering content frame

Procedure documentation Creating BSP Applications, Controllers and Views Locate the document in its SAP Library structure

In the Web Application Builder, create the following:

We have chosen tutorial_3 as the name. This is a sample BSP application contained in package SBOOKSHOP. Pay attention to the customer namespaces when you are naming your BSP application.

Select your BSP application (Properties tabstrip) as Stateful. This is recommended when you work with sub-controllers (see Bookshop Structure), because the main controller must recognize all sub-controllers when it delegates the data. It must also be instantiated.

Background documentation

If you want to program the application as stateless, you must create sub-controllers in the DO_INIT method of that controller. You can find additional information about this in Stateful and Stateless.

bookshop.do. This is the main controller that is also called using the URL by the browser. Method ON_REQUEST of the controller class of this controller is executed first of all. This calls the view default.htm. Creating Main Controller bookshop.do describes how you create this controller.

search.do. This is the controller that is responsible for the book search. It must react to the searchbutton, process the book data that are entered, search for suitable books and then write these to an internal table. It then passes this table to view search.htm. Creating Controller search.do for the Search describes how you create this controller.

result.do. This controller is responsible for outputting the books that are found as well as for event handling when a user clicks on a book to display detailed data about that book. Individual rendering of the author column must also be determined. Creating Controller result.do for the Results Page describes how you create this controller.

detail.do. This controller is responsible for determining the detailed data for a selected book. It then passes this table to view detail.htm. Creating Controller search.do for the Detail Display describes how you create this controller.

default.htm. This is the main view that consists of the header and 3 HTMLB trays, which contain the search-, result- and detail controllers and the corresponding views. Creating Main View default.htm describes how you create this view.

search.htm. Creating View search.htm for the Search describes how you create the view for inputting the search data.

result.htm. Creating View result.htm for the Results List describes the view for displaying the results list with an HTMLB table view.

detail.htm. This view returns details on a book selected in the results table. Creating View detail.htm for the Details Display describes how you create the view.

about.htm. If no books were found in the search or the results table is empty for another reason, information about the bookshop should be displayed instead of the book details. Create the view as described in Creating View about.htm for the Detail Display.

 

 

Leaving content frame