{ "id": "125611", "key": "TIMOB-16781", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [], "resolution": { "id": "3", "description": "The problem is a duplicate of an existing issue.", "name": "Duplicate" }, "resolutiondate": "2014-04-01T00:37:31.000+0000", "created": "2014-01-30T00:05:47.000+0000", "priority": null, "labels": [ "Blackberry", "WebView", "evalJs" ], "versions": [], "issuelinks": [ { "id": "36334", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "outwardIssue": { "id": "127906", "key": "TIMOB-16650", "fields": { "summary": "BlackBerry: Calling webview.evalJS works, but does NOT return a value", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "Low", "id": "4" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "mrahman", "key": "mrahman", "displayName": "Mostafizur Rahman", "active": true, "timeZone": "Asia/Dhaka" }, "updated": "2014-04-01T00:37:31.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10230", "name": "BlackBerry", "description": "BlackBerry Platform" } ], "description": "h6.Issue\r\nEvalJS does not return data to the app:\r\n\r\nh6.Test case\r\nUsing a simple Alloy app:\r\nindex.xml\r\n{code:xml}\r\n\r\n\t\r\n\t\r\n\t\r\n\r\n{code}\r\n\r\nController: index.js\r\n\r\n{code:javascript}\r\nfunction checkState(e) {\r\n\tvar webTitle = $.webContent.evalJS('document.title');\r\n\t$.webContent.evalJS(\"alert(document.title)\");\r\n\talert(webTitle);\r\n}\r\n$.webContent.addEventListener('load', checkState);\r\n$.index.open();\r\n{code}\r\n\r\nOne alert works (As its triggered from within the webview), the second fails as it does not pass back to the controller.", "attachment": [ { "id": "46919", "filename": "TC-3675-BlackBerry_FirstAlert.png", "author": { "name": "egomez", "key": "egomez", "displayName": "Eduardo Gomez", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2014-03-28T03:28:37.000+0000", "size": 81777, "mimeType": "image/png" }, { "id": "46920", "filename": "TC-3675-BlackBerry_SecondAlert.png", "author": { "name": "egomez", "key": "egomez", "displayName": "Eduardo Gomez", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2014-03-28T03:28:37.000+0000", "size": 71677, "mimeType": "image/png" }, { "id": "46917", "filename": "TC-3675-iOS_FirstAlert.png", "author": { "name": "egomez", "key": "egomez", "displayName": "Eduardo Gomez", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2014-03-28T03:28:37.000+0000", "size": 49600, "mimeType": "image/png" }, { "id": "46918", "filename": "TC-3675-iOS_SecondAlert.png", "author": { "name": "egomez", "key": "egomez", "displayName": "Eduardo Gomez", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2014-03-28T03:28:37.000+0000", "size": 54715, "mimeType": "image/png" } ], "flagged": false, "summary": "BlackBerry: TiUIWebview does not return evalJS data", "creator": { "name": "stereoket", "key": "stereoket", "displayName": "Ketan Majmudar", "active": true, "timeZone": "Europe/London" }, "subtasks": [], "reporter": { "name": "stereoket", "key": "stereoket", "displayName": "Ketan Majmudar", "active": true, "timeZone": "Europe/London" }, "environment": "Titanium SDK Version: 3.2.0.GA\r\nHost OS: Mac OS X\r\nOS Version: 10.8.5\r\nAppcelerator Studio Version: 3.2.0.201312191455\r\nBlackberry VM - 10_2_1.1925", "comment": { "comments": [], "maxResults": 0, "total": 0, "startAt": 0 } } }