You have two options. First One is writing an enhancement and the other one is writing a z program to update these two fields (may be you can create a background job to run the z program)
Earlier we had a similar requirement to fill the reference field for the Excise invoice posted through J1IV. We had written a small program to update the field.