Hi, 

I cloned the Isis git repository and took a look at the source code. I
now have a general idea of how the "hide" option works for tables, but
I'm having a hard time deciding what would be the best approach for
adding this behavior to fieldsets. 

I'm thinking of three possibilities: 

#1. Creating my own modified Isis version for internal use, with direct
modifications to FieldSet, PropertyGroup, etc. This sounds like the
easier option, but would give me trouble when the time comes to upgrade
to new versions of Isis. 

#2. Replacing components as described in [1]. This sounds like the
cleaner option, which would imply replacing the default implementations
with my own modified versions. Problem is PropertyGroup doesn't seem to
have a Factory, unlike for example EntityCollectionPanel which has one,
so I'm not sure how to proceed here. 

#3. Writing an add-on, similar to the collection views described in [2].
I *think* this might be actually the same as #2 but packaged in a
different way, but I'm not sure about that. 

Am I on the right track with these ideas? Which one of these would you
recommend (if any?) 

Thank you. 

[1]
https://isis.apache.org/guides/ugvw/ugvw.html#_ugvw_extending_replacing-page-elements


[2]
https://isis.apache.org/guides/ugvw/ugvw.html#7.2.3.-additional-views-of-collections


El 2017-04-14 05:52, Dan Haywood escribió:

> Hi Hector, 
> 
> Thanks for uploading that image ... a picture tells a thousand words. 
> 
> To implement your requirements, I could imagine the <fieldset> element having 
> an additional attribute, say "defaultView" (similar to the <collection> 
> element / @CollectionLayout annotation), which might default to "open" but 
> also support "hide".  This corresponds to the 
> org.apache.isis.applib.layout.component.FieldSet class. 
> 
> In the UI, this corresponds to the 
> org.apache.isis.viewer.wicket.ui.components.entity.fieldset.PropertyGroup 
> class, which is passed the FieldSet into its constructor (by way of its 
> Wicket model).  So it looks like this PropertyGroup component could quite 
> easily be made a little more sophisticated to have a drop-down. 
> 
> Do you fancy delving in to see if you can get a spike working (with a view to 
> incorporating this functionality into a future version of the framework)?  
> Martin Grigorov is our Wicket expert, and he is usually very prompt at 
> answering any Wicket-specific questions. 
> 
> HTH 
> Dan

-- 
Hector Fabio Meza

R&D LEAD SMARTOOLS 
(57) 300 2254455 [1] 
Skype: hectorf.meza 
www.smartools.com.co [2] 

 

Links:
------
[1] tel:%2857%29%20300%206815404
[2] http://www.smartools.com.co/

Reply via email to