Hi! I'am trying to register a list of IDs as tags in PushWoosh.
The App is created with the Appcelerator Titanium Platform.
The following code works on iOS but not on Android:


var ids_strabschnitt = [];
while (ids_strabschnitt_query.isValidRow()) {
    ids_strabschnitt.push(ids_strabschnitt_query.fieldByName('ID_STRASSE'));
    ids_strabschnitt_query.next();
}
PushWoosh.setTags({
    ids_strabschnitt : JSON.stringify(ids_strabschnitt)
});
It creates the following request:
PushWooshRequest: 
{
  "request": {
    "tags": {
      "ids_strabschnitt": "[\"0900007001-000\",\"0900007002-000\",\"0900000005-000\"]"
    },
    "hwid": "xxxxxxxxxxxxxxxx",
    "application": "XXXXX-XXXXX"
  }
}
But I get the following error:
PushWooshResult: { "status_code": 200, "status_message": "OK", "response": { "skipped": [ { "tag": "ids_strabschnitt", "reason": "Type mismatch" } ], "tags_values": { "Language": "de", "Country": "de", "City": "de, aachen" } } }

If I try directly pass the array to the setTags Method this Exception is thrown:

com.arellomobile.android.push.exception.PushWooshException: java.lang.RuntimeException: wrong type for tag: ids_strabschnitt

How can I correctly implement a list tag in Titanium in Android?
Thank you ver much in advance!

asked 28 Jan '14, 22:09
dThulke's gravatar image

dThulke
112

Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×446
×64
×30
×10
×9

question asked: 28 Jan '14, 22:09

question was seen: 1,067 times

last updated: 28 Jan '14, 22:09