{ "id": "175918", "key": "ALOY-1748", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "11113", "key": "ALOY", "name": "Alloy", "projectCategory": { "id": "10400", "description": "Tools for developing applications", "name": "Tooling" } }, "fixVersions": [], "resolution": null, "resolutiondate": null, "created": "2020-12-17T21:05:42.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [ "9.3.0.GA", "Android", "CLI8.1.1", "Widget", "exports", "iOS" ], "versions": [], "issuelinks": [ { "id": "59292", "type": { "id": "10122", "name": "Gantt: start-finish", "inward": "is triggered by", "outward": "is triggering" }, "inwardIssue": { "id": "145396", "key": "ALOY-1256", "fields": { "summary": "Widget/Require as top-level element uses controller as view", "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": "None", "id": "6" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "59290", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "175805", "key": "ALOY-1743", "fields": { "summary": "Runtime error when Widget contains another Widget at the top level", "status": { "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.", "name": "Resolved", "id": "5", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "None", "id": "6" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "59291", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "175488", "key": "ALOY-1738", "fields": { "summary": "CLI 8.1.0: crash when to listening backbone.events on required controller in ScrollableView", "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": "Critical", "id": "1" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "amukherjee", "key": "amukherjee", "displayName": "Abir Mukherjee", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2021-06-16T15:07:46.000+0000", "status": { "description": "The issue is open and ready for the assignee to start work on it.", "name": "Open", "id": "1", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "components": [], "description": "Hello. Good afternoon.\r\n\r\nBasically adding a *widget* to any section, and trying to execute a *functionality* which it was *exported* from the section where it was added the widget; some of the exported functionalities are *not working* with the *CLI 8.1.1*, but if you try to use a lower version it is working pretty good, so that's mean that it is a regression. More details, please try to use the project attached.\r\n\r\n* XML\r\n{code:java}\r\n\r\n \r\n\r\n{code}\r\n\r\n* JS\r\n{code:java}\r\n$.win.open();\r\n$.win.showAlert();\r\n{code}\r\n\r\nThis part about $.win.showAlert(); it is working with CLI 8.0.0, but not with CLI 8.1.1.\r\n\r\n* WIDGET XML\r\n{code:java}\r\n\r\n \r\n\r\n{code}\r\n\r\n* WIDGET JS\r\n{code:java}\r\nvar args = arguments[0] || {};\r\n\r\nexports.open = function () {\r\n\t$.win.open();\r\n};\r\n\r\nexports.showAlert = function() {\r\n\talert(\"CLI 8.0.0 WORKING!!!\");\r\n};\r\n{code}\r\n\r\n\r\nPlease let me know whether you have any doubt or question.\r\n\r\nThanks, and best,\r\nAntonio Duran.", "attachment": [ { "id": "67755", "filename": "8.0.0-Working.png", "author": { "name": "antonioduran", "key": "antonioduran", "displayName": "Francisco Antonio Duran Ramirez", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-12-17T21:05:30.000+0000", "size": 427106, "mimeType": "image/png" }, { "id": "67756", "filename": "8.1.1-NotWorking.png", "author": { "name": "antonioduran", "key": "antonioduran", "displayName": "Francisco Antonio Duran Ramirez", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-12-17T21:05:30.000+0000", "size": 613677, "mimeType": "image/png" }, { "id": "67757", "filename": "eightononenotworkingcliwidget.zip", "author": { "name": "antonioduran", "key": "antonioduran", "displayName": "Francisco Antonio Duran Ramirez", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-12-17T20:59:50.000+0000", "size": 8679352, "mimeType": "application/zip" } ], "flagged": false, "summary": "Widget - Regression - weird behavior - some exporting functions are not working with CLI 8.1.1", "creator": { "name": "antonioduran", "key": "antonioduran", "displayName": "Francisco Antonio Duran Ramirez", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "antonioduran", "key": "antonioduran", "displayName": "Francisco Antonio Duran Ramirez", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Appcelerator : 6.0.0.202005141803\r\nNode version : v10.18.1\r\nCLI : 8.1.1\r\nTitanium SDK : 9.3.0.GA\r\nXcode : 12.2\r\nAlloy version : 1.15.3", "comment": { "comments": [ { "id": "458775", "author": { "name": "john.staunton", "key": "john.staunton", "displayName": "John Staunton", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Exact same issue here - big issues caused due to this bug, seemingly no way to work around it", "updateAuthor": { "name": "john.staunton", "key": "john.staunton", "displayName": "John Staunton", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2021-06-15T12:15:08.000+0000", "updated": "2021-06-15T12:15:08.000+0000" }, { "id": "458776", "author": { "name": "john.staunton", "key": "john.staunton", "displayName": "John Staunton", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Bug also exists in CLI 9.0.1", "updateAuthor": { "name": "john.staunton", "key": "john.staunton", "displayName": "John Staunton", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2021-06-15T12:25:07.000+0000", "updated": "2021-06-15T12:25:07.000+0000" }, { "id": "458786", "author": { "name": "john.staunton", "key": "john.staunton", "displayName": "John Staunton", "active": true, "timeZone": "America/Los_Angeles" }, "body": "A workaround (posted in the TiSlack channel) that seems to work is to change your widget slightly to export the function as:\r\n\r\n $.widget.showAlert = function() {\r\n\r\n}\r\n\r\ninstead of exports.showAlert... where 'widget' is the top-level View or Window of your widget", "updateAuthor": { "name": "john.staunton", "key": "john.staunton", "displayName": "John Staunton", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2021-06-16T14:16:00.000+0000", "updated": "2021-06-16T14:16:00.000+0000" }, { "id": "458787", "author": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "body": "This is caused by a behaviour change we overlooked when implementing the linked ticket, if a widget is the only node in a view it will become the top level node. So $.win then becomes a reference to the window in the Widget rather than the Widget itself.\r\n\r\nAnother way to workaround this is to add an empty tag of some kind to the view, so that the Widget tag isn't the only tag in the view. Off the top of my head, I'm not sure how we can maintain the correct behaviour and support ALOY-1256", "updateAuthor": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "created": "2021-06-16T15:07:46.000+0000", "updated": "2021-06-16T15:07:46.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }