@@ -16,7 +16,8 @@ class Edit extends PureComponent {
1616 numUsers : 0 ,
1717 mexSignups : 0 ,
1818 burnerSignups : 0 ,
19- bipoclgbtqSignups : 0
19+ bipoclgbtqSignups : 0 ,
20+ helpyourblackneighborSignups : 0 ,
2021 } ;
2122
2223 componentDidMount = ( ) => {
@@ -35,6 +36,7 @@ class Edit extends PureComponent {
3536 this . getMexicoCount ( ) ;
3637 this . getBurnerCount ( ) ;
3738 this . getBipocCount ( ) ;
39+ this . getHelpYourBlackNeighborCount ( ) ;
3840 }
3941
4042 getMexicoCount = ( ) => {
@@ -73,6 +75,18 @@ class Edit extends PureComponent {
7375 } )
7476 }
7577
78+ getHelpYourBlackNeighborCount = ( ) => {
79+ const { entriesCollection } = this . props . firebase ;
80+ entriesCollection
81+ . where ( 'group' , '==' , 'helpyourblackneighbor' )
82+ . get ( )
83+ . then ( ( querySnapshot ) => {
84+ this . setState ( {
85+ helpyourblackneighborSignups : querySnapshot . docs . length
86+ } )
87+ } )
88+ }
89+
7690 handleChange = event => {
7791 this . setState ( {
7892 query : event . target . value
@@ -150,6 +164,7 @@ class Edit extends PureComponent {
150164 < p > There are currently { this . state . mexSignups } Mexico signups.</ p >
151165 < p > There are currently { this . state . burnerSignups } Burner signups.</ p >
152166 < p > There are currently { this . state . bipoclgbtqSignups } BIPOCLGBTQ signups.</ p >
167+ < p > There are currently { this . state . helpyourblackneighborSignups } helpyourblackneighbor signups.</ p >
153168 < p > search for a user by their email.</ p >
154169 < form className = { styles . SearchForm } onSubmit = { this . handleSearch } >
155170 < input type = "text" name = "query" value = { this . state . query } onChange = { this . handleChange } placeholder = "email-goes-here@gmail.com" />
0 commit comments