Quality Business Function 'Global Switch to 114 Server' Verification Report

Quality Business Function 'Global Switch to 114 Server' Verification Report

Generation Time: 2026-08-25 | Objective: All quality-related functions successfully run on the cloud 114 (.NET/SQLServer) environment

I. Configuration Changes (Root Cause Fix)

The SCSAI section in .env changed from local :5000 to 114 (backup .env.bak.20260825085235):

| Item | Old Value (Local) | New Value (114) |

|---|---|---|

| SCSAI_SERVER | http://localhost:5000 | https://ylxt.chat/scplm |

| SCSAI_DATABASE | SCPLM_CLOUD_20260813 | SCPLM |

| SCSAI_USERNAME | admin | root |

| SCSAI_PASSWORD | innovator | gyc123456; (trailing semicolon is required) |

| SCSAI_ENDPOINT_PATH | /server/SCSAIServer.aspx | /server/InnovatorServer.aspx |

Code alignment synchronized with 114 (quality-inspection.js / inventory.js / vendor.js / change.js reverted to defaults,

quality.js commented out) to avoid silent fallback to local database when configuration is missing.

II. Service Restart

Stop the old process (PID 30128) still occupying port 3006 and loading old configuration. Restart using env -u http_proxy ... PORT=3006 node server.js

(Bypass local HTTP_PROXY=127.0.0.1:10809, otherwise requests to 114 will be intercepted by the local proxy). Startup log:

✅ SCSAI connection normal (https://ylxt.chat/scplm, DB: SCPLM).

III. Verification Results (Actual measurement, not speculation)

3.1 Online API (:3006) data source has been switched to 114

  • GET /api/quality-inspection/ncrs → {"success":true,"source":"SCSAI","total":3,...}
  • GET /api/quality/kpi → NCR_TOTAL:3, data_source:"scsai" (Previously local DB returned 21)

3.2 verify_114_quality.cjs (Forced 114) all items PASS

| Check Item | Result |

|---|---|

| 8 quality ItemTypes queryable | 7 have data; CASC211_JG_EXAMINE_ITEM type exists but has 0 records |

| NCR create + delete write path | ✅ ok |

| ncr-worker run() | ✅ total=3 (SCSAI NCR QS) |

| capa-worker run() | ✅ total=3 (SCSAI QCA QS) |

| audit-worker run() | ✅ total=1 (SCSAI Audit QS) |

| qcc-worker run() | ✅ 1 card (SCSAI Q_CONTROL_CARD MES, read-only monitoring) |

| spc-worker run() | ✅ 15 characteristics (SCSAI Characteristic) |

| stat-worker run() | ✅ real-time aggregated KPI |

| fmea-worker run() | ✅ DFMEA=2 / PFMEA=1 |

Note: Instance 114 does not support ValidateUser (ItemNotFoundException), but real Basic authentication is effective (both query and write succeed), non-blocking.

IV. The gap in QCC Quality Control Card 'Create' has been located and fixed (tested PASS).

4.1 Root Cause (Not a server-side modeling constraint, but AML tag case sensitivity).

  • On instance 114, the taskitemid in CASC211_JG_Q_CONTROL_CARD is a regular property (actual name is all lowercase: taskitemid,

data_type=decimal, is_required=1). Aras matches properties precisely by XML element name (case-sensitive).

Previously, QCC creation did not pass this field / the tag name case did not match → value was discarded → INSERT NULL for this column → NOT NULL constraint error.

  • Cross-validation (114 direct connection):
  • Uppercase 999001 → Cannot insert NULL into column 'TASKITEMID' (failed).
  • Lowercase 999001 → Created successfully, can be deleted for cleanup.
  • Legitimacy evidence: The actual value of taskitemid for existing cards is "0" (server default fills 0); on 114,

JG_PRODUCE_TASK/CASC211_JG_PRODUCE_TASK query count=0 → taskitemid is not a foreign key,

any non-null decimal satisfies the constraint (matching existing card's 0 is safest).

4.2 Fix (qcc-worker.js)

When constructing cardData in the create/seed branch, explicitly supplement taskitemid (lowercase key). Value priority:

params.cardData.taskitemid → params.cardData.TASKITEMID (case-insensitive compatibility) → defaults to "0" (consistent with existing data in 114).

Via CapabilityRuntime.create → unified-create, the data key is used as-is for XML tags → lowercase taskitemid is correctly recognized and written.

4.3 End-to-End Verification (Real Code Path, 114)

server/scripts/e2e_qcc_create.cjs: require new worker to run run({action:'seed', withItem:false}).

  • Result: success:true, created_id=5FA33C3679FE403FB03759A2BADC1790, cleanup deletion success:true.
  • Proves that QCC quality control card creation has passed through the real code path in 114.
  • Restarted running instance (PID 29892) loaded new worker code; online GET /api/quality/kpi still sourced from 114 (NCR_TOTAL=3, data_source=scsai).

V. Remaining Items and Verification Assets

  • Local :5000 historical test NCR residues no longer have impact (true source switched to 114), can be cleaned up as needed.
  • Verification scripts (retained, can be re-run):
  • server/scripts/verify_114_quality.cjs — 7 quality employees run() + NCR write path (forced to 114).
  • server/scripts/e2e_qcc_create.cjs — QCC creation passed through real code path in 114 (auto-cleaned).
← 返回案例列表

Try 左帮右臂 Industrial Agent — your digital workforce

Available as a WeChat mini program, web app (ylxt.chat) and desktop client. Start from whichever fits your workflow.

🌐 Web App 💻 Desktop Download 📞 Call 189-8606-6876
WeChat mini program QR
Scan for the WeChat mini program
Share:
🤖 Try Now →
🤖
🎁