{"action":"created","comment":{"url":"https://api.github.com/repos/foodcoops/foodsoft/pulls/comments/224963155","pull_request_review_id":164466881,"id":224963155,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIyNDk2MzE1NQ==","diff_hunk":"@@ -33,4 +33,55 @@ class BankTransaction < ActiveRecord::Base\n   def image_url\n     'data:image/png;base64,' + Base64.encode64(self.image)\n   end\n+\n+  def assign_to_invoice\n+    return false unless supplier\n+\n+    content = text\n+    content += \"\\n\" + reference if reference.present?\n+    invoices = supplier.invoices.unpaid.select {|i| content.include? i.number}","path":"app/models/bank_transaction.rb","position":10,"original_position":10,"commit_id":"9c8c986ff4bd046499e982182176af807a963a36","original_commit_id":"9c8c986ff4bd046499e982182176af807a963a36","user":{"login":"wvengen","id":503804,"node_id":"MDQ6VXNlcjUwMzgwNA==","avatar_url":"https://avatars3.githubusercontent.com/u/503804?v=4","gravatar_id":"","url":"https://api.github.com/users/wvengen","html_url":"https://github.com/wvengen","followers_url":"https://api.github.com/users/wvengen/followers","following_url":"https://api.github.com/users/wvengen/following{/other_user}","gists_url":"https://api.github.com/users/wvengen/gists{/gist_id}","starred_url":"https://api.github.com/users/wvengen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wvengen/subscriptions","organizations_url":"https://api.github.com/users/wvengen/orgs","repos_url":"https://api.github.com/users/wvengen/repos","events_url":"https://api.github.com/users/wvengen/events{/privacy}","received_events_url":"https://api.github.com/users/wvengen/received_events","type":"User","site_admin":false},"body":"Ok then!","created_at":"2018-10-13T15:34:59Z","updated_at":"2018-10-13T15:34:59Z","html_url":"https://github.com/foodcoops/foodsoft/pull/568#discussion_r224963155","pull_request_url":"https://api.github.com/repos/foodcoops/foodsoft/pulls/568","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/foodcoops/foodsoft/pulls/comments/224963155"},"html":{"href":"https://github.com/foodcoops/foodsoft/pull/568#discussion_r224963155"},"pull_request":{"href":"https://api.github.com/repos/foodcoops/foodsoft/pulls/568"}},"in_reply_to_id":224817389},"pull_request":{"url":"https://api.github.com/repos/foodcoops/foodsoft/pulls/568","id":222479904,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIyNDc5OTA0","html_url":"https://github.com/foodcoops/foodsoft/pull/568","diff_url":"https://github.com/foodcoops/foodsoft/pull/568.diff","patch_url":"https://github.com/foodcoops/foodsoft/pull/568.patch","issue_url":"https://api.github.com/repos/foodcoops/foodsoft/issues/568","number":568,"state":"open","locked":false,"title":"Add automatic generation of financial transactions and links","user":{"login":"paroga","id":337009,"node_id":"MDQ6VXNlcjMzNzAwOQ==","avatar_url":"https://avatars1.githubusercontent.com/u/337009?v=4","gravatar_id":"","url":"https://api.github.com/users/paroga","html_url":"https://github.com/paroga","followers_url":"https://api.github.com/users/paroga/followers","following_url":"https://api.github.com/users/paroga/following{/other_user}","gists_url":"https://api.github.com/users/paroga/gists{/gist_id}","starred_url":"https://api.github.com/users/paroga/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paroga/subscriptions","organizations_url":"https://api.github.com/users/paroga/orgs","repos_url":"https://api.github.com/users/paroga/repos","events_url":"https://api.github.com/users/paroga/events{/privacy}","received_events_url":"https://api.github.com/users/paroga/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-10-12T14:11:23Z","updated_at":"2018-10-13T15:34:59Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6533f21dc4769b017ea34e22ef574146bf984a73","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/foodcoops/foodsoft/pulls/568/commits","review_comments_url":"https://api.github.com/repos/foodcoops/foodsoft/pulls/568/comments","review_comment_url":"https://api.github.com/repos/foodcoops/foodsoft/pulls/comments{/number}","comments_url":"https://api.github.com/repos/foodcoops/foodsoft/issues/568/comments","statuses_url":"https://api.github.com/repos/foodcoops/foodsoft/statuses/9c8c986ff4bd046499e982182176af807a963a36","head":{"label":"paroga:assign","ref":"assign","sha":"9c8c986ff4bd046499e982182176af807a963a36","user":{"login":"paroga","id":337009,"node_id":"MDQ6VXNlcjMzNzAwOQ==","avatar_url":"https://avatars1.githubusercontent.com/u/337009?v=4","gravatar_id":"","url":"https://api.github.com/users/paroga","html_url":"https://github.com/paroga","followers_url":"https://api.github.com/users/paroga/followers","following_url":"https://api.github.com/users/paroga/following{/other_user}","gists_url":"https://api.github.com/users/paroga/gists{/gist_id}","starred_url":"https://api.github.com/users/paroga/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paroga/subscriptions","organizations_url":"https://api.github.com/users/paroga/orgs","repos_url":"https://api.github.com/users/paroga/repos","events_url":"https://api.github.com/users/paroga/events{/privacy}","received_events_url":"https://api.github.com/users/paroga/received_events","type":"User","site_admin":false},"repo":{"id":28336053,"node_id":"MDEwOlJlcG9zaXRvcnkyODMzNjA1Mw==","name":"foodsoft","full_name":"paroga/foodsoft","private":false,"owner":{"login":"paroga","id":337009,"node_id":"MDQ6VXNlcjMzNzAwOQ==","avatar_url":"https://avatars1.githubusercontent.com/u/337009?v=4","gravatar_id":"","url":"https://api.github.com/users/paroga","html_url":"https://github.com/paroga","followers_url":"https://api.github.com/users/paroga/followers","following_url":"https://api.github.com/users/paroga/following{/other_user}","gists_url":"https://api.github.com/users/paroga/gists{/gist_id}","starred_url":"https://api.github.com/users/paroga/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paroga/subscriptions","organizations_url":"https://api.github.com/users/paroga/orgs","repos_url":"https://api.github.com/users/paroga/repos","events_url":"https://api.github.com/users/paroga/events{/privacy}","received_events_url":"https://api.github.com/users/paroga/received_events","type":"User","site_admin":false},"html_url":"https://github.com/paroga/foodsoft","description":"Web-based software to manage a non-profit food coop (product catalog, ordering, accounting, job scheduling).","fork":true,"url":"https://api.github.com/repos/paroga/foodsoft","forks_url":"https://api.github.com/repos/paroga/foodsoft/forks","keys_url":"https://api.github.com/repos/paroga/foodsoft/keys{/key_id}","collaborators_url":"https://api.github.com/repos/paroga/foodsoft/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/paroga/foodsoft/teams","hooks_url":"https://api.github.com/repos/paroga/foodsoft/hooks","issue_events_url":"https://api.github.com/repos/paroga/foodsoft/issues/events{/number}","events_url":"https://api.github.com/repos/paroga/foodsoft/events","assignees_url":"https://api.github.com/repos/paroga/foodsoft/assignees{/user}","branches_url":"https://api.github.com/repos/paroga/foodsoft/branches{/branch}","tags_url":"https://api.github.com/repos/paroga/foodsoft/tags","blobs_url":"https://api.github.com/repos/paroga/foodsoft/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/paroga/foodsoft/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/paroga/foodsoft/git/refs{/sha}","trees_url":"https://api.github.com/repos/paroga/foodsoft/git/trees{/sha}","statuses_url":"https://api.github.com/repos/paroga/foodsoft/statuses/{sha}","languages_url":"https://api.github.com/repos/paroga/foodsoft/languages","stargazers_url":"https://api.github.com/repos/paroga/foodsoft/stargazers","contributors_url":"https://api.github.com/repos/paroga/foodsoft/contributors","subscribers_url":"https://api.github.com/repos/paroga/foodsoft/subscribers","subscription_url":"https://api.github.com/repos/paroga/foodsoft/subscription","commits_url":"https://api.github.com/repos/paroga/foodsoft/commits{/sha}","git_commits_url":"https://api.github.com/repos/paroga/foodsoft/git/commits{/sha}","comments_url":"https://api.github.com/repos/paroga/foodsoft/comments{/number}","issue_comment_url":"https://api.github.com/repos/paroga/foodsoft/issues/comments{/number}","contents_url":"https://api.github.com/repos/paroga/foodsoft/contents/{+path}","compare_url":"https://api.github.com/repos/paroga/foodsoft/compare/{base}...{head}","merges_url":"https://api.github.com/repos/paroga/foodsoft/merges","archive_url":"https://api.github.com/repos/paroga/foodsoft/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/paroga/foodsoft/downloads","issues_url":"https://api.github.com/repos/paroga/foodsoft/issues{/number}","pulls_url":"https://api.github.com/repos/paroga/foodsoft/pulls{/number}","milestones_url":"https://api.github.com/repos/paroga/foodsoft/milestones{/number}","notifications_url":"https://api.github.com/repos/paroga/foodsoft/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/paroga/foodsoft/labels{/name}","releases_url":"https://api.github.com/repos/paroga/foodsoft/releases{/id}","deployments_url":"https://api.github.com/repos/paroga/foodsoft/deployments","created_at":"2014-12-22T11:31:56Z","updated_at":"2018-06-11T13:54:59Z","pushed_at":"2018-10-12T14:37:30Z","git_url":"git://github.com/paroga/foodsoft.git","ssh_url":"git@github.com:paroga/foodsoft.git","clone_url":"https://github.com/paroga/foodsoft.git","svn_url":"https://github.com/paroga/foodsoft","homepage":"http://www.foodcoops.net/","size":8972,"stargazers_count":0,"watchers_count":0,"language":"Ruby","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":1,"watchers":0,"default_branch":"master"}},"base":{"label":"foodcoops:master","ref":"master","sha":"413799203292c398a5e8cb7e3ae2913d57b051b6","user":{"login":"foodcoops","id":4523295,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQ1MjMyOTU=","avatar_url":"https://avatars1.githubusercontent.com/u/4523295?v=4","gravatar_id":"","url":"https://api.github.com/users/foodcoops","html_url":"https://github.com/foodcoops","followers_url":"https://api.github.com/users/foodcoops/followers","following_url":"https://api.github.com/users/foodcoops/following{/other_user}","gists_url":"https://api.github.com/users/foodcoops/gists{/gist_id}","starred_url":"https://api.github.com/users/foodcoops/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/foodcoops/subscriptions","organizations_url":"https://api.github.com/users/foodcoops/orgs","repos_url":"https://api.github.com/users/foodcoops/repos","events_url":"https://api.github.com/users/foodcoops/events{/privacy}","received_events_url":"https://api.github.com/users/foodcoops/received_events","type":"Organization","site_admin":false},"repo":{"id":102952,"node_id":"MDEwOlJlcG9zaXRvcnkxMDI5NTI=","name":"foodsoft","full_name":"foodcoops/foodsoft","private":false,"owner":{"login":"foodcoops","id":4523295,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQ1MjMyOTU=","avatar_url":"https://avatars1.githubusercontent.com/u/4523295?v=4","gravatar_id":"","url":"https://api.github.com/users/foodcoops","html_url":"https://github.com/foodcoops","followers_url":"https://api.github.com/users/foodcoops/followers","following_url":"https://api.github.com/users/foodcoops/following{/other_user}","gists_url":"https://api.github.com/users/foodcoops/gists{/gist_id}","starred_url":"https://api.github.com/users/foodcoops/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/foodcoops/subscriptions","organizations_url":"https://api.github.com/users/foodcoops/orgs","repos_url":"https://api.github.com/users/foodcoops/repos","events_url":"https://api.github.com/users/foodcoops/events{/privacy}","received_events_url":"https://api.github.com/users/foodcoops/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/foodcoops/foodsoft","description":"Web-based software to manage a non-profit food coop (product catalog, ordering, accounting, job scheduling).","fork":false,"url":"https://api.github.com/repos/foodcoops/foodsoft","forks_url":"https://api.github.com/repos/foodcoops/foodsoft/forks","keys_url":"https://api.github.com/repos/foodcoops/foodsoft/keys{/key_id}","collaborators_url":"https://api.github.com/repos/foodcoops/foodsoft/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/foodcoops/foodsoft/teams","hooks_url":"https://api.github.com/repos/foodcoops/foodsoft/hooks","issue_events_url":"https://api.github.com/repos/foodcoops/foodsoft/issues/events{/number}","events_url":"https://api.github.com/repos/foodcoops/foodsoft/events","assignees_url":"https://api.github.com/repos/foodcoops/foodsoft/assignees{/user}","branches_url":"https://api.github.com/repos/foodcoops/foodsoft/branches{/branch}","tags_url":"https://api.github.com/repos/foodcoops/foodsoft/tags","blobs_url":"https://api.github.com/repos/foodcoops/foodsoft/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/foodcoops/foodsoft/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/foodcoops/foodsoft/git/refs{/sha}","trees_url":"https://api.github.com/repos/foodcoops/foodsoft/git/trees{/sha}","statuses_url":"https://api.github.com/repos/foodcoops/foodsoft/statuses/{sha}","languages_url":"https://api.github.com/repos/foodcoops/foodsoft/languages","stargazers_url":"https://api.github.com/repos/foodcoops/foodsoft/stargazers","contributors_url":"https://api.github.com/repos/foodcoops/foodsoft/contributors","subscribers_url":"https://api.github.com/repos/foodcoops/foodsoft/subscribers","subscription_url":"https://api.github.com/repos/foodcoops/foodsoft/subscription","commits_url":"https://api.github.com/repos/foodcoops/foodsoft/commits{/sha}","git_commits_url":"https://api.github.com/repos/foodcoops/foodsoft/git/commits{/sha}","comments_url":"https://api.github.com/repos/foodcoops/foodsoft/comments{/number}","issue_comment_url":"https://api.github.com/repos/foodcoops/foodsoft/issues/comments{/number}","contents_url":"https://api.github.com/repos/foodcoops/foodsoft/contents/{+path}","compare_url":"https://api.github.com/repos/foodcoops/foodsoft/compare/{base}...{head}","merges_url":"https://api.github.com/repos/foodcoops/foodsoft/merges","archive_url":"https://api.github.com/repos/foodcoops/foodsoft/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/foodcoops/foodsoft/downloads","issues_url":"https://api.github.com/repos/foodcoops/foodsoft/issues{/number}","pulls_url":"https://api.github.com/repos/foodcoops/foodsoft/pulls{/number}","milestones_url":"https://api.github.com/repos/foodcoops/foodsoft/milestones{/number}","notifications_url":"https://api.github.com/repos/foodcoops/foodsoft/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/foodcoops/foodsoft/labels{/name}","releases_url":"https://api.github.com/repos/foodcoops/foodsoft/releases{/id}","deployments_url":"https://api.github.com/repos/foodcoops/foodsoft/deployments","created_at":"2009-01-07T22:38:49Z","updated_at":"2018-10-12T14:04:14Z","pushed_at":"2018-10-13T15:33:16Z","git_url":"git://github.com/foodcoops/foodsoft.git","ssh_url":"git@github.com:foodcoops/foodsoft.git","clone_url":"https://github.com/foodcoops/foodsoft.git","svn_url":"https://github.com/foodcoops/foodsoft","homepage":"https://foodcoops.github.io/","size":8860,"stargazers_count":162,"watchers_count":162,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":90,"mirror_url":null,"archived":false,"open_issues_count":109,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":90,"open_issues":109,"watchers":162,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/foodcoops/foodsoft/pulls/568"},"html":{"href":"https://github.com/foodcoops/foodsoft/pull/568"},"issue":{"href":"https://api.github.com/repos/foodcoops/foodsoft/issues/568"},"comments":{"href":"https://api.github.com/repos/foodcoops/foodsoft/issues/568/comments"},"review_comments":{"href":"https://api.github.com/repos/foodcoops/foodsoft/pulls/568/comments"},"review_comment":{"href":"https://api.github.com/repos/foodcoops/foodsoft/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/foodcoops/foodsoft/pulls/568/commits"},"statuses":{"href":"https://api.github.com/repos/foodcoops/foodsoft/statuses/9c8c986ff4bd046499e982182176af807a963a36"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"wvengen"}}