Re: django and WorkBench
Carl Karsten <[email protected]> Sat, 09 Jun 2007 10:17:41 -0500
| Newsgroups | gmane.comp.db.mysql.mycc |
|---|---|
| Message-ID | <[email protected]> |
Alfredo Kojima wrote: > Hi Carl! > > Carl Karsten wrote: >> I am working with django (python web framework >> http://djangoproject.com) which "works best" if you define your data >> like this: >> > > [snip] > >> In the past, I have used my data modeling tool (like MySql Workbench) >> as the primary. I am hoping to continue. What I envision is using >> Workbench to define my model, then somehow generate the class code. The > > Nice! That'd be a good use for Workbench indeed. > >> problem is the django class code supports more than what Workbench >> supports. see: http://www.djangoproject.com/documentation/model-api/ >> > > Can you give some examples of what is missing? If these things belong > to a generic data model, we will look into adding support for that. > If they're specific to django models, you can add custom data fields > to the model objects. > >> So, before I got looking at the xml that Workbench uses to represent a >> model or any other such fun, has anyone started down this path? >> > > A couple of notes: > > 1- Workbench has a powerful plugin system, which includes support for > Python. > That is the preferred path to write such functionality, so it's not > necessary > to understand or even touch the model XML files directly. What is useful to > understand are the XML files with meta-information about internal > representation > (the struct.*.xml files), but then, in the GRT shell you can have a > friendlier > view of their contents. > > 2- We're currently refactoring the Workbench a great deal, so some of the > internals are being changed. It should be possible to migrate a plugin > from the > currently released WB to the new one without too much work, but they > won't work > directly. So if you want to start working on that, I encourage you to > and will > help you as I can. Otherwise, I'd advise to wait for the 1st public release > of the refactored WB later this year. > > 3- There is some preliminary info on writing plugins at > http://forge.mysql.com/wiki/MySQL_Workbench_Plugins and > http://forge.mysql.com/wiki/MySQL_Workbench I'll take a crack at writing my django thingy if someone will give me a python example. (like the java and lua examples - we need a python one, right?) thanks, Carl K > > but some of the info will become obsolete when the new WB is released, > specially how some of the code will look like, the "Object Tree" structure > and some other things. > However, most of the concepts will still be valid, so it may still have > some > use. > > > Cheers, > Alfredo > -- MySQL GUI Tools Mailing List For list archives: http://lists.mysql.com/gui-tools To unsubscribe: http://lists.mysql.com/[email protected]