Mapping JSON object with lodash
<p>I'm trying to map a JSON object using lodash.  I'm calling the json object as follows:</p>

<pre><code>var json = (function() {
var json = null;
$.ajax({
    'async': false,
    'global': false,
    'url': "{% url 'api_temp_income_statement' asset_details.id %}",
    'datatype': "json",
    'success': function (data) {
        json = data;
    }
});
return json;
</code></pre>

<p>})</p>

<p>Which returns a JSON object that looks like this:</p>

<pre><code>[{"model": "tempincomestatement",
  "pk": 3,
  "fields": {"income_period": "2016-01-31", "lease_income_collected": "994174.0000", "storage_income_collected": "236216.0000", "tax_income_collected": "131020.0000", "other_income_collected": "0.0000"}
},... ]
</code></pre>

<p>I'm trying to create a map that has an Income Period : remaining fields relationship, so</p>

<pre><code> "2016-01-31" : {"lease_income_collected" : "994174", ... }
</code></pre>

<p>Reading the docs, it doesn't really address how to go about this...How would I accomplish this?</p>