How to use the @rxweb/reactive-form-validators.FormBuilderConfiguration function in @rxweb/reactive-form-validators

To help you get started, we’ve selected a few @rxweb/reactive-form-validators examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github rxweb / rxweb / rxwebio / src / assets / examples / reactive-form-validators / decorators / alpha / dynamic / alpha-dynamic.component.ts View on Github external
ngOnInit() {
        let addressInfo = new AddressInfo();
        let formBuilderConfiguration = new FormBuilderConfiguration();
		this.http.get('assets/examples/reactive-form-validators/decorators/alpha/dynamic/dynamic.json?v=' + environment.appVersion).subscribe(dynamic => {
            formBuilderConfiguration.dynamicValidation = JSON.parse(JSON.stringify(dynamic));
			this.addressInfoFormGroup = this.formBuilder.formGroup(addressInfo,formBuilderConfiguration);
        })
    }
}
github rxweb / rxweb / rxwebio / src / assets / examples / reactive-form-validators / validators / digit / dynamic / digit-dynamic.component.ts View on Github external
ngOnInit() {
		let formBuilderConfiguration = new FormBuilderConfiguration();
		this.http.get('assets/examples/reactive-form-validators/validators/digit/dynamic/dynamic.json?v='+environment.appVersion).subscribe(dynamic => {
			formBuilderConfiguration.dynamicValidation = JSON.parse(JSON.stringify(dynamic));
			var user = { age:'', phoneNumber:'', faxNumber:'', mobileNumber:'',  }
			this.userFormGroup = this.formBuilder.group(user,formBuilderConfiguration);
		})
    }
}
github rxweb / rxweb / rxweb.io / src / assets / examples / reactive-form-validators / validators / greaterThanEqualTo / dynamic / greater-than-equal-to-dynamic.component.ts View on Github external
ngOnInit() {
        let formBuilderConfiguration = new FormBuilderConfiguration();
        formBuilderConfiguration.dynamicValidation = {
			
			memberAge : {
				greaterThanEqualTo : {fieldName:'age',conditionalExpression:'x => x.age >= 18 ',} 
			},			
			otherAge : {
				greaterThanEqualTo : {fieldName:'age',message:'Please enter number greater than or equal to 1.',} 
			},
		};
		var user = { age:'', voterAge:'', memberAge:'', otherAge:'',  }
		this.userFormGroup = this.formBuilder.group(user,formBuilderConfiguration);
    }
}
github rxweb / rxweb / rxwebio / src / assets / examples / reactive-form-validators / decorators / lowerCase / dynamic / lower-case-dynamic.component.ts View on Github external
ngOnInit() {
        let user = new User();
        let formBuilderConfiguration = new FormBuilderConfiguration();
		this.http.get('assets/examples/reactive-form-validators/decorators/lowerCase/dynamic/dynamic.json?v=' + environment.appVersion).subscribe(dynamic => {
            formBuilderConfiguration.dynamicValidation = JSON.parse(JSON.stringify(dynamic));
			this.userFormGroup = this.formBuilder.formGroup(user,formBuilderConfiguration);
        })
    }
}
github rxweb / rxweb / rxwebio / src / assets / examples / reactive-form-validators / validators / password / dynamic / password-dynamic.component.ts View on Github external
ngOnInit() {
		let formBuilderConfiguration = new FormBuilderConfiguration();
		this.http.get('assets/examples/reactive-form-validators/validators/password/dynamic/dynamic.json?v='+environment.appVersion).subscribe(dynamic => {
			formBuilderConfiguration.dynamicValidation = JSON.parse(JSON.stringify(dynamic));
			var loginInfo = { newPassword:'', oldPassword:'',  }
			this.loginInfoFormGroup = this.formBuilder.group(loginInfo,formBuilderConfiguration);
		})
    }
}
github rxweb / rxweb / rxweb.io / src / assets / examples / reactive-form-validators / decorators / different / dynamic / different-dynamic.component.ts View on Github external
ngOnInit() {
        let accountInfo = new AccountInfo();
        let formBuilderConfiguration = new FormBuilderConfiguration();
        formBuilderConfiguration.dynamicValidation = {
	
			password : {
				different : {fieldName:"firstName",message:'{{0}} is same as firstName',} 
			},	
	
			userName : {
				different : {fieldName:"firstName",conditionalExpression:'x => x.firstName == "Bharat"',} 
			},		};
        this.accountInfoFormGroup = this.formBuilder.formGroup(accountInfo,formBuilderConfiguration);
    }
}
github rxweb / rxweb / rxwebio / src / assets / examples / reactive-form-validators / validators / minDate / dynamic / min-date-dynamic.component.ts View on Github external
ngOnInit() {
		let formBuilderConfiguration = new FormBuilderConfiguration();
		this.http.get('assets/examples/reactive-form-validators/validators/minDate/dynamic/dynamic.json?v='+environment.appVersion).subscribe(dynamic => {
			formBuilderConfiguration.dynamicValidation = JSON.parse(JSON.stringify(dynamic));
			var user = { userName:'', allocationDate:'', birthDate:'', admissionDate:'', registrationDate:'', enrollmentDate:'', lastRegistrationDate:'', confirmationDate:'',  }
			this.userFormGroup = this.formBuilder.group(user,formBuilderConfiguration);
		})
    }
}
github rxweb / rxweb / rxweb.io / src / assets / examples / reactive-form-validators / decorators / minDate / dynamic / min-date-dynamic.component.ts View on Github external
ngOnInit() {
        let user = new User();
        let formBuilderConfiguration = new FormBuilderConfiguration();
        formBuilderConfiguration.dynamicValidation = {
	
	
			admissionDate : {
				minDate : {value:new Date(2018,7,30),conditionalExpression:'x => x.userName == "Bharat"',} 
			},	
			registrationDate : {
				minDate : {value:new Date(2018,7,30),message:'{{0}} exceeds the Minimum Date Limit',} 
			},		};
        this.userFormGroup = this.formBuilder.formGroup(user,formBuilderConfiguration);
    }
}
github rxweb / rxweb / rxwebio / src / assets / examples / reactive-form-validators / validators / contains / dynamic / contains-dynamic.component.ts View on Github external
ngOnInit() {
		let formBuilderConfiguration = new FormBuilderConfiguration();
		this.http.get('assets/examples/reactive-form-validators/validators/contains/dynamic/dynamic.json?v='+environment.appVersion).subscribe(dynamic => {
			formBuilderConfiguration.dynamicValidation = JSON.parse(JSON.stringify(dynamic));
			var user = { emailAddress:'', businessEmailAddress:'', recoveryEmailAddress:'', otherEmailAddress:'',  }
			this.userFormGroup = this.formBuilder.group(user,formBuilderConfiguration);
		})
    }
}
github rxweb / rxweb / rxweb.io / src / assets / examples / reactive-form-validators / validators / ascii / dynamic / ascii-dynamic.component.ts View on Github external
ngOnInit() {
		let formBuilderConfiguration = new FormBuilderConfiguration();
		this.http.get('assets/examples/reactive-form-validators/validators/ascii/dynamic/dynamic.json').subscribe(dynamic => {
			formBuilderConfiguration.dynamicValidation = JSON.parse(JSON.stringify(dynamic));
			var user = { language:'', numberAsciiCode:'', alphabetAsciiCode:'', specialCharAsciiCode:'',  }
			this.userFormGroup = this.formBuilder.group(user,formBuilderConfiguration);
		})
    }
}

@rxweb/reactive-form-validators

[![Build Status](https://dev.azure.com/ajayojha/rxweb/_apis/build/status/rxweb-CI?branchName=master)](https://dev.azure.com/ajayojha/rxweb/_build/latest?definitionId=39&branchName=master) [![Gitter](https://badges.gitter.im/rx-web/Lobby.svg)](https://git

MIT
Latest version published 1 year ago

Package Health Score

57 / 100
Full package analysis