You are reading the articles stored in Aspetti tecnici
Feb 10, 2011
Pyramid CRUD
I have been using Pyramid/BFG in several our projects. It really rocks. Probably you already know that. What I think could be an extremely useful add-on is a CRUD. For our internal usage (more as a proof-of-concept) we have developed one - traversal with SQLAlchemy support. Now we want to make it more generic and open-source. Interested in?
What we have is a working version of a traversal CRUD. General concept is similar to Sergey Volobuev Kelpie. Everything is based on repoze.bfg 1.2 (though it should work smoothly on 1.3).
Model definition is done using SQLAlchemy declarative approach. This choice provoke us to use FormAlchemy as a form generator (with fa.jquery widget support). It's easy to start with but difficult to extend later. That's why it's the first thing we would like to change in the future. Everything is glued together with bfg hybrid traversal approach.
What we are planing to do (probably not exactly in that order):
- check if somebody else didn't start similar project and maybe share concepts or do it together
- check possibility of integrate existing solutions with Pyramid
- reuse what can be reused from our bfg crud and move it to Pyramid
- organize a python sprint that will work on these topics



Document Actions
Nov 03, 2010
Lotus Notes and chart in client: great stuff!!
A way to render charts in Lotus Notes Client through Google Charts
Working with the Lotus Notes Client I came across the necessity of working with graphs.
The opportunities were:
- Integrate with third-party products, which will require installation on your PC ( RMCHART (http://www.brothersoft.com/rmchart-35638.html) is a very good library);
- Using
Microsoft Excel, if it is installed on your PC, creating a template
that is then filled with data and processes them in a chart
Then I thought, why not use Google Charts?
So I did a test, that list step by step.
- In the form that contains my data to process I created a pass-thru <computedvalue> containing the URL of Google (ie "http://chart.apis.google.com/chart?cht=p3&chd=s:Uf9a&chs=250x100&chl=January|February|March|April")
- I opened the document with the form above, and I noticed a picture with a "red cross"

- Right click on the picture I noticed the option "Show images", selecting the image appears correctly
Everything ok, but how to avoid each time you select "Show images"?
If
you go on the properties of the document you will notice that there is
a field "$DelayedImages" to 1, when the red cross is shown on the
image
However if you have selected the option "Show Images" has a field "$DelayedImagesOK" set to "ok".
So, in document form, i've created a computed field "$DelayedImagesOK" with value" ok "and you're done!
This is the result
Document Actions
Oct 27, 2010
Forms with the same alias is *still* a bad practice (Xpages Bug)
Probably a bug found in XPages 8.5.2 engine
There is not to boast, but perhaps the development team RedTurtle found a bug in the engine of XPages 8.5.2.
It's happened during the development of an application where we had to connect a datasource to a Xpage. It appears that, in case you have two forms with the same alias, the list of available fields always refer to the first of two forms that is found in the list (we know, it's a very bad practice assigning same aliases to different forms, but we inherit this scenario from someone else...)
Only renaming the alias you obtain the right binding of the fields, even if the engine allows you to refer to the two blur.
By submitting the matter to two of the leading experts on the subject, Bob Balfe and John Mackey, we had confirmation that the problem exists.
UI Architect for IBM Workplace Designer has been alerted and will investigate the problem.
You will be posted ...
Document Actions
Oct 13, 2010
Oracle and IBM Collaborate to Accelerate Java Innovation Through OpenJDK
Oracle and IBM today announced that the companies will collaborate to allow developers and customers to build and innovate based on existing Java investments and the OpenJDK reference implementation. Specifically, the companies will collaborate in the OpenJDK community to develop the leading open source Java environment.
Document Actions
Sep 10, 2010
"Received" field is big trouble for Lotusscript..
A bit of background when SMTP mail headers come in, they create multiple 'received' fields in mail document
This is done instead of putting multiple entries in a single field, but the problem comes from the fact that the notes mail document includes a 'Received' field for every server it has passed.
Lotus Notes give us a documented method that gets the text values of the Received items in a mail document.
stringArray = notesDocument.GetReceivedItemText( )
But sometimes it doesn't work...
Agent message: Received Item is not standard format - access with GetItemValue
Thanks to Raymond Neeves for his great function
After calling this, you can simply access all values of Received field with
Forall v In doc.Received
msgbox v
End Forall