Puyuan EOS case

1 Create a project 

1)   Enter the development perspective of EOS Studio;

Click on the main menu item "File" and select "New" -> "Empty EOS Project"

2) In the pop-up "Create Empty EOS Project" view, configure relevant parameters. "Project Name": EOSTriping,

3) Click the [Finish] button, the system completes the creation of the project framework and exits .

[Description] When creating a new project, a pkg component package will be created by default, and you can delete this component package by right-clicking the mouse.

2. Create a component package

 1) In the Project Explorer view, click to expand the context menu of the "EOSTriping" project, and select "New"

2) In the pop-up "Create Component Package" view, set relevant parameters.

3) Component package name: HelloWorld, click the [Finish] button to end the component package creation wizard

 

3 Create business logic

1) In the "Project Explorer View", expand the "EOSTripingàHelloWorldàbiz" component, right-click on the "biz" component, and select the context menu "New→Business Logic".

 

2) Enter "bizHelloWorld" in the "File Name" item in the "Create Business Logic" dialog box that pops up, and click the Finish button to end the Create Business Logic Wizard.

After creating the "bizHelloWorld" business logic, the "Business Logic Editor" in Studio will automatically open the just-created business logic.

3) Expand "Reference Component Package àfcdomàBNNode.class" in the "Project Explorer" view, select the "BL_setNodeValueBatch" operation logic, hold down the left mouse button, and drag the operation logic to the "bizHelloWorld" editing area 

4) Use the mouse to click the "Connection Line" tool in the "Palette" in the business logic editing area, click the "Start" primitive, and then click the "BL_setNodeValueBatch" primitive to connect the "Start" primitive and the "BL_setNodeValueBatch" primitive stand up.

5) Double-click the "BL_setNodeValueBatch" operation logic primitive, in the pop-up "Properties Setting" dialog box, click the "Parameter Definition" tab page, and enter the parameters: Parameter 1, the node type is EOS Field, and the node path is "show/info" ( User can customize), the node type of parameter 2 is constant, and the node value is "Hello world!" (this operation means to set "Hello world!" under the show/info node)

6) Double-click the "Start" element in the business logic editor, in the pop-up "Properties Settings" dialog box, click the "Interface Definition" tab, and enter the parameters: parameter 1 The node type is EOS Entity (you can also set it here EOS Field), the node path is show, which means that the set show/info information will be output to the logical data area that calls this business logic.

7) Click the "Save" button in the toolbar or use the shortcut "Ctrl+S" to save the business logic.

4 Create JSP pages

1) In the "Project Explorer View", expand the "EOSTripingàHelloWorldàpage" component, right-click on the "page" component, select the context menu "New àjsp Page", Studio starts the page wizard, and in the pop-up "Page Generation Wizard" dialog box, enter the parameters, and click the [Finish] button to end the Create Page dialog box:

 

2) In the page editor of the page development view, enter the following jsp code:

 

<%@ include file="/internet/common.jsp"%>
<html>

    <body>

        <div align="center">

            <br><font color="red" size="20">     

            <bean:write property="show/info"/>

            </font>

        </div>

    </body>

</html>

3) Click the "Save" button on the toolbar or use the shortcut key "Ctrl+S" to save the jsp page.

 

5 Create presentation logic

1) The steps to create presentation logic are basically the same as the steps to create business logic. In the "Project Explorer View", expand the "EOSTripingàHelloWorldàpr" component, right-click on the "pr" component, and select the context menu "New→Display Logic". In the "Create Presentation Logic" dialog box that pops up, enter "prHelloWorld" in the "File Name" item, and click the [Finish] button.

2) Drag and drop the business logic "bizHelloWorld" and the page "helloworld.jsp" just created into the presentation logic editor, click the "Connector" tool in the "Palette", and use the method used to create the business logic. Connect the "start", "bizHelloWorld", "helloworld.jsp" and "end" primitives in sequence:

3) Save the presentation logic you just created.

6. Compile and deploy

1) Save all the files you just created and edited;

2) Click the shortcut icon to select the project "EOSTriping" to be run, and start the server

7 run

1) After the server starts normally, open the IE browser.

2) Enter: http://localhost:8080/ in the address bar of the IE browser ; log in with the system administrator sysadmin, password 000000 (or the password modified during installation), and enter the main interface.

3) Change the address bar to:

http://localhost:8080/HelloWorld.pr.prHelloWorld.do (pay attention to the way the path is written and capitalized), press Enter; if the project is running normally, the page will be displayed as shown.

8. Summary

1) Create a project: specify the project name, EOS Server and WEB application directory for the project.

2) Create a component package: formulate the component package name, organize the storage of various components and logic in the form of a directory, and facilitate Studio management. The names of various components can be modified.

3) Create business logic: write the logic code, call the operation logic (BL method) to process the input data, complete the business logic, and return the processing result to the presentation logic.

4) Create JSP page: the user interface of the EOS application, use Jsp Tag to display the information in the RequestContext data area to the user.

5) Create presentation logic: control the execution of the program flow, call the business logic to obtain the processed information, and then call the page logic to return the information to the user.

6) Compile and deploy: Select [Auto Build] in the [Project] menu bar, save and compile, and EOS Server will automatically perform hot deployment when the deployment is debugging or running.

7) Running case: Enter a URL in the form of "component package name.display component name.display logic file name.do" in the IE address bar (the case of the URL should be the same as "component package name.display component name.display logic" in Studio The upper and lower case of the file name” is exactly the same), and the call to the EOS application can be completed.

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=325131645&siteId=291194637