cap-materialbom-graph
A CAP sample that walks a material bill of materials on the server and draws it as a UI5 network graph in a custom section of a Fiori elements object page, on SQLite with no deployment.
The model holds materials and the parent-child rows between them, each row carrying a quantity, a unit and a relationship type, beside a pseudo-entity whose nodes, lines and groups are JSON strings filled at runtime rather than columns anything stores. Reading that entity is a handler of its own: it takes the material from the request path, walks the bill of materials from there, and keys every node by material and path, so a component reached along two branches is drawn twice and a repeat stops instead of looping. The app is a list report and object page generated from the SAP Fiori tools template, with the graph hung off the object page as a custom section whose fragment binds sap.suite.ui.commons.networkgraph to a layered layout, a colour per material type and a button back to the material's own page. It runs on @sap/cds@sap/cdsThe CAP Node.js runtime, which compiles the CDS model, serves the services declared in it, answers generic requests before any handler runs, and loads every cds-plugin.sap official, cap 8 against SQLite and says nothing about deployment, so what it offers is the read handler and the fragment rather than an application to put in front of anyone.
Facts
Where it sits
Who is behind it
In the atlas: maintains 35, contributes to 86, wrote 25@marianfoomaintainer
Before choosing this
Signals
LicenceNo licenseNeither the package manifest nor the repository tree declares a licence
Without a licence the default is all rights reserved. Ask the maintainer, or check for terms stated elsewhere, before depending on it.
What it declares
Every artifact
- Type
- Sample
- Origin
- Independently maintained
- Runtime
- Node.js
As a sample
- Declared for
- ^8
- Form
- A tutorial's companion code
Connections
Describing a service so a Fiori client renders it without UI code
Whole applications to read rather than snippets to copy
Download
README
quoted from marianfoo/cap-materialbom-graph, readGetting Started
Welcome to your new project.
This project is explained in the following blog post:
It contains these folders and files, following our recommended project layout:
| File or Folder | Purpose |
|---|---|
app/ | content for UI frontends goes here |
db/ | your domain models and data go here |
srv/ | your service models and code go here |
package.json | project metadata and configuration |
readme.md | this getting started guide |
Details
Sources
Sources are graph entities: the same page may back several entries, and an unreachable source flags every row that rests on it.
Compatibility and provenance
History in the atlas
- Drafted from the repository's own files, because its README is the unedited `cds init` template and the only sentence the maintainer wrote about it is the repository description, "This is a sample to show the Material as Network Graph in a Fiori elements app": db/schema.cds for the model and the GraphNetwork pseudo-entity, srv/service.js for the READ handler that walks the bill of materials, app/material/webapp/manifest.json for the list report and object page generated from `@sap/generator-fiori:lrop` and the custom section, the graph fragment for `sap.suite.ui.commons.networkgraph`, and package.json for `@sap/cds` ^8 and `@cap-js/sqlite`. artifact_type sample and use_as starting-point are a placement: one commit, a local SQLite run and no deployment described. domain ui-and-frontend-bridge follows the half of it the sample is about, as on cap-sflight. No licence is recorded: the repository has no LICENSE file and package.json carries the `cds init` defaults "license": "UNLICENSED" and "private": true.
- First seen.
For your agent
- Ref
artifact:marianfoo-cap-materialbom-graph- JSON
- /artifacts/marianfoo-cap-materialbom-graph.json
- MCP
- Connecting an agent