[
https://jira.jboss.org/jira/browse/GTNPORTAL-541?page=com.atlassian.jira....
]
Tan Pham Dinh resolved GTNPORTAL-541.
-------------------------------------
Resolution: Done
Now, we can configure priority in the gatein-resources.xml. Children of <param>
tag(for javascript) are js-module, js-path [and js-priority]. Thanks
Javascript merge ordering
-------------------------
Key: GTNPORTAL-541
URL:
https://jira.jboss.org/jira/browse/GTNPORTAL-541
Project: GateIn Portal
Issue Type: Task
Reporter: Julien Viet
Assignee: Tan Pham Dinh
Fix For: 3.0.0-CR01
Original Estimate: 1 day
Remaining Estimate: 1 day
based on a priority XML tag that will allow the javascript service to merge them.
if <priority> tag is not specified : priority => -1 : -1 means that the scripts
will be loaded *last*
merge of javascript is based on priority + alphabetical name with the following policy:
compare(int p1, String n1, int p2, String n2) {
if (p1 == p2) {
// we compare n1 and n2
} else {
if (p1 == -1) {
// p2 is more important
} else if (p2 == -1) {
// p1 is more important
} else {
// we compare p1 and p2
}
}
}
the javascript service will keep the script + priority and every time a new script is
added, the final javascript will be recomputed.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira