Hi Jazib,
This is not the way we calculate OT. WT can take just Amount or Number. Here you are puting Number and a ABAP code calculates the Amount but it's better to read Number in your schema and make calculation by PCR.
Consider sub-schema XAP9, PCR X011. Here systems reads Number and into it or in a separate PCR after that you can make OT calculation.
By the way, I am not sure just put A in OPIND operation(like this OPIND A) in X011 line 80 to see if it works or not.
Regards,
Omid