Skip to content

Commit

Permalink
dynamic component by Slava
Browse files Browse the repository at this point in the history
  • Loading branch information
ZatolokinPavel committed Mar 31, 2016
1 parent f02ba2f commit 0542b62
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/forms.erl
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,9 @@ fields(Document, Object) ->
fun (#field{type=empty}=X1,Acc) ->
[#panel{class=box, style="display:none;",id=wf:atom([X1#field.name,Name])}|Acc];

%% dynamic component (that is build with fun component/3 and inserted)
(#field{type=dynamic}=X4,Acc) -> [X4#field.raw|Acc];

% card row
(#field{type=card,name=[Name1,Name2,Name3]}=X2,Acc) ->
[#panel { id=wf:atom([Name1,Name]), class=[box,pad0], body=[
Expand Down

0 comments on commit 0542b62

Please sign in to comment.