igi_orion_cignacmb
Version:
Censors words out of text
30 lines • 713 B
JavaScript
/*
* @Author: weicong.ling
* @Date: 2020-05-06 10:05:50
* @Last Modified by: weicong.ling
* @Last Modified time: 2020-05-11 09:58:07
*/
/**
*
* @param {数值} result
*/
var idIsLongValid = function (result) {
var value = result.field.value;
var error = {
isCorrect: true,
type: "tooltip",
msg: "",
code: "",
id: result.id
};
try {
if (value == "1" && result.item.idType.value == "G") {
error.isCorrect = false;
error.msg = '港澳台居住证有效期为5年内';
}
} catch (error) {
console.error(error)
}
return error;
};
module.exports = idIsLongValid;