Yes this might be interesting, I'm not sure either David is really opposed. Especially if someone provides a patch well tested !
http://docs.ofbiz.org/display/OFBADMIN/OFBiz+Contributors+Best+Practices Jacques De : "opablo" <[EMAIL PROTECTED]> > Hi Jonathon, > > I've been reading the thread you posted, and I think you've got a point > presenting the example: it is one classic situation where filtering is > needed (or at least avoids many headaches!). > > I also read David's post: > > >In general entity and view entity definitions are meant to model > >structure, not query constraints. Just add your desired constraints to > >the EntityCondition passed into the findByCondition call (or Map for > >findByAnd or whatever). > > > >-David > > and I only want to add that views don't model structure, they model only > a view of the data (filtered and not filtered). Tables (entities) are > what model the structure. > > The "expert" in this "modelling" are database systems, and they do have > this kind of filtering in their views (as SQL prompts in its standard). > > Just tell me what can we do to add this "feature request" to JIRA and > I'll work on it. And then we could try to convince David to accept the > feature in OfBiz! :P > > Oscar > > On Mon, 2007-09-10 at 18:50 +0800, Jonathon -- Improov wrote: > > Hi Oscar, > > > > I started a thread on it quite recently. See > > http://www.nabble.com/forum/ViewPost.jtp?post=12018323&framed=y . > > > > I don't see any possibility in the current Entity Engine to do what we want. > > > > I have my own implementation to do this, since there wasn't any interest > > from OFBiz ML to get this > > functionality into OFBiz SVN. > > > > In fact, I seem to have been compiling quite a sizable pile of enhancements > > I haven't been able to > > put back into OFBiz SVN! There are other enhancements, in the Widget > > department, the Entity > > Engine, the Minilang, etc. > > > > If you can help me document this "feature request" in the JIRA issues, help > > iron out the details > > and community requirements and thoughts on this, I'll put in my enhancement > > right there. > > > > Jonathon > > > > opablo wrote: > > > Hi all, > > > > > > Since I began working with OfBiz I missed a feature in its entity > > > engine: some feature to allow to include some sort of filtering in the > > > view definition. I'm talking about a code like the following (the > > > "filter" tag): > > > > > > <view-entity entity-name="Suppliers" > > > package-name="the.package.name" > > > title="List of suppliers"> > > > <member-entity entity-alias="PR" entity-name="Party_Role"/> > > > > > > <alias-all entity-alias="PR"/> > > > > > > <view-link entity-alias="PR" rel-entity-alias="P"> > > > <key-map field-name="partyIdFrom" rel-field-name="partyId"/> > > > </view-link> > > > > > > <filter entity-alias="PR"> > > > <key-map field-name="roleTypeId" value="SUPPLIER"> > > > </key-map> > > > </filter> > > > </view-entity> > > > > > > I know I can do the filtering when obtaining the data by code just by > > > adding the filter condition, but when views grow, it is easier to > > > organize your views into "functional" areas, or even it helps when > > > querying and browsing data in webtools tab. > > > > > > Is it in the roadmap for next versions? Has anyone discussed about this > > > previously? > > > > > > Thanxs, > > > > > > Oscar > > > > > >
