mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-19 19:15:22 +00:00
Merge pull request #524 from 8191/mvc-fields
Additional fields in MVC library
This commit is contained in:
commit
ff563e7221
@ -61,6 +61,10 @@ allownew : allow new items (for list) if applicable
|
||||
<br/><a href="#" class="text-danger" id="clear-options" for="{{id}}"><i class="fa fa-times-circle"></i></a> <small>{{ lang._('Clear All') }}</small>
|
||||
{% elseif type == "dropdown" %}
|
||||
<select {% if size|default(false) %}size="{{size}}"{% endif %} id="{{ id }}" class="{{style|default('selectpicker')}}" data-width="{{width|default("348px")}}"></select>
|
||||
{% elseif type == "password" %}
|
||||
<input type="password" class="form-control" size="{{size|default("50")}}" id="{{ id }}" >
|
||||
{% elseif type == "textbox" %}
|
||||
<textarea rows="{{height|default("5")}}" id="{{ id }}"></textarea>
|
||||
{% elseif type == "info" %}
|
||||
<span id="{{ id }}" ></span>
|
||||
{% endif %}
|
||||
|
||||
@ -40,7 +40,7 @@
|
||||
function getFormData(parent) {
|
||||
|
||||
var data = {};
|
||||
$( "#"+parent+" input,#"+parent+" select" ).each(function( index ) {
|
||||
$( "#"+parent+" input,#"+parent+" select,#"+parent+" textarea" ).each(function( index ) {
|
||||
if ($(this).prop('id') == undefined) {
|
||||
// we need an id.
|
||||
return;
|
||||
@ -96,7 +96,7 @@ function getFormData(parent) {
|
||||
* @param data named array structure
|
||||
*/
|
||||
function setFormData(parent,data) {
|
||||
$( "#"+parent+" input,#"+parent+" select,#"+parent+" span" ).each(function( index ) {
|
||||
$( "#"+parent+" input,#"+parent+" select,#"+parent+" span,#"+parent+" textarea" ).each(function( index ) {
|
||||
if ($(this).prop('id') == undefined) {
|
||||
// we need an id.
|
||||
return;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user