Question
BITSINGLASS
IN
Last activity: 4 Oct 2018 11:08 EDT
grid operation need to be triggered based on condition
i have a requirement like when user clicks on add item or delete item button i need to do check some condition and then only that action should be happened. can any one help me out on this ??
**Moderation Team has archived post**
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Accepted Solution
BITSINGLASS
IN
We used custom script to achieve this functionality.
Thank you all for responding to my question.
Pegasystems Inc.
IN
Can you describe your business scenario in detail, what kind of conditional checks do you need to perform.
As per initial understanding, i would suggest disabling Add/Delete links based on those conditions.
Would be able to provide more inputs once business scenario is clear.
BITSINGLASS
IN
Hi Pankaj,
sorry for the delayed response.
my requirement is ..
when user clicks on delete button i need to show confirm popup(do you really want to delete ?(yes/no)) if user clicks on yes then need delete the item and after that show another popup(deleted successfully) .Here the problem is that i cannot use OOTB delete item and if i remove the primary(current page of list) page then i cannot show the second popup which will be throwing error(no page reference so searching in @baseclass for the rules).
when user clicks on add button : need to validate already added records if validation passed then only record will be added after the focused record.
Updated: 22 Oct 2015 8:11 EDT
Luxoft
UA
Hi,
Delete icon:
On click add "to show local action" (Flow action)
Flow action(section) has 2 layouts:
1) Ok/Cancel Buttons
2) Message about success action
Each Layout has appropriate visible conditions.
"Ok" button -- to add delete activity on the action,
"Cancel" -- to close pop up.
Add icon:
The similar approach with validation activity on icon.
Thanks,
Artem
BITSINGLASS
IN
Hi Artem,
Thanks for the response.
when i refresh section after clicking on the yes button(on click i am deleting(page-remove) current page and refreshing current section ) it is throwing error.this might be becoz the primary page is removed.
for add functionality i can write an activity to do validation and append a page after the last item but i cannot add item after the focused row(which is the requirement).
Pegasystems Inc.
IN
Hi,
Based on information you provided to add, if you want to add new row not at end of list but after focussed row you can use pyRowSelected.
Use of pyRowSelected Selectable ListView Property to store true/false based upon listview row selection.
The row selected has pyRowSelected flag as true and other rows as false, based on this you can add new row after the selected row and not after last row in grid.
In activity use <INSERT> instead of <APPEND>.
<INSERT > index Use the <INSERT> keyword followed by an integer to insert a new element and its value into a Value List or Page List property at a numeric index position. Any elements with the same or higher index value are "pushed down" by one. This keyword can only be used in target property references, not expressions.
Please share your comments and thoughts,
Aditya
Accepted Solution
BITSINGLASS
IN
We used custom script to achieve this functionality.
Thank you all for responding to my question.