Switch տեսք Դիտել Ելնելով օգտվողի ID-ին տված InfoPath ձեւ

Մենք զարգացած է InfoPath ձեւ բազմաթիվ դիտարկումներ է աջակցելու նոր Վարձակալություն / on-boarding process. When the company hires a new person, ՏՏ վարչության եւ այլ խմբերը պետք է քայլեր ձեռնարկել (ստեղծել Աշխատավարձային, հնարավորություն են տալիս մուտք դեպի համապատասխան ծրագրեր, Տեղադրեք մի գրասեղան, եւ այլն:). We use on form but a different view of the form for each of those functions.

At this company, most of the people involved in the business process are IT-savvy, so when they access the form, their default view is a "menu" view with buttons that direct them to their specific function. Սակայն, we needed to simplify things for the new hire’s direct manager. This person should not see any of the IT related stuff. Ի դեպ, she should see just one view of the form and not even have an option to see the other views.

Մեր դեպքում,, that direct manager’s account is directly tied to the form courtesy of a contact selector (which I am always wanting to call a "people picker" for some reason).

The steps are as follows:

1. In design mode, go to Tools -> Form Options -> Open and Save.

2. Select "rules".

3. Create a new rule whose action is "switch to view" and whose condition leverages the userName() ֆունկցիա.

Մականուն() returns the "simple" user name without the domain. If I log into SharePoint with credentials "domain\pagalvin", Մականուն() returns "pagalvin".

The contact selector provides three bits of information for a contact. The "AccountID" portion is most useful for this scenario. The only thing that makes this even a little bit of challenge is that the contact selector (in my environment anyway) returns the domain and user ID, as in "domain\pagalvin". This prevents us from doing a straight-forward equality condition since AccountID ("domain\pagalvin") will never equal userName() ("pagalvin").

We can get around this using the "contains" operator: AccountID contains userName().

Մենք կարող ենք վերցնել այն ավելի ու նախընտրական pend է դժվար կոդավորված դոմեյն դիմաց Մականուն() գործառույթ ստանալ մեր հավասարություն ստուգել եւ վերացնել վտանգը կեղծ դրական է պարունակում օպերատորին.

We would have REALLY like to automatically switch view for other users based on their AD security group membership. Օրինակ,, when a member of the "IT Analytics" Խումբը, որին accesses ձեւը, automatically switch to the IT Analytics view. We didn’t have time to implement it, but my first thought is to create a web service that would have a method like "IsMemberOfActiveDirectorySecurityGroup", անցնում այն ​​Մականուն() and return back true or false. Does anyone have any other, ավելի խելացի միտք? Is there any SharePoint function we can leverage from InfoPath to make that determination?

</վերջ>

Արորդիների Tags:

3 thoughts on "Switch տեսք Դիտել Ելնելով օգտվողի ID-ին տված InfoPath ձեւ

  1. Pingback: Infopath Switch View Based On User « Sladescross's Blog

Թողնել Պատասխանել Eng. R'aed Al_Momani Ավելացնել կարծիք Չեղարկել պատասխանել

Ձեր էլ. Փոստի հասցեն չի հրապարակվելու. Պահանջվող դաշտերը նշված են աստղանիշով *