1

gift message this link working fine for me, Now I want to update my Payment Method Name into Gift message field in sales order in admin side area, that Means if I have checkmo payment method , then update this into Gift message field into admin side area.

1

Please do below changes as per your code into the site.

if($payment_method_code == "xyz"){

            $paymentmethodvalue = $order->getPayment()->getCheckNo();

            $giftMessage = Mage::getModel('giftmessage/message'); 
            $giftMessage->setMessage($paymentmethodvalue); 
            $giftObj = $giftMessage->save(); 
            $order->setGiftMessageId($giftObj->getId()); 
            $order->save(); 
    }

Add this code into observer file you will save payment method data into Gift card option in admin,

| improve this answer | |
  • 1
    Thank you @nikul. It's working fine for me. – Anil Mar 30 '19 at 7:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.