반응형
Introduction

전에 3장에서 각각의 Human Task 폼(화면)을 자동으로 만들었습니다.


이 챕터에서는 ADF(application Development Framework)라는 것으로 화면을 수동으로 만들어 봅시다.

※ 총 3개의 프로젝트를 새로 만들어야 하는데.. 너무 양이 많아서  처음 1개의 프로젝트만 새로 만들어 보겠습니다.

※ 어느정도 익숙해지면 pdf(원서) 보고하는게 더 빠를 것입니다. ㅎㅎ



Task forms for entering a quote

Setup

자동으로 만들었던 Human Flow UI 를 지우고 수동으로 새로 만들겠습니다.

EnterQuoteUILab 프로젝트를 삭제합니다.


파일까지 싸악~ 삭제합니다.




Create a new UI project

Application 메뉴에서 New Project... 클릭.


Generic Project 프로젝트를 선택합니다.



아무것도 없는 빈 프로젝트가 생성됩니다.


Create Business Components

프로젝트 위에서 오른쪽 버튼 클릭 후 New 클릭.


Business Components from Tables 를 선택합니다.



Connection 오른쪽의 추가 버튼(녹색 플러스)을 클릭합니다.



0장(Chapter 0) 에서 만들었던 quote 디비 정보를 입력합니다.



OK 버튼을 클릭합니다.



Package: enterquoteui.adfbc


Query 버튼을 클릭하면 quote 스키마의 테이블들이 Available 목록에 나옵니다.


PRODUCT, TERM 테이블을 선택하고 가운데에 오른쪽으로 가는 화살표를 클릭하여 Selected 목록으로 옮깁니다.


Next 버튼 클릭. (아직 Finish 하면 안됩니다!)



2단계(Step 2)에서는 할 것이 없습니다. Next 버튼 클릭.



3단계에서 1단계에서 했던 것과 같은 작업을 합니다. Next 버튼 클릭.



4단계에서 Finish 버튼을 클릭합니다.



EnterQuoteUILab(프로젝트) - Application Soureces - enterquote.adfbc - AppModule 를 편집합니다.



Configurations 탭으로 이동합니다.


AppModuleLocal 선택 후 수정(연필) 버튼을 클릭합니다.



Connection Type 을 JDBC DataSource 를 선택 하고 Datasource Name 은 jdbc/quoteDB 로 변경합니다.



AppModuleShared 도 같은 값으로 변경합니다.



모두 저장합니다.


Create Task Flow

이제부터 UI(화면)를 만들어 봅시다.

프로젝트(EnterQuoteUILab)에서 오른쪽 버튼 클릭 후 New 클릭.

Web Tier - JSF 분류에서 ADF Task Flow Based on Human Task 를 선택합니다.

BPM의 Human Task 를 기반으로 ADF UI 를 만드는 겁니다.


QuoteProcessLab 프로젝트 안에 EnterQUoteDetails.task 파일을 선택합니다.



Create Train 을 체크합니다.



taskDetails1_jsp(View)가 만들어져 있는데 삭제합니다.



View 컴포넌트를 추가합니다. 이름은 enterHeader.



아래와 같이 차례대로 View 컴포넌트를 4개 더 추가합니다.


각각 이름은 selectProduct, requestDiscount, requestTerms, submit 입니다.


그 후 Control Flow Case 로 submit(View)와 taskReturn 을 연결합니다.



enterHeader 뷰를 선택 후 Mark Default Activity 버튼을 클릭합니다.



기본 흐름이 완성 되었습니다.




Create a form for entering the quote header data

일단 템플릿이 들어있는 라이브러를 프로젝트에 추가시켜 봅시다.

리소스 팔레트(View - Resource Palette)에서 커넥션을 하나 추가합니다.


Connection Name: SalesQuoteUIadflib




경로는 이 라이브러리 파일이 들어있는 폴더(디렉토리)를 선택합니다.



그럼 지정한 폴더 안에 있는 파일들이 표시됩니다.


그 중에 adflibSalesQuoteUITemplates.jar 파일을 프로젝트에 추가시킵니다.



enterHeader 뷰를 더블클릭합니다.



템플릿으로 Oracle BPM 11gR1 Training - Enter Header Template 를 선택합니다.



Data Controls 패널에서 EnterQuoteUILab_EnterQuoteDetails - getTaskDetails(...) - Return 까지 이동합니다.


※ 앞으로 여기가 데이터의 기준이 됩니다. (한군대에선 빼고...)


Task 를 UI 화면 상단 오른쪽의 task-action 부분(facet)에 드래그 앤 드랍합니다.



Human Task - Task Action 을 선택합니다.


※ 앞으로 4개의 뷰를 더 만들텐데 이 작업은 항상 똑같습니다.



Task - Payload - Quote Request - Summary 를 task-summart 부분에 드래그 앤 드랍(이하 추가) 합니다.



Form - ADF Form 선택.



NewCustomer, TotalNetRevenue, EffectiveDiscount 필드는 삭제합니다.



OK 버튼 클릭.



구조 팔레트 부분을 보면 화면의 내용물(?)들이 트리 형태로 잘 보입니다.


방금 추가한 폼을 선택 합니다.


   


그리고 Property Inspector(이하 프로퍼티) 팔레트 부분은 선택한 부분의 속성들을 변경 할 수 있습니다.


MaxColumns: 3

Rows: 1


변경합니다.



Address 데이터 컨트롤을 task-summary-address 부분에 추가 후 ADF - ADF Forms 선택. 설정 창은 그냥 OK.



Panel Collection 컴포넌트를 task-summary-contacts 부분에 추가합니다.



Contacts 데이터 컨트롤을 추가한 Panel Collection 영역에 추가 후 Table - ADF Table 선택.


설정 창은 그냥 OK 합니다.



Panel Collection 컴포넌트의 toolbar 부분에 Toolbar 컴포넌트를 추가합니다.



추가한 툴파 영역에 Contacts - Operations - Create 를 추가합ㅎ니다.



ADF Toolbar Button 클릭.



Delete 를 바로 다음에 추가합니다. 마찬가지로 ADF Toolbar Button 클릭.



처음 추가한 버튼의 Text 속성을 Add 로 변경합니다.



완성된 화면 입니다.



모두 저장합니다.



Create a form for adding products to the quote


프로젝트에서 마우스 오른쪽 버튼 클릭 - Project Properties 클릭.


Libraries and Classpath 로 이동 후 Add JAR/Directory 버튼을 클릭합니다.





라이브러리 파일을 선택합니다.



OK 버튼 클릭.



Task Flow 설정 화면을 엽니다. (파일 위치: {프로젝트}/Web Content/WEB-INF/EnterQuoteDetails_TaskFlow.xml)


Overview 탭으로 이동 후 Managed Beans  탭으로 이동합니다.


추가(Add) 버튼을 클릭합니다.



Name: dropProduct


Class 필드에서 오른쪽에 화살표 클릭 후 Edit 클릭.



enterquoteui.backing.DropProduct 클래스를 선택합니다.



Scope: session



같은 방법으로 2개를 더 추가합니다.


Name: discountHelper

Class: enterquoteui.backing.DiscountHelper

Scope: session


Name: termChoices

Class: enterquoteui.backing.TermChoices

Scope: session



selectProduct 뷰를 편집합니다.



Select Prodcut Template 선택.



Task 데이터 컨트롤을 상단 오른쪽의 task-action 부분에 추가 후 Human ATask - Task Action 선택.


※ 이제 이 부분은 빼겠습니다. 다음 3개의 View를 만들때 맨 처음 해주세요.


available-products 부분에 Panel Collsction 컴포넌트(레이아웃 컨테이너)를 추가합니다.


데이터 컨트롤 중에 AppModuleDataControl - ProductView1 을 available-products의 패널에 추가합니다.



Table - ADF Read-only Table 선택.



Category, Imageurl 필드는 삭제합니다.



Multiple Rows 선택 후 OK 버튼을 클릭합니다.



selected-rpoducts 부분에 Panel Collection 컴포넌트 추가 후 Product Item 을 추가합니다.



RequesteDiscount, ControlledAvailability 필드는 삭제합니다.



Data Source(Operations) 컴포넌트를 Available Products 테이블에 추가합니다.



화면에는 보이지 않으니 구조 팔레트에서 선택합니다.



아래와 같이 속성을 바꿔줍니다.


Actions: COPY

DefaultAction: COPY

Discriminant: productItem



Collection Drop Target(Operations) 컴포넌트를 Selected Products 테이블에 추가합니다.



DropListener 오른쪽에 화살표 클릭 후 Method Expression Builder 선택.



ADF Managed Beans - dropProduct - HandleDrop 을 선택합니다.



OK 버튼 클릭.



추가한 Collection Drop Target 컴포넌트의 속성은 아래와 같이 변경합니다.


Actions: COPY

ModalName: prodcutItem



완성된 화면입니다. 모두 저장합니다.




Create a form for request discount

requestDiscount 뷰를 편집합니다.


Request Discount Template 선택.



Summary 데이터 컨트롤을 summary 부분에 추가 후 ADF Form 선택.



TotalNewRevenue, EffectiveDiscount 만 남기고 나머지 필드들은 삭제합니다.



Form 패널의 속성을 아래와 같이 변경합니다.


MaxColumns: 2

Rows: 1



두 필드를 선택합니다. (컨트롤키를 이용)



ReadOnly 속성을 true 로 변경합니다.



NetRevenue 필드만 선택합니다.



Value 속성 오른쪽에 화살표 클릭 후 Expression Builder 를 선택합니다.



입력되어 있던 값 삭제 후 ADF Managed Beans - discountHelper - netRevenue 를 입력합니다.



EffectiveDiscount 필드는 discountHelper - effectiveDiscount 를 입력 해줍니다.


discounts-table 부분에 Panel Collection 컴포넌트를 올리고 Product Item 데이터 컨트롤은 추가합니다.


RestrictedItem, ControlledAvailability 필드는 삭제합니다.



discount-table 부분에 추가했던 Panel Connection 컴포넌트의 StyleClass 를 AFStretchWidth 로 설정합니다.


화면의 가로 길이에 따라 가로 크기가 최대로 늘어나게 됩니다.



ProductId, ProductName, ListPrice, PreApprovedDiscount 필드(칼럼 아님!)를 선택합니다.



readOnly 속성을 true로 변경합니다.



Requested Discount 칼럼을 Quantity 오른쪽으로 이동시킵니다.



Quanity 필드를 선택하면 오른쪽에 나오는 버튼 클릭 후 Convert To 클릭.



Input Number Spinbox 선택.



변환 하게되면 MaximumLength 속성이 없어진다고 하는것 같습니다. -_-;;;



Quantity, Requested Discount 필드를 선택합니다.



autoSubmit 속성을 true 로 변경합니다.



Quantity 칼럼 선택 후 id 속성을 cQuantity 로 변경합니다.


   


Requested Discount 칼럼 선택 후 id 속성을 cRequestedDiscount 로 변경합니다.


  


From 에서 NetRevenue, EffecitveDiscunt 필드 선택합니다.



Partial Triggers 속성을 설정합니다.



아래와 같이 선택합니다.



테이블에서 Product Name 칼럼의 id 값을 적어 놓습니다.


  


테이블의 ColumnStretching 속성을 설정합니다.



완성된 화면입니다.




Create a form for adding terms and conditions to the quote


requestTerms 뷰를 편집합니다.



Request Terms Template 을 선택합니다.



business-terms 부분에 Panel Collection 추가 후 License Term 데이터 컨트롤을 추가합니다.



Table - ADF Table 선택.



Select One Choice 컴포넌트를 Category 칼럼에 추가합니다.



Value: #{termChoices.categoryChoices} (ADF Managed Beans - termChoices - categoryChoices 선택)


Next 버튼 클릭.



Label: Category

Value: #{row.bindings.Category.inputValue} (같은 칼럼의 text 필드의 Value 속성 값)



Select One Choice 컴포넌트를 Type 칼럼에 추가합니다.



Value: #{termChoices.termTypeChoices}


Next 버튼 클릭.



Label: Type

Value: ${row.bindings.Type.inputValue}



추가 후 남아있는 텍스트 필드 두개를 삭제 합니다.


그리고 Create, Delete Operations 두개를 툴바로 추가합니다



바인딩을 하나 추가해줘야 합니다.


Bindings 탭으로 이동 후 컨트롤 바인딩을 추가합니다.



table 을 선택합니다.



Data Collection: AppModuleDataControl - TermView1


Select an Iterator 오른쪽에 New 버튼을 클릭합니다.



OK 버튼 클릭.



Available Attributes 목록에 있는 필드를 전부 Display Attributes 목록으로 옮깁니다.


OK 버튼을 클릭합니다.



아래와 같이 바인딩이 추가 되었습니다.




Create a submit form


마지막으로 submit 뷰를 편집합니다.



Submit Template 탬플릿을 선택합니다.



quote-summary 부분에 Summary 데이터 컨트롤을 추가합니다.


AccountName, SlaesRepName, TotalNetRevenue, EffectiveDiscount, ValidUntil 만 남기고 다른 필드는 삭제합니다.



TotalNetRevenue, EffectiveDiscount 필드의 readOnly 속성을 true 로 설정합니다.


products-discount 부분에 Panel Collection 컴포넌트를 추가합니다.


Product Item 데이터 컨트롤을 추가합니다.



ProductId, ProductName, Quantity, RequestedDiscount 필드만 남기고 삭제합니다.



license-terms 부분에 Panel Collection 컴포넌트 추가 후 License Term 데이터 컨트롤을 추가합니다.


마지막으로 Task 테이터 컨트롤을 comments 부분에 추가 후 Human Task - Task Comment And Attachment 클릭.


완성된 화면입니다.





Test

배치(Deploy) 후 bpm workspace에 접속합니다. (jcooper 계정으로 로그인)

프로세스를 하나 구동(?) 시킵니다.


enterHeader 화면입니다. Industry 값을 입력 후 2단계로 이동합니다.



2단계(selectProduct) 제품을 드래그 앤 드랍으로 선택할 수 있습니다.



3단계(requestDiscount) 화면은 수량과 할인율을 설정하는 화면입니다.



4단계 화면(requestTerms).



마지막 확인 화면(submit).







반응형
//
반응형
Implementing Approve Quote

Configuring the Human Task

ArroveDeal.task 파일을 열어 수정합니다.



Data 탭으로 이동합니다.

파라미터를 추가합니다. (other parameter)



Element 선택 후 찾기(돋보기) 버튼 클릭.



Quote.xsd - ApprovalFlow 선택.



OK 버튼 클릭.



quote.xsd - ApproveTaskInfo 도 같은 방법으로 추가해 줍니다.


General 탭으로 이동합니다.

Task Title 의 콤보를 Text and Xpath 으로 변경 후 XPath builder 버튼을 클릭합니다.



아래와 같이 입력합니다. (Schema 에서 찾아서 Insert 하는게 편함. ㅋㅋ)



앞에 "Approve Deal for " 를 붙여 줍니다.



Owner 콤보를 User 로 선택 후 찾기(돋보기) 버튼을 클릭합니다.



jstein 유저를 찾아서 선택합니다.



jstein 유저 확인. (직접 입력 해도 됨.)



Assignment 탭으로 이동합니다.

Stage1 부분을 더블 클릭 합니다.



Stage Name: Tier3



default.DefaultPerformer 더블 클릭.



Type: Serial
Label: SalesManagement



Build a list of particlpants using: Management Chain

Value-based 선택 후 유저(User) 추가.



데이터 타입(Data Type)을 수식(By Expression)으로 변경합니다.



... 버튼 클릭.



Identity Service Functions 에 있는 getManager() 함수를 이용하여 아래 조건식은 만듭니다.



Number of Levels: XPath

오른쪽에 XPath Builder 버튼을 클릭합니다.



아래와 같이 입력합니다.



완성된 Participant 수정 화면 입니다.

OK 버튼을 클릭합니다.



다시 Assignment 탭 화면 입니다.

Tier3(Stage)를 선택 하고, Sequential stage 를 추가합니다.



Tier3 아래에 stage 가 생성됩니다.

이름(Name)을 Tier2 로 변경 후 <Edit Participant> 부분을 더블 클릭 합니다.



아래와 같이 설정합니다.

유저의 수식은 /task:task/task:payload/ns0:ApprovalFlow/ns0:Tier2Approvers 입니다.



한번더 Tier2 아래에 스테이지를 추가합니다.



추가한 스테이지의 이름을 Tier1 으로 변경하고 <Edit Paricipant> 더블 클릭.



아래와 같이 설정 합니다.

Name 오른쪽의 찾기 버튼을 클릭합니다.



Tier1ApprovalGroup 를 선택합니다.

※ 만약 여기서 Tier1ApprovalGroup 이 보이지 않느다면 그냥 수동으로 입력합니다.



OK 버튼을 클릭합니다.



Adding a data assignment

BPM Project Navigator 에서 QuoteProcessLab 를 편집합니다.

Approve Deal 액티브티를 더블 클릭하여 수정 합니다.



Implementation 탭에서 Edit Data Associations 버튼을 클릭합니다.



approvalFlow 데이터를 Input 쪽에 넣어줍니다.



Deploy the application

모두 저장 후 배치(Deploy) 합니다.



Running

Creating the approval group

Tier1ApprovalGroup 이 존재하는지 확인해봅시다.

BPM Workspace 에 접속합니다. (weblogic 관리자 계정으로 로그인)

Administration - Approval Groups 로 이동합니다.

Tier1ApprovalGroup 그룹이 없으면 만들고 그룹에 속한 유저로 cdoyle 를 등록해줍니다.

※ 전 그룹이 이미 만들어져 있었습니다. -_-;




Hierarchy of users

아래 그림은 테스트할 유저들의 조직도입니다. 이 조직도를 잘 봐야 합니다.



Instantiate a new process

jcooper 계정으로 bpm workspace 에 로그인하여 주문의 만듭니다.

이때 주문자를 wshake 계정으로 합니다.


비지니스 룰(Business Rule)에 따라 결제가 어떻게 달라지는지 테스트 해보겠습니다.

아래 그림의 3가지 조건을 테스트 해보겠습니다.



R1 조건

아래 그림 흐름을 보면 이해가 될 것입니다. (안돼면......)

Approval Deal 에서 NumOfTeir3Levels 값에 의해서 주문자(wshake) 보다 한단계(0) 위에 있는 사람(rsteven)까지 결제를 하게 됩니다.




R2 조건

discount가 0.4 가 되서 NumOfTier3Levels 가 1이 됩니다.

그럼 Approve Deal 의 Tier3에서는 2단계 위의 사람(rsteven, jsteion)까지 결제를 하게 됩니다.




R5 조건

비지니스룰의 결과에 따라 NumberOfTier3Levels 가 2가 되고, Tier2 단계의 결제자가 2명이 되었습니다.



주문자(wshake)를 기준으로 NumOfTier3Levels 값에 따른 결제자의 목록입니다.







반응형
//
반응형
Introduction

정해진 업무의 규칙에 따라서 처리를 하게 할 수 있습니다.



Creating and Using New Business Rules

Adding Business Rules Activity

QuoteEntered(Measurement)와 IS Business Practices Review required?(XOR) 사이에 Business Rule 액티브티를 추가합니다.



Name: Determine Approvals




Adding Data Object to hold rules results

Business Object 를 추가합니다.



Name: ApprovalFlow
Destination Module: Data

Based on External Schema 체크 후 찾기 버튼 클릭.



Quote.xsd - ApprovalFlow 선택.



OK 버튼을 클릭합니다.



RequestQuoteLab BPM 편집 화면의 구조 패널에서 Process Data Object 를 추가합니다.



Name: approvalFlow
Type: <Component>

찾기(돋보기) 버튼을 클릭합니다.



ApprovalFlow 선택.



OK 버튼을 클릭합니다.




Creating new Rules Dictionary[각주:1]

DeterMine Approvals(Business Rule)를 더블클릭하여 편집 합니다.

Implementation 탭으로 이동 후 Business Rule 을 추가합니다. (녹색 + 버튼)

 



Name: ApprovalRules

Input Data Object 를 추가합니다.



RequestQuoteLab - quote 를 추가합니다.



방향(Direction)을 출력(Output)으로 변경 후 approvalFlow 를 추가합니다.


OK 버튼을 클릭하면 Business Ruels Dictionary 이 만들어집니다.




Bind Business Rules Activity to Implementation

Use Associations 체크 후 편집(연필) 버튼을 클릭합니다.

 



입력에는 quote, 출력에는 approvalFlow 를 넣어줍니다.




Defining Rules

Now it's time to define the rule within the dictionary you just created.


Adding Decision Table Rules

ApprovalRules.rules 를 열어서 편집합니다.



Globals 탭으로 이동합니다.

추가 버튼을 클릭합니다.



Name: preApprovedDiscount
Type: double

Value 오른쪽의 Expression builder 버튼을 클릭합니다.



0.3 을 입력합니다.



Final 체크 후 OK 버튼을 클릭합니다.



같은 방법으로 추가합니다.

Name: tier2Approvers-base
Type: String
Value: "wfaulk" // 쌍따옴표(") 포함!



Name: tier2Approvers-high
Type: String
Value: "wfaulk,jlondon"



총 3개의 글로벌 변수(인듯?)가 추가되었습니다.



Bucketsets 탭으로 이동합니다.

추가 버튼 클릭 - List of Ranges 클릭.



Bucketset3 이 추가되었습니다. 선택 후 편집 버튼을 클릭합니다.



Name: DiscountBuckets

아래와 같이 4개의 Range Bucket Values 를 설정합니다.



또 하나의 Bucketset 을 추가합니다.

Name: RevenueBuckets

아래와 같이 Range Bucket Values 를 추가합니다.



2개의 Bucketset 을 추가하였습니다.



Ruleset1 탭으로 이동합니다.



DecisionTable1 이라고 되어 있는 이름을 ApprovalMatrix 로 변경합니다.



조건(condition)을 추가합니다.



<edit condition> 부분을 더블클릭 후 수식편집(Expression Builder) 버튼을 클릭합니다.



Variables 탭에서 QuoteSummaryType - effectiveDiscount 를 선택 후 Insert Into Expression 버튼을 클릭합니다.



뒤에 <=  를 입력하고 Constants 탭에서 preApprovedDiscount 를 수식에 추가합니다.



수식이 완성되었습니다. OK 버튼을 클릭합니다.



조건을 하나 추가 후 <edit condition> 더블 클릭 후 effectiveDiscount 를 선택합니다.



조건 추가 후 totalNetRevenue 를 선택합니다.



아래와 같이 3개의 조건이 추가 되었습니다.


두번째 조건(QuoteSummary.effectiveDiscount) 선택 후 Local List of Ranges 콥보 클릭 후 DiscountBuckets 선택.



세번째 조건(QuoteSummaryType.totalnetRevenue)은 RevenueBuckets 를 선택합니다.



Assert New 액션을 추가합니다.



assert new 부분을 더블클릭 합니다.



Facts: ApprovalFlowType

Properties 에 나오는 모든 Parameterized 를 체크합니다.



아래와 같이 액션이 만들어졌습니다.



R1 아래 첫번째 라인(C1)의 ? 를 클릭 후 true 를 체크합니다.



Rule 을 추가합니다.



새로 추가된 룰(R1)에 첫번째 라인(C1) ? 를 클릭 후 false 를 선택합니다.



그러면 false 로 선택한 Rule 이 두번째로 이동 했습니다. (햇갈리지 마세용!)

R2 의 두번째 라인(C2) ? 를 클릭 후 <0.3 과 (0.3, 0.6) 을 체크합니다.



이런식으로 R4 까지 완성 합니다.

나머지 설정 안한 ? 부분은 해당 셀에서 오른쪽 버튼 클릭 후 Don't Care 를 클릭합니다.



? 표시가 - 표시로 바뀌었습니다.

Action 쪽도 아래 그림처럼 완성해줍니다.



R4 의 Confilict 셀(R3)을 더블클릭합니다.



Resolution 칼럼의 콤보를 Override 로 변경합니다.



비지니스 룰(Business Rule)이 완성되었습니다.



아래의 흐름(Flow)을 수정합니다.



아래와 같이 조건을 변경합니다.

비지니스 룰을 거쳐서 나온 결과를 비교합니다.




Testing

인스턴스 생성 후 EM에서 확인해봅시다.



비지니스 룰을 거쳐 갔습니다.

출력 데이터를 확인 해봅시다.




이 부분에 대해서는 9장에서 자세히 다루겠습니다.





9장 후다닥하느라 8장까지 완료한 소스를 따로 안 빼놨네요 -_-;;;
  1. (컴퓨터의) 사전[딕셔너리] [본문으로]
반응형
//
반응형
Introduction

In this exercise, you publish the BPM Project to MDS and open the published project in Process Composer. In addition, you also convert the BPM Project as a template and open this template inside Process Composer to create a new project.

Objectives

After completing this lesson, you will know how to:
  • Publish BPM projects inside BPM Studio to MDS.
  • Open published BPM Projects inside Process Composer
  • Convert BPM Project to template and publish template to MDS
  • Create new BPM Project out of template inside Process Composer


Set up MDS Connection

Resource Palette 에서 Database Connection 을 추가합니다.



접속 정보를 입력합니다.

Connection Name: bpm_ps3_db

BPM 도메인 생성시 설정했던 데이터베이스 스키마중 하나("{접두어}_MDS")입니다.



SOA-MDS Connection 을 추가합니다.



Connection Name: bpm_ps3_mds
Connection Type: DB Based MSD
Connection: bpm_ps_db (방금 만들었던 데이터베이스 커넥션)



BPM MDS Navigator(안보이면 View - BPM MSD Navigator)에서 커넥션을 설정합니다.



MDS Connections: bpm_ps3_mds (방금 만들었던 SOA_MSD 커넥션)



아래와 같이 두개의 폴더가 표시됩니다.




Publish BPM Project in BPM Studio to MDS

BPM Project Navigator 에서 QuoteProcessLab 선택 후 마우스 오른쪽 버튼 클릭 - Public to BPM MDS 클릭.



Project Name: QuoteProcessLab

Override 체크 후 Location 에서 폴더를 추가합니다.



Name: QuoteToCashLab



OK 버튼 클릭.



BPM MDS Navigator 에 보면 발행(Publish)된 것을 볼 수 있습니다.





View the Published BPM Project

BPC(Business Process Composer)에 접속합니다. (weblogic 계정으로 로그인)



화면에 발행한 BPM 프로젝트가 보입니다. 제목을 클릭합니다.



아래와 같이 볼 수 있습니다.




Publish process template to MDS

BPM Project Navigator 에서 QuoteProcessLab 선택 후 마우스 오른쪽 버튼 클릭 - Convert to template 클릭.



아래와 같이 경고가 나옵니다. 되돌릴 수 없다고 합니다...

이 부분부터 진행을 하게 되면 이 프로젝트는 일반 BPM 프로젝트가 아니라 템플릿 프로젝트가 됩니다.

서버에 직접 배치도 안됩니다.



Approve Terms 액티브티를 편집합니다.



Permissions: Must implement



액티브티 이미지에 아이콘이 하나 더 달렸습니다.



MDS에 발행합니다.

여기서 보면 위치가 Templates 아래인 것을 확인할 수 있습니다.





Creating a new BPm Project from a template

BPC에 접속(weblogic 계정) 후 Create New Project 를 클릭합니다.

1단계
전에 배포한 QuoteProcesslab 선택.

2단계
Name: QuoteProcessLab_Custom
Enable Sharing, Begin editing new 체크

3단계
Next 버튼 클릭.



4단계
Respository - QuoteToCashlab 선택.

5단계
뭔지 몰름 -_-;;

6단계
Create 버큰 클릭.



QuoteProcessLab_Custom 편집 화면 입니다.

보면 오른쪽에 컴포넌트 팔레트가 있고, Approve Terms 에 빈 조각 구멍이 나 있습니다.


컴포넌트 팔레트는 Basic Flow Objects, BPMN Flow Objects, Business Catalog 3개로 구성되어 있습니다.

 


ApproveTerms(Suman Task)를 구멍난 Approve Terms 에 드래그합니다.



구멍이 채워졌습니다!!

채워진 Approve Terms 선택 후 Data Association 버튼을 클릭합니다.



아래와 같이 Data Object 를 넣습니다.



validate 버튼을 클릭합니다.



에러가 없다고 나옵니다. Save 버튼을 클릭하여 저장합니다.



Editing 상태의 버튼을 클릭하여 발행(Publish) 합니다.



Tools 클릭 - Deploy Project 클릭. 배치합니다.



New Revision ID: 1.0
Deployer username: weblogic
Password: welcome1
Deploy Target: default

Deploy 버튼 클릭.



배치가 완료 되었습니다.


※ 그냥 배치를 해보면 네임스페이스가 중복된다면서 배치가 안될 것입니다.

기존에 배치되어 있던 QuoteProcessLab 조합(Composite)을 배치 해제한 후 배치해 봅시다.





반응형
//
반응형

Setting Up for Monitoring with Oracle BAM


Configuring BAM Adapter


웹로직 콘솔에 접속합니다.

디플로이(Deployments) 화면에서 OracleBamAdapter 선택.



Configuration 탭 - Outbound Connection Pools 탭으로 이동합니다.

eis/bam/soap 클릭.



BAM 서버의 정보에 맞게 입력합니다.

HostName: localhost
Password: welcome1
PortNumber: 9101
UserName: weblogic

Save 버튼 클릭.


적당한 위치에 BAM Plan 파일을 저장합니다.



다시 디플로이 목록에서 OracleBamAdapter 선택 후 Update 버튼 클릭.


Finish 버튼 클릭.



Configuring BPM Engine for BAM Integration

Enterprise Manager(EM)에 접속합니다.

왼쪽 메뉴에서 Farm_{DOMAIN_NAME} - WebLogic Domain - soa_server 선택합니다.

WebLogic Server 콤보(selectbox)를 선택 후 System MBean Browser 선택.



왼쪽 트리에서 Application Defined MBeans - oracle.as.soainfra.config - Server: soa_server1 - BPMNConfig - bmpn 선택.

MBean 속성 정보에서 DisableActions 값을 삭제합니다.

Apply 버튼 클릭.



Importing BAM Monitor Express

Monitoring Express 샘플을 설치합니다.

콘솔에서 작업합니다.

// 미들웨어 홈 환경변수 등록
$ export MW_HOME=/home/weblogic/app/11.1.1.4.0
// 설정파일 수정
$ vi $MW_HOME/Oracle_SOA1/bam/config/BAMICommandConfig.xml

<BAMICommand>
  <!-- 추가 -->
  <ICommand_Default_User_Name>weblogic</ICommand_Default_User_Name>
  <ICommand_Default_Password>welcome1</ICommand_Default_Password>
  <!--// 추가 -->
  <ADCServerName>localhost</ADCServerName>
  <ADCServerPort>9101</ADCServerPort>

// 자바 홈 환경변수 등록
$ export JAVA_HOME=/usr/lib/jvm/java-6-sun
// monitoring express 설치 실행 디렉토리로 이동
$ cd $MW_HOME/Oracle_SOA1/bam/samples/bam/monitorexpress/bin
// 설치 실행
$ ./setup.sh

BAM Home =/home/weblogic/app/Oracle_SOA1/bam
Using JAVA_HOME=/usr/lisb/jvm/java-6-sun
Creating the Data Objects

Oracle BAM 명령 유틸리티 [빌드 13846, BAM 저장소 버전 2025] Copyright (c) 2002, 2011, Oracle and/or its affiliates. All rights reserved.
"/home/weblogic/app/Oracle_SOA1/bam/samples/bam/monitorexpress/data_objects/MonitorExpress_DataObjects.xml" 파일에서 임포트하는 중입니다.
/Samples/Monitor Express 폴더가 생성되었습니다.
"/Samples/Monitor Express" 폴더에 데이터 객체 "COMPONENT" 생성 중...
데이터 객체 "/Samples/Monitor Express/COMPONENT"이(가) 생성되었습니다.
"INSTANCE_IDS" 인덱스가 생성되었습니다.
임포트할 내용 섹션이 없습니다.
데이터 객체가 성공적으로 임포트되었습니다(0개 행).
"/Samples/Monitor Express" 폴더에 데이터 객체 "INTERVAL" 생성 중...
데이터 객체 "/Samples/Monitor Express/INTERVAL"이(가) 생성되었습니다.
"UPDATE_INDEX" 인덱스가 생성되었습니다.
임포트할 내용 섹션이 없습니다.
데이터 객체가 성공적으로 임포트되었습니다(0개 행).
"/Samples/Monitor Express" 폴더에 데이터 객체 "COUNTER" 생성 중...
데이터 객체 "/Samples/Monitor Express/COUNTER"이(가) 생성되었습니다.
"UPDATE_INDEX" 인덱스가 생성되었습니다.
임포트할 내용 섹션이 없습니다.
데이터 객체가 성공적으로 임포트되었습니다(0개 행).
"3" 항목이 성공적으로 임포트되었습니다.
Data Objects successfully created
Creating the Reports

Oracle BAM 명령 유틸리티 [빌드 13846, BAM 저장소 버전 2025] Copyright (c) 2002, 2011, Oracle and/or its affiliates. All rights reserved.
"/home/weblogic/app/Oracle_SOA1/bam/samples/bam/monitorexpress/reports/FaultReport.xml" 파일에서 임포트하는 중입니다.
"/public/Report/Samples/Monitor Express/Sub-reports/Fault Report" 보고서가 성공적으로 임포트되었습니다.
"1" 항목이 성공적으로 임포트되었습니다.

$

// 영어 로그




Configuring BPM Project for BAM Monitoring

BPM Projects Navigator 에서 QuoteProcessLab 에서 오른쪽 버튼 클릭 - Proejct Preferences 클릭.



Category - Process Analytics Summary

Data Targets 탭 선택.

Enable BAM 체크.

Data Object Path: /Samples/Monitor Express




Creating Process Specific BAM Data Object

Oracle BAM 접속. (weblogic 계정으로 로그인)

Architect 버튼 클릭.

/Samples/Monitor Express 폴더에서 BI_default_QuoteProcessLab_RequestQuoteLab 데이터 오브젝트 선택.

Layout 클릭.



Edit Layout 버튼 클릭.



아래와 같이 필요한 필드를 추가해줍니다.


Save changes 버튼 클릭 - Continue 버튼 클릭.




Creating BAM Dashboards

Oracle BAM 접속. (weblogic 계정으로 로그인)

메인 화면에서 Active Studio 버튼 클릭.

Shared Reports 탭으로 이동 후 Create A new Report 버튼을 클릭합니다.



세로 2단 템플릿을 선택합니다.



타이틀 부분은 Request Quote Dashboard 입력.

첫번째 영역은 "3D Bar Chart"를 선택합니다.



그러면 화면 아래쪽에 설정 마법사(?)가 뜹니다.

Data Object: BI_default_QuoteProcessLab_RequestQuoteLab 선택.

Next 버튼 클릭.



필드를 설정합니다.

Group By: METRIC_RANGE_revenueDimesion, METRIC_industry
Chart Values: METRIC_discount
Summary Function(s): Average

Next 버튼 클릭.



Change View Properties 클릭.



General 탭으로 이동합니다.

View title: Discounts by Revenue and Idustry
Vetical Axis Label: Discount%




Data 부분의 Fields 탭으로 이동합니다.

Group By 중에서 industry 를 선택하고 화살표를 이용하여 최상위로 올립니다.

OK 버튼 클릭.



아래의 영역은 Range Gauge 를 선택합니다.



Data Object: BI_default_QuoteProcessLab_RequestQuoteLab 선택 후 Next 버튼 클릭



가운데 콤보는 METRIC_discount 선택.
그 바래 콤보는 Average 선택.

Next 버튼 클릭.



Change View Properties 클릭.



View Title: Discount Gauge
Value display ranges: 0, 30, 65, 90

Apply 버튼 클릭 - OK 버튼 클릭.



Save 버튼 클릭



Shared Reports/Samples/Monitor Express 폴더에 Request Quote Dashboard 이름으로 저장.



저장 되었습니다.




Viewing BAM Dashboards

OracleBAM 로그인 후 Active Viewer 클릭.



Select Report 버튼 클릭.



Shared Reports/Samples/Monitor Express 폴더에 Request Quote Dashboard 선택.



데이터를 좀 넣으면서 보면 실시간으로 갱신 됩니다.


이번에는 샘플로 깔았던 기본 Express Dashboard 를 열어봅시다.



아래와 같이 총 통계를 볼 수 있습니다.





Create an Alert for a High Discount Sales Quote

discount 의 평균이 지정한 수보다 높으면 경고가 나는 Alert 기능을 만들어보겠습니다.

OracleBAM 로그인 후 Active Studio 클릭.



Create A New Alert 버튼 클릭.



시간대를 맞추라고 합니다. 현재 아시아 도쿄로 되어있네요...



Asia/Seoul 로 변경합니다.



OK 버튼 클릭.



Create A Rule 클릭.



Rule Name: HighDiscount Alert

"When a data field in report meets specified conditions" 선택 후 Rule Expression 부분에서 "select report" 클릭.



Request Quote Dashboard 선택.



"this data field has condition of x" 클릭.



Data Objects: BI_default_QuoteProcessLab_ReuquestQuoteLab 선택.

Group Filter 탭으로 이동 후 "add new entry" 클릭.



Field: AVG(METRIC_discount)
Comparison: is greater than or equal to, Value
Value: 65

입력 후 "Add Entry" 클릭. (이걸 클릭 안하면 저장이 안됩니다)



OK 버튼 클릭.



Select an Action 에서 "Send a message via email" 체크 후 Rule Expression 영역에서 두번째 줄에 "create message" 클릭.



아래와 같이 입력 후 OK 버튼 클릭.

[AVG(...)] 처럼 빨간색으로 된 글씨는 아래 필드 부분에서 선택해서 삽입(Inert)한 것입니다.



"select user" 클릭.



"weblogic" 선택 후 OK 버튼 클릭.



완성 되었습니다. OK 버튼 클릭.



Active Studio 에서 Alert 탭을 보면 아래와 같이 등록되어 있습니다.


Active Studio 에서 Request Quote Dashboard 를 클릭합니다.



Edit 클릭.



Insert View 버튼클 클릭합니다.



Action List 를 선택합니다.



Data Object: Data objects/System/Alerts/History 선택.

Next 버튼 클릭.



Data Fields: MessageText, SentDate



Change View Properties 클릭



View Title: Alerts

OK 버튼 클릭.



레이아웃을 잘 조정하여 배치시킵니다.



저장 후 데이터를 경보가 발생되게 넣어봅시다. 그러면 아래와 같이 경보가 나옵니다.






반응형
//
반응형
Adding Process Analytics Specification to BPMN Process

In this lab, you add process analytics information to the Sales Quote process.

For the purposes of this lab, you analyze discounts offered to understand its distribution across deal sizes (total net revenue) and industries. At the end of this lab, you will have created the following dashboard:





Adding Business Indicators

Process Analytics capture standard data such as workload and cycle time and process specific data. Business Indicators are used to specify what process specific data should be captured.

There are 3 types of Business Indicators supported:

  • Measures – These are numerical data that typically signify a value that is interesting in process analytics. In this scenario, you create a measure for discount.
  • Dimensions – These specify how process analytic data may be sliced. A dimension has to have a finite set of values. In cases where it is not, such as for numbers and date/time, a set of ranges must be specified for the data. In this scenario, you create dimensions for industry and revenue, where revenue is a numerical dimension, and needs ranges to be specified.
  • Counters – As the name indicates, these are useful for counting iterations. In this scenario, you add a counter to count the number of times the quote needs to be revised. The number of iterations is clearly an interesting data point for analytics and can be used for creating dashboards as a challenge exercise.

RequestQuoteLab BPMN 프로젝트 편집 화면의 구조(Structure) 패널이 있습니다. // 없으면 View - Structure (Ctrl + Shift + S)
 
Business Indicators 에서 오른쪽 버튼 클릭 - New - Dimension 클릭.



Name: revenueDimension
Type: Int



추가 버튼을 이용해서 아래와 같이 범위(Range)를 입력합니다.



다시 Dimension 추가.

Name: industry
Type: String



Measure를 추가합니다.



Name: discount
Type: Int



카운트(Counter)를 추가합니다.



Name: numQuoteEdits





Assigning Data to Business Indicators

Now that we have defined our business indicators, we need to assign data to them. Business indicators behave just like other data objects regarding data assignment (association). That is, data can be assigned to them either as part of an activity’s output data association or within a Script activity.

Since, in this scenario, the Enter Quote Details output data association is already used for assigning to quote data object, use a Script activity to assign data to the business indicators from the quote data object.

"Enter Quote Details"와 "Is Business Practices Required?" 사이에 Script 액티브티를 추가합니다.



Name: Assign Indicators



Implementation 탭에서 Use Associations 채크 후 편집합니다.



discount, industry, revenueDimension 을 각각 축합니다.



quote - summary - industry 를 아래와 같이 industry variable에 추가합니다.

두번째 discount 인자 오른쪽의 "Expression Builder" 버튼을 클릭합니다.



round(quote.summary.effectiveDiscount) 입력.



세번째 인자인 revenueDimension 에는 round(quote.summary.totalNetRevenue) 입력.



아래와 같이 3개의 값을 설정 했습니다. OK 클릭.



OK 클릭.





Adding Measurement Mark

By default, process analytic data is specified at the project level and there are 3 settings possible:

  • Generate for interactive activities only
  • Generate for all activities
  • Do not generate

Measurement marks provide a way to add additional capture points. In addition to providing additional capture points, Measurement marks also:

  • Allow specification of a business name which can be used for filtering during analysis
  • Provide a visual notation to indicate the capture point

If it is someone’s preference not to have measurement marks displayed on the canvas, it is possible to specify equivalent capture points by using the Sampling Point property of preceding activity.

Measurement 를 "Assign Indicators"와 "Is Business Practices Required?" 사이에 추가합니다.



더블 클릭하여 수정합니다.



Measurement Type: Single Measurement
Name: QuoteEntered

"discount[Measure]" 를 선택합니다. (Selected 영역에 오게 합니다.)




Adding Counter

Enter Quote Detail 액티브티에서 마우스 오른쪽 버튼 클릭 - Add Counter Mark 클릭.



numQuoteEdits[Counter] 채크.




Running Instances to Create Sample Data

재배치(deploy)합니다.



수정하지 않은 taskflow 프로젝트는 배치하지 않아도 됩니다. (배치가 빨라짐)





Creating Dashboards

As described below, deploy the new version of the process and run a few instances so that during dashboard creation in the next section some data is already available to view.

bpm workspace 에 jcooper 계정으로 로그인합니다.

화면 상단 오른쪽에 문서 추가 버튼을 클릭합니다.



Name: SalesQuoteLab

Add Panel 버튼 클릭.



Panel: Dashboard (Charts) 선택 - OK 버튼 클릭.



Name: Chart

Data Source 오른쪽의 돋보기 아이콘 클릭.



New 버튼 클릭.



아래와 같이 정보를 입력합니다.

OK 버튼 클릭.




Apply 버튼 클릭.



상단 오른쪽의 Apply 버튼 클릭.



아래와 같이 SalesQuoteLab 탭에 차트가 하나 생성되었습니다. 지금은 데이터가 없는지 안나오는군요 -_-


※ 이제부터는 industry, revenue, discount 3개의 필드는 꼭 입력해야 합니다.





반응형
//
반응형
Using the Oracle BPM Workspace

Oracle BPM's Workspace is a web application that allows you to interact with a process in relation to your assigned role or roles within your company. The Workspace helps you to manage your tasks effectively and efficiently with minimal training. It serves as a portal, or window, into a business process for which you have an assigned role. When you select a pending task, the Workspace allows you to execute the transaction or transactions associated with the task. The Workspace allows you to access your work with an Internet browser from any location. You can use the Workspace interface like an e-mail reader to view incoming tasks for which you are responsible.

Workspace allows you to:
   • Invoke instance activity tasks
   • Route completed instances automatically to the user or system responsible for the next step in the process
   • Delegate required tasks to a specific end user
   • Perform operations on a batch of instances
   • Add notes and attachments to an instance of a process
   • Customize how your activities and instances are organized
   • View detailed activity documentation, notes, attachments, and audit trail information
   • Search for instances in processes



A Quick Tour of the BPM Workspace

흐름을 간단하게 설명화면 아래 그림과 같습니다.

 

01234




Triggering the Sales Quote Process

bpm workspace에 접속해서 jcooper 계정으로 로그인 합니다.

왼쪽 상단 Applicatinos 부분에 챕터3에서 배치한 어플이 보입니다. 한번 클릭 합니다.



새창으로 아래와 같은 주문 폼이 뜹니다. 일단은 창을 닫습니다.

※ Script 액티브티에 의해서 자동으로 주문이 생성된 것입니다.





Executing the Interactive Tasks and completing the Process

My Task 탭에서 새로고침 아이콘을 클릭합니다.



방금 전에 창을 닫았던 주문이 목록에 보입니다.

한번만 클립합니다. (더블클릭하게 되면 새 창으로 뜨게 됩니다.)

아래쪽에 코맨트와 첨부를 해봅시다. ㅎㅎ



SUBMIT 버튼 클릭.



SUBMIT 버튼을 클릭하면 jcooper의 작업 목록에서 사라지게 됩니다.

이제 cdickens 계정으로 로그인 합니다.

작업 목록에 보면 jcooper에 의해서 처리된 작업이 Approve Deal 단계로 작업에 올라와 있습니다.

일단 가볍게 승인(Approve 버튼)합니다.



wfaulk 계정으로 로그인 해보면 jcooper에 의해 처리된 작업이 Approve Terms 단계로 올라와 있습니다.

이것도 가볍게 승인!



작업 목록을 새로고침 해보면 Finalize Contracts 단계의 작업이 올라와 있습니다.

OK!



이렇게 하나의 처리가 완료 되었습니다.

주문(Quote) 파일을 저장하기로 했던 곳에 가보면 quote_{seq}.txt 파일이 저장되어 있습니다.



Monitoring the Process Instance using Workspace

다른 BPM 프로젝트의 상태를 확인해 봅시다.

bpm workspace에 jstein 계정으로 접속합니다.

Process Tracking 으로 이동해서 검색창 오른쪽의 "Advanced"를 클릭합니다.


Assigned: Anyone, at any Role in the process

OK 버튼 클릭.



하나의 작업이 진행 중이군요... (jcooper 계정으로 맨 처음 생성만 한 작업입니다.)



가운데에 Audit Trail 왼쪽의 화살표를 클릭해 봅시다.



처리가 어떻게 되가고 있는지 내용이 나옵니다.



Graphical을 선택하면 아래와 같이 그림으로 나옵니다.

현재 Enter QUote Details 에서 멈춰 있군요. ㅎㅎ






반응형
//
반응형
Introduction

In the first exercise, you built a basic process with roles, activities, and transitions. In this lesson, you will further enhance the process by creating data types, variables, Task Services, Rule Services, and Adapter Services and binding them to the process activities.

Objectives

After completing this lesson, you will know how to:
   • Implement Process Activities and create Task, Rule and Adapter Services
   • Define the different kinds of Data Objects (variables)
   • Define Data Inputs and Data Outputs (arguments)
   • Map arguments to instance variables

The tasks you will complete in this lesson are:
   • Understanding of Business Catalog
   • Define Task Services and map to Interactive Tasks
   • Define Rule Services and map to Rule Task
   • Define Adapter Services and map to Service Task.
   • Create Business Objects (data types)
   • Create Data Inputs (input arguments) and Data Outputs (output arguments) for process and process steps
   • Create Variables (Data Objects)
   • Create Data Mappings



Create a Business Object



QuoteProcessLab - Business Catelog 에서 마우스 오른쪽 버튼 클릭 - "New - BusinessObject" 클릭.



Business Object: Quote

Destination Module 오른쪽의 돋보기 아이콘을 클릭합니다.



Module 버튼 클릭.



Module: Data



"Data" 선택.



Based on External Schema 선택 후 오른쪽의 돋보기 클릭.



Import 버튼 클릭 후 URL 오른쪽의 돋보기 버튼 클릭.



Quote.xsd 파일 선택.



"Copy to Project" 체크.



"Maintain original directory structure for imported files" 체크 해제.



QuoteRequest 선택.



OK 버튼 클릭.




Data Inputs and Data Outputs

Data Input refers to the information required to start the Activity (Task, Sub-process) or Process. It is the input argument. A collection of Data Inputs is referred to as an Input Set.

Data Output refers to the data that is returned from the Activity or Process. It is the output argument. A collection of Data Outputs is referred to as an Output Set.

The Start Event has only Output Set. The End Event has only Input Set. Other activities can have both Input and Output Sets.

The Output Set of the Start Event and the Input Set of the End Event determine the arguments of the Process.



Note: As you will see in later section, the input and output arguments of the process step is the same as the inputs and outputs of the Service (Task, Rules, or System) that it is bound to.



Creating Data Objects

아래와 같이 5개의 Process Data Object를 만들어야 합니다.



BPM 프로세스가 열려 있는 상태에서 왼쪽 하단의 구조(Structure) 창에서 작업합니다.

"Process Data Objecs" 에서 마우스 오른쪽 버튼 클릭 - New 클릭.



Name: approveDealOutcome
Type: String



Name: approveTermsOutcome
Type: String



Name: businessPracticesOutcome
Type: String



Name: businessPracticesReviewRequire (d는 짤림 -_-)
Type: Bool



기본형(?)이 아닌 타입의 선택 방법은 아래와 같습니다.

Name: quote
Type: <Component>

오른쪽의 돋보기 클릭.



Quote 선택



OK 클릭.




Implementing Enter Quote Details


Defining the Task Service

"Enter Quote Details" 액티브티를 더블 클릭하여 편집합니다.



Implementation 탭으로 이동합니다.

Human Task 오른쪽의 Add 버튼을 클릭합니다.



Name: EnterQuoteDetails
Pattern: Initiator
Title: Enter Quote

Parameters: 오른쪽의 추가 버튼을 클릭합니다. 오른쪽에 "Browse Data Objects" 창이 열립니다.

RequestQuoteLab - quote 를 파라미터 영역에 드래그 합니다.



아래와 같이 추가가 되면 Enable 을 체크 합니다. OK 버튼 클릭.



OK 버튼 클릭.



QuoteProcessLab -  Business Catalog - HumanTasks 에 보면 방금 만든 휴먼 테스크가 하나 추가되어 있습니다.

"EnterQuoteDetails.task" 더블 클릭.



Task Title: Text and XPath

오른쪽의 Expression Builder 버튼 클릭.



아래와 같이 입력. (Expression Builder 이용)

concat('Enter Quote Details for customer', /task:task/task:payload/ns0:QuoteRequest/ns0:Summary/ns0:AccountName, 'Quote id = ', /task:task/task:payload/ns0:QuoteRequest/ns0:Summary/ns0:OpportunityID)



Generate Form for the Task

Create Form 클릭 - Auto-Generate Task For... 클릭.



Project Name: EnterQuoteUILab



아래와 같이 ADF 프로젝트가 생김. 전부 저장 후 닫기.



Bussiness Practices Review, Approve Deal, Approve Terms, Finalize Contract 4개의 액티브티도 동일한 방식으로 Human Task를 생성합니다.

"Business Practices Review" Human Task 생성.








BusinessPracticesReview.task 파일 편집(더블 클릭)







Approve Deal 구현






Approve Terms 구현





Finalize Contracts 구현



Outcomes 변경.



"Finalize Contracts"의 outcome은 OK 만 설정합니다.







Mapping swim lane Roles to LDAP Roles

"Organization"에서 오른쪽 버튼 클릭 - Open 클릭



Roles 탭에서 작업합니다.

SalesRep 롤 선택 후 맴버를 등록합니다. (웹로직에 등록되어있는 유저를 찾기)



jcooper 유저를 선택합니다.



Approvers 롤은 cdickens 유저.



Business Practices 롤은 jstein 유저.



Contracts 롤은 wfaulk 유저.



Process Owner 롤은 jstein 유저.




Configuration of the Service Task

Now complete the following to add a service to your application which implements the SaveQuote Service Task. First you create the service by adding a Service Reference to the application using the composite editor. Then, you go back to the BPM process and bind the service to the SaveQuote Service Task.

BPM 편집기 상단 오른쪽의 "Goto Composite Editor" 버튼을 클릭합니다.



"File Adapter"를 추가합니다.



Service Name: SaveQuote





Write File 선택.



Directory for Outgoing Files: /tmp/quotes (원하는 곳으로 설정)

File Naming Convention: quote_%SEQ%.txt



메세지 구조를 설정합니다.

URL 오른쪽의 돋보기 버튼 클릭.



Quote.xsd - QuoteRequest 선택.



Next 버튼 클릭.



Finish 클릭.



아래와 같이 File Adapter 컴포넌트가 생성 되었습니다.



다시 BPM 편집기로 넘어와 "Save Quote" 액티브티를 편집합니다.



Implementation: Service Call

Name 오른쪽의 돋보기 버튼 클릭.



"SaveQuote" 선택.



Use Associations 선택 후 편집(연필) 버튼을 클릭합니다.



아래와 같이 오른쪽의 "quote"를 왼쪽의 Input 으로 드래그합니다.



OK 버튼 클릭.



Business Catelog - Services 부분에 SaveQuote 가 추가되어 있는 것을 볼 수 있습니다.





Data Association configuration for conditional flows

The outcomes of the Business Practices Review, Approve Deal and Approve Terms Interactive tasks have to be evaluated for conditional branching. The task outcome of these tasks is a string value of “APPROVE” or “REJECT”. You set these outcomes when you defined the task. The outcomes get mapped to the Data Objects so you can then use the Data Objects in the conditional expressions used for branching.

"Business Practices Review" 액티브티를 열어 편집합니다.

Implementation 탭에서 "Use Associations" 체크 후 편집합니다.



아래와 같이 "businessPracticesOutcome" 데이터를 outcome 출력 인자에 추가에 매핑합니다.



Approve Deal 액티브티는 approveDealOutcome 데이터를 outcome 출력 인자와 매핑합니다.



Approve Terms 액티브티는 approveTermsOutcome 인자.



Business Practices Rejected(Sequence Flow)를 편집합니다.



Properties 탭에서 businessPracticesOutcome == "REJECT" 입력.




Deal or Terms Rejected(Sequence Flow)를 편집합니다.



approveDealOutcome == "REJECT" or approveTermsOutcome == "REJECT"



Business Practices Revie(User)로 가는 Yes(Sequence Flow)를 편집합니다.



businessPracticesReviewRequire == true





Configuration of Script Tasks

Finally, you need to add a Script Task to set the payload (the input data) for the Enter Quote Details task and to determine whether the Business Practices Review activity is required or not. The script goes right before Enter Quote Details. Using a script to set the input data makes testing this process easier but when running such a process for real, the user who initiates the task would enter the input data.

Script(Activity)를 Start와 Enter Quote Details(Activity) 사이에 추가합니다.



Name: Initialize Quote



Implementation 탭에서 User Associations 채크하고 편집합니다.



아래와 같이 quote 데이터를 중앙에 드래그 합니다.



Expression Builder 버튼 클릭.



Mode: XML Literal

<ns1:QuoteRequest xmlns:ns1="http://www.mycompany.com/ns/salesquote">
  <ns1:Summary>
    <ns1:OpportunityID>zzzz2</ns1:OpportunityID>
    <ns1:AccountName>Acme New</ns1:AccountName>
    <ns1:Address>
      <ns1:Street>Demo Way</ns1:Street>
      <ns1:City>Redwood Shores</ns1:City>
      <ns1:State>CA</ns1:State>
      <ns1:Zip>94065</ns1:Zip>
      <ns1:Country>USA</ns1:Country>
    </ns1:Address>
    <ns1:SalesRepId>jcooper</ns1:SalesRepId>
    <ns1:SalesRepName>James Cooper</ns1:SalesRepName>
    <ns1:ValidUntil>2010-05-30</ns1:ValidUntil>
    <ns1:EffectiveDiscount>0.0</ns1:EffectiveDiscount>
  </ns1:Summary>
  <ns1:QuoteRequestStatus/>
</ns1:QuoteRequest>



businessPracticesReviewRequire 데이터를 추가합니다.



Expression Builder 클릭.



Mode: XPath Exp.

Expression: false()



OK 버튼 클릭.



Enter Quote Details(Activity)의 Data Associations 편집 화면에서 uuote 데이터를 quoteRequest 입력 인자에 추가합니다.




Deploying the process

배치 합니다.





관련된 Human Task 프로젝트도 같이 배치합니다.












반응형
//