{"action":"created","comment":{"url":"https://api.github.com/repos/dimagi/Vellum/pulls/comments/28455652","id":28455652,"diff_hunk":"@@ -0,0 +1,495 @@\n+define([\n+    'vellum/form',\n+    'jquery',\n+    'underscore',\n+    'vellum/mugs',\n+    'vellum/parser',\n+    'vellum/tree',\n+    'vellum/util',\n+    'vellum/widgets',\n+    'tpl!vellum/templates/widget_update_case',\n+    'vellum/core'\n+], function (\n+    form_,\n+    $,\n+    _,\n+    mugs,\n+    parser,\n+    Tree,\n+    util,\n+    widgets,\n+    widget_update_case\n+){\n+    function createsCase(mug) {\n+        return mug ? mug.p.use_create : false;\n+    }\n+\n+    function closesCase(mug) {\n+        return mug ? mug.p.use_close : false;\n+    }\n+\n+    function updatesCase(mug) {\n+        return mug ? mug.p.use_update : false;\n+    }\n+\n+    function addSetValue(mug) {\n+        var path = mug.absolutePath;\n+\n+        if (createsCase(mug)) {\n+            mug.form.addSetValue('xforms-ready', path + \"/case/@case_id\", mug.p.case_id);\n+        }\n+    }\n+\n+    var saveCasePropWidget = function (mug, options) {\n+        var widget = widgets.normal(mug, options),\n+            id = options.id;\n+\n+        // todo make a style for this when vellum gets a facelift\n+        widget.kvInput = $('<div class=\"control-row\" />').attr('name', id);\n+\n+        widget.getControl = function () {\n+            if (widget.isDisabled()) {\n+                // todo\n+            }\n+            return widget.kvInput;\n+        };\n+\n+        widget.setValue = function (value) {\n+            value = _.isUndefined(value) ? {} : value;\n+            widget.kvInput.html(widget_update_case({\n+                props: value\n+            }));\n+            widget.kvInput.find('input').bind('change keyup', function () {\n+                widget.handleChange();\n+            });\n+            widget.kvInput.find('.fd-add-update-property').click(function (e) {\n+                widget.refreshControl();\n+                e.preventDefault();\n+            });\n+            widget.kvInput.find('.fd-remove-update-property').click(function (e) {\n+                $(this).parent().parent().parent().remove();\n+                widget.refreshControl();\n+                widget.save();\n+                e.preventDefault();\n+            });\n+        };\n+\n+        widget.getValue = function () {\n+            var currentValues = {};\n+            _.each(widget.kvInput.find('.fd-update-property'), function (kvPair) {\n+                var $pair = $(kvPair);\n+                currentValues[$pair.find('.fd-update-property-name').val()] = {\n+                    calculate: $pair.find('.fd-update-property-source').val(),\n+                    relevant: $pair.find('.fd-update-property-relevant').val(),\n+                };\n+            });\n+            return currentValues;\n+        };\n+\n+        widget.save = function () {\n+            this.mug.p[this.path] = this.getValue();\n+        };\n+\n+        widget.getValidValues = function () {\n+            var values = _.clone(widget.getValue());\n+            if (values[\"\"]) {\n+                delete values[\"\"];\n+            }\n+            return values;\n+        };\n+\n+        widget.updateValue = function () {\n+            var currentValues = widget.getValue();\n+            if (!(\"\" in currentValues)) {\n+                widget.kvInput.find('.btn').removeClass('hide');\n+                widget.kvInput.find('.fd-remove-update-property').removeClass('hide');\n+            }\n+            widget.save();\n+        };\n+\n+        widget.refreshControl = function () {\n+            widget.setValue(widget.getValue());\n+        };\n+\n+        return widget;\n+    };\n+\n+    var CASE_XMLNS = \"http://commcarehq.org/case/transaction/v2\",\n+        saveToCaseMugOptions = {\n+            typeName: 'Save to Case',\n+            isTypeChangeable: false,\n+            isDataOnly: true,\n+            supportsDataNodeRole: true,\n+            icon: 'icon-italic',\n+            init: function (mug, form) {},\n+            spec: {\n+                xmlnsAttr: { presence: \"optional\" },\n+                \"date_modified\": {\n+                    lstring: \"Date modified\",\n+                    visibility: 'visible',\n+                    presence: 'required',\n+                    widget: widgets.xPath,\n+                    validationFunc: function (mug) {\n+                        if (mug.p.date_modified === \"\") {\n+                            return \"Date Modified is required\";\n+                        }\n+                        return 'pass';\n+                    }\n+                },\n+                \"user_id\": {\n+                    lstring: \"User ID\",\n+                    visibility: 'visible',\n+                    presence: 'optional',\n+                    widget: widgets.xPath\n+                },\n+                \"case_id\": {\n+                    lstring: \"Case ID\",\n+                    visibility: 'visible',\n+                    presence: 'optional',\n+                    widget: widgets.xPath,\n+                    validationFunc: function (mug) {\n+                        if (mug.p.case_id === \"\") {\n+                            return \"Case ID is required\";\n+                        }\n+                        return 'pass';\n+                    }\n+                },\n+                \"use_create\": {\n+                    lstring: \"Create Case\",\n+                    visibility: 'visible',\n+                    presence: 'optional',\n+                    widget: widgets.checkbox\n+                },\n+                \"create_property\": {\n+                    lstring: \"Properties To Create\",\n+                    visibility: 'visible',\n+                    presence: 'optional',\n+                    widget: saveCasePropWidget,\n+                    validationFunc: function (mug) {\n+                        if (mug.p.use_create) {\n+                            var props = _.without(_.keys(mug.p.create_property), \"\"),\n+                                required = [\"case_type\", \"case_name\"],\n+                                optional = [\"owner_id\"],\n+                                legal = _.union(required, optional),\n+                                illegalProps = _.difference(props, legal),\n+                                requiredProps = _.intersection(props, required),\n+                                invalidProps = _.filter(props, function(p) {\n+                                    return !/[a-z_]*/.test(p);\n+                                });\n+\n+                            if (requiredProps.length !== required.length) {\n+                                return \"You must include \" + \n+                                    required.join(\", \") + \n+                                    \" columns to create a case\";\n+                            } else if (illegalProps.length > 0) {\n+                                return \"You can only use the following properties: \" +\n+                                    legal.join(', ');\n+                            } else if (invalidProps.length > 0) {\n+                                return invalidProps.join(\", \") + \n+                                    \" are invalid properties\";\n+                            }\n+\n+                        }\n+                        return 'pass';\n+                    }\n+                },\n+                \"use_close\": {\n+                    lstring: \"Close Case\",\n+                    visibility: 'visible',\n+                    presence: 'optional',\n+                    widget: widgets.checkbox\n+                },\n+                \"close_condition\": {\n+                    lstring: \"Close Condition\",\n+                    visibility: 'visible',\n+                    presence: 'optional',\n+                    widget: widgets.xPath\n+                },\n+                \"use_update\": {\n+                    lstring: \"Update Case\",\n+                    visibility: 'visible',\n+                    presence: 'optional',\n+                    widget: widgets.checkbox\n+                },\n+                \"update_property\": {\n+                    lstring: \"Properties To Update\",\n+                    visibility: 'visible',\n+                    presence: 'optional',\n+                    widget: saveCasePropWidget,\n+                    validationFunc: function (mug) {\n+                        if (mug.p.use_update) {\n+                            var props = _.without(_.keys(mug.p.update_property), \"\"),\n+                                invalidProps = _.filter(props, function(p) {\n+                                    return !/[a-z_]*/.test(p);\n+                                });\n+\n+                            if (invalidProps.length > 0) {\n+                                return invalidProps.join(\", \") + \n+                                    \" are invalid properties\";\n+                            }\n+                        }\n+                        return 'pass';\n+                    }\n+                }\n+            },\n+            getExtraDataAttributes: function (mug) {\n+                addSetValue(mug);\n+                return {\n+                    \"vellum:role\": \"SaveToCase\"\n+                };\n+            },\n+            dataChildFilter: function (children, mug) {\n+                function simpleNode(name, children, dataValue) {\n+                    children = children ? children : [];\n+                    var node = new Tree.Node(children, {\n+                        getNodeID: function () { return name; },\n+                        p: {\n+                            rawDataAttributes: null,\n+                            dataValue: dataValue\n+                        },\n+                        options: { }\n+                    });\n+                    return node;\n+                }\n+\n+                function makeColumns(properties) {\n+                    return _.map(properties, function(v, k) {\n+                        if (k) {\n+                            return simpleNode(k);\n+                        }\n+                    });\n+                }\n+\n+                var actions = [];\n+                if (createsCase(mug)) {\n+                    actions.push(simpleNode('create', makeColumns(mug.p.create_property)));\n+                }\n+\n+                if (updatesCase(mug)) {\n+                    actions.push(simpleNode('update', makeColumns(mug.p.update_property)));\n+                }\n+\n+                if (closesCase(mug)) {\n+                    actions.push(simpleNode('close'));\n+                }\n+\n+                return [new Tree.Node(actions, {\n+                    getNodeID: function () { return \"c:case\"; },\n+                    p: {rawDataAttributes: null},\n+                    options: { \n+                        getExtraDataAttributes: function (mug) {\n+                            return {\n+                                \"xmlns:c\": CASE_XMLNS,\n+                                case_id: '',\n+                                date_modified: '',\n+                                user_id: '',\n+                            };\n+                        }\n+                    }\n+                })];\n+            },\n+            getBindList: function (mug) {\n+                var ret = [];\n+                function generateBinds(action, properties) {\n+                    return _.map(properties, function(v, k) {\n+                        return {\n+                            nodeset: mug.absolutePath + \"/case/\" + action + \"/\" + k,\n+                            calculate: v.calculate,\n+                            relevant: v.relevant\n+                        };\n+                    });\n+                }\n+\n+                if (createsCase(mug)) {\n+                    ret = ret.concat(generateBinds('create', mug.p.create_property));\n+                }\n+                if (updatesCase(mug)) {\n+                    ret = ret.concat(generateBinds('update', mug.p.update_property));\n+                }\n+                if (closesCase(mug)) {\n+                    ret.push({\n+                        nodeset: mug.absolutePath + \"/case/close\",\n+                        relevant: mug.p.close_condition\n+                    });\n+                }\n+\n+                if (createsCase(mug) || updatesCase(mug) || closesCase(mug)) {\n+                    ret.push({\n+                        nodeset: mug.absolutePath + \"/case/@date_modified\",\n+                        calculate: mug.p.date_modified,\n+                        type: \"xsd:dateTime\"\n+                    });\n+                    ret.push({\n+                        nodeset: mug.absolutePath + \"/case/@user_id\",\n+                        calculate: mug.p.user_id\n+                    });\n+\n+                    if (!createsCase(mug)) {\n+                        ret.push({\n+                            nodeset: mug.absolutePath + \"/case/@case_id\",\n+                            calculate: mug.p.case_id\n+                        });\n+                    }\n+                }\n+                return ret;\n+            },\n+            parseDataNode: function (mug, $node) {\n+                var case_ = $node.children(),\n+                    create = case_.find('create'),\n+                    close = case_.find('close'),\n+                    update = case_.find('update');\n+                if (create && create.length !== 0) {\n+                    mug.p.use_create = true;\n+                }\n+                if (update && update.length !== 0) {\n+                    mug.p.use_update = true;\n+                }\n+                if (close && close.length !== 0) {\n+                    mug.p.use_close = true;\n+                }\n+                return $([]);\n+            }\n+        },\n+        sectionData = {\n+            SaveToCase: [\n+                {\n+                    slug: \"main\",\n+                    displayName: \"Basic\",\n+                    properties: [\n+                        \"nodeID\",\n+                        \"date_modified\",\n+                        \"user_id\",\n+                        \"case_id\",\n+                    ],\n+                },\n+                {\n+                    slug: \"create\",\n+                    displayName: \"Create\",\n+                    properties: [\n+                        \"use_create\",\n+                        \"create_property\",\n+                    ],\n+                    isCollapsed: function (mug) {","path":"src/saveToCase.js","position":372,"original_position":372,"commit_id":"57714d8342fa5bbba8be8b56fa4df0c5d032c200","original_commit_id":"eb7915229ade59b09f36798c5a6cfa37935e352f","user":{"login":"emord","id":1471773,"avatar_url":"https://avatars.githubusercontent.com/u/1471773?v=3","gravatar_id":"","url":"https://api.github.com/users/emord","html_url":"https://github.com/emord","followers_url":"https://api.github.com/users/emord/followers","following_url":"https://api.github.com/users/emord/following{/other_user}","gists_url":"https://api.github.com/users/emord/gists{/gist_id}","starred_url":"https://api.github.com/users/emord/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emord/subscriptions","organizations_url":"https://api.github.com/users/emord/orgs","repos_url":"https://api.github.com/users/emord/repos","events_url":"https://api.github.com/users/emord/events{/privacy}","received_events_url":"https://api.github.com/users/emord/received_events","type":"User","site_admin":false},"body":"Collapse sections when they aren't being used","created_at":"2015-04-15T19:48:36Z","updated_at":"2015-04-15T19:48:36Z","html_url":"https://github.com/dimagi/Vellum/pull/374#discussion_r28455652","pull_request_url":"https://api.github.com/repos/dimagi/Vellum/pulls/374","_links":{"self":{"href":"https://api.github.com/repos/dimagi/Vellum/pulls/comments/28455652"},"html":{"href":"https://github.com/dimagi/Vellum/pull/374#discussion_r28455652"},"pull_request":{"href":"https://api.github.com/repos/dimagi/Vellum/pulls/374"}}},"pull_request":{"url":"https://api.github.com/repos/dimagi/Vellum/pulls/374","id":33389216,"html_url":"https://github.com/dimagi/Vellum/pull/374","diff_url":"https://github.com/dimagi/Vellum/pull/374.diff","patch_url":"https://github.com/dimagi/Vellum/pull/374.patch","issue_url":"https://api.github.com/repos/dimagi/Vellum/issues/374","number":374,"state":"open","locked":false,"title":"Save to case on master","user":{"login":"emord","id":1471773,"avatar_url":"https://avatars.githubusercontent.com/u/1471773?v=3","gravatar_id":"","url":"https://api.github.com/users/emord","html_url":"https://github.com/emord","followers_url":"https://api.github.com/users/emord/followers","following_url":"https://api.github.com/users/emord/following{/other_user}","gists_url":"https://api.github.com/users/emord/gists{/gist_id}","starred_url":"https://api.github.com/users/emord/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/emord/subscriptions","organizations_url":"https://api.github.com/users/emord/orgs","repos_url":"https://api.github.com/users/emord/repos","events_url":"https://api.github.com/users/emord/events{/privacy}","received_events_url":"https://api.github.com/users/emord/received_events","type":"User","site_admin":false},"body":"Originally was based on itemset-connector-2, but I think it survived the rebase to master.\r\n\r\nLooks something like this (R&D feature to start with):\r\n\r\n![image](https://cloud.githubusercontent.com/assets/1471773/7167671/3f7122ba-e385-11e4-83f9-ab02e8aaec93.png)\r\n\r\nI think the hope is to support all of this: https://github.com/dimagi/commcare/wiki/casexml20\r\n\r\nDoesn't currently have index or attachment. They can either be added to this PR or done in a separate PR. Figured I'd put it up here before it gets too large.\r\n\r\n@ctsims any feedback on this/is this close to what you were expectting?\r\n\r\n@millerdev @snopoke ","created_at":"2015-04-15T19:42:29Z","updated_at":"2015-04-15T19:48:36Z","closed_at":null,"merged_at":null,"merge_commit_sha":"bb234a0aaf6d2e206354536b28fc049d4c1c0ee5","assignee":{"login":"millerdev","id":464726,"avatar_url":"https://avatars.githubusercontent.com/u/464726?v=3","gravatar_id":"","url":"https://api.github.com/users/millerdev","html_url":"https://github.com/millerdev","followers_url":"https://api.github.com/users/millerdev/followers","following_url":"https://api.github.com/users/millerdev/following{/other_user}","gists_url":"https://api.github.com/users/millerdev/gists{/gist_id}","starred_url":"https://api.github.com/users/millerdev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/millerdev/subscriptions","organizations_url":"https://api.github.com/users/millerdev/orgs","repos_url":"https://api.github.com/users/millerdev/repos","events_url":"https://api.github.com/users/millerdev/events{/privacy}","received_events_url":"https://api.github.com/users/millerdev/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/dimagi/Vellum/pulls/374/commits","review_comments_url":"https://api.github.com/repos/dimagi/Vellum/pulls/374/comments","review_comment_url":"https://api.github.com/repos/dimagi/Vellum/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dimagi/Vellum/issues/374/comments","statuses_url":"https://api.github.com/repos/dimagi/Vellum/statuses/57714d8342fa5bbba8be8b56fa4df0c5d032c200","head":{"label":"dimagi:save-to-case-on-master","ref":"save-to-case-on-master","sha":"57714d8342fa5bbba8be8b56fa4df0c5d032c200","user":{"login":"dimagi","id":94514,"avatar_url":"https://avatars.githubusercontent.com/u/94514?v=3","gravatar_id":"","url":"https://api.github.com/users/dimagi","html_url":"https://github.com/dimagi","followers_url":"https://api.github.com/users/dimagi/followers","following_url":"https://api.github.com/users/dimagi/following{/other_user}","gists_url":"https://api.github.com/users/dimagi/gists{/gist_id}","starred_url":"https://api.github.com/users/dimagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimagi/subscriptions","organizations_url":"https://api.github.com/users/dimagi/orgs","repos_url":"https://api.github.com/users/dimagi/repos","events_url":"https://api.github.com/users/dimagi/events{/privacy}","received_events_url":"https://api.github.com/users/dimagi/received_events","type":"Organization","site_admin":false},"repo":{"id":1859793,"name":"Vellum","full_name":"dimagi/Vellum","owner":{"login":"dimagi","id":94514,"avatar_url":"https://avatars.githubusercontent.com/u/94514?v=3","gravatar_id":"","url":"https://api.github.com/users/dimagi","html_url":"https://github.com/dimagi","followers_url":"https://api.github.com/users/dimagi/followers","following_url":"https://api.github.com/users/dimagi/following{/other_user}","gists_url":"https://api.github.com/users/dimagi/gists{/gist_id}","starred_url":"https://api.github.com/users/dimagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimagi/subscriptions","organizations_url":"https://api.github.com/users/dimagi/orgs","repos_url":"https://api.github.com/users/dimagi/repos","events_url":"https://api.github.com/users/dimagi/events{/privacy}","received_events_url":"https://api.github.com/users/dimagi/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dimagi/Vellum","description":"An XForms form designer written purely in Javascript","fork":false,"url":"https://api.github.com/repos/dimagi/Vellum","forks_url":"https://api.github.com/repos/dimagi/Vellum/forks","keys_url":"https://api.github.com/repos/dimagi/Vellum/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dimagi/Vellum/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dimagi/Vellum/teams","hooks_url":"https://api.github.com/repos/dimagi/Vellum/hooks","issue_events_url":"https://api.github.com/repos/dimagi/Vellum/issues/events{/number}","events_url":"https://api.github.com/repos/dimagi/Vellum/events","assignees_url":"https://api.github.com/repos/dimagi/Vellum/assignees{/user}","branches_url":"https://api.github.com/repos/dimagi/Vellum/branches{/branch}","tags_url":"https://api.github.com/repos/dimagi/Vellum/tags","blobs_url":"https://api.github.com/repos/dimagi/Vellum/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dimagi/Vellum/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dimagi/Vellum/git/refs{/sha}","trees_url":"https://api.github.com/repos/dimagi/Vellum/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dimagi/Vellum/statuses/{sha}","languages_url":"https://api.github.com/repos/dimagi/Vellum/languages","stargazers_url":"https://api.github.com/repos/dimagi/Vellum/stargazers","contributors_url":"https://api.github.com/repos/dimagi/Vellum/contributors","subscribers_url":"https://api.github.com/repos/dimagi/Vellum/subscribers","subscription_url":"https://api.github.com/repos/dimagi/Vellum/subscription","commits_url":"https://api.github.com/repos/dimagi/Vellum/commits{/sha}","git_commits_url":"https://api.github.com/repos/dimagi/Vellum/git/commits{/sha}","comments_url":"https://api.github.com/repos/dimagi/Vellum/comments{/number}","issue_comment_url":"https://api.github.com/repos/dimagi/Vellum/issues/comments{/number}","contents_url":"https://api.github.com/repos/dimagi/Vellum/contents/{+path}","compare_url":"https://api.github.com/repos/dimagi/Vellum/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dimagi/Vellum/merges","archive_url":"https://api.github.com/repos/dimagi/Vellum/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dimagi/Vellum/downloads","issues_url":"https://api.github.com/repos/dimagi/Vellum/issues{/number}","pulls_url":"https://api.github.com/repos/dimagi/Vellum/pulls{/number}","milestones_url":"https://api.github.com/repos/dimagi/Vellum/milestones{/number}","notifications_url":"https://api.github.com/repos/dimagi/Vellum/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dimagi/Vellum/labels{/name}","releases_url":"https://api.github.com/repos/dimagi/Vellum/releases{/id}","created_at":"2011-06-07T13:03:34Z","updated_at":"2015-04-14T21:25:33Z","pushed_at":"2015-04-15T19:45:06Z","git_url":"git://github.com/dimagi/Vellum.git","ssh_url":"git@github.com:dimagi/Vellum.git","clone_url":"https://github.com/dimagi/Vellum.git","svn_url":"https://github.com/dimagi/Vellum","homepage":"","size":14653,"stargazers_count":25,"watchers_count":25,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":15,"mirror_url":null,"open_issues_count":4,"forks":15,"open_issues":4,"watchers":25,"default_branch":"master"}},"base":{"label":"dimagi:master","ref":"master","sha":"bffb80a2c73c5e583bb72cd9c60a21f06432b0aa","user":{"login":"dimagi","id":94514,"avatar_url":"https://avatars.githubusercontent.com/u/94514?v=3","gravatar_id":"","url":"https://api.github.com/users/dimagi","html_url":"https://github.com/dimagi","followers_url":"https://api.github.com/users/dimagi/followers","following_url":"https://api.github.com/users/dimagi/following{/other_user}","gists_url":"https://api.github.com/users/dimagi/gists{/gist_id}","starred_url":"https://api.github.com/users/dimagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimagi/subscriptions","organizations_url":"https://api.github.com/users/dimagi/orgs","repos_url":"https://api.github.com/users/dimagi/repos","events_url":"https://api.github.com/users/dimagi/events{/privacy}","received_events_url":"https://api.github.com/users/dimagi/received_events","type":"Organization","site_admin":false},"repo":{"id":1859793,"name":"Vellum","full_name":"dimagi/Vellum","owner":{"login":"dimagi","id":94514,"avatar_url":"https://avatars.githubusercontent.com/u/94514?v=3","gravatar_id":"","url":"https://api.github.com/users/dimagi","html_url":"https://github.com/dimagi","followers_url":"https://api.github.com/users/dimagi/followers","following_url":"https://api.github.com/users/dimagi/following{/other_user}","gists_url":"https://api.github.com/users/dimagi/gists{/gist_id}","starred_url":"https://api.github.com/users/dimagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimagi/subscriptions","organizations_url":"https://api.github.com/users/dimagi/orgs","repos_url":"https://api.github.com/users/dimagi/repos","events_url":"https://api.github.com/users/dimagi/events{/privacy}","received_events_url":"https://api.github.com/users/dimagi/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dimagi/Vellum","description":"An XForms form designer written purely in Javascript","fork":false,"url":"https://api.github.com/repos/dimagi/Vellum","forks_url":"https://api.github.com/repos/dimagi/Vellum/forks","keys_url":"https://api.github.com/repos/dimagi/Vellum/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dimagi/Vellum/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dimagi/Vellum/teams","hooks_url":"https://api.github.com/repos/dimagi/Vellum/hooks","issue_events_url":"https://api.github.com/repos/dimagi/Vellum/issues/events{/number}","events_url":"https://api.github.com/repos/dimagi/Vellum/events","assignees_url":"https://api.github.com/repos/dimagi/Vellum/assignees{/user}","branches_url":"https://api.github.com/repos/dimagi/Vellum/branches{/branch}","tags_url":"https://api.github.com/repos/dimagi/Vellum/tags","blobs_url":"https://api.github.com/repos/dimagi/Vellum/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dimagi/Vellum/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dimagi/Vellum/git/refs{/sha}","trees_url":"https://api.github.com/repos/dimagi/Vellum/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dimagi/Vellum/statuses/{sha}","languages_url":"https://api.github.com/repos/dimagi/Vellum/languages","stargazers_url":"https://api.github.com/repos/dimagi/Vellum/stargazers","contributors_url":"https://api.github.com/repos/dimagi/Vellum/contributors","subscribers_url":"https://api.github.com/repos/dimagi/Vellum/subscribers","subscription_url":"https://api.github.com/repos/dimagi/Vellum/subscription","commits_url":"https://api.github.com/repos/dimagi/Vellum/commits{/sha}","git_commits_url":"https://api.github.com/repos/dimagi/Vellum/git/commits{/sha}","comments_url":"https://api.github.com/repos/dimagi/Vellum/comments{/number}","issue_comment_url":"https://api.github.com/repos/dimagi/Vellum/issues/comments{/number}","contents_url":"https://api.github.com/repos/dimagi/Vellum/contents/{+path}","compare_url":"https://api.github.com/repos/dimagi/Vellum/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dimagi/Vellum/merges","archive_url":"https://api.github.com/repos/dimagi/Vellum/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dimagi/Vellum/downloads","issues_url":"https://api.github.com/repos/dimagi/Vellum/issues{/number}","pulls_url":"https://api.github.com/repos/dimagi/Vellum/pulls{/number}","milestones_url":"https://api.github.com/repos/dimagi/Vellum/milestones{/number}","notifications_url":"https://api.github.com/repos/dimagi/Vellum/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dimagi/Vellum/labels{/name}","releases_url":"https://api.github.com/repos/dimagi/Vellum/releases{/id}","created_at":"2011-06-07T13:03:34Z","updated_at":"2015-04-14T21:25:33Z","pushed_at":"2015-04-15T19:45:06Z","git_url":"git://github.com/dimagi/Vellum.git","ssh_url":"git@github.com:dimagi/Vellum.git","clone_url":"https://github.com/dimagi/Vellum.git","svn_url":"https://github.com/dimagi/Vellum","homepage":"","size":14653,"stargazers_count":25,"watchers_count":25,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":15,"mirror_url":null,"open_issues_count":4,"forks":15,"open_issues":4,"watchers":25,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dimagi/Vellum/pulls/374"},"html":{"href":"https://github.com/dimagi/Vellum/pull/374"},"issue":{"href":"https://api.github.com/repos/dimagi/Vellum/issues/374"},"comments":{"href":"https://api.github.com/repos/dimagi/Vellum/issues/374/comments"},"review_comments":{"href":"https://api.github.com/repos/dimagi/Vellum/pulls/374/comments"},"review_comment":{"href":"https://api.github.com/repos/dimagi/Vellum/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dimagi/Vellum/pulls/374/commits"},"statuses":{"href":"https://api.github.com/repos/dimagi/Vellum/statuses/57714d8342fa5bbba8be8b56fa4df0c5d032c200"}}}}