{ "id": "174519", "key": "TIMOB-27805", "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": "11", "description": "Is not a bug in our product", "name": "Not Our Bug" }, "resolutiondate": "2020-03-16T18:43:17.000+0000", "created": "2019-12-06T22:24:19.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [], "versions": [], "issuelinks": [], "assignee": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2020-03-16T18:43:22.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": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "When requesting access to the user's photo gallery on iOS, the app should not allow the gallery to display if permission has not been granted.\r\n\r\nSimple test:\r\nindex.js\r\n\r\n\r\n{code:java}\r\nTitanium.Media.openPhotoGallery({\r\n\t\t\t\t\tsuccess: function (event) {\r\n\t\t\t\t\t\t// alert( 'libraryHandler success: ' + JSON.stringify( event, null, 2 ) );\r\n\t\t\t\t\t\t_params.event = event;\r\n\t\t\t\t\t\tprocessImage(_params, false);\r\n\t\t\t\t\t},\r\n\t\t\t\t\terror: function (event) {\r\n\t\t\t\t\t\talert('libraryHandler error: ' + JSON.stringify(event, null, 2));\r\n\t\t\t\t\t\tTitanium.API.info('Sending file error');\r\n\t\t\t\t\t\tTitanium.API.info(event);\r\n\t\t\t\t\t},\r\n\t\t\t\t\tmediaTypes: [Ti.Media.MEDIA_TYPE_PHOTO],\r\n\t\t\t\t\tallowEditing: true\r\n\t\t\t\t});\r\n{code}\r\n\r\nThe photo gallery will display and you can select a photo and get a successful result.\r\n", "attachment": [], "flagged": false, "summary": "Open Photo Gallery not requiring permissions", "creator": { "name": "raybelisle", "key": "raybelisle", "displayName": "Ray Belisle", "active": true, "timeZone": "America/Edmonton" }, "subtasks": [], "reporter": { "name": "raybelisle", "key": "raybelisle", "displayName": "Ray Belisle", "active": true, "timeZone": "America/Edmonton" }, "environment": "Appc Ti SDK 8.0+", "closedSprints": [ { "id": 1182, "state": "closed", "name": "2020 Sprint 6", "startDate": "2020-03-16T21:38:00.000Z", "endDate": "2020-03-27T21:38:00.000Z", "completeDate": "2020-03-27T16:02:02.830Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "453173", "author": { "name": "fhaque", "key": "fhaque", "displayName": "Fazlul Haque", "active": false, "timeZone": "America/Los_Angeles" }, "body": "Hello [~raybelisle],\r\n\r\nThanks for reporting this issue. Can you please share us the steps to reproduce the issue? Did you check the issue on your physical device? Also, please try to check this issue on latest SDK 8.3.0.GA and add the following permission code on tiapp.xml file under section.\r\n{code}\r\nNSPhotoLibraryUsageDescription\r\nTo allow you to upload photos of documents\r\nNSPhotoLibraryAddUsageDescription\r\nTo allow you to upload photos of documents\r\n{code}\r\n\r\nThanks", "updateAuthor": { "name": "fhaque", "key": "fhaque", "displayName": "Fazlul Haque", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2019-12-12T19:33:20.000+0000", "updated": "2019-12-12T19:33:20.000+0000" }, { "id": "454714", "author": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "body": "As per [Apple doc|https://developer.apple.com/documentation/photokit/requesting_authorization_to_access_photos?language=objc] -\r\n\"When using the UIImagePickerController to bring up the user's photo library, your app doesn't need to request permission explicitly.\"\r\n\r\nIn titanium, UIImagePickerController is used to access user's photo gallery.\r\n\r\nI tested this on different iOS versions in native iOS app and behavior is as below - \r\nIn iOS 10.x, it is mandatory to use the mentioned key otherwise it will crash.\r\nIn iOS 11.0+, it is not mandatory to use.\r\n\r\nSo mentioned issue is not an issue in titanium. It is similar behavior to native.\r\n\r\nIf it is required to check for user's permission please use [requestPhotoGalaryPermissions|https://docs.appcelerator.com/platform/latest/#!/api/Titanium.Media-method-requestPhotoGalleryPermissions]", "updateAuthor": { "name": "vijaysingh", "key": "vijaysingh", "displayName": "Vijay Singh", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2020-03-16T18:30:25.000+0000", "updated": "2020-03-16T18:30:25.000+0000" } ], "maxResults": 6, "total": 6, "startAt": 0 } } }