Loading
보험
InsProductService: runRules

InsProductService: runRules

이 서비스를 사용하여 해당 제품의 가격을 조정하지 않고 제품에 대한 규칙을 실행합니다.

클래스: InsProductService

방법: runRules

작동 방법

  1. 서비스는 입력 JSON에서 selectedProduct 키를 검색합니다.

  2. selectedProduct 노드에서 규칙을 실행합니다.

    실행되는 규칙 집합은 True로 설정된 원격 옵션에 따라 다릅니다.

  3. selectedProduct 노드에 추가된 규칙의 결과와 함께 JSON을 반환합니다.

원격 옵션

옵션

설명

ruleAttributeSetValues

true 또는 false

기본값은 true입니다.

true이면 서비스에서 특성 집합 값 규칙을 실행합니다.

evalOptionalCoverageRelationship

true 또는 false

기본값은 false입니다.

이 옵션이 true로 설정되면 서비스에서 사용 가능한 규칙을 기준으로 선택적 보장 관계를 평가하고 영향을 받는 선택적 보장 레코드의 isSelected 플래그를 업데이트합니다.

runDefaultSelected

true 또는 false

true로 설정하면 선택한 제품에 대해 기본 선택된 보장 규칙을 실행합니다.

runEligibility

true 또는 false

true로 설정하면 선택한 제품에 대한 적격성 규칙을 실행합니다.

규칙이 false로 평가되는 경우 서비스에서 선택적 적용 범위의 isEligible 노드를 false로 설정합니다.

runRequiredCoverage

true 또는 false

true로 설정하면 옵션 적용 범위 필수 보장 규칙을 실행합니다.

validateCoverageSelection

true 또는 false

기본값은 false입니다.

이 옵션이 true로 설정되면 서비스에서 사용 가능한 규칙에 따라 선택 가능한 보장 범위를 확인합니다.

규칙이 false로 평가될 경우 서비스에서 영향을 받는 옵션 적용 범위 레코드에 메시지 노드를 추가합니다.

입력 JSON

이 서비스는 입력 JSON의 selectedProduct 키에서 제품 개체를 찾습니다. 이 객체는 getRatedProducts와 같은 다른 서비스에서 만들 수 있습니다. 루트 제품, 하위 제품, 손자 제품이 포함됩니다.

이 예에는 서비스에서 규칙을 실행하기 전에 입력 노드가 하나만 포함되어 있습니다.


"Name": "Accidental Death",
                    "Description": "An accidental death benefit rider also known as a double indemnity clause provides a higher death benefit to the beneficiaries of the policy in case the insured dies because of an accident. The death benefit is generally a multiple of the face value of the base coverage.",
                    "Family": "Individual Life",
                    "ProductCode": "ADDCOV",
                    "LineOfBusiness__c": "Individual Health",
                    "Type__c": "Coverages",
                    "IsRecommended__c": false,
                    "PricingSource__c": "premiumADD",
                    "RecordTypeName__c": "CoverageSpec",
                    "IsConfigurable__c": true,
                    "productId": "01t1U000000OEamQAG",
                    "pciId": "a2w1U0000001G4YQAU",
                    "selectValidationCriteria": "[{\"expression\":\"WOP.isSelected == true\",\"code\":\"code_0\"}]",
                    "selectValidationMessage": "[{\"message\":\"WOP must be true\",\"severity\":\"INFO\",\"code\":\"code_0\"}]",
                    "isOptional": true,
                    "isSelected": true,
                    "parentInstanceKey": "Jack Kirkland",
                    "Price": 358,
                    "pathFromRoot": "[0].childProducts.records[2].childProducts.records[2]",
                    "formattedParentInstanceKey": "jack-kirkland",
                    "parentProductName": "Jack Kirkland",
                    "originalIndex": 2,
                    "numberCategories": 18,
                    "numberAttributes": 18,
                    "popoverOpen": false,
                    "isOriginalOptional": true,
                    "isAddedOptional": true,
                    "showTypeHeader": true,
                    "displaySequence": 1                 

preTransformBundle Alternative

또는 입력 JSON에 전달된 데이터를 서비스에 필요한 형식으로 매핑하는 Omnistudio 데이터 매퍼 변환을 정의할 수 있습니다. 이 데이터 매퍼의 출력 JSON은 runRules에 필요한 selectedProducts 노드입니다. 이 서비스를 OmniScript에 추가할 때 서비스에서 Data Mapper를 사용하도록 데이터 매퍼의 이름으로 preTransformBundle를 설정합니다.

출력 JSON

서비스는 규칙 실행 결과와 함께 selectedProduct 노드의 JSON 구조와 동일하게 반환합니다. 이 객체의 내용과 구조에 대한 자세한 내용은 제품 JSON 구조 모델을 참조하십시오.

이 예에는 서비스가 규칙 실행 결과와 함께 규칙을 실행한 후 출력 노드가 하나만 포함되어 있습니다.

"messages": [
                    {
                      "code": "code_0",
                      "severity": "INFO",
                      "message": "WOP must be true"
                    }
                  ],
                  "displaySequence": 1,
                  "lastNonOptional": true,
                  "firstOptional": true,
                  "Id": "01t1U000000OEamQAG",
                  "Name": "Accidental Death",
                  "Description": "An accidental death benefit rider also known as a double indemnity clause provides a higher death benefit to the beneficiaries of the policy in case the insured dies because of an accident. The death benefit is generally a multiple of the face value of the base coverage.",
                  "Family": "Individual Life",
                  "ProductCode": "ADDCOV",
                  "LineOfBusiness__c": "Individual Health",
                  "Type__c": "Coverages",
                  "IsRecommended__c": false,
                  "PricingSource__c": "premiumADD",
                  "RecordTypeName__c": "CoverageSpec",
                  "IsConfigurable__c": true,
                  "productId": "01t1U000000OEamQAG",
                  "pciId": "a2w1U0000001G4YQAU",
                  "selectValidationCriteria": "[{\"expression\":\"WOP.isSelected == true\",\"code\":\"code_0\"}]",
                  "selectValidationMessage": "[{\"message\":\"WOP must be true\",\"severity\":\"INFO\",\"code\":\"code_0\"}]",
                  "isOptional": true,
                  "isSelected": true,
                  "parentInstanceKey": "Jack Kirkland",
                  "Price": 358,
                  "pathFromRoot": "[0].childProducts.records[2].childProducts.records[2]",
                  "formattedParentInstanceKey": "jack-kirkland",
                  "parentProductName": "Jack Kirkland",
                  "originalIndex": 2,
                  "numberCategories": 18,
                  "numberAttributes": 18,
                  "popoverOpen": false,
                  "isOriginalOptional": true,
                  "isAddedOptional": true,
                  "showTypeHeader": true,                                             
 
로드 중
Salesforce Help | Article