Files
WidgetWorkbench/HMI_V4_README.md
2026-10-21 19:34:42 +00:00

3.6 KiB
Raw Blame History

Workbench HMI V4 – Native Fertigungswidgets, AI-Skill und Online-ios.css

Based on supplied Workbench-16100e34b5c74434383600ee9890d526e37eb84f.zip and the V3 integrated HMI framework. Complete sources, not a prebuilt WAR.

Build / Deploy

cd hmi-frontend
npm install
npm run typecheck
npm run test:mes
npm run build
cd ../backend
mvn clean package

Or run ./build-hmi.sh (requires npm registry access and Maven). Deploy backend/target/backend-1.war to the GlassFish instance. Existing environment's dsCustNJTA must be configured, with rights to create HMI tables, including HMI_APP_CSS_REVISION, when missing. The first schema init also tracks v3 in HMI_APP_SCHEMA_VERSION.

Important: The downloaded sources include a previously built backend/target directory from the original project. These binaries do not include V4 changes; always run a clean build. The package does not contain npm dependencies.

URLs

  • HMI Designer/Runtime /backend/hmi/ – use the widget catalog or Production preset.
  • Full CSS editor: sidebar 🎨 ios.css bearbeiten (hmi-designer / hmi-publisher / hmi-admin).
  • Published CSS for legacy pages: /backend/hmi-theme/ios.css.
  • CSS admin API: /backend/api/hmi/v1/styles/ios (Jersey).

How online CSS works

The deployed backend/src/main/webapp/ios.css remains an immutable fallback. The online editor loads the complete original or a version from CUST.HMI_APP_CSS_REVISION, previews in an isolated, sandboxed iframe, saves a DRAFT, and only then publishes it to legacy HTML pages and the Vue token bridge. Old revisions can be selected and published again for rollback; publishing is restricted to HMI publisher/admin roles. Legacy pages no longer link the original /backend/ios.css URL directly.

  • Role hmi-designer: edit and save drafts.
  • Role hmi-publisher / hmi-admin: publish and roll back.
  • A publication does not rewrite the read-only WAR or change Git source; export approved CSS into the repository separately if you want deployment reproducibility.
  • Raw CSS can change visual appearance and hide fields, so audit and approval are mandatory. A limited CSS filter blocks external-resource loading.

Native widgets

  • wb.history: 6 data panels, order/layer change, missing serial assignment, status rebooking.
  • wb.activities: workplan and state gate, measurements, failures, setup/setup-check, attributes, MES write actions.
  • The original HTML clients remain for comparison and fallback. Native widgets no longer launch them.
  • A same-origin MES proxy must expose /mes/imsapi/rest/actions/. The old globallogin session is reused in-memory.

AI Skill

.agents/skills/workbench-hmi-clients/SKILL.md documents the extraction/migration requirements and is referenced by AGENTS.md. Use node .agents/skills/workbench-hmi-clients/scripts/new-widget.mjs <slug> <label> for a registry-connected new Vue widget skeleton.

Validation and limitations

  • Java 11 compile for new CSS service classes performed with local target dependencies.
  • TS source and lightweight typecheck of new Vue <script setup> passed; test harness uses local global TypeScript compiler.
  • Full Vue/Vite build was blocked by npm registry DNS EAI_AGAIN and no live GlassFish/Oracle/SQL Server/IMSAPI tests are available here.
  • Therefore not production-certified. Test every actual MES write at a non-production station. Consult hmi-docs/CLIENT_MIGRATION_MATRIX.md.

V4.1: Anmeldung und Datenbankdiagnose

Browser: /backend/hmi-diagnose.html, JSON: /backend/hmi-health, geschützte Live-Prüfung: /backend/api/hmi/v1/diagnostics (hmi-admin). Details in hmi-docs/ANMELDUNG_DATENBANK_DIAGNOSE.md.