[html-formfu] empty_rows in HTML::Form::Model::DBIC
Ferruccio Zamuner
nonsolosoft at diff.org
Tue Dec 22 09:35:05 GMT 2015
Hi,
I'm using HTML::FormFu::Model::DBIC and
- type: Repeatable
nested_name: chairs
increment_field_names: 1
counter_name: chairs_num
model_config:
empty_rows: 1
default_column: id_room
elements:
- type: Hidden
name: id
- type: Select
name: Country
label_loc: country
id: country
model_config:
resultset: Countries
id_column: id
label_column: label
default: "IT"
- type: Text
name: zip
label_loc: ZIP
size: 5
filters:
- TrimEdges
model_config:
null_if_empty: 1
- type: Text
name: town
label_loc: town
id: town
size: 44
filters:
- TrimEdges
model_config:
null_if_empty: 1
- type: Text
name: address
label_loc: address
size: 44
id: address
filters:
- TrimEdges
model_config:
null_if_empty: 1
....
And it insert a chair even if all fields are void but there is country
with default value 'IT'.
How can I update/insert only the main record "room" and not the has_many
chairs if the chair part of the form
is without data?
Thank you in advance and best wishes, \ferz
More information about the HTML-FormFu
mailing list