English
excelImport.validateMappingFields.before
About 144 wordsLess than 1 minute
2026-05-08
Execution Timing
Before validating Excel import field mappings
Parameters
| Parameter | Description | Type |
|---|---|---|
| param | Import parameter object | Object |
Return Result
| Parameter | Description | Type |
|---|---|---|
| isNoCheck | Flag indicating whether to skip field mapping validation | Boolean |
Notes
- This hook is triggered before Excel import field mapping validation and can be used to control whether field mapping validation is executed.
- When the returned
isNoCheckis true, the system skips field mapping validation. - If the returned
isNoCheckis false or is not returned, the system continues field mapping validation.
Code Example
export default class Plugin {
apply() {
return [{
event: "excelImport.validateMappingFields.before",
functional: this.validateMappingFields.bind(this)
},
];
}
validateMappingFields(context){
let { param } = context;
// Determine whether to skip field mapping validation based on business logic
const shouldSkipCheck = this.checkIfSkipValidation(param);
return{
isNoCheck: shouldSkipCheck
}
}
checkIfSkipValidation(param) {
// Custom business logic to determine whether field mapping validation should be skipped
return false;
}
}