Coder Social home page Coder Social logo

zfrk / cloud-extension-s4hana-business-process Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sap-samples/cloud-extension-s4hana-business-process

0.0 0.0 0.0 62.33 MB

This sample showcases how to complement an existing business process in an SAP solution – currently SAP S/4HANA, with additional business process steps. This involves adding major logic and/or additional data.

License: Apache License 2.0

JavaScript 64.86% HTML 13.24% CAP CDS 21.89%

cloud-extension-s4hana-business-process's Introduction

SAP S/4HANA Extended Business Process Scenario

REUSE status

Description

The main intent of this scenario is to complement an existing business process in an SAP solution – currently SAP S/4HANA with additional business process steps. This involves adding major logic and/or additional data and goes beyond simple UI changes.

This application showcases:

  • Building applications on SAP Business Technology Platform (BTP) using SAP Cloud Application Programming Model(CAP)
  • Consuming events from SAP S/4HANA on premise using SAP Event Mesh
  • Consuming REST APIs from SAP S/4HANA on premise using SAP Business Technology Platform Connectivity Service

Business Scenario

A business scenario is used to showcase how to build a S/4 HANA on premise extension Application on SAP BTP.

John who is an employee of Business Partner Validation Firm iCredible, which is a third-party vendor of ACME Corporation would like to get notifications whenever new Business Partners are added in the S/4HANA backend system of ACME Corporation. John would then be able to review the Business Partner details in his extension app. He would proceed to visit the Business Partner’s registered office and do some background verification. John would then proceed to update/validate the verification details into the extension app. Once the details are verified, the Business Partner gets activated in the S/4HANA system of ACME Corporation.

  • Custom extension application that works independently from S/4HANA.

  • Changes in S/4 communicated via events in real time to extension application.

  • Compute intensive processing available on demand (serverless environment).

  • Vendor personnel needs access to only custom app

Architecture

Solution Diagram

solution diagram

The Business Partner Validation application is developed using the SAP Cloud Application programming Model (CAP) and runs on the SAP BTP, Cloud Foundry runtime. It consumes platform services like SAP Event Mesh, SAP HANA and Connectivity. The events occuring in S/4 HANA on premise are inserted into the Event Mesh queue. The application running in Cloud Foundry is notified on events, consumes them from the queue and inserts the event data into the HANA database. The Business Partner Validation Application uses S/4 HANA REST API's to read additional Business Partner Data from the S/4 HANA system.

Requirements

  • SAP S/4HANA on premise system.
  • SAP Business Technology Platform account

For local development you would require the following:

Make sure you run the latest long-term support (LTS) version of Node.js with an even number like 16. Refrain from using odd versions, for which some modules with native parts will have no support and thus might even fail to install. In case of problems, see the Troubleshooting guide for CAP for more details.

Entitlements

The application requires below set of SAP Business Technology Platform Entitlements/Quota

Service Plan Number of Instances
Event Mesh default 1
SAP HANA Schemas & HDI Containers hdi-shared 1
SAP HANA Cloud hana 1
Cloud Foundry runtime 1

Configuration

Step 1: Setup SAP BTP subaccount

You can use SAP BTP - Boosters to setup the subaccount. Boosters Will create the subaccount with the required entitlements, subscriptions and assign the required roles to your user to run this application. Steps to run the booster are provided in link. You can create subaccount manually also following link

Step 4: Build and deploy the CAP application

Steps to deploy locally

  • Open terminal in VSCode
  • Run npm install sqlite3 --save-dev
  • Run cds watch

Steps to deploy the application on Cloud Foundry

  1. Build the application mbt build -p=cf

  2. Login to Cloud Foundry by typing the below commands on command prompt

    cf api <api>
    cf login -u <username> -p <password>
    

    api - URL of the Cloud Foundry landscape that you are trying to connect to.

    Select the org and space when prompted to.

  3. Deploy the application

    Navigate to mta_archives folder and run the below command from CLI

    cf deploy BusinessPartnerValidation_1.0.0.mtar

Demo script

  1. Go to Launchpad and access the 'Business Partner Validation' application

  2. Click on Business Partner Validation tile

fiori tile

  1. The list of BusinessPartners along with their verification status gets displayed.

BP list

  1. Login to the S/4HANA on-premise system

S/4HANA login

  1. Enter transaction code 'bp'

bp transaction

  1. Click on Person

person

  1. Provide first name, last name for the business partner name

  2. Provide the address address

  3. Move to the status tab and check mark the 'Central Block' lock. Save the BP. This will create a new Business Partner

lock

  1. Now go back to the BusinessPartnerValidation application to see if the new BusinessPartners has come on the UI

new bp

  1. Go to the details page for the new BusinessPartner. Click on edit.

edit bp

  1. Change the Verification Status to VERIFIED. You can also edit the street name, postal code also if needed. Save the data.

edit values

  1. Open S/4HANA system, bp transaction. Search for the newly created bp

search bp

  1. Double click on the BP

click bp

  1. You can see that the central Block lock has been removed

release lock

  1. You can also notice that in the BusinessPartner Validation UI, the status is now set as COMPLETED.

Known Issues

No known issues.

How to Obtain Support

In case you find a bug, or you need additional support, please open an issue here in GitHub.

License

Copyright (c) 2020 SAP SE or an SAP affiliate company. All rights reserved. This project is licensed under the Apache Software License, version 2.0 except as noted otherwise in the LICENSE file.

cloud-extension-s4hana-business-process's People

Contributors

btbernard avatar dependabot[bot] avatar ejazsyed avatar i353590 avatar karstenstrothmann avatar navinkrishnan avatar priyankashivakumar avatar sarahkraemer avatar shankarigr avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.