NxTIC/js/lib/form-builder-min.js

3 lines
900 B
JavaScript
Raw Normal View History

var default_definition={input:{html:"<input {{__attributes__}}>"},"h/^([1-6])$/":{html:"<h{{$1}} {{__attributes__}}>{{__children__}}</h{{$1}}>"},br:{html:"<br>"},option:{html:"<option {{__attributes__}}>{{__children__}}</option>"},select:{html:"<select {{__attributes__}}>{{__children__}}</select>"}},custom_definition={"input:/^([a-z]+)$/":{node:"input",attributes:{type:"{{$1}}","data-name":"{{name}}",value:"{{value}}",placeholder:"{{placeholder}}"},next_child:{node:"br"}}},form={node:"h4",attributes:{"data-icon":"o",
"class":"new-contact color2"},children:[{node:"input:hidden",$name:"uid",$value:"{{uid}}"},{node:"input:hidden",$name:"call",$value:"{{call}}"},{node:"input:hidden",$name:"sms",$value:"{{sms}}"},{node:"input:hidden",$name:"countcall",$value:"{{countcall}}"},{node:"input:hidden",$name:"countsms",$value:"{{countsms}}"},{node:"input:text",$name:"number",$value:"{{number}}"}]};