{ "id": "137670", "key": "AC-1208", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "12217", "key": "AC", "name": "Appcelerator - INBOX", "projectCategory": { "id": "10000", "description": "", "name": "Customer Service" } }, "resolution": { "id": "7", "description": "", "name": "Invalid" }, "resolutiondate": "2015-02-11T22:15:56.000+0000", "created": "2014-10-06T10:11:25.000+0000", "labels": [ "TCSupportTriage", "defect" ], "versions": [], "issuelinks": [], "assignee": { "name": "mpmiranda", "key": "mpmiranda", "displayName": "Mauro Parra-Miranda", "active": true, "timeZone": "America/Mexico_City" }, "updated": "2016-03-08T07:37:35.000+0000", "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" } }, "components": [ { "id": "14544", "name": "Alloy", "description": "Please enter tickets related to the Alloy here." } ], "description": "Alloy compiler is complaining when Models are named like Book.js.\r\n\r\nSee this feature-related test case [https://github.com/feons/alloy/tree/ALOY-443/test/apps/testing/ALOY-443]\r\n\r\nh2. Error\r\n[ERROR] : Attempt to reference the deep object reference : \"Book.title\".\r\n[ERROR] : Instead, please map the object property to an attribute of the model.\r\n[ERROR] : Alloy compiler failed\r\n\r\nh2. Test Case\r\n{code:title=view.xml}\r\n\r\n\t\r\n\t\t\r\n \r\n \t\r\n\t\r\n\r\n{code}\r\n\r\n{code:title=Book.js}\r\nexports.definition = {\r\n\tconfig : {\r\n\t\tcolumns : {\r\n\t\t\t\"title\" : \"string\",\r\n\t\t\t\"author\" : \"string\"\r\n\t\t},\r\n\t\tadapter : {\r\n\t\t\ttype : \"sql\",\r\n\t\t\tcollection_name : \"Book\"\r\n\t\t}\r\n\t},\r\n\textendModel : function(Model) {\r\n\t\t_.extend(Model.prototype, {\r\n\t\t\t// extended functions and properties go here\r\n\t\t});\r\n\t\treturn Model;\r\n\t},\r\n\textendCollection : function(Collection) {\r\n\t\t_.extend(Collection.prototype, {\r\n\t\t\t// extended functions and properties go here\r\n\t\t});\r\n\t\treturn Collection;\r\n\t}\r\n}; \r\n{code}\r\n\r\n\r\n\r\n", "attachment": [], "flagged": false, "summary": "Model-View binding does not work if Model name has a captial letter at the beginning", "creator": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "environment": "Alloy 1.5.1\r\nTiSDK 3.3.0", "comment": { "comments": [ { "id": "327010", "author": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I reckon it is supposed to be a very quick fix and expect it in possible 1.5.2 soon :) ", "updateAuthor": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-10-06T10:16:08.000+0000", "updated": "2014-10-06T10:17:05.000+0000" }, { "id": "327011", "author": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Also, I recommend full model-view binding test case could be part of Alloy sample project [https://github.com/appcelerator/alloy]", "updateAuthor": { "name": "jialhe85@gmail.com", "key": "jialhe85@gmail.com", "displayName": "David He", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2014-10-06T10:19:49.000+0000", "updated": "2014-10-06T10:20:14.000+0000" }, { "id": "342983", "author": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "body": "Models must be named with a lowercase letter. The Backbone constructor is named with a lead-capitalized letter and instance of the model are named with the matching, though lowercase-first-letter version of the name.", "updateAuthor": { "name": "skypanther", "key": "skypanther", "displayName": "Tim Poulsen", "active": true, "timeZone": "America/New_York" }, "created": "2015-02-11T22:15:56.000+0000", "updated": "2015-02-11T22:15:56.000+0000" } ], "maxResults": 4, "total": 4, "startAt": 0 } } }