Blueprint changed by rejon:
Whiteboard changed:
A composite widget object would be useful for the following fields:
display_urls - I would like to write a single URL object, and then
reference it in multiple widgets. Currently I have to copy-paste a list
of display_urls to multiple widgets. Changing on URL means changing all
of them. A widget could even reference multiple URL objects, why not?
Select Query and Content - I would like to be able to write a Query
object, then connect it to a Content object. I can then write a
different Query object and connect it to the same Content object. To get
this effect currently I have to write one widget, then another widget
with an (#(inherit: that feeds a new SQL statement.
-----------------------------------------------------------------
About display_url: You are changing the way to use aiki: instead write
multiple values in display url we must slice aiki_widges in three tables:
table displays_urls ----> table table to display -----> aiki_widget
When a user add a display url, he/she select in a list the widgets that will
be displayed.
correct?
What is a Query Object:
Is your query object a type of meta-SQL, i mean. Instead write a SQL to
retrieve user data, you only must write SQL(user,2), for the cliparts of an
artist SQL(cliparts),
The SQL is a container of SQL statement, retrieved by name, and where
you can insert data:
function SQL(){
$SQLS = array(
"user" => "SELECT * FROM aiki_users WHERE id='%s')
'clipart' => "SELECT * FROM aiki WHERE ...ORDER,)
..
..
return insert_parameters ( $SQLS($argv[0), $argv))...
}
-----------------------------
I admit I haven't thought this through much, but just wanted to get
something written down.
A "query object" is just the content of the Select Query field. So like
the display_urls example above, yes, you would break it into multiple
tables.
Then many widgets could reference the same select query, or a widget
could reference multiple select queries. (Although that would break how
loops are handled).
Feel free to ignore this blueprint, unless it gives you any good ideas.
;)
~~Christopher
+
+ ###
+
+ needs more discussion, but generally I agree, just a big one to
+ implement @rejon
--
Represent widgets and widget fields using the composite design pattern
https://blueprints.launchpad.net/aikiframework/+spec/widgets-composite-pattern
_______________________________________________
Mailing list: https://launchpad.net/~aikiframework-devel
Post to : [email protected]
Unsubscribe : https://launchpad.net/~aikiframework-devel
More help : https://help.launchpad.net/ListHelp