Dec 02

UKOUG Oracle APEX SIGI attended the first two days at the UKOUG conference in Birmingham and after last attending in 2007 I have to say it was pretty quiet this time round, funnily enough though not for APEX. Our company has a stand there and it was part of my job to at least spend half the day on it, whilst catching a presentation here and there, anyway the point is that a lot of the people were coming up to talk about APEX.

What was more interesting was the type of companies, i.e. ISV’s (independent software vendors) who have started to commit to APEX. The thing is that they’re on the lookout for modularized functionality, which means that there will be commercial opportunities for plugins in APEX 4.0. In my opinion a little financial incentive always gets me motivated, so get ready for 4.0 as ROI for plugins will be much easier than full applications, and less time consuming!

Another highlight from the event was John Scott’s presentation on APEX scalability, what was really impressive was the Apache compression technique combined with the expire headers and caching, this is going to give a massive boost to our apps as they are heavily dependant on javascript and images. I was amazed at what sort of performance boost you could get from this!! jMeter was pretty damn cool too, another must have! Download his presentation for more details, i’d strongly recommend it.

Note: John hasn’t uploaded it yet but he did do the presentation at the APEX SIG, so if your a member of OUG you should be able to login and download it here

Tagged with:
Aug 13

We’re all eagerly anticipating the release of APEX 4.0, and we can’t wait to see the plugin functionality Patrick Wolf is building into the product. We’ve seen a few people looking to host a plugin registry and we thought we’d throw our hat into the ring and let the community decide which will be the best one to use. We’ve decided to build a plugin registry using our APExt JS Framework as it seems like the perfect choice as we’ll be creating Ext plugins post release of APEX 4.0 (we’re looking to submit the plugin registry for the APEX developer competition, but chances are it will get disqualified as it’s a little grey around third party licensing)

Today’s post focuses on an issue we found with the row expander grid plugin. Some background first: we are building a simple report which will break the plugins into categories using Ext grouping and will provide row expanding functionality for the plugin comments. (See the following image for a basic example).

APEX Plugin Registry

We disabled the column headings in the Grid to make it look more like what you see on the Ext 3.0 samples page setting the “hideHeaders” attribute to true. In the example we actually have two columns, 1 for the plugin image and the other for the plugin details. In order to obtain the formatting for the plugin details we needed to embed some HTML into our SQL query. e.g.

select * from (
SELECT 'Some information to come soon!' comments
,      pc.name category
,      p.name  plugin_name
,      '<img src="&EXT_BASE_DIR./../../../apr/img/'||p.image||'" width="100" />' image
,      '<table cellpadding="0" cellspacing="0" summary=""><tr ><td style="padding-bottom:10px;"><span style="font-size:16px;font-weight:bold;">'||p.name||'</span></td></tr></table>'||
       '<table cellpadding="0" cellspacing="0" summary=""><tr ><td style="width:85px;">'||
       '<b>Description </b></td><td style="width:8px;"><b>:</b></td><td>'||substr(p.description,1,100)||
       '</td></tr><tr><td><b>Version </b></td><td><b>:</b></td><td>'||p.version||
       '</td></tr><tr><td><b>'||'Author </b></td><td><b>:</b></td><td>'||u.known_as||
       '</td></tr><tr><td><b>APEX Version </b></td><td><b>:</b></td><td>'||p.required_version||
       '</td></tr><tr><td><b>'||'Downloads </b></td><td><b>:</b></td><td>'||nvl(downloads_total,0)||
       '</td></tr><tr><td><b>'||'Rating </b></td><td><b>:</b></td><td>'||
       jquery_widgets.get_stars('f'||lpad(to_char(rownum),2,'0'),round(p.average_rating))||'</td></tr></table>' details
FROM   apr_plugins           p
,      apr_plugin_categories pc
,      apr_users             u
WHERE  p.category_id = pc.category_id
AND    p.author_id   = u.user_id)
where (
 instr(upper("CATEGORY"),upper(nvl(:P4_CATEGORY,"CATEGORY"))) > 0  and (
 instr(upper("PLUGIN_NAME"),upper(nvl(:P4_REPORT_SEARCH,"PLUGIN_NAME"))) > 0  or
 instr(upper("DETAILS"),upper(nvl(:P4_REPORT_SEARCH,"DETAILS"))) > 0
))

It gave us the look we were wanting to achieve, however the side affect was that it broke the row expander plugin because we were embedding a HTML table in one of the row columns, i.e. the detail column.. The problem was due to the following call on line 116 of the rowexpander.js plugin

var body = Ext.DomQuery.selectNode('tr:nth(2) div.x-grid3-row-body', row);

Basically body was “undefined” and we received a js error. The fix, after a little tedious debugging, was to change the CSS selector to the following:

var body = Ext.DomQuery.selectNode('tr:nth-child(2) div.x-grid3-row-body', row);

Essentially we just made sure that the CS selector looked at the direct children of the parent root node.

Note: you’ll also see that we’re using the jQuery star rating plugin that Roel Hartman blogged about, it’s a nice little plugin…. it shows that you can mix and match functionality from multiple javascript frameworks.

preload preload preload