cancel
Showing results for 
Search instead for 
Did you mean: 

HOW TO MAKE FIELD PTK10-LOC_FROM and PTK10-LOC_TO MANDATORY

Former Member
0 Kudos

Hi all,

We need to make the starting and ending location of trip segment mandatory. However, when I go to FIVFELD and FITVFELD_WEB, the option to make it a required field is greyed out. Is there a way to make this mandatory without any code changes? I read somewhere that there's a way to do this using table T706Z1but my question is, do I add an entry to this table for these two fields for EVERY schema? Also, if this is what I have to do, what entry should I add for the following?

MANDT Client

MOREI Trip Provision Variant

PROG Program Name

SCHEM Trip Schema

TRIPF Feature (TRVFD)

DYNNR Screen

FNAME Field name

RDYNNR Dependent screen no. for fiel

AUSWL Field attribute

DEFLT Default value

FTXT Alternative Field Text

I know the trip provision variant, schema and field name. I'm not sure of the other fields what value I should put.

Any input would be greatly appreciated.

Thank you!

Accepted Solutions (0)

Answers (1)

Answers (1)

0 Kudos

Hi Jinny

You are quite right, The fields PTK10-LOC_FROM and PTK10-LOC_TO cannot be customize as "Mandatory field" in FITVFELD. This is not possible in standard.

As an Alternative solution, if you want to make this field as mandatory you can indeed modify the table T706Z1 in SE16.

But this is not a standard solution but rather a modification:

You have to maintain the following entry:

MOREI XX

PROG SAPMP56T

SCHEM XX

TRIPF

DYNNR 1801

FNAME PTK10-LOC_FROM

RDYNNR TRIP

AUSWL +

DEFLT

FTXT

***

MOREI XX

PROG SAPMP56T

SCHEM XX

TRIPF

DYNNR 1801

FNAME PTK10-LOC_TO

RDYNNR TRIP

AUSWL +

DEFLT

FTXT

Note also that if this relates to specific requirement for Norway, you should look at this note

1582951 as the coding was changed due to legal requirement...

Sally

***

MOREI XX

Former Member
0 Kudos

Hi Sally,

I tried this, howver, because the "Trip Segments" section has multiple lines to begin with, as soon as they get into this section, the field 'Start Location' and 'End Location' become mandatory, and because there are multiple lines to input trip segments, even if only one line is required, it won't let the user exit this part of the screen until all the lines are filled in.

Is there a BADI that we could leverage to put some code to control this requirement only if there is something in the kilometers field? Also we would have to implement this both in the Portal and R/3.

Thanks!

Jinny

0 Kudos

Hello,

The requested function is already a legal requirement for Travel country version norway: Please check note 1582951 and the correction instruction.

If your support package level includes already the corrections/correction instructions of the note

you can modify the coding line:

CHECK WA_HEAD-MOLGA = '20'. (in Include MP56TI80)

and

IF PWA_KMVER-KMGES GT 0 AND PWA_HEAD-MOLGA = '20'. (in Include LPTRA_UTIL_MILEAGEF01/for the web travel solution)

and change the molga from '20' (norway) to your molga. Than it should work similar for your country version - a linewise check if start_loc and end_loc is filled.

A Badi or User-Exit doens't exist therfore.

Best regards

Klaus