Permalink
Browse files

Initialize hasSameAs field in SenateSiteBill resolutions

Resolutions in the NYSenate.gov dump were not getting their hasSameAs
field set. This caused a false positive mismatch for every resolution
that had a same as.

This commit sets the resolution's SenateSiteBill hasSameAs to the value
specified in the dump.

refs #11141
  • Loading branch information...
KevinCaseiras committed Dec 6, 2017
1 parent 612e47a commit 37cf27e0c5c74ce496330d1dafbec55d2c3e617e
@@ -82,13 +82,12 @@ private SenateSiteBill extractSenSiteBill(JsonNode billNode, SenateSiteDumpFragm
bill.setLastStatus(getValue(billNode, "field_ol_last_status"));
bill.setLastStatusDate(getDateTimeValue(billNode, "field_ol_last_status_date"));
bill.setActions(getActionList(billNode, "field_ol_all_actions"));
bill.setHasSameAs(getBooleanValue(billNode, "field_ol_has_same_as"));
if (bill.getBaseBillId().getBillType().isResolution()) {
// Public Website has different models for resolution and bills. For resolutions action info is stored
// in the field_ol_all_statuses node.
bill.setActions(getActionList(billNode, "field_ol_all_statuses"));
} else {
bill.setHasSameAs(getBooleanValue(billNode, "field_ol_has_same_as"));
}
return bill;

0 comments on commit 37cf27e

Please sign in to comment.