From: Alex B. <en...@tu...> - 2001-08-15 22:54:15
|
> the entity declaration makes good sense to me, though i have a few > questions and concerns. > > 1. within <field>, your example showed TEXT and POINTER. could we get a > list of these 'application' types w/ descriptions? don't exist yet. I imagine email, text, dna_sequence, phone_number, date, etc. It would be extensible with user 'types' - we'll have a set of default ones that come with the system. They'd be simple classes that do validation. > 2. i noticed <maxlength> which i can forsee being used for setting a > maxlength in a input field (HTML), and for possibly determining the > field length in the database. (is this correct?) BUT, there was no Correct on both accounts. > LENGTH value anywhere. if HTML forms are to be built on the entities, > having a MAXLENGTH as well as a LENGTH would be desired. Yes, I see your point. I was toying with the idea of associating UI controls with each field type. That may still happen, so: <field> <name>furbee_type_id</name> <label>Furbee type ID</label> <desc>The id of the type of furbee</desc> <path>furbee_type_id</path> <required>true</required> <type> <dbtype>int</dbtype> <!-- note the "pointer" type this field is a pointer to another entity, and a foreign key in the database --> <type>pointer</type> <!-- form above, the entity name to use for requesting data from this pointer --> <entity>furbee_type</entity> <maxlength>20</maxlength> <format>/[\w\s_\-\.]{0,20}/</format> </type> <!-- look here --> <uicontrol> <name>TextField</name> <params> <length>20</length> </params> </uicontrol> </field> > 3. could you explain a field PATH a bit? path is sort of like the way you ref a table.field_name in sql: location.locationid is an entity path that points to a field in an entity. it could also be a sql table_name.field_name path - it's intentionally similar. the idea is to be able to ask FormBuilder to make you a form for an entire entity, or just a set of fields in that entity by passing in entity paths. > .. beautiful sh*t you have going on here. =] thanks :) This isn't all mine, I was on the right track but odysseas, john donagher, and john campbell are the masterminds behind the original entitymanager. I'm making tweaks to some of the design so it's less application specific, and more "metabase integrated" if that makes sense. :) _alex > jason |