[SOLVED]Placing dynamic fields separatly

Moderator: crythias

Locked
aph
Znuny superhero
Posts: 646
Joined: 20 Jun 2014, 12:11
Znuny Version: 3.3.9, 4.x, 5.x

[SOLVED]Placing dynamic fields separatly

Post by aph »

Hello all,
#is it possible to display dynamic fields on different parts of a page (new email ticket page for example). At the moment I'm able to place dynamic fields only as a block by moving the following code around.

Code: Select all

<!-- dtl:block:DynamicField -->
                    <div class="Row Row_DynamicField_$QData{"Name"}">
                        $Data{"Label"}
                        <div class="Field">
                            $Data{"Field"}
                        </div>
                        <div class="Clear"></div>
                    </div>
<!-- dtl:block:DynamicField -->
Unbenannt_42.PNG
For example, I would like to keep the field 'Produkt' at its current position and move the field 'Asset Number' below the text. How can I achieve it?

Thanks
You do not have the required permissions to view the files attached to this post.
Last edited by aph on 22 Jul 2014, 17:27, edited 1 time in total.
OTRS 3.3.x (private/testing) on Windows Server 2008 with MSSQL database.
OTRS 3.3.x (private/testing) on CentOS with MySQL database and apache
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Placing dynamic fields separatly

Post by crythias »

"Is it possible" ...probably. Practically speaking, anything in code is possible.
aph wrote: to display dynamic fields on different parts of a page
sure.

You're able to place code and asking if it's possible to place code...
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Placing dynamic fields separatly

Post by crythias »

Note that DynamicFields have "order" as an attribute.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
aph
Znuny superhero
Posts: 646
Joined: 20 Jun 2014, 12:11
Znuny Version: 3.3.9, 4.x, 5.x

Re: Placing dynamic fields separatly

Post by aph »

Probably I did not express myself clearly enough. At the moment I can move dynamic fields around only as a group, i.e. when I move the following code around, ALL dynamic fields are moved

Code: Select all

<!-- dtl:block:DynamicField -->
                    <div class="Row Row_DynamicField_$QData{"Name"}">
                        $Data{"Label"}
                        <div class="Field">
                            $Data{"Field"}
                        </div>
                        <div class="Clear"></div>
                    </div>
<!-- dtl:block:DynamicField -->
For example, I have two dynamic fields 'Produkt' and 'Asset Number' as can be seen in the following screenshot
Unbenannt_42.PNG
What I want to achieve is to place the dynamic field 'Produkt' under the field 'Customer ID' (i.e. in its current position) and place the field 'Asset Number' below the field 'Text'.
Unbenannt_44.PNG
Is it possible to place the dynamic fields separately as I intend to or can they be placed on the page only in groups?

Thank you.
You do not have the required permissions to view the files attached to this post.
Last edited by aph on 22 Jul 2014, 17:29, edited 1 time in total.
OTRS 3.3.x (private/testing) on Windows Server 2008 with MSSQL database.
OTRS 3.3.x (private/testing) on CentOS with MySQL database and apache
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Placing dynamic fields separatly

Post by crythias »

edit Kernel/Output/HTML/Standard/AgentTicketEmail.dtl

See:

Code: Select all

# example of how to use fixed dynamic field blocks for customizations
# Note: Field1 and Field2 are the names of the fields and had to be replaced with the actual
# field names
#<!-- dtl:block:DynamicField_Field1 -->
#                    <div class="Row Row_DynamicField_$QData{"Name"}">
#                        $Data{"Label"}
#                        <div class="Field">
#                            $Data{"Field"}
#                        </div>
#                        <div class="Clear"></div>
#                    </div>
#<!-- dtl:block:DynamicField_Field1 -->
#<!-- dtl:block:DynamicField_Field2 -->
#                    <div class="Row Row_DynamicField_$QData{"Name"}">
#                        $Data{"Label"}
#                        <div class="Field">
#                            $Data{"Field"}
#                        </div>
#                        <div class="Clear"></div>
#                    </div>
#<!-- dtl:block:DynamicField_Field2 -->
Note that every DynamicField for the page (SysConfig enabled) needs to be explicitly defined for location: Loop or above code.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
aph
Znuny superhero
Posts: 646
Joined: 20 Jun 2014, 12:11
Znuny Version: 3.3.9, 4.x, 5.x

Re: Placing dynamic fields separatly

Post by aph »

Thanks!
OTRS 3.3.x (private/testing) on Windows Server 2008 with MSSQL database.
OTRS 3.3.x (private/testing) on CentOS with MySQL database and apache
Locked