• Welcome to KonaKart Community Forum. Please login or sign up.
 

Inserting new Order object in konakartadmin FAILS

Started by iseekk, July 02, 2013, 11:15:54 am

Previous topic - Next topic

iseekk

Hi all,

I am generating new Order (AdminOrder) object in konakartadmin side and then trying to insert it in db with
(AdminOrderMgrIf) orderMgr.insertOrder(AdminOrder orderObj)

Now this new orderObj contains all the info that such an object could possibly need, but this insertion results in an exception:
"Exception Message = The String parameter called paymentModule (value=null) must be given a value. It cannot be set to null or be left empty."

This is a bit strange as AdminOrder does have such setters as setPaymentModuleCode(..), setPaymentModuleSubCode(..), setPaymentMethod(..), which all now have values, but it does NOT have setPaymentModule(..) separately.

Have any of you tried and succeeded inserting new Order object in konakartadmin side? Is this possibly a BUG? Or should I know of some specific way of setting payment module as the exception suggests? Any help would be appreciated..

BR,
iseekk

ming

That insertOrder API needs a fully populated order....  see  http://www.konakart.com/javadoc/admin/com/konakartadmin/appif/KKAdminIf.html#insertOrder(java.lang.String, com.konakartadmin.app.AdminOrder)

It's really only designed for imports of orders from other systems.  Normally you would add orders using the storefront APIs (KKEngIf).


Are you sure you have set values in?:

PaymentModuleCode
ShippingModuleCode

Both need to have values.

iseekk

Hello and thank you!

It seems that missing ShippingModuleCode was indeed the problem. The error message was a bit misleading in this case; PaymentModule info was all there while the error indicated otherwise...