Material Integrity Detection
Introduction
MaterialIntegrityDetectionActivity is a MES-specific material integrity verification node used to verify whether the materials required for the product are complete and correct. This node supports two verification modes: Material BOM List Verification and Material Correctness Verification, ensuring the integrity and accuracy of materials during the production process.
Configuration Items
This node is controlled via process configuration and flow context variables.
Process Configuration
| Configuration Item | Description |
|---|---|
| MaterialBomDetection | Material BOM List Verification Switch |
| MaterialCorrectDetection | Material Correctness Verification Switch |
| MaterialParameters | Material Parameter Configuration List |
Input Variables
| Variable Name | Constant | Type | Description |
|---|---|---|---|
| MaterialIntegrityDetection_SerialNumber_Value | FlowItemCollection.MaterialIntegrityDetectionSerialNumberValue | string | Product Serial Number (Optional) |
| MaterialIntegrityDetection_Product_Value | FlowItemCollection.MaterialIntegrityDetectionProductValue | string | Product Identification Code (Optional) |
Output Variables
| Variable Name | Constant | Type | Description |
|---|---|---|---|
| MaterialIntegrityDetection_Result | FlowItemCollection.MaterialIntegrityDetectionResultKey | int | Verification Result Code |
| MaterialIntegrityDetection_Description | FlowItemCollection.MaterialIntegrityDetectionDescriptionKey | string | Verification Result Description |
| TraceModel | FlowItemCollection.TraceModel | TraceModel | Trace Model (when queried) |
| ProductModel | FlowItemCollection.ProductModel | ProductModel | Product Model |
Verification Result Codes
| Code | Description |
|---|---|
| 0 | Not Executed (Initial State) |
| 1 | Verification Passed |
| 2 | Material BOM List Verification Failed |
| 3 | Material Correctness Verification Failed |
| 4 | Both Verifications Failed / Product Model Not Found |
Business Logic
Material BOM List Verification
Checks whether all materials configured in the product BOM have been collected:
- Get the BOM list of the product.
- Filter material items required for the current process.
- Traverse material items:
- Check if the material barcode has been collected.
- Not collected → Record missing material.
- If BOM is not configured with materials → Verification fails.
Material Correctness Verification
Checks whether the collected material barcodes comply with barcode rules:
- Traverse material parameters in process configuration.
- Get corresponding material barcodes.
- Call material service to verify barcode rules:
- Does not comply with rules → Record verification failed material.
Usage Example
Basic Configuration
{
"Name": "Material Integrity Verification",
"Type": "MaterialIntegrityDetectionActivity"
}
Check Verification Result
{
"Activities": [
{
"Name": "Material Integrity Verification",
"Type": "MaterialIntegrityDetectionActivity"
},
{
"Name": "Check Result",
"Type": "ConditionActivity",
"Condition": "MaterialIntegrityDetection_Result == 1"
}
]
}