{ "id": "154978", "key": "TIMOB-20421", "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": "2", "description": "The problem described is an issue which will never be fixed.", "name": "Won't Fix" }, "resolutiondate": "2017-06-29T18:51:15.000+0000", "created": "2016-02-17T20:58:18.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "mobileweb", "windows" ], "versions": [ { "id": "17072", "name": "Release 5.1.2", "archived": false, "released": true, "releaseDate": "2016-01-12" }, { "id": "17532", "name": "Release 5.1.1", "archived": false, "released": true, "releaseDate": "2015-11-24" } ], "issuelinks": [ { "id": "50635", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "133744", "key": "AC-836", "fields": { "summary": "Cannot use Ti.Cloud commonjs module with MobileWeb", "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" } }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": { "name": "cbarber", "key": "cbarber", "displayName": "Chris Barber", "active": true, "timeZone": "America/Chicago" }, "updated": "2018-04-04T23:20:20.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": "11500", "name": "MobileWeb", "description": "Mobile Web (HTML) Platform" } ], "description": "h6.Issue Description\r\nCan't get response from ti.cloud module methods running as mobile web preview in browser on windows environment, the same code running from a Mac OS system is working as expected. \r\n\r\nh6. Steps to reproduce\r\n\r\n# Create a new classic default project application on studio with cloud services enabled\r\n# Replace the code inside app.js with the next simple test case: \r\n{code}\r\n// this sets the background color of the master UIView (when there are no windows/tab groups on it)\r\nTitanium.UI.setBackgroundColor('#000');\r\n\r\n// create tab group\r\nvar tabGroup = Titanium.UI.createTabGroup();\r\n\r\n\r\n//\r\n// create base UI tab and root window\r\n//\r\nvar win1 = Titanium.UI.createWindow({ \r\n title:'Tab 1',\r\n backgroundColor:'#fff'\r\n});\r\nvar tab1 = Titanium.UI.createTab({ \r\n icon:'KS_nav_views.png',\r\n title:'Tab 1',\r\n window:win1\r\n});\r\n\r\nvar label1 = Titanium.UI.createLabel({\r\n\tcolor:'#999',\r\n\ttext:'I am Window 1',\r\n\tfont:{fontSize:20,fontFamily:'Helvetica Neue'},\r\n\ttextAlign:'center',\r\n\twidth:'auto'\r\n});\r\n\r\nwin1.add(label1);\r\n\r\n//\r\n// create controls tab and root window\r\n//\r\nvar win2 = Titanium.UI.createWindow({ \r\n title:'Tab 2',\r\n backgroundColor:'#fff'\r\n});\r\nvar tab2 = Titanium.UI.createTab({ \r\n icon:'KS_nav_ui.png',\r\n title:'Tab 2',\r\n window:win2\r\n});\r\n\r\nvar label2 = Titanium.UI.createLabel({\r\n\tcolor:'#999',\r\n\ttext:'I am Window 2',\r\n\tfont:{fontSize:20,fontFamily:'Helvetica Neue'},\r\n\ttextAlign:'center',\r\n\twidth:'auto'\r\n});\r\n\r\nwin2.add(label2);\r\n\r\n\r\n\r\n//\r\n// add tabs\r\n//\r\ntabGroup.addTab(tab1); \r\ntabGroup.addTab(tab2); \r\n\r\n\r\n// open tab group\r\ntabGroup.open();\r\n\r\n\r\n// added during app creation. this will automatically login to\r\n// ACS for your application and then fire an event (see below)\r\n// when connected or errored. if you do not use ACS in your\r\n// application as a client, you should remove this block\r\n(function(){\r\nvar ACS = require('ti.cloud'),\r\n env = Ti.App.deployType.toLowerCase() === 'production' ? 'production' : 'development',\r\n username = Ti.App.Properties.getString('acs-username-'+env),\r\n password = Ti.App.Properties.getString('acs-password-'+env);\r\n\r\n// if not configured, just return\r\nif (!env || !username || !password) { return; }\r\n/**\r\n * Appcelerator Cloud (ACS) Admin User Login Logic\r\n *\r\n * fires login.success with the user as argument on success\r\n * fires login.failed with the result as argument on error\r\n */\r\nACS.Users.login({\r\n\tlogin:username,\r\n\tpassword:password,\r\n}, function(result){\r\n\tif (env==='development') {\r\n\t\tTi.API.info('ACS Login Results for environment `'+env+'`:');\r\n\t\tTi.API.info(result);\r\n\t\talert(JSON.stringify(result));\r\n\t}\r\n\tif (result && result.success && result.users && result.users.length){\r\n\t\tTi.App.fireEvent('login.success',result.users[0],env);\r\n\t} else {\r\n\t\tTi.App.fireEvent('login.failed',result,env);\r\n\t}\r\n});\r\n\r\n})();\r\n{code}\r\n# The alert or Ti info's from the ACS variable are not executed on windows.\r\n", "attachment": [], "flagged": false, "summary": "ti.cloud module methods are not responding on MobileWeb when building from Windows", "creator": { "name": "rramirez", "key": "rramirez", "displayName": " Ricardo Ramirez", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "rramirez", "key": "rramirez", "displayName": " Ricardo Ramirez", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Windows 8.1\r\nti.SDK 5.1.2GA\r\nStudio 4.4\r\nCLI 5.1.0", "comment": { "comments": [ { "id": "377139", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "This is a MobileWeb/Studio issue, not a Windows SDK issue. I'm not sure if the bug is in the MobileWeb SDK (if it is, then that'd be [~cbarber]'s ticket); or in Studio for whatever browser/webserver the IDE is using/starting (then it'd be [~kkolipaka]'s ticket in TISTUD)\r\n\r\n", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2016-02-17T21:29:33.000+0000", "updated": "2016-02-17T21:29:33.000+0000" }, { "id": "377141", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "[~rramirez] It'd be pretty easy to try and narrow this down by trying to run the app from the CLI (outside Studio) and see if the bug persists. If so, then it's likely an issue in MobileWeb or maybe even the ACS cloud module. If it _only_ happens inside Studio, then it's a Studio ticket.", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2016-02-17T21:31:10.000+0000", "updated": "2016-02-17T21:31:10.000+0000" }, { "id": "378499", "author": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "body": "I can reproduce this issue using\r\n\r\nWindows 10 Pro\r\nAppc NPM: 4.2.3\r\nAppc Core: 5.2.0\r\nTi SDK: 5.2.0.GA, 5.1.2.GA\r\nAppcelerator Studio: 4.5.0.201602170821\r\n\r\n\r\nWhen building from both Studio and the CLI on Windows for MobileWeb there are no alerts show, additionally there the following error in the browser console {{Uncaught TypeError: Cannot read property 'login' of undefined}}.\r\n\r\nThe ti.cloud module appears to be copied to the build folder just fine, it is seen in the {{build/mobileweb/modules/ti.cloud}} folder\r\n\r\nThis appears to be a MobileWeb specific issue as the following platforms, built on Windows, work as expected(that is an alert is shown with the login information):\r\n* Android emulator\r\n* Android device\r\n* Windows Phone emulator\r\n* Windows Phone device\r\n* Winstore local", "updateAuthor": { "name": "eharris", "key": "eharris", "displayName": "Ewan Harris", "active": true, "timeZone": "Europe/Dublin" }, "created": "2016-03-02T20:09:28.000+0000", "updated": "2016-03-02T20:09:28.000+0000" }, { "id": "423188", "author": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Resolving as \"Won't Fix\" as MobileWeb has been deprecated.", "updateAuthor": { "name": "lmorris", "key": "lmorris", "displayName": "Lee Morris", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2017-06-29T18:51:15.000+0000", "updated": "2017-06-29T18:51:15.000+0000" }, { "id": "436333", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Closing as will not fix.", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-04-04T23:20:20.000+0000", "updated": "2018-04-04T23:20:20.000+0000" } ], "maxResults": 8, "total": 8, "startAt": 0 } } }