xtk:form: use linkList without having a link in a schema?

Avatar

Avatar
Validate 10
Level 2
yetanother_andrey
Level 2

Likes

18 likes

Total Posts

31 posts

Correct reply

1 solution
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile

Avatar
Validate 10
Level 2
yetanother_andrey
Level 2

Likes

18 likes

Total Posts

31 posts

Correct reply

1 solution
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile
yetanother_andrey
Level 2

06-08-2019

I have a schema of an Object, let's call it cus:object. User can create an Object instance or modify existing one selected in folder using the Form cus:object.

There is also another schema - cus:provider - where the data of Providers (external systems) are stored.

Object and Provider has no logical links - they are not using each other in real world.

So cus:object and cus:provider don't have a link (<element type="link"... />) to each other also.

Provider is a piece of information obtained from a CSV file importing to AC on a daily basis - so if it was existing yesterday it might be deleted today and vice versa.

What I need right now is a button on the Object's form which will call the SOAP method and pass an array of Providers that user have selected. There is no need to store the combination of "Object-Provider" after.

I'm wondering if I can define something like a temporary schema inside cus:object form just to use linkList input, or, what might be better, - if I could create something like a subform using cus:provider as a schema and returning the selection to parent form as a /temp/selection xpath?

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Validate 1
Level 4
DimaKudryavtsev
Level 4

Likes

43 likes

Total Posts

44 posts

Correct reply

10 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 25
Boost 10
View profile

Avatar
Validate 1
Level 4
DimaKudryavtsev
Level 4

Likes

43 likes

Total Posts

44 posts

Correct reply

10 solutions
Top badges earned
Validate 1
Boost 5
Boost 3
Boost 25
Boost 10
View profile
DimaKudryavtsev
Level 4

06-08-2019

Do you want to select multiple Providers per Object or only one?

You can specify a schema for your input component and have forms that are not technically linked with anything. This is an example from nms:delivery:

          <input img="nms:deliveryOutline.png" label="Select a delivery outline..."

                 nolabel="true" prebuildSubForm="false" type="subFormLink" xpath="deliveryOutline">

            <form label="Select a delivery outline" nothingToSave="true">

              <input img="nms:deliveryOutline.png" monoSelection="true" schema="nms:deliveryOutline"

                     toolbarCaption="List of delivery outlines" type="linkListChoice"

                     xpath="." xpathOut="/ignored/deliveryOutlineList">

                <input xpath="[.]"/>

                <sysFilter>

                  <condition expr="[@operation-id]=$(../@operation-id)"/>

                  <condition>

                    <condition boolOperator="OR" expr="@messageType=$(../@messageType)"/>

                    <condition expr="@messageType=127"/>

                  </condition>

                </sysFilter>

              </input>

              <leave>

                <set expr="[/ignored/deliveryOutlineList/deliveryOutline/@id]" xpath="@id"/>

                <set expr="[/ignored/deliveryOutlineList/deliveryOutline/@_cs]" xpath="@_cs"/>

                <set expr="[/ignored/deliveryOutlineList/deliveryOutline/@id]" xpath="../@deliveryOutline-id"/>

              </leave>

            </form>

          </input>

        </container>

is this what you searching?

Answers (1)

Answers (1)

Avatar

Avatar
Validate 10
Level 2
yetanother_andrey
Level 2

Likes

18 likes

Total Posts

31 posts

Correct reply

1 solution
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile

Avatar
Validate 10
Level 2
yetanother_andrey
Level 2

Likes

18 likes

Total Posts

31 posts

Correct reply

1 solution
Top badges earned
Validate 10
Validate 1
Boost 5
Boost 3
Boost 10
View profile
yetanother_andrey
Level 2

06-08-2019

Looks like what I need, thanks!