Display bio on member search and notes to admins

This commit is contained in:
Tanner Collin 2020-05-01 03:54:23 +00:00
parent b4f52fb37a
commit 23c20a2c5c
3 changed files with 42 additions and 15 deletions

View File

@ -400,6 +400,11 @@ export function AdminMemberForm(props) {
/> />
</Form.Field> </Form.Field>
<Form.TextArea
label={'Private Notes (shared with ' + input.preferred_name + ')'}
{...makeProps('private_notes')}
/>
<Form.Button loading={loading} error={error.non_field_errors}> <Form.Button loading={loading} error={error.non_field_errors}>
Submit Submit
</Form.Button> </Form.Button>
@ -478,9 +483,16 @@ export function AdminMemberInfo(props) {
<Table.Cell>Emergency Contact Phone:</Table.Cell> <Table.Cell>Emergency Contact Phone:</Table.Cell>
<Table.Cell>{member.emergency_contact_phone || 'None'}</Table.Cell> <Table.Cell>{member.emergency_contact_phone || 'None'}</Table.Cell>
</Table.Row> </Table.Row>
<Table.Row>
<Table.Cell>Public Bio:</Table.Cell>
</Table.Row>
</Table.Body> </Table.Body>
</BasicTable> </BasicTable>
<p className='bio-paragraph'>
{member.public_bio || 'None yet.'}
</p>
{member.member_forms && <p> {member.member_forms && <p>
<a href={staticUrl + '/' + member.member_forms} target='_blank'> <a href={staticUrl + '/' + member.member_forms} target='_blank'>
View application forms View application forms

View File

@ -162,6 +162,7 @@ export function MemberDetail(props) {
{isAdmin(user) ? {isAdmin(user) ?
<AdminMemberInfo result={result} refreshResult={refreshResult} {...props} /> <AdminMemberInfo result={result} refreshResult={refreshResult} {...props} />
: :
<React.Fragment>
<BasicTable> <BasicTable>
<Table.Body> <Table.Body>
<Table.Row> <Table.Row>
@ -175,8 +176,16 @@ export function MemberDetail(props) {
<Table.Cell>Joined:</Table.Cell> <Table.Cell>Joined:</Table.Cell>
<Table.Cell>{member.current_start_date || 'Unknown'}</Table.Cell> <Table.Cell>{member.current_start_date || 'Unknown'}</Table.Cell>
</Table.Row> </Table.Row>
<Table.Row>
<Table.Cell>Public Bio:</Table.Cell>
</Table.Row>
</Table.Body> </Table.Body>
</BasicTable> </BasicTable>
<p className='bio-paragraph'>
{member.public_bio || 'None yet.'}
</p>
</React.Fragment>
} }
</Grid.Column> </Grid.Column>

View File

@ -108,6 +108,12 @@ body {
width: 10rem; width: 10rem;
} }
.bio-paragraph {
white-space: pre-line;
margin-top: -1rem;
margin-left: 1rem;
}
.footer { .footer {
margin-top: -20rem; margin-top: -20rem;