export function validateDateMinMax()

in src/framework/Validator.ts [44:56]


export function validateDateMinMax(a:Assembly, schema:MFieldSchemaAnonymity, value:any, path:string): MValidationResult {
  if(schema.min){
    if(!value || value < schema.min) {
      return {message: `请选择${schema.min}之后的时间`, path};
    }
  }
  if(schema.max){
    if(!value || value > schema.max) {
      return {message: `请选择${schema.min}之前的时间`, path};
    }
  }
  return undefined;
}