Thursday, September 20 - Qcodo 0.3.33 Released

thread: 24 messages  |  last: about 4 years ago  |  started: thursday, september 20, 2007, 2:54 pm pdt


#1  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Thursday, September 20, 2007, 2:54 PM PDT

Folks,

I'm happy to announce a very development-based release for 0.3.33.  Please view the changelog for the rather lengthy list of changes.

codegen templates and drafts restructured

But the main thing to note is that I have restructured and greatly improved the code gen templates as well as the entire way form drafts and panel drafts once worked.

The main issue I kept running into before is that while form and panel drafts are a great easy way to view your database in HTML form, they were tough to use, especially if you are wanting to build out a more complex form based on a form draft.

So with 0.3.33, I'm happy to announce new experimental templates to generate  MetaControls and MetaDataGrids for your ORM.  Instead of a FormDraft being a subclass of the FormBase code... now you have a Form Draft which is just a simple QForm.  The Form Draft uses a MetaControl which, itself, contains the links between a set of QControls and its underlying data object.

What this should allow is a much easier way to build out pages and panels that have controls which would interact with your ORM.

So instead of needing to code almost a dozen+ lines for each field-which-maps-to-a-qcontrol... all you need to do is to have three lines total:
** One to declare the control/field in your form
** A second to call the MetaControl to create AND return you a control which maps to a field
** A final one in your template file to tell it where you want it rendered

Everything else, including the saving/updating back to the data object, is taken care of for you.

And this same concept is also applied to the MetaDataGrid object as well.

These are a very rough first cut as to the power of what MetaControl and MetaDataGrid will eventually become, but I'm incredibly excited about this and I would like to encourage everyone to check it out and to provide feedback on how it can be improved.

In terms of backward compatability, most people should have no issues using this new version.  However, for people who have overridden some of the templates, note that some of the once rather large template files have been modularized significantly (e.g. db_class_gen used to be > 1000 lines... now it's just 96 lines!) with most of the functionality within the template being broken out into more subtemplates.  The reason for this is to make it easier for people to override certain templates / subtemplates.  e.g. if you want to override just one aspect, you don't have to override the entire thing.

Also, for those who have applications which still depend on the original generated formbase and panelbase objects, because those have been removed from the core distribution, I'm placing a 0.3.33+ codegen-compatible set of formbase and panelbase templates in the Downloads directory.

CSS Improvements

I am also slowly going through many of the qcontrols to make much better use of CSS.  It'll be a slow process, but the changelog will list the sets of qcontrols which has been updated to make better use of CSS.

In short, we're going to eventually get rid of any hackish or silly HTML in the various controls' GetControlHtml() calls in favor of standardized HTML elements using CSS styling to do the same thing.  So, for example, instead of having   in QDateTimePicker to provide spacing around the listbox elements, we're now using class names for each listbox element, and defining CSS styles to provide that same functionality.

In the end, you'll be able to customize any/all look and feel elements solely through CSS changes and w/o requiring to go into the PHP at all -- which, of course, is what CSS was meant to do in the first place. =)

For now, QDateTimePicker, QDataGrid and QPaginator are the ones that have been overhauled in this first release.

There should be relatively no functional backward compatability issues -- the only thing that you'll want to be aware of is you might need to define and/or declare CSS classes for the datagrids in your existing application if something doesn't look right.

Fortunately, the core Qcodo release's styles.css file has been clearly commented and shows the “default” way you would want to style each of these controls.

A new qcodo.com website?

Thank you very much for all the feedback I have gotten from the previous blog post about the future of qcodo.  Due to the feedback, the next thing that I am looking to do is to revamp qcodo.com to improve the community features of this community.  Many of the changes in qcodo 0.3.33 will go to helping to make the qcodo.com rewrite go a lot faster. =)  The main things we'll be looking to add is a bug tracker, a wiki-type documentation system, and a showcase page.  And of course, it will be rewritten in Qcodo Beta 3 (the current site is still in Qcodo Beta 2).  And we plan on releasing the source code, too. =)

#2  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Thursday, September 20, 2007, 3:25 PM PDT

As a head's up, the legacy FormBase and PanelBase codegen templates which are now Codegen 0.3.33+ compatible have been placed in the Downloads section at <http://www.qcodo.com/downloads/item.php/147>.

#3  |  dynamicwebworks Germany
Friday, September 21, 2007, 6:57 AM PDT

When do you think will Qcodo.com get the new webpage?

#4  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Friday, September 21, 2007, 7:01 AM PDT

hopefully within the next week or so.

#5  |  fimbulvetr (Denver, CO)
Saturday, September 22, 2007, 8:57 AM PDT

Hi Mike,

Can you post a very very basic example of these metacontrol/dg enhancements? I'm talking the simplest page you can do, because I don't want to waste your time, but I'd really like to try this out.

#6  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Saturday, September 22, 2007, 11:48 AM PDT

Yeah... I'm trying to figure out a clear way of documenting this.

I think for now, go ahead and create a new project with your current data model and let the code generator generate everything for you.

You should see in the newly designed edit and list form drafts how those qforms utilize the metacontrol and meta datagrid.

definitely post with specific questions -- it will help me to understand what things are unclear and how I can better document how they work.

#7  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Saturday, September 22, 2007, 11:48 AM PDT

Just a head's up - I've released 0.3.34 with some new functionality - see the changelog for more information.

#8  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Sunday, September 23, 2007, 8:52 AM PDT

And 0.3.35 has now been posted with a few extra functionality and some fixes.

#9  |  gibran (Paris) Lebanon
Monday, September 24, 2007, 4:33 AM PDT

wow Mike ! Back to the good old times where you released a version per day :)

For the MetaControls, an example page with their advantages and the differences with the old model would be nice I guess.

#10  |  Mike Ho (Sunnyvale, CA) United States of America Qcodo Administrator
Monday, September 24, 2007, 11:13 AM PDT

Yep... the “good ol' days”... ;^)

Anyway, thanks to the various bug posts thus far.  We're now at 0.3.36.

Keep the reports coming in!



Copyright © 2005 - 2012, Quasidea Development, LLC
This open-source framework for PHP is released under the terms of The MIT License.