2018-10-19 15:17:02 +00:00
|
|
|
import validations from 'consul-ui/validations/token';
|
|
|
|
import policy from 'consul-ui/forms/policy';
|
2018-11-19 14:53:08 +00:00
|
|
|
import builderFactory from 'consul-ui/utils/form/builder';
|
2018-10-19 15:17:02 +00:00
|
|
|
const builder = builderFactory();
|
|
|
|
export default function(name = '', v = validations, form = builder) {
|
|
|
|
return form(name, {})
|
|
|
|
.setValidators(v)
|
|
|
|
.add(policy());
|
|
|
|
}
|