I have to make some modifications in the save function of revenue line items module. What is the best way to achieve that on OnDemand Version.
Depends. Do want to add some extra validation?
Please look into 'adding field validation to record view'
If you need to set a field value on the same record when the record is saved based on some logic you can use use Logic hooks or SugarBPM / Workflow (depends on the type of sugar you have) or even dependencies . So can you tell us a bit more on what you want to achieve?
I have made the revenue line item unit price editable using dependency metadata. Now when the save is called , it calls a function to get unit price from product catalog and hence overwrite my inputted value again from product catalog.
I know that function which is doing so in save method. So i wanted to remove that line of code . It is happening only when we create a record, not on edit.
Can u tell me how can i remove that line of code from save function
One 'dirty' way of doing it would be to introduce a new field that replaced the unit price field. Give it the same label and type as the current one. Let the user fill in this field and in a after save logic hook set the value of the real unit price field to the value of that new field. It's not the nicest option but it should work, Another way is to overwrite the revenue line item class using the data framework as explained here for the leads module. The only thing you should need to overwrite is the specific method that does the inheritance of the unit price from the catalogue.