Using the PIA Welcome Message

2023-11-08 14:20
文章标签 message using welcome pia

本文主要是介绍Using the PIA Welcome Message,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

The PIA Welcome message, or Portal Greeting is a pretty simple piece of functionality, but I’ve not seen it used on a single client site. For those that haven’t seen it before, it looks like this:

Welcome Message example

The welcome message is stored on a per user basis, it is set using the ‘Personalize Content’ link on the Homepage, and it is stored in the table PSPRUHDEFN. If updated via SQL, it won’t appear instantly unless you either bounce the App Server (and clear the cache) or increment the versions in PSVERSION and PSLOCK. There is an (Oracle) sql script to update the message – so it appears instantly – at the foot of this post.

A more constructive use of the greeting would be to alter it slightly. Particularly during development and testing it would be useful to display the logged on user and the environment name. An extremely simple change to a Tools object (yes, I know, but it’s such a small change that the upgrade implications will be minimal) allows this.

Updated Portal Greeting

There are two steps, output the user/database in the greeting and make the message appear on every page, not just the Homepage.

1. Output the user/database in the greeting

Open Application Package PT_BRANDING, Application Class BrandingBase, Method GetIScriptHPDefaultHdrHTML.

Replace:
Greeting = &Portal.Homepage.Greeting;

With:
/* <name> – 13/06/07 – Adding user and environment to branding */
/* &Greeting = &Portal.Homepage.Greeting; */
&Greeting = %UserId | ” on ” | %DbName;
/* <name> – End */

2) Make the message appear on every page, not just the Homepage.

If you want it to display on all pages, you need to edit Application Package PT_BRANDING, Application Class BrandingBase, Method GetUniHeaderHTML and GetUniHeaderHTML_PIA.

Add the following just before the ‘If &navTheme.isNS4x()’:
/* <name> – 13/06/07 – Adding user and environment to branding */
&Greeting = %UserId | ” on ” | %DbName;
/* <name> – End */

Oracle SQL Script to update the message for a single user

–===================================================================
define portal=’EMPLOYEE’
define oprid=’<oprid>’
define message=’<desired message>’

UPDATE PSLOCK SET VERSION = VERSION + 1 WHERE OBJECTTYPENAME IN (‘CRM’, ‘PRUH’);

DELETE FROM PSPRUHDEFN WHERE PORTAL_NAME = ‘&portal’ AND OPRID = ‘&oprid’;
DELETE FROM PSPRUHTAB WHERE PORTAL_NAME = ‘&portal’ AND OPRID = ‘&oprid’;
DELETE FROM PSPRUHTABPGLT WHERE PORTAL_NAME = ‘&portal’ AND OPRID = ‘&oprid’;
DELETE FROM PSPRUHPERSPGLT WHERE PORTAL_NAME = ‘&portal’ AND OPRID = ‘&oprid’;
DELETE FROM PSPRUHDEL WHERE PORTAL_NAME = ‘&portal’ AND OPRID = ‘&oprid’;

INSERT INTO PSPRUHDEFN ( LASTUPDDTTM, LASTUPDOPRID, OBJECTOWNERID, VERSION, PORTAL_NAME, OPRID, PORTAL_GREETING254)
SELECT sysdate, ‘&oprid’, ‘ ‘, VERSION, ‘&portal’, ‘&oprid’, ‘&message’
FROM PSLOCK WHERE OBJECTTYPENAME = ‘PRUH’;

INSERT INTO PSPRUHTAB ( PORTAL_NAME, OPRID, PORTAL_OBJNAME, PORTAL_SEQ_NUM, PORTAL_LABEL, PORTAL_COLLAYOUT, PORTAL_STG_NAME)
VALUES ( ‘&portal’, ‘&oprid’, ‘DEFAULT’, 0, ‘My Page’, 3, ‘PR_EMPLOYEE_DEFAULT’);

INSERT INTO PSPRUHTABPGLT ( PORTAL_NAME, OPRID, PORTAL_OBJNAME, PORTAL_OBJNAME_PGT, PORTAL_COL_NUM, PORTAL_ROW_NUM, PORTAL_MINIMIZE)
VALUES ( ‘&portal’, ‘&oprid’, ‘DEFAULT’, ‘MENU’, 1, 1, 0);

UPDATE PSVERSION SET VERSION = VERSION + 1 WHERE OBJECTTYPENAME = ‘SYS’;
UPDATE PSLOCK SET VERSION = (SELECT VERSION FROM PSLOCK WHERE OBJECTTYPENAME = ‘CRM’) WHERE OBJECTTYPENAME = ‘CRM’;
UPDATE PSLOCK SET VERSION = (SELECT VERSION FROM PSLOCK WHERE OBJECTTYPENAME = ‘PRUH’) WHERE OBJECTTYPENAME = ‘PRUH’;
UPDATE PSVERSION SET VERSION = (SELECT VERSION FROM PSLOCK WHERE OBJECTTYPENAME = ‘CRM’) WHERE OBJECTTYPENAME = ‘CRM’;
UPDATE PSVERSION SET VERSION = (SELECT VERSION FROM PSLOCK WHERE OBJECTTYPENAME = ‘PRUH’) WHERE OBJECTTYPENAME = ‘PRUH’;
–===================================================================

Comments»

1. Jim J. Marion - July 2, 2007

Well done. It is good to see people digging into the branding objects.

Reply
2. Jim J. Marion - July 2, 2007

Another idea… For security reasons, many PeopleSoft administrators avoid displaying the OPRID and database name through the PIA. To facilitate this while avoiding reaplying this change every time you copy PRO to TST/DEV, you could wrap your app package change in an if statement that uses &Portal.Homepage.Greeting in PRO, but uses %UserId | ” on ” | %DbName when in DEV/TST.

Reply
3. PeopleSoft Tipster - July 3, 2007

Good point. I’d probably not advocate moving this customisation into Production, but your solution is a much smarter idea as it removes the need for an extra step each time Prod is cloned. I like it …

Reply
4. Stephen Fols - August 1, 2007

Why is it not a good idea to display the oprid and database name in prod?

Reply
5. PeopleSoft Tipster - August 15, 2007

Just from a security point of view. Anyone looking over your shoulder can see your username, and then they have half of your username/password combination.

It’s not something that worries every company, but some don’t like usernames to be shown.

Reply
6. Hexawala - February 19, 2008

Hi, I was asked to Display a Welcome message to the users. I found this solution very useful. Since we have multi language users, How can we display the Messages in the Language that the user logged in. Any help is highly appreciated.

Reply
7. Hexawala - February 19, 2008

Hi
Got it. Used the %Language_User … as follows.

If %Language_User = “ARA” Then
&Greeting = “أنظمة الإدارة المدرسية”;
Else
&Greeting = “School Mangement System”;
End-If;

Thank you All.

Reply
8. ba - June 21, 2008

cant change the PT_BRANDING package. it is saying read only why ???

Reply
9. PeopleSoft Tipster - June 23, 2008

This might be something as simple as the user you are using doesn’t have the correct privileges. If you’re the sysadmin you could always grant yourself the ‘PeopleSoft Administrator’ role then relogin to App Designer again.

Reply
10. ba - July 2, 2008

i do have the ‘PeopleSoft Administrator’ and i am using super user PS/PS. am i missing anything else….

Reply
11. RN - August 14, 2008

Tried the code changes suggested above but didn’t get the greetings. Am I missing something? I am assuming that the sql updates are not necessary if the Application package changes are made? Is this change particular to a specific branding/theme?

Reply
12. PeopleSoft Tipster - August 14, 2008

Once you make the App Package changes then you need to do one of the following:

1) bounce App Server and Clear the cache.

2) run the SQL listed.

This isn’t for any particular branding or theme.

Reply
13. RN - August 15, 2008

Did all that.. I thought that the SQL listed below was for a single user and a different approach to the app package changes. Well did the sql, did all the cache cleaning but still didn’t work..will keep tugging at it.. thanks for the blog

Reply
14. Devesh Padmanabhan - August 19, 2008

What if I wish to display the Full Name (FIRST_NAME and LAST_NAME) instead of the User ID. How can we move ahead with this?

Reply
15. PeopleSoft Tipster - August 19, 2008

RN > are you using anything like Portal, or just an application like HR, Financials, CRM …

Devesh > If you already have the OPRID you can look up the name from the user profile, or just get it via SQL. There are plenty of examples in the code if you need help.

Reply
16. Devesh - August 25, 2008

Hi,

I am not a PeopleSoft Developer. I would apreciate if you could write the code (PeopleCode/ App Package Code and not the SQL), so that I can test it in my instance.

Thanks in advance,
Devesh

Reply
17. PeopleSoft Tipster - August 25, 2008

Devesh > It’s a little unrealistic to expect me (or any other blog author) to provide a free solution just because you aren’t a developer yourself. Most readers are grateful enough that they’re given 80% of the solution. If you really can’t find the time to learn (PeopleBooks is a free resource) then perhaps getting someone in might be the best bet.

Reply
18. RN - August 27, 2008

I am using Ent. Portal 8.8. Made all the changes at the specified places. Ran the scripts, cleaned cache.etc.. No luck..Thanks for your input..

Reply
19. Devesh - August 28, 2008

Ok. No issues. I’ll check the PeopleBooks for reference. Thanks anyways for your reply.

Reply
20. PeopleSoft Tipster - August 28, 2008

RN > I’ve not tried this on Enterprise Portal, only on the other applications. I would assume portal would be different so you’ll probably have to do a fair bit of tweaking to get it to work. It’s probably worth checking out though as it may well be easier to achieve the same result in Portal than HR …

Reply
21. simrose - September 11, 2008

Why we need to run Oracle SQL Script , why by just changing the application package code will not do the need full.Can u please xplain the need for Oracle SQL Script..
Thanks in Advance

Reply
22. Tipster - September 22, 2008

The SQL updates the message to give a specified message to a single user. It’s a quick and dirty update. The PeopleCode version is the method to use if you’re doing it ‘properly’.

Reply
23. neel - November 4, 2008

Thanks for the update,

I am totally new in this arena and doing peoplesoft admin for last 2 years.

recently got an assignment of our peoplesoft hompeage branding.

please refere any red paper if possible or share me the activity list that is needed from peoplesoft admin to perticipate in branding.

Regards
Neel

Reply
24. Tipster - November 4, 2008

You’ll want to look in PeopleBooks and the red paper library on Customer Connection.

Reply
25. Navin Sahay - January 8, 2009

Hi! Everybody,

Good Morning!

Actually, I want to hide the ‘Home’ link [which is coming top right of every page] for some pages.

I have made changes in PT_BRANDING (Application Package), in class ‘HeaderLinkPIA’ and ‘HeaderLink Base’.

My addition in ‘HeaderLinkPIA’ class in PT_BRANDING (Application Package):

To hide the ‘AddToFavorites’ while going to Careers page(Root > SelfService > Recruiting Activities > Careers)

I have added the below code in the method ‘SetAddFav’

/* If &CRef.Name = “HC_HRS_CE_GBL” Then
&DisplayAddToFavLink = False;
End-If;

If &CRef.Name = “HC_HRS_CE_GBL2″ Then
&DisplayAddToFavLink = False;
End-If;
*/

*** And it worked successfully ***

So, I have tried to apply the same concept to hide the ‘Home’ link, I have added one method ‘SetHomeURL’ in ‘HeaderLinkPIA’ class. Tried to catch the HTML for ‘Home’ link, like ‘PORTAL_HEADER_ADDTOFAVORITES’ is the HTML for the ‘AddToFavorites’ link. However i haven’t found the exact HTML with button coding in for the ‘Home’ link, as i have found button coding n all in ‘PORTAL_HEADER_ADDTOFAVORITES’ for ‘AddToFavorites’ link.

I have found many HTML for ‘Home’ like ‘PORTAL_HOME_1′, ‘PORTAL_HOME_HEADER’, ‘PORTAL_HOME_SKELETON’, ‘PR_EMPLOYEE_HOMEPAGE_DESIGNERA’, ‘PT_HOME_SKELETON’ etc. and tried to hide the link as i have done with ‘AddToFavorites’, BUT NO SUCCESS….:(

Anyone, please please please help me.

Warm Regards,
Navin

Reply
26. ernst - June 30, 2009

Thanks Tipster, saved me a lot of time to figure the tables out myself :-) . Using it in DEV instances to tell the tools and bundle level.

Reply
27. Portal Greeting on Tools 8.50 « PeopleSoft Tipster - May 21, 2010

[...] posted before about using the Portal Greeting / PIA Welcome message to display something useful here.  I’ve recently come to implement this on a client and discovered that the method I [...]

Reply

这篇关于Using the PIA Welcome Message的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/370452

相关文章

Build Min Heap Using Array

Build min-heap using Array. 思路1:首先明白heap的底层implementation就是array,从0开始的parent和left,right的关系为, 如果现在的node index为i,那么parent index就是 (i-1)/2;   left  为2*i+1, right为 2*i+2;          ( i-1 ) / 2

Implement Set using Array.

参考链接:http://faculty.washington.edu/moishe/javademos/ch03%20Code/jss2/ArraySet.java 被Pivotal的面试官给问到了,trick的地方在于remove的那一块,要把最后的元素跟自己remove的元素进行互换,然后count--;还有,自动扩容那块,构造函数需要两个,一个默认的,一个是可以限定side的。然后扩容的时

Implement Rand10() Using Rand7()

Given a function rand7 which generates a uniform random integer in the range 1 to 7, write a function rand10 which generates a uniform random integer in the range 1 to 10. Do NOT use system's Math.ra

C# 使用中点查找矩形的角(Find Corners of Rectangle using mid points)

考虑一个矩形 ABCD,我们给出了边 AD 和 BC 中点(分别为 p 和 q)的坐标以及它们的长度 L(AD = BC = L)。现在给定参数,我们需要打印 4 个点 A、B、C 和 D 的坐标。 例子:  输入:p = (1, 0)         q = (1, 2)         L = 2 输出:(0,0),(0,2),(2,2),(2,0) 解释: 打

SDUT1500_Message Flood(字典树)

Message Flood Time Limit: 1500MS Memory limit: 65536K 题目描述 Well, how do you feel about mobile phone? Your answer would probably be something like that "It's so convenient and benefits peop

MQTT: Will Message

Will Message (遗嘱信息) Will 消息需要被服务器保存在服务器端,和当前网络连接关联。 Will 消息必须在后续网络连接断开之后被分发出去(Publish), 除非服务器收到了来自客户端的 Disconnect 包。 发布 Will信息的情形包括但不限于: 服务器检测到客户端连接中断或者 I/O 错误。客户端没有按照约定的 Keep-Alive 时间发送 Ping 消息。客

Android源码解析Handler系列第(一)篇 --- Message全局池

1、UI不能在子线程中更新是个伪命题 我们常说UI需要在主线程中进行更新,子线程就不能更新UI吗?不是,我们并不是说不能在子线程中更新UI,而是说UI必须要在它的创建线程中进行更新,比如下面一段代码在子线程更新UI就不会报错。 new Thread(new Runnable() {@Overridepublic void run() {TextView textView=new

【C++】using简写

using TransformStamped = geometry_msgs::msg::TransformStamped;   作用:定义了一个类型别名 TransformStamped,简化了 geometry_msgs::msg::TransformStamped 的书写。目的:提高代码可读性和简洁性。 2. 在 Tf2ListenerModule 中的应用 class Tf2L

Hive 2.3.0 MetaException(message:Version information not found in metastore. )

使用Hive 2.3.0 配置远程模式(Remote)时,执行hive --service metastore命令时出现MetaException(message:Version information not found in metastore. )错误。 解决办法: The necessary tables required for the metastore are missing i

Working with excel files using Pandas

https://www.geeksforgeeks.org/working-with-excel-files-using-pandas/