Overriding the "Processing" Icon:
This requirement is similar to overriding the Favorite Icon. The "Processing/Spinning" icon generally appears when the PeopleSoft PIA is still processing a request. This "Processing" icon is simply a GIF image - PT_PROCESSING_FMODE delivered image object. In some scenarios, this delivered icon may not really fit in with the custom Branding theme. If we want to override this icon then there are two options.
Option 1: Replace delivered GIF image object PT_PROCESSING_FMODE with a custom GIF image object. This is not something I would recommend but it is an option for those looking for a quick and dirty override (along the lines of Doc ID 2004996.1).
Option 2: Use the jQuery image replacement technique detailed in the previous post for overriding this delivered image PT_PROCESSING_FMODE with a custom image (CSK_PROCESSING_FMODE).
I am using the following image as my custom "Processing" icon:
Delivered PT_PROCESSING_FMODE image for reference:
I am updating my image replacement javascript object CSK_FL_IR_JS again. I am finding all the occurrences of PT_PROCESSING_FMODE (delivered image) with id = "processing" and replacing it with a custom image (CSK_PROCESSING_FMODE) using jQuery.
Updated javascript (CSK_FL_IR_JS) for reference:
// Get Image URL for CSK_LOGO (FavIcon);
document.write(unescape("%3Cscript src='/psc/" + site + "/EMPLOYEE/EMPL/s/WEBLIB_FL_CSK.ISCRIPT1.FieldFormula.IScript_Set_Image_URL_Variable?var=cskFavIcon&img=CSK_LOGO_FAVICON' type='text/javascript'%3E%3C/script%3E"));
// Get Image URL for CSK_LOGO (Fluid);
document.write(unescape("%3Cscript src='/psc/" + site + "/EMPLOYEE/EMPL/s/WEBLIB_FL_CSK.ISCRIPT1.FieldFormula.IScript_Set_Image_URL_Variable?var=cskLogo&img=CSK_LOGO_SVG' type='text/javascript'%3E%3C/script%3E"));
// Get Image URL for CSK_LOGO (Fluid SFF);
document.write(unescape("%3Cscript src='/psc/" + site + "/EMPLOYEE/EMPL/s/WEBLIB_FL_CSK.ISCRIPT1.FieldFormula.IScript_Set_Image_URL_Variable?var=cskLogoSFF&img=CSK_LOGO_SFF_SVG' type='text/javascript'%3E%3C/script%3E"));
// Get Image URL for CSK Custom Processing Icon for Fluid;
document.write(unescape("%3Cscript src='/psc/" + site + "/EMPLOYEE/EMPL/s/WEBLIB_FL_CSK.ISCRIPT1.FieldFormula.IScript_Set_Image_URL_Variable?var=cskProcessingFmode&img=CSK_PROCESSING_FMODE' type='text/javascript'%3E%3C/script%3E"));
var $jq = jQuery.noConflict();
$jq(document).ready(function(){
// Get current Image Source;
var imageSrc = $jq('#PTNUI_LP_HEADER_PTNUI_LOGO img').attr('src');
if (imageSrc != null) {
if (imageSrc.indexOf("PTNUI_ORACLE_LOGO_SFF") < 0) {
// Use Regular Image;
$jq('#PTNUI_LP_HEADER_PTNUI_LOGO img').attr('src', cskLogo);
} else {
// Use Small Form Factor Image;
$jq('#PTNUI_LP_HEADER_PTNUI_LOGO img').attr('src', cskLogoSFF);
}
}
// Replace Browser Favorite Icon(s);
$jq('head link[href*=LOGO_FAVICON]').attr('href', cskFavIcon);
// Fluid Processing Icon;
// 20160420 - Updated selector to be more specific to Fluid using src attribute wildcard;
$jq('#processing[src*=PT_PROCESSING_FMODE]').attr('src', cskProcessingFmode);
});
Result:
Check out this demo video >>>> Override Processing Icon
This requirement is similar to overriding the Favorite Icon. The "Processing/Spinning" icon generally appears when the PeopleSoft PIA is still processing a request. This "Processing" icon is simply a GIF image - PT_PROCESSING_FMODE delivered image object. In some scenarios, this delivered icon may not really fit in with the custom Branding theme. If we want to override this icon then there are two options.
Option 1: Replace delivered GIF image object PT_PROCESSING_FMODE with a custom GIF image object. This is not something I would recommend but it is an option for those looking for a quick and dirty override (along the lines of Doc ID 2004996.1).
Option 2: Use the jQuery image replacement technique detailed in the previous post for overriding this delivered image PT_PROCESSING_FMODE with a custom image (CSK_PROCESSING_FMODE).
I am using the following image as my custom "Processing" icon:
Delivered PT_PROCESSING_FMODE image for reference:
I am updating my image replacement javascript object CSK_FL_IR_JS again. I am finding all the occurrences of PT_PROCESSING_FMODE (delivered image) with id = "processing" and replacing it with a custom image (CSK_PROCESSING_FMODE) using jQuery.
Updated javascript (CSK_FL_IR_JS) for reference:
// Get Image URL for CSK_LOGO (FavIcon);
document.write(unescape("%3Cscript src='/psc/" + site + "/EMPLOYEE/EMPL/s/WEBLIB_FL_CSK.ISCRIPT1.FieldFormula.IScript_Set_Image_URL_Variable?var=cskFavIcon&img=CSK_LOGO_FAVICON' type='text/javascript'%3E%3C/script%3E"));
// Get Image URL for CSK_LOGO (Fluid);
document.write(unescape("%3Cscript src='/psc/" + site + "/EMPLOYEE/EMPL/s/WEBLIB_FL_CSK.ISCRIPT1.FieldFormula.IScript_Set_Image_URL_Variable?var=cskLogo&img=CSK_LOGO_SVG' type='text/javascript'%3E%3C/script%3E"));
// Get Image URL for CSK_LOGO (Fluid SFF);
document.write(unescape("%3Cscript src='/psc/" + site + "/EMPLOYEE/EMPL/s/WEBLIB_FL_CSK.ISCRIPT1.FieldFormula.IScript_Set_Image_URL_Variable?var=cskLogoSFF&img=CSK_LOGO_SFF_SVG' type='text/javascript'%3E%3C/script%3E"));
// Get Image URL for CSK Custom Processing Icon for Fluid;
document.write(unescape("%3Cscript src='/psc/" + site + "/EMPLOYEE/EMPL/s/WEBLIB_FL_CSK.ISCRIPT1.FieldFormula.IScript_Set_Image_URL_Variable?var=cskProcessingFmode&img=CSK_PROCESSING_FMODE' type='text/javascript'%3E%3C/script%3E"));
var $jq = jQuery.noConflict();
$jq(document).ready(function(){
// Get current Image Source;
var imageSrc = $jq('#PTNUI_LP_HEADER_PTNUI_LOGO img').attr('src');
if (imageSrc != null) {
if (imageSrc.indexOf("PTNUI_ORACLE_LOGO_SFF") < 0) {
// Use Regular Image;
$jq('#PTNUI_LP_HEADER_PTNUI_LOGO img').attr('src', cskLogo);
} else {
// Use Small Form Factor Image;
$jq('#PTNUI_LP_HEADER_PTNUI_LOGO img').attr('src', cskLogoSFF);
}
}
// Replace Browser Favorite Icon(s);
$jq('head link[href*=LOGO_FAVICON]').attr('href', cskFavIcon);
// Fluid Processing Icon;
// 20160420 - Updated selector to be more specific to Fluid using src attribute wildcard;
$jq('#processing[src*=PT_PROCESSING_FMODE]').attr('src', cskProcessingFmode);
});
Result:
Check out this demo video >>>> Override Processing Icon
Thanks Shasank for the additional work...funny enough I am looking and working my way through the blog and was wondering where the original CSK_FL_IR_JS code you used in previous sections.. I am jumping around a little so, can you point out which section? Thanks,
ReplyDeleteSorry. It is a series of posts, I should have been clearer and I see how it can be confusing.
ReplyDeleteHere is the original bootstrap code for injecting javascripts to Fluid:
http://pe0ples0ft.blogspot.com/2015/11/peopletools-854-branding-part-5b-fluid.html#FluJSInjectionBootstrap
Here is where I started creating the CSK_FL_IR_JS and kept building on it:
http://pe0ples0ft.blogspot.com/2015/11/peopletools-854-branding-part-5c-fluid.html#jQueryToOverrideFluImages
Hopefully it gives you what you are looking for. Just let me know if I am still missing any steps!
No worries.. I have just finished going through the entire Fluid 5 series, excellent work... I did figure it out it was a matter of going through 5c past the point where I was to see the code.
DeleteI do like the JS image injection work you have done. I was on a project where discussed a similar approach to do some changes but the pace of the work prevented us from exploring things further. Oh well, nice to see you worked a very good solution.
...STB
Great post Sasank!
ReplyDelete-Amar
Thanks Amar! :)
DeleteHello Sasank,
ReplyDeleteI would like to hide the peoplesoft home link form Header, can you please suggest how can i able to that
Are you referring to the Home link on the Classic or Fluid?
DeleteFor Classic, you can go to the header that you are using and delete it.
For example: https://snag.gy/Av9c8b.jpg
Hey Sasank,
ReplyDeleteFirst of all, thank you for sharing so much quality material!
I know this post is pretty old, but I though I could add another simple method of accomplishing this.
1. Create new image object with your gif/img (e.g. CW_APPL_LOADING).
2. Create new HTML object: window.onload = function() { document.getElementById("WAIT_win0").innerHTML = "";};
3. Import JS using AddJavaScript function in component PeopleCode.
Regards,
Bradley Reeves
Noticed my HTML was removed. For innerHTML you just need to add the usual id, style, and src.
DeleteHi Sasank, I've notice a difference with the PS Processing Icon and that of the Browser...on certain actions, the PS Icon stops spinning as if the action is complete...but the Browser's icon keep spinning. Any idea to keep the 2 in sync? It seems App Server thinks the Webserver is done when it isn't as the Browser still spins. It is a bit confusing for users who think a button that was clicked isn't working as the anticipate being transferred after the PS Icon stops spinning for example. I looked in the PT_PROCESSING html object but not sure.
ReplyDeleteHi Ricky - That is a good question! I don't think I have noticed that difference but you are right the app server processing and web server processing might be the reasons for the mismatch.
DeleteI don't know if there is an easy way to control that. Will let you know if I get any ideas. Thanks!
Hi Sasank, I have been reading you post, they are very informative and clear.
ReplyDeleteI have a requirement to add my own custom Submit Button on the header section. I have done using the Group Box(Custom Header Right) and wants to change the color to GREEN (back ground color). Any delivered style sheet?, coz it is taking Default color (BLUE) of the Banner. Any suggestion?