Skip to content

Commit

Permalink
chore: fix resident id search bar
Browse files Browse the repository at this point in the history
  • Loading branch information
hopetambala committed Oct 25, 2020
1 parent 7a7be91 commit 14817f3
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ import ResidentIdSearchbar from '../../../ResidentIdSearchbar';
import { theme, layout } from '../../../../modules/theme';
import { postObjectsToClass } from '../../../../services/parse/crud';

const relationships = [
'Parent', 'Sibling', 'Grand-Parent', 'Cousin', 'Other'
];
// const relationships = [
// 'Parent', 'Sibling', 'Grand-Parent', 'Cousin', 'Other'
// ];

const HouseholdManager = (props) => {
const { formikProps, formikKey, surveyingOrganization } = props;
Expand Down Expand Up @@ -70,19 +70,20 @@ const HouseholdManager = (props) => {
<Appbar.BackAction onPress={() => setModalView('first')} />
<Appbar.Content title="Household Manager" subtitle="" />
</Appbar.Header>

<ResidentIdSearchbar
surveyee={selectPerson}
setSurveyee={setSelectPerson}
surveyingOrganization={surveyingOrganization}
/>
<Text>What is their role/relationship in the household?</Text>
{/* <Text>What is their role/relationship in the household?</Text>
<View style={layout.buttonGroupContainer}>
{relationships.map((result) => (
<Button style={layout.buttonGroupButtonStyle} key={result} mode="outlined" onPress={() => setHouseholdRelationship(result)}>
<Text>{result}</Text>
</Button>
))}
</View>
</View> */}
<Button theme={{ backgroundColor: theme.colors.primary }} style={layout.buttonGroupButtonStyle} mode="contained" onPress={onSubmit}>
<Text>Submit</Text>
</Button>
Expand Down
2 changes: 1 addition & 1 deletion components/ResidentIdSearchbar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ const ResidentIdSearchbar = ({ surveyee, setSurveyee, surveyingOrganization }) =
</View>
))}

{surveyee.objectId && (
{surveyee && surveyee.objectId && (
<ResidentCard resident={surveyee} />
)}
</View>
Expand Down

0 comments on commit 14817f3

Please sign in to comment.