Follow Us on Twitter

The Modular Layout Application in APEX

by Douwe Pieter van den Bos on November 12, 2009 · 0 comments

In my previous post, about a.s.a.p. APEX, one of my readers points out that he (or she) doesn’t actually understands what I meant. The reader, who has the appropriate name of ‘My Name’, even offers me a job in order for him to understand what I meant! So, let me be a bit more clear about this subject in this post.
When we look at ‘as simple as possible APEX’, one of the most important parts is modular design. This means that we take as small as possible functional parts of the application we need to deliver and develop them is as small as possible development teams. One of the modules you will need in order to make this a success is the layout application. Inside this application we completely define the look and feel of all the applications that combined form the system we’re developing.

In this way we can focus on developing an application without worrying about the layout we need in the end. The layout application contains the templates we are going to use in the end. This means that the layout application is one of the first parts developed in a complete system. I usually create this application as follow:

First I, of course, create the application itself. Based on one of the standard Themes in APEX, like theme 4, I create my own theme. At this point I can delete all the templates in the theme I don’t want to be inside my project. For example, theme 4 contains 69 templates, you can imagine that you won’t need all these templates and that working with less templates can only improve the way the application looks. Developers have less choice between templates and this secures the overall continues look of the entire application. When you’re down to the templates that just want to use, I usually go down to about 10 templates, you’re ready to roll!

Now we get into the second step of our modular layout. This step includes creating all the underlying applications in the system we are about to develop. When we have set up an application within APEX, we create a theme based on the theme we just created in the layout application. Go to Shared Components, Themes and create a new theme inside the application and give it an appropriate name. Once done, click inside the task bar on the right of the screen to ‘Replace templates in this application with templates from another application.’ Select the layout application and then the theme you have created. Then we have the screen that we need: select for the appropriate templates the destination and the action ‘Replace / Subscribe’. This is it!

Once we have created some subscriptions to our own Theme we can edit the theme as we like it. I usually create a separate folder within /i/ by copying theme 4 and rename to the projects name. At this point we can edit the theme by pointing towards the right folder, renaming and editing the stylesheet (CSS) and editing the templates to make them look as we want. I won’t go into how this works in this post, but maybe later.

Once you have edited a template in the layout application you can publish this to all the applications that have a subscription on this template by simply clicking on the ‘Publish’ link inside the Subscription part of the Edit Template page. This is all the info you need to create an easy to maintain and develop layout inside an APEX application.

Ratings:
VN:F [1.9.3_1094]
Rating: 0.0/5 (0 votes cast)

Leave a Comment

Previous post:

Next post: