I am using android odoo-mobile framework and this is how i am inserting a record online with the help of createRecord()
now I want to insert record in manyTomany and oneTomany field in odoo database.I dont know how to insert it online.please help me.
Thanks!
this is how i am inserting/creating a new record online.
protected OdooResult doInBackground(Void... voids)
{
ORecordValues values = new ORecordValues();
values.put("partner_id", Integer.parseInt(resPartnerArrayList.get(idc).get_id()));
String UTCDate = toUTCTime(binding.qOrderDate.getText().toString())
values.put("date_order", UTCDate);
if(!expDate.isEmpty())
{
values.put("validity_date",binding.qExpirationDate.getText().toString());
}
if(!paymentTerms.isEmpty())
{
values.put("payment_term_id", Integer.parseInt
(paymentTermArrayList.get(idP).get_id()));
}
if(!binding.qUntaxedAmount.getText().toString().isEmpty())
{
values.put("amount_untaxed",binding.qUntaxedAmount.getText().toString());
}
if(!binding.qTotal.getText().toString().isEmpty())
{
values.put("amount_total", binding.qTotal.getText().toString());
}
if(!binding.qTaxes.getText().toString().isEmpty())
{
values.put("amount_tax", binding.qTaxes.getText().toString());
}
return odoo.createRecord("sale.order", values);
}