I have added a custom field called custom_payment_id in spy_sales_payment table,added the field in transfer file too sales_payment.transfer.xml
and added the column using slaes.schema.xml file
How to set value to this field while placing order
I have added a custom field called custom_payment_id in spy_sales_payment table,added the field in transfer file too sales_payment.transfer.xml
and added the column using slaes.schema.xml file
How to set value to this field while placing order
A concrete answer is hard, because it depends where you get the data from. Spryker is very flexible and there are many ways to solve that.
I guess you're adding the
custom_payment_idduring checkout (i.e. in the payment step) to thePaymentTransferobject inside of theQuoteTransferobject. (It's a good idea to extend the PaymentTransfer object as well).Then
\Spryker\Zed\Payment\Business\Order\SalesPaymentSaver::mapSalesPaymentEntityis a good starting point to extend, which hydrates theSpySalesPaymentobject from thePaymentTransferobject.