Zum Inhalt springen
Menü
Sie müssen registriert sein, um mit der Community zu interagieren.
Diese Frage wurde gekennzeichnet
5032 Ansichten
I was set some breakpoints in odoo ir.attachment and found most of the time consuming was before the "create" method.
This is the Android code:
HashMap map = new HashMap();
map.put("res_model", res_model);
map.put("res_name", res_name);
map.put("type", "binary");
map.put("res_field","image");
map.put("res_id", res_id);
map.put("name", "image");
map.put("datas", image2Base64(imagePath));
try {
    models.execute("execute_kw", asList(
        db, uid, password,
        "ir.attachment", "create",
        asList(map)
    ));
} catch (XmlRpcException e) {
    e.printStackTrace();
}
Avatar
Verwerfen
Verknüpfte Beiträge Antworten Ansichten Aktivität
3
Jan. 19
7812
1
März 17
4624
0
Nov. 15
3352
1
Okt. 24
1866
1
Apr. 24
1941