Home > Forum > Actions > How from 1 item list take data to populate another Item list ?

How from 1 item list take data to populate another Item list ?
0

I have got:

1. proces with Item list where:
a) I set person (from AD)
b) in item list in that proces I add competitions
final I have got step finish
- Person
- Item list what he/she can do.
From that I created data sorce with columns, so i have multi rows:
Person 1 = can do 1
Person 1 = can do 2
Person 2 = can do 1
Person 3 = can do 2

2. In other proces I have got attribute:
a) Item list A [pick person]
So I create List
Person 1
Person 3

b) Item list B [sorce proces 1 ]
I would like to populate Item List B with only:
Person 1 and Person 3 - who I pick in Item List A

I webcon I don't know how:
- for each row in Item List A check if column Person = Person in data sorce - copy all to Item List B and repeat
- if i Could initialize it .. could be grate .. if not .. I can add this to step / path ect. / menu button

At the moment if I have Dropdown list and One Person then I can do Filter to Itemlist B ...
If in Drop down list I have got 2 or more people then filter is not working because is more than One ...
so ...
I dropped that Idea because Item list is more readable than dropdown list ...

And now I stopped on depending Item Lists ... :/

MVP

Hi,
I haven't encountered this situation before. However, I can offer you a few ideas. I hope they help.
I think you should make use of the settings in the item list, specifically the 'Initialize'
In the main item list when adding/modifying a column, you should put in 'Style and behavior' a foreach, and if the condition is okay, to execute the form rule 'initialize itemlist'.
I found this post; maybe you can get an idea starting from this one.
https://community.webcon.com/posts/post/javascript-functions-in-the-html-form-fields-part-2/167/23
You can create a javascript form rule that it add a rows in itemlist.
I hope some of these ideas will be helpful to you.



Thanks,
Raluca

In reply to: Raluca-Mirabela Lupu

Hi,
I haven't encountered this situation before. However, I can offer you a few ideas. I hope they help.
I think you should make use of the settings in the item list, specifically the 'Initialize'
In the main item list when adding/modifying a column, you should put in 'Style and behavior' a foreach, and if the condition is okay, to execute the form rule 'initialize itemlist'.
I found this post; maybe you can get an idea starting from this one.
https://community.webcon.com/posts/post/javascript-functions-in-the-html-form-fields-part-2/167/23
You can create a javascript form rule that it add a rows in itemlist.
I hope some of these ideas will be helpful to you.



Thanks,
Raluca

Thx, I will check ...
in meanwhile I try different angle ...

BTW: I don't know JS or SQL but I try ...

I was play with SQL request (from Data source created which I use in Item list ..) and more less I have in second Item List filtered to

[code]
SELECT
WFD_ID,
WFD_Signature,
DEF_ID,
dbo.ClearWFElemAdv(ISNULL(WFD_AttChoose1, '''')) as WFD_AttChoose1,

DET_ID,
dbo.ClearWFElemAdv(ISNULL(DET_Att2, '''')) as DET_Att2,
ISNULL(DET_Att3, '''') as DET_Att3

FROM V_WFElements as wfelems
LEFT JOIN WFElementDetails on (DET_WFDID=WFD_ID and DET_WFCONID=2719)

WHERE WFD_ID IN (
SELECT WFD_ID FROM WFElements
JOIN WFDocTypes ON WFD_DTYPEID = DTYPE_ID
JOIN WFSteps ON WFD_STPID = STP_ID
where WFD_DTYPEID in (110) and WFD_STPID in (406) /*ADVANCEDINNERSEARCH*/ AND (1=1 )
)
[/code]

this gives me
table with out filtration ... (yet) now I need to compare item list 1 to results ...