{"action":"created","comment":{"url":"https://api.github.com/repos/OCA/web/pulls/comments/78945092","id":78945092,"diff_hunk":"@@ -0,0 +1,77 @@\n+/*\n+    Copyright 2016 Siddharth Bhalgami <siddharth.bhalgami@techreceptives.com>\n+    License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl).\n+*/\n+odoo.define('web_widget_image_webcam.webcam_widget', function(require) {\n+\"use strict\";\n+\n+    var core = require('web.core');\n+\n+    core.form_widget_registry.get(\"image\").include({\n+\n+        render_value: function () {\n+            this._super();\n+\n+            var self = this,\n+                web_cam = this.$el.find('.oe_form_binary_file_web_cam');\n+\n+            $(web_cam).click(function(){\n+\n+                // ::webcamjs:: < https://github.com/jhuckaby/webcamjs >\n+                // Webcam: Set Custom Parameters\n+                Webcam.set({\n+                    width: 320,\n+                    height: 240,\n+                    dest_width: 320,\n+                    dest_height: 240,\n+                    image_format: 'jpeg',\n+                    jpeg_quality: 90,\n+\n+                    /*\n+                        :: Important Note about Chrome 47+ :: < https://github.com/jhuckaby/webcamjs#important-note-for-chrome-47 >\n+                        Setting \"force_flash\" to \"true\" will always run in Adobe Flash fallback mode on Chrome, but it is not desirable.\n+                    */\n+                    force_flash: false,\n+                    /*\n+                        If \"force_flash\" is true, then this extra parameter \"swfURL\" is necessary.\n+                        Remove comment tag from \"swfURL\" parameter.\n+                    */\n+                    // swfURL: '/web_widget_image_webcam/static/src/js/webcam.swf',\n+                    flip_horiz: true,\n+                    fps: 45,\n+                });\n+\n+                // Init Webcam\n+                Webcam.attach('#live_webcam');\n+\n+                $('#take_snap_btn').click(function(){\n+                    Webcam.snap( function(data) {\n+                        // Display Snap besides Live WebCam Preview\n+                        document.getElementById('webcam_result').innerHTML = '<img src=\"'+data+'\"/>';","path":"web_widget_image_webcam/static/src/js/webcam_widget.js","position":50,"original_position":50,"commit_id":"0d3eb271d7503b3db6f574e9fd3d0b7760a9f0ab","original_commit_id":"0d3eb271d7503b3db6f574e9fd3d0b7760a9f0ab","user":{"login":"Yajo","id":973709,"avatar_url":"https://avatars.githubusercontent.com/u/973709?v=3","gravatar_id":"","url":"https://api.github.com/users/Yajo","html_url":"https://github.com/Yajo","followers_url":"https://api.github.com/users/Yajo/followers","following_url":"https://api.github.com/users/Yajo/following{/other_user}","gists_url":"https://api.github.com/users/Yajo/gists{/gist_id}","starred_url":"https://api.github.com/users/Yajo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Yajo/subscriptions","organizations_url":"https://api.github.com/users/Yajo/orgs","repos_url":"https://api.github.com/users/Yajo/repos","events_url":"https://api.github.com/users/Yajo/events{/privacy}","received_events_url":"https://api.github.com/users/Yajo/received_events","type":"User","site_admin":false},"body":"You're welcome. No need to answer \"done\" to every comment, just push the commit and they will disappear automatically :wink: ","created_at":"2016-09-15T11:46:42Z","updated_at":"2016-09-15T11:46:42Z","html_url":"https://github.com/OCA/web/pull/422#discussion_r78945092","pull_request_url":"https://api.github.com/repos/OCA/web/pulls/422","_links":{"self":{"href":"https://api.github.com/repos/OCA/web/pulls/comments/78945092"},"html":{"href":"https://github.com/OCA/web/pull/422#discussion_r78945092"},"pull_request":{"href":"https://api.github.com/repos/OCA/web/pulls/422"}}},"pull_request":{"url":"https://api.github.com/repos/OCA/web/pulls/422","id":85197438,"html_url":"https://github.com/OCA/web/pull/422","diff_url":"https://github.com/OCA/web/pull/422.diff","patch_url":"https://github.com/OCA/web/pull/422.patch","issue_url":"https://api.github.com/repos/OCA/web/issues/422","number":422,"state":"open","locked":false,"title":"[NEW] web_widget_image_webcam","user":{"login":"bud-e","id":8414798,"avatar_url":"https://avatars.githubusercontent.com/u/8414798?v=3","gravatar_id":"","url":"https://api.github.com/users/bud-e","html_url":"https://github.com/bud-e","followers_url":"https://api.github.com/users/bud-e/followers","following_url":"https://api.github.com/users/bud-e/following{/other_user}","gists_url":"https://api.github.com/users/bud-e/gists{/gist_id}","starred_url":"https://api.github.com/users/bud-e/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bud-e/subscriptions","organizations_url":"https://api.github.com/users/bud-e/orgs","repos_url":"https://api.github.com/users/bud-e/repos","events_url":"https://api.github.com/users/bud-e/events{/privacy}","received_events_url":"https://api.github.com/users/bud-e/received_events","type":"User","site_admin":false},"body":"Module that allows to take image with webcam.\r\n\r\nWorks with any Image(Binary) field in edit mode.","created_at":"2016-09-14T09:49:12Z","updated_at":"2016-09-15T11:46:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e60d25100771979a0346c8ad992fdf1ac96152b1","assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/OCA/web/milestones/4","html_url":"https://github.com/OCA/web/milestones/9.0","labels_url":"https://api.github.com/repos/OCA/web/milestones/4/labels","id":1354421,"number":4,"title":"9.0","description":null,"creator":{"login":"pedrobaeza","id":7165771,"avatar_url":"https://avatars.githubusercontent.com/u/7165771?v=3","gravatar_id":"","url":"https://api.github.com/users/pedrobaeza","html_url":"https://github.com/pedrobaeza","followers_url":"https://api.github.com/users/pedrobaeza/followers","following_url":"https://api.github.com/users/pedrobaeza/following{/other_user}","gists_url":"https://api.github.com/users/pedrobaeza/gists{/gist_id}","starred_url":"https://api.github.com/users/pedrobaeza/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pedrobaeza/subscriptions","organizations_url":"https://api.github.com/users/pedrobaeza/orgs","repos_url":"https://api.github.com/users/pedrobaeza/repos","events_url":"https://api.github.com/users/pedrobaeza/events{/privacy}","received_events_url":"https://api.github.com/users/pedrobaeza/received_events","type":"User","site_admin":false},"open_issues":18,"closed_issues":17,"state":"open","created_at":"2015-10-14T00:57:07Z","updated_at":"2016-09-14T23:52:35Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/OCA/web/pulls/422/commits","review_comments_url":"https://api.github.com/repos/OCA/web/pulls/422/comments","review_comment_url":"https://api.github.com/repos/OCA/web/pulls/comments{/number}","comments_url":"https://api.github.com/repos/OCA/web/issues/422/comments","statuses_url":"https://api.github.com/repos/OCA/web/statuses/0d3eb271d7503b3db6f574e9fd3d0b7760a9f0ab","head":{"label":"bud-e:9.0_web_widget_webcam_image","ref":"9.0_web_widget_webcam_image","sha":"0d3eb271d7503b3db6f574e9fd3d0b7760a9f0ab","user":{"login":"bud-e","id":8414798,"avatar_url":"https://avatars.githubusercontent.com/u/8414798?v=3","gravatar_id":"","url":"https://api.github.com/users/bud-e","html_url":"https://github.com/bud-e","followers_url":"https://api.github.com/users/bud-e/followers","following_url":"https://api.github.com/users/bud-e/following{/other_user}","gists_url":"https://api.github.com/users/bud-e/gists{/gist_id}","starred_url":"https://api.github.com/users/bud-e/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bud-e/subscriptions","organizations_url":"https://api.github.com/users/bud-e/orgs","repos_url":"https://api.github.com/users/bud-e/repos","events_url":"https://api.github.com/users/bud-e/events{/privacy}","received_events_url":"https://api.github.com/users/bud-e/received_events","type":"User","site_admin":false},"repo":{"id":55272037,"name":"web","full_name":"bud-e/web","owner":{"login":"bud-e","id":8414798,"avatar_url":"https://avatars.githubusercontent.com/u/8414798?v=3","gravatar_id":"","url":"https://api.github.com/users/bud-e","html_url":"https://github.com/bud-e","followers_url":"https://api.github.com/users/bud-e/followers","following_url":"https://api.github.com/users/bud-e/following{/other_user}","gists_url":"https://api.github.com/users/bud-e/gists{/gist_id}","starred_url":"https://api.github.com/users/bud-e/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bud-e/subscriptions","organizations_url":"https://api.github.com/users/bud-e/orgs","repos_url":"https://api.github.com/users/bud-e/repos","events_url":"https://api.github.com/users/bud-e/events{/privacy}","received_events_url":"https://api.github.com/users/bud-e/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bud-e/web","description":"Odoo web client UI related addons","fork":true,"url":"https://api.github.com/repos/bud-e/web","forks_url":"https://api.github.com/repos/bud-e/web/forks","keys_url":"https://api.github.com/repos/bud-e/web/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bud-e/web/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bud-e/web/teams","hooks_url":"https://api.github.com/repos/bud-e/web/hooks","issue_events_url":"https://api.github.com/repos/bud-e/web/issues/events{/number}","events_url":"https://api.github.com/repos/bud-e/web/events","assignees_url":"https://api.github.com/repos/bud-e/web/assignees{/user}","branches_url":"https://api.github.com/repos/bud-e/web/branches{/branch}","tags_url":"https://api.github.com/repos/bud-e/web/tags","blobs_url":"https://api.github.com/repos/bud-e/web/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bud-e/web/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bud-e/web/git/refs{/sha}","trees_url":"https://api.github.com/repos/bud-e/web/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bud-e/web/statuses/{sha}","languages_url":"https://api.github.com/repos/bud-e/web/languages","stargazers_url":"https://api.github.com/repos/bud-e/web/stargazers","contributors_url":"https://api.github.com/repos/bud-e/web/contributors","subscribers_url":"https://api.github.com/repos/bud-e/web/subscribers","subscription_url":"https://api.github.com/repos/bud-e/web/subscription","commits_url":"https://api.github.com/repos/bud-e/web/commits{/sha}","git_commits_url":"https://api.github.com/repos/bud-e/web/git/commits{/sha}","comments_url":"https://api.github.com/repos/bud-e/web/comments{/number}","issue_comment_url":"https://api.github.com/repos/bud-e/web/issues/comments{/number}","contents_url":"https://api.github.com/repos/bud-e/web/contents/{+path}","compare_url":"https://api.github.com/repos/bud-e/web/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bud-e/web/merges","archive_url":"https://api.github.com/repos/bud-e/web/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bud-e/web/downloads","issues_url":"https://api.github.com/repos/bud-e/web/issues{/number}","pulls_url":"https://api.github.com/repos/bud-e/web/pulls{/number}","milestones_url":"https://api.github.com/repos/bud-e/web/milestones{/number}","notifications_url":"https://api.github.com/repos/bud-e/web/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bud-e/web/labels{/name}","releases_url":"https://api.github.com/repos/bud-e/web/releases{/id}","deployments_url":"https://api.github.com/repos/bud-e/web/deployments","created_at":"2016-04-02T01:28:21Z","updated_at":"2016-04-02T01:28:24Z","pushed_at":"2016-09-14T12:02:52Z","git_url":"git://github.com/bud-e/web.git","ssh_url":"git@github.com:bud-e/web.git","clone_url":"https://github.com/bud-e/web.git","svn_url":"https://github.com/bud-e/web","homepage":"","size":8583,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"9.0"}},"base":{"label":"OCA:9.0","ref":"9.0","sha":"531f1195d8545d58f191d0a7de9a9c1c533a29ac","user":{"login":"OCA","id":7600578,"avatar_url":"https://avatars.githubusercontent.com/u/7600578?v=3","gravatar_id":"","url":"https://api.github.com/users/OCA","html_url":"https://github.com/OCA","followers_url":"https://api.github.com/users/OCA/followers","following_url":"https://api.github.com/users/OCA/following{/other_user}","gists_url":"https://api.github.com/users/OCA/gists{/gist_id}","starred_url":"https://api.github.com/users/OCA/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OCA/subscriptions","organizations_url":"https://api.github.com/users/OCA/orgs","repos_url":"https://api.github.com/users/OCA/repos","events_url":"https://api.github.com/users/OCA/events{/privacy}","received_events_url":"https://api.github.com/users/OCA/received_events","type":"Organization","site_admin":false},"repo":{"id":20895915,"name":"web","full_name":"OCA/web","owner":{"login":"OCA","id":7600578,"avatar_url":"https://avatars.githubusercontent.com/u/7600578?v=3","gravatar_id":"","url":"https://api.github.com/users/OCA","html_url":"https://github.com/OCA","followers_url":"https://api.github.com/users/OCA/followers","following_url":"https://api.github.com/users/OCA/following{/other_user}","gists_url":"https://api.github.com/users/OCA/gists{/gist_id}","starred_url":"https://api.github.com/users/OCA/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OCA/subscriptions","organizations_url":"https://api.github.com/users/OCA/orgs","repos_url":"https://api.github.com/users/OCA/repos","events_url":"https://api.github.com/users/OCA/events{/privacy}","received_events_url":"https://api.github.com/users/OCA/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OCA/web","description":"Odoo web client UI related addons","fork":false,"url":"https://api.github.com/repos/OCA/web","forks_url":"https://api.github.com/repos/OCA/web/forks","keys_url":"https://api.github.com/repos/OCA/web/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OCA/web/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OCA/web/teams","hooks_url":"https://api.github.com/repos/OCA/web/hooks","issue_events_url":"https://api.github.com/repos/OCA/web/issues/events{/number}","events_url":"https://api.github.com/repos/OCA/web/events","assignees_url":"https://api.github.com/repos/OCA/web/assignees{/user}","branches_url":"https://api.github.com/repos/OCA/web/branches{/branch}","tags_url":"https://api.github.com/repos/OCA/web/tags","blobs_url":"https://api.github.com/repos/OCA/web/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OCA/web/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OCA/web/git/refs{/sha}","trees_url":"https://api.github.com/repos/OCA/web/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OCA/web/statuses/{sha}","languages_url":"https://api.github.com/repos/OCA/web/languages","stargazers_url":"https://api.github.com/repos/OCA/web/stargazers","contributors_url":"https://api.github.com/repos/OCA/web/contributors","subscribers_url":"https://api.github.com/repos/OCA/web/subscribers","subscription_url":"https://api.github.com/repos/OCA/web/subscription","commits_url":"https://api.github.com/repos/OCA/web/commits{/sha}","git_commits_url":"https://api.github.com/repos/OCA/web/git/commits{/sha}","comments_url":"https://api.github.com/repos/OCA/web/comments{/number}","issue_comment_url":"https://api.github.com/repos/OCA/web/issues/comments{/number}","contents_url":"https://api.github.com/repos/OCA/web/contents/{+path}","compare_url":"https://api.github.com/repos/OCA/web/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OCA/web/merges","archive_url":"https://api.github.com/repos/OCA/web/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OCA/web/downloads","issues_url":"https://api.github.com/repos/OCA/web/issues{/number}","pulls_url":"https://api.github.com/repos/OCA/web/pulls{/number}","milestones_url":"https://api.github.com/repos/OCA/web/milestones{/number}","notifications_url":"https://api.github.com/repos/OCA/web/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OCA/web/labels{/name}","releases_url":"https://api.github.com/repos/OCA/web/releases{/id}","deployments_url":"https://api.github.com/repos/OCA/web/deployments","created_at":"2014-06-16T18:34:12Z","updated_at":"2016-09-02T11:12:18Z","pushed_at":"2016-09-15T09:55:36Z","git_url":"git://github.com/OCA/web.git","ssh_url":"git@github.com:OCA/web.git","clone_url":"https://github.com/OCA/web.git","svn_url":"https://github.com/OCA/web","homepage":"","size":16226,"stargazers_count":107,"watchers_count":107,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":313,"mirror_url":null,"open_issues_count":97,"forks":313,"open_issues":97,"watchers":107,"default_branch":"9.0"}},"_links":{"self":{"href":"https://api.github.com/repos/OCA/web/pulls/422"},"html":{"href":"https://github.com/OCA/web/pull/422"},"issue":{"href":"https://api.github.com/repos/OCA/web/issues/422"},"comments":{"href":"https://api.github.com/repos/OCA/web/issues/422/comments"},"review_comments":{"href":"https://api.github.com/repos/OCA/web/pulls/422/comments"},"review_comment":{"href":"https://api.github.com/repos/OCA/web/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/OCA/web/pulls/422/commits"},"statuses":{"href":"https://api.github.com/repos/OCA/web/statuses/0d3eb271d7503b3db6f574e9fd3d0b7760a9f0ab"}}}}
{"actor":{"display_login":"Yajo"}}