Improved m-Power Templates
Beginning with the August 2012 update, m-Power templates have been significantly improved. Specifically:
- m-Power JavaScript files have been packed (compressed) into a single file. This packed JavaScript file is optimized for a faster load time of generated applications.
- Cascading Style Sheets (CSS) file has been updated and relocated. Your Data Dictionary’s style sheet has moved – it can now be found in /m-power/mrcjava/mrcclasses/DATA_DICTIONARY. Moving the style sheet to this location allows your generated applications to utilize industry standard syntax when linking to your styles at run-time. Moving this file isn’t just about industry standards, it also improves the m-Power experience for your developers. Developers can now modify their CSS files and immediately see their changes. Previously, they would need to log back into m-Power to view any changes that were made.
- HTML optimization – Previous versions of m-Power templates relied on HTML tables to organize the content of the application. Now, m-Power developers will have greater flexibility of their applications as m-Power templates now utilize DIV tags to help layout and organize the HTML elements of their applications.
m-Power users who have updated with the m-Power update.exe (found here in the Customer Portal) have already implemented these new features simply by running the executable! Existing applications will continue to look and behave as they did prior to this update. Newly generated applications will utilize the enhancements listed above.
m-Power users who have updated with the m-Power update.zip file (also found here in the Customer Portal) need to run a program on their m-Power server to configure their CSS files. Users can navigate to the /m-power folder. Users should then run one of the three files, based on the system m-Power is installed:
- Windows – Double click on copy-style-files.bat
- Linux – Type “sh copy-style-files-linux.sh” from a terminal prompt
- AS400 – Type “sh copy-style-files400.sh” from a QSH prompt.
New CSS File location
Whether you updated m-Power with the .exe or the .zip file, you may want to be aware of the new location of your dictionary’s stylesheet. (Don’t worry, any existing m-Power applications already know about this change and will automatically point to the new location. The m-Power interface has been updated too so when you click on Admin -> Edit Data Dictionary Files -> Web 2.0 Servlet Style Sheet, m-Power will automatically allow you to edit the file in the new location.
As part of the update process, any existing CSS files will be moved from:
/m-Power/mrcjava/WEB-INF/classes/DATA_DICTIONARY/mrc_servlet_stylesheet_css.html to
/mPower/mrcjava/mrcclasses/DATA_DICTIONARY/mrc_servlet_stylesheet.css
Additionally, /m-Power/mrcjava/WEB-INF/classes/DATA_DICTIONARY/mrc_servlet_stylesheet_css.html will be renamed to mrc_servlet_stylesheet_css_obsolete.html as it will no longer be used. You can delete it at your discretion.
Promoting applications
When promoting applications generated after August 2012, be sure to do the following on your production server:
- Be sure the production server is running the August 2012 update.
- Be sure the /m-power/mrcjava/DATA_DICTIONARY folder has been copied to production
If you do not copy the /m-power/mrcjava/DATA_DICTIONARY folder to production, your applications will not have the necessary CSS file to reference.
To aid in the promotion process, please consider download and installing the Application Promotion Utility, found here, within our Project Exchange.