You need to sign in to do that
Don't have an account?

Cross Object Field Update without relationship
Hi Guys can you please help me out with this Trigger? We are using Managed Package and I am not able to update any Trigger in Managed Package.
We have Order custom object and whenever we update status of Order to Released then Invoice gets generated. We don't have any relationship between Order and Invoice Object. It is happening through the managed package.
I need couple of Order Fields Values copy over to Invoice when the new invoice gets generated.
Order Fields: Cancel Reason and Credit Reason Invoice Fields: Cancel Reason and Credit Reason
So when Invoice gets generated it should copy Order Cancel and Credit Reason over to Invoice Cancel and Credit Reason
Any idea how it can be achieved?
We have Order custom object and whenever we update status of Order to Released then Invoice gets generated. We don't have any relationship between Order and Invoice Object. It is happening through the managed package.
I need couple of Order Fields Values copy over to Invoice when the new invoice gets generated.
Order Fields: Cancel Reason and Credit Reason Invoice Fields: Cancel Reason and Credit Reason
So when Invoice gets generated it should copy Order Cancel and Credit Reason over to Invoice Cancel and Credit Reason
Any idea how it can be achieved?
All Answers
Thanks
Shashikant
So what you could do is to write a trigger on Invoice before insert and based on some criteria find the appropriate order and fetch the fields that you want.
Yes I found a Junction Object and I don't need Trigger for this anymore. It can be done by Process Builder. Thanks for your help.