Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
12 replies
Subscribers
7 subscribers
Views
4720 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
General
Hi, Can we format the data which is displayed in gridTextColumn.
deepanc712
over 10 years ago
Hi,
Can we format the data which is displayed in gridTextColumn.
data:index(local!displaydatasubset.data,"emailaddress",{}) .
From the above code I'd like to fetch the user first name and display on the grid column.
Suggestions appreciated.
Thanks....
OriginalPostID-135856
OriginalPostID-135856
Discussion posts and replies are publicly visible
0
radhaa
over 10 years ago
we can format data displayed in grid
Example:
data: apply( rule!getFormattedUserName,{index(local!dataSubset,"userName",{})})
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Vijay
Certified Senior Developer
over 10 years ago
Hi Deepan,
It is possible if the emailaddress belongs to an Appian user,
There is a custom plugin available for getting user object from email address.
By using the user() function we can get an user firstname from that user object.
Here is the link for that custom plugin.
forum.appian.com/.../summary
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
deepanc712
over 10 years ago
Thanks Vijay
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
deepanc712
over 10 years ago
radhaa, The result is returning null on the grid. The Rule input I used is
=concat(user(ri!user,"firstName"),user(ri!user,"lastName"))
ri!user is a type of text..
Thanks,
Deepan
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
radhaa
over 10 years ago
deepanc, expression rule will work if you pass correct user name to that. if you would like to see the result of expression test it out side with test username.
As far as I know, null value is return in these two cases for your specifications
1. if you did null handling (if it is empty input then returning null value).
2. index(local!displaydatasubset.data,"emailaddress",{}) means there is no data , it will give empty arrray to that grid column.
Please check these two and also for debugging print local!datasubset data in any sail component like test,paragraph fields.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
deepanc712
over 10 years ago
radhaa, Thanks for the checkpoints to be verified, I have checked with all the above scenarios, my user name is getting stored as email address and it has got the values in the record. Do you have any guess on null return.
Thanks,
Deepan
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
radhaa
over 10 years ago
could you please attach the code
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
deepanc712
over 10 years ago
Attached is the values
sail code.docx
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
radhaa
over 10 years ago
Embed below code in your section layout, column contents like attached code
a!textField(
label: "Print Grid data",
value: local!displaydatasubset.data
)
and check whether displaydatasubset contains data or not.
Sail Code
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
deepanc712
over 10 years ago
radhaa, Am getting list of grid values in array as output.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
>