Other Category Updates
- Consistent Construction Date between Age and Team categories - Disable unused Verify buttons - Add missing Verify buttons - Add tooltips to Disaster section - Add new fields to database
This commit is contained in:
parent
19c906fcc5
commit
8487ce3afe
@ -304,6 +304,14 @@ export const buildingAttributesConfig = valueType<DataFieldConfig>()({ /* eslint
|
|||||||
edit: true,
|
edit: true,
|
||||||
verify: true,
|
verify: true,
|
||||||
},
|
},
|
||||||
|
sust_retrofit_source_type: {
|
||||||
|
edit: true,
|
||||||
|
verify: true,
|
||||||
|
},
|
||||||
|
sust_retrofit_source_links: {
|
||||||
|
edit: true,
|
||||||
|
verify: true,
|
||||||
|
},
|
||||||
sust_life_expectancy: {
|
sust_life_expectancy: {
|
||||||
edit: false,
|
edit: false,
|
||||||
},
|
},
|
||||||
@ -422,6 +430,14 @@ export const buildingAttributesConfig = valueType<DataFieldConfig>()({ /* eslint
|
|||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
},
|
},
|
||||||
|
extension_source_type: {
|
||||||
|
edit: true,
|
||||||
|
verify: true
|
||||||
|
},
|
||||||
|
extension_source_links: {
|
||||||
|
edit: true,
|
||||||
|
verify: true
|
||||||
|
},
|
||||||
developer_type: {
|
developer_type: {
|
||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
@ -430,6 +446,10 @@ export const buildingAttributesConfig = valueType<DataFieldConfig>()({ /* eslint
|
|||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
},
|
},
|
||||||
|
developer_source_type: {
|
||||||
|
edit: true,
|
||||||
|
verify: true
|
||||||
|
},
|
||||||
developer_source_link: {
|
developer_source_link: {
|
||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
@ -438,6 +458,10 @@ export const buildingAttributesConfig = valueType<DataFieldConfig>()({ /* eslint
|
|||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
},
|
},
|
||||||
|
landowner_source_type: {
|
||||||
|
edit: true,
|
||||||
|
verify: true
|
||||||
|
},
|
||||||
landowner_source_link: {
|
landowner_source_link: {
|
||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
@ -446,6 +470,10 @@ export const buildingAttributesConfig = valueType<DataFieldConfig>()({ /* eslint
|
|||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
},
|
},
|
||||||
|
designers_source_type: {
|
||||||
|
edit: true,
|
||||||
|
verify: true
|
||||||
|
},
|
||||||
designers_source_link: {
|
designers_source_link: {
|
||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
@ -466,6 +494,10 @@ export const buildingAttributesConfig = valueType<DataFieldConfig>()({ /* eslint
|
|||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
},
|
},
|
||||||
|
builder_source_type: {
|
||||||
|
edit: true,
|
||||||
|
verify: true
|
||||||
|
},
|
||||||
builder_source_link: {
|
builder_source_link: {
|
||||||
edit: true,
|
edit: true,
|
||||||
verify: true
|
verify: true
|
||||||
|
@ -106,6 +106,24 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
placeholder={dataFields.date_source.example}
|
placeholder={dataFields.date_source.example}
|
||||||
options={dataFields.date_source.items}
|
options={dataFields.date_source.items}
|
||||||
/>
|
/>
|
||||||
|
{(props.building.date_source == dataFields.date_source.items[0] ||
|
||||||
|
props.building.date_source == dataFields.date_source.items[1] ||
|
||||||
|
props.building.date_source == null) ? <></> :
|
||||||
|
<>
|
||||||
|
<MultiDataEntry
|
||||||
|
title={dataFields.date_link.title}
|
||||||
|
slug="date_link"
|
||||||
|
value={props.building.date_link}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.date_link.tooltip}
|
||||||
|
placeholder="https://..."
|
||||||
|
editableEntries={true}
|
||||||
|
isUrl={true}
|
||||||
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
<hr/>
|
<hr/>
|
||||||
<InfoBox type='warning'>
|
<InfoBox type='warning'>
|
||||||
This section is under development.
|
This section is under development.
|
||||||
@ -331,6 +349,10 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
options={dataFields.date_source.items}
|
options={dataFields.date_source.items}
|
||||||
placeholder={dataFields.date_source.example}
|
placeholder={dataFields.date_source.example}
|
||||||
/>
|
/>
|
||||||
|
{(props.building.date_source == dataFields.date_source.items[0] ||
|
||||||
|
props.building.date_source == dataFields.date_source.items[1] ||
|
||||||
|
props.building.date_source == null) ? <></> :
|
||||||
|
<>
|
||||||
<MultiDataEntry
|
<MultiDataEntry
|
||||||
title={dataFields.date_link.title}
|
title={dataFields.date_link.title}
|
||||||
slug="date_link"
|
slug="date_link"
|
||||||
@ -343,6 +365,8 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
editableEntries={true}
|
editableEntries={true}
|
||||||
isUrl={true}
|
isUrl={true}
|
||||||
/>
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
<hr/>
|
<hr/>
|
||||||
<InfoBox type='warning'>
|
<InfoBox type='warning'>
|
||||||
This section is under development.
|
This section is under development.
|
||||||
@ -373,14 +397,14 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
value=""
|
value=""
|
||||||
mode='view'
|
mode='view'
|
||||||
/>
|
/>
|
||||||
<Verification
|
{/* <Verification
|
||||||
slug="date_link"
|
slug="date_link"
|
||||||
allow_verify={props.user !== undefined && props.building.date_link !== null && !props.edited}
|
allow_verify={props.user !== undefined && props.building.date_link !== null && !props.edited}
|
||||||
onVerify={props.onVerify}
|
onVerify={props.onVerify}
|
||||||
user_verified={props.user_verified.hasOwnProperty("date_link")}
|
user_verified={props.user_verified.hasOwnProperty("date_link")}
|
||||||
user_verified_as={props.user_verified.date_link}
|
user_verified_as={props.user_verified.date_link}
|
||||||
verified_count={props.building.verified.date_link}
|
verified_count={props.building.verified.date_link}
|
||||||
/>
|
/> */}
|
||||||
<DataEntry
|
<DataEntry
|
||||||
title="Source"
|
title="Source"
|
||||||
slug=""
|
slug=""
|
||||||
@ -393,14 +417,14 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
value=""
|
value=""
|
||||||
mode='view'
|
mode='view'
|
||||||
/>
|
/>
|
||||||
<Verification
|
{/* <Verification
|
||||||
slug="date_link"
|
slug="date_link"
|
||||||
allow_verify={props.user !== undefined && props.building.date_link !== null && !props.edited}
|
allow_verify={props.user !== undefined && props.building.date_link !== null && !props.edited}
|
||||||
onVerify={props.onVerify}
|
onVerify={props.onVerify}
|
||||||
user_verified={props.user_verified.hasOwnProperty("date_link")}
|
user_verified={props.user_verified.hasOwnProperty("date_link")}
|
||||||
user_verified_as={props.user_verified.date_link}
|
user_verified_as={props.user_verified.date_link}
|
||||||
verified_count={props.building.verified.date_link}
|
verified_count={props.building.verified.date_link}
|
||||||
/>
|
/> */}
|
||||||
<DataEntry
|
<DataEntry
|
||||||
title="Source"
|
title="Source"
|
||||||
slug=""
|
slug=""
|
||||||
|
@ -10,6 +10,7 @@ import InfoBox from '../../components/info-box';
|
|||||||
|
|
||||||
import { CategoryViewProps } from './category-view-props';
|
import { CategoryViewProps } from './category-view-props';
|
||||||
import { DataEntryGroup } from '../data-components/data-entry-group';
|
import { DataEntryGroup } from '../data-components/data-entry-group';
|
||||||
|
import { MultiDataEntry } from '../data-components/multi-data-entry/multi-data-entry';
|
||||||
|
|
||||||
const EnergyCategoryOptions = ["A", "B", "C", "D", "E", "F", "G"];
|
const EnergyCategoryOptions = ["A", "B", "C", "D", "E", "F", "G"];
|
||||||
const BreeamRatingOptions = [
|
const BreeamRatingOptions = [
|
||||||
@ -98,20 +99,50 @@ const SustainabilityView: React.FunctionComponent<CategoryViewProps> = (props) =
|
|||||||
user_verified_as={props.user_verified.sust_retrofit_date}
|
user_verified_as={props.user_verified.sust_retrofit_date}
|
||||||
verified_count={props.building.verified.sust_retrofit_date}
|
verified_count={props.building.verified.sust_retrofit_date}
|
||||||
/>
|
/>
|
||||||
|
<SelectDataEntry
|
||||||
|
title={dataFields.sust_retrofit_source_type.title}
|
||||||
|
slug="sust_retrofit_source_type"
|
||||||
|
value={props.building.sust_retrofit_source_type}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.sust_retrofit_source_type.tooltip}
|
||||||
|
options={dataFields.sust_retrofit_source_type.items}
|
||||||
|
placeholder={dataFields.sust_retrofit_source_type.example}
|
||||||
|
/>
|
||||||
|
{(props.building.sust_retrofit_source_type == dataFields.sust_retrofit_source_type.items[0] ||
|
||||||
|
props.building.sust_retrofit_source_type == dataFields.sust_retrofit_source_type.items[1] ||
|
||||||
|
props.building.sust_retrofit_source_type == null) ? <></> :
|
||||||
|
<>
|
||||||
|
<MultiDataEntry
|
||||||
|
title={dataFields.sust_retrofit_source_links.title}
|
||||||
|
slug="sust_retrofit_source_links"
|
||||||
|
value={props.building.sust_retrofit_source_links}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.sust_retrofit_source_links.tooltip}
|
||||||
|
placeholder="https://..."
|
||||||
|
editableEntries={true}
|
||||||
|
isUrl={true}
|
||||||
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
|
<hr/>
|
||||||
<DataEntry
|
<DataEntry
|
||||||
title="Date of Significant Retrofits"
|
title="Date of Significant Retrofits"
|
||||||
slug=""
|
slug=""
|
||||||
value=""
|
value=""
|
||||||
mode='view'
|
mode='view'
|
||||||
/>
|
/>
|
||||||
<Verification
|
{/* <Verification
|
||||||
slug="date_link"
|
slug="date_link"
|
||||||
allow_verify={props.user !== undefined && props.building.date_link !== null && !props.edited}
|
allow_verify={props.user !== undefined && props.building.date_link !== null && !props.edited}
|
||||||
onVerify={props.onVerify}
|
onVerify={props.onVerify}
|
||||||
user_verified={props.user_verified.hasOwnProperty("date_link")}
|
user_verified={props.user_verified.hasOwnProperty("date_link")}
|
||||||
user_verified_as={props.user_verified.date_link}
|
user_verified_as={props.user_verified.date_link}
|
||||||
verified_count={props.building.verified.date_link}
|
verified_count={props.building.verified.date_link}
|
||||||
/>
|
/> */}
|
||||||
<DataEntry
|
<DataEntry
|
||||||
title="Source"
|
title="Source"
|
||||||
slug=""
|
slug=""
|
||||||
|
@ -24,6 +24,9 @@ const ResilienceView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
|
|
||||||
return (<>
|
return (<>
|
||||||
<DataEntryGroup name="Building damage assessment tool" collapsed={true} >
|
<DataEntryGroup name="Building damage assessment tool" collapsed={true} >
|
||||||
|
<InfoBox type='warning'>
|
||||||
|
This section is under development.
|
||||||
|
</InfoBox>
|
||||||
<div className={`alert alert-dark`} role="alert" style={{ fontSize: 13, backgroundColor: "#f6f8f9" }}>
|
<div className={`alert alert-dark`} role="alert" style={{ fontSize: 13, backgroundColor: "#f6f8f9" }}>
|
||||||
<i>
|
<i>
|
||||||
This feature is designed as an assessment tool to help communities capture data on the state of buildings following major disasters.
|
This feature is designed as an assessment tool to help communities capture data on the state of buildings following major disasters.
|
||||||
@ -76,7 +79,7 @@ const ResilienceView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
'Other human (blast damage/spills etc.)',
|
'Other human (blast damage/spills etc.)',
|
||||||
'Other'
|
'Other'
|
||||||
]}
|
]}
|
||||||
|
tooltip={dataFields.disaster_type.tooltip}
|
||||||
onChange={props.onChange}
|
onChange={props.onChange}
|
||||||
mode={props.mode}
|
mode={props.mode}
|
||||||
copy={props.copy}
|
copy={props.copy}
|
||||||
@ -93,7 +96,7 @@ const ResilienceView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
'Minimal',
|
'Minimal',
|
||||||
'No damage visible',
|
'No damage visible',
|
||||||
]}
|
]}
|
||||||
|
tooltip={dataFields.disaster_severity.tooltip}
|
||||||
onChange={props.onChange}
|
onChange={props.onChange}
|
||||||
mode={props.mode}
|
mode={props.mode}
|
||||||
copy={props.copy}
|
copy={props.copy}
|
||||||
@ -116,7 +119,7 @@ const ResilienceView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
'Specialist emergency group/charity',
|
'Specialist emergency group/charity',
|
||||||
'Other',
|
'Other',
|
||||||
]}
|
]}
|
||||||
|
tooltip={dataFields.disaster_assessment_method.tooltip}
|
||||||
onChange={props.onChange}
|
onChange={props.onChange}
|
||||||
mode={props.mode}
|
mode={props.mode}
|
||||||
copy={props.copy}
|
copy={props.copy}
|
||||||
|
@ -160,6 +160,14 @@ const SizeView: React.FunctionComponent<CategoryViewProps> = (props) => (
|
|||||||
step={0.1}
|
step={0.1}
|
||||||
min={0}
|
min={0}
|
||||||
/>
|
/>
|
||||||
|
<Verification
|
||||||
|
slug="size_height_eaves"
|
||||||
|
allow_verify={props.user !== undefined && props.building.size_height_eaves !== null}
|
||||||
|
onVerify={props.onVerify}
|
||||||
|
user_verified={props.user_verified.hasOwnProperty("size_height_eaves")}
|
||||||
|
user_verified_as={props.user_verified.size_height_eaves}
|
||||||
|
verified_count={props.building.verified.size_height_eaves}
|
||||||
|
/>
|
||||||
<SelectDataEntry
|
<SelectDataEntry
|
||||||
title={dataFields.size_height_eaves_source_type.title}
|
title={dataFields.size_height_eaves_source_type.title}
|
||||||
slug="size_height_eaves_source_type"
|
slug="size_height_eaves_source_type"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import React, { Fragment } from 'react';
|
import React, { Fragment } from 'react';
|
||||||
import InfoBox from '../../components/info-box';
|
import InfoBox from '../../components/info-box';
|
||||||
import { dataFields } from '../../config/data-fields-config';
|
import { commonSourceTypes, dataFields } from '../../config/data-fields-config';
|
||||||
import SelectDataEntry from '../data-components/select-data-entry';
|
import SelectDataEntry from '../data-components/select-data-entry';
|
||||||
import NumericDataEntry from '../data-components/numeric-data-entry';
|
import NumericDataEntry from '../data-components/numeric-data-entry';
|
||||||
import Verification from '../data-components/verification';
|
import Verification from '../data-components/verification';
|
||||||
@ -42,6 +42,36 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
user_verified_as={props.user_verified.date_year}
|
user_verified_as={props.user_verified.date_year}
|
||||||
verified_count={props.building.verified.date_year}
|
verified_count={props.building.verified.date_year}
|
||||||
/>
|
/>
|
||||||
|
<SelectDataEntry
|
||||||
|
title={dataFields.date_source.title}
|
||||||
|
slug="date_source"
|
||||||
|
value={props.building.date_source}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.date_source.tooltip}
|
||||||
|
options={dataFields.date_source.items}
|
||||||
|
placeholder={dataFields.date_source.example}
|
||||||
|
/>
|
||||||
|
{(props.building.date_source == dataFields.date_source.items[0] ||
|
||||||
|
props.building.date_source == dataFields.date_source.items[1] ||
|
||||||
|
props.building.date_source == null) ? <></> :
|
||||||
|
<>
|
||||||
|
<MultiDataEntry
|
||||||
|
title={dataFields.date_link.title}
|
||||||
|
slug="date_link"
|
||||||
|
value={props.building.date_link}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.date_link.tooltip}
|
||||||
|
placeholder="https://..."
|
||||||
|
editableEntries={true}
|
||||||
|
isUrl={true}
|
||||||
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
|
<hr/>
|
||||||
<LogicalDataEntry
|
<LogicalDataEntry
|
||||||
title={dataFields.has_extension.title}
|
title={dataFields.has_extension.title}
|
||||||
slug="has_extension"
|
slug="has_extension"
|
||||||
@ -73,6 +103,35 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
user_verified_as={props.user_verified.extension_year}
|
user_verified_as={props.user_verified.extension_year}
|
||||||
verified_count={props.building.verified.extension_year}
|
verified_count={props.building.verified.extension_year}
|
||||||
/>
|
/>
|
||||||
|
<SelectDataEntry
|
||||||
|
title={dataFields.extension_source_type.title}
|
||||||
|
slug="extension_source_type"
|
||||||
|
value={props.building.extension_source_type}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.extension_source_type.tooltip}
|
||||||
|
options={dataFields.extension_source_type.items}
|
||||||
|
placeholder={dataFields.extension_source_type.example}
|
||||||
|
/>
|
||||||
|
{(props.building.extension_source_type == dataFields.extension_source_type.items[0] ||
|
||||||
|
props.building.extension_source_type == dataFields.extension_source_type.items[1] ||
|
||||||
|
props.building.extension_source_type == null) ? <></> :
|
||||||
|
<>
|
||||||
|
<MultiDataEntry
|
||||||
|
title={dataFields.extension_source_links.title}
|
||||||
|
slug="extension_source_links"
|
||||||
|
value={props.building.extension_source_links}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.extension_source_links.tooltip}
|
||||||
|
placeholder="https://..."
|
||||||
|
editableEntries={true}
|
||||||
|
isUrl={true}
|
||||||
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
</>
|
</>
|
||||||
) : (null)}
|
) : (null)}
|
||||||
</DataEntryGroup>
|
</DataEntryGroup>
|
||||||
@ -96,6 +155,21 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
user_verified_as={props.user_verified.landowner}
|
user_verified_as={props.user_verified.landowner}
|
||||||
verified_count={props.building.verified.landowner}
|
verified_count={props.building.verified.landowner}
|
||||||
/>
|
/>
|
||||||
|
<SelectDataEntry
|
||||||
|
title={dataFields.landowner_source_type.title}
|
||||||
|
slug="landowner_source_type"
|
||||||
|
value={props.building.landowner_source_type}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.landowner_source_type.tooltip}
|
||||||
|
options={dataFields.landowner_source_type.items}
|
||||||
|
placeholder={dataFields.landowner_source_type.example}
|
||||||
|
/>
|
||||||
|
{(props.building.landowner_source_type == commonSourceTypes[0] ||
|
||||||
|
props.building.landowner_source_type == commonSourceTypes[1] ||
|
||||||
|
props.building.landowner_source_type == null) ? <></> :
|
||||||
|
<>
|
||||||
<MultiDataEntry
|
<MultiDataEntry
|
||||||
title={dataFields.landowner_source_link.title}
|
title={dataFields.landowner_source_link.title}
|
||||||
slug="landowner_source_link"
|
slug="landowner_source_link"
|
||||||
@ -108,6 +182,8 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
editableEntries={true}
|
editableEntries={true}
|
||||||
isUrl={true}
|
isUrl={true}
|
||||||
/>
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
</DataEntryGroup>
|
</DataEntryGroup>
|
||||||
<DataEntryGroup name="Developer data">
|
<DataEntryGroup name="Developer data">
|
||||||
<SelectDataEntry
|
<SelectDataEntry
|
||||||
@ -146,6 +222,21 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
user_verified_as={props.user_verified.developer_name}
|
user_verified_as={props.user_verified.developer_name}
|
||||||
verified_count={props.building.verified.developer_name}
|
verified_count={props.building.verified.developer_name}
|
||||||
/>
|
/>
|
||||||
|
<SelectDataEntry
|
||||||
|
title={dataFields.developer_source_type.title}
|
||||||
|
slug="developer_source_type"
|
||||||
|
value={props.building.developer_source_type}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.developer_source_type.tooltip}
|
||||||
|
options={dataFields.developer_source_type.items}
|
||||||
|
placeholder={dataFields.developer_source_type.example}
|
||||||
|
/>
|
||||||
|
{(props.building.developer_source_type == commonSourceTypes[0] ||
|
||||||
|
props.building.developer_source_type == commonSourceTypes[1] ||
|
||||||
|
props.building.developer_source_type == null) ? <></> :
|
||||||
|
<>
|
||||||
<MultiDataEntry
|
<MultiDataEntry
|
||||||
title={dataFields.developer_source_link.title}
|
title={dataFields.developer_source_link.title}
|
||||||
slug="developer_source_link"
|
slug="developer_source_link"
|
||||||
@ -158,6 +249,8 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
editableEntries={true}
|
editableEntries={true}
|
||||||
isUrl={true}
|
isUrl={true}
|
||||||
/>
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
</DataEntryGroup>
|
</DataEntryGroup>
|
||||||
<DataEntryGroup name="Designer data">
|
<DataEntryGroup name="Designer data">
|
||||||
<MultiDataEntry
|
<MultiDataEntry
|
||||||
@ -179,18 +272,7 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
user_verified_as={props.user_verified.designers}
|
user_verified_as={props.user_verified.designers}
|
||||||
verified_count={props.building.verified.designers}
|
verified_count={props.building.verified.designers}
|
||||||
/>
|
/>
|
||||||
<MultiDataEntry
|
|
||||||
title={dataFields.designers_source_link.title}
|
|
||||||
slug="designers_source_link"
|
|
||||||
value={props.building.designers_source_link}
|
|
||||||
mode={props.mode}
|
|
||||||
copy={props.copy}
|
|
||||||
onChange={props.onChange}
|
|
||||||
tooltip={dataFields.designers_source_link.tooltip}
|
|
||||||
placeholder="https://..."
|
|
||||||
editableEntries={true}
|
|
||||||
isUrl={true}
|
|
||||||
/>
|
|
||||||
<SelectDataEntry
|
<SelectDataEntry
|
||||||
slug='lead_designer_type'
|
slug='lead_designer_type'
|
||||||
title={dataFields.lead_designer_type.title}
|
title={dataFields.lead_designer_type.title}
|
||||||
@ -208,6 +290,36 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
user_verified_as={props.user_verified.lead_designer_type}
|
user_verified_as={props.user_verified.lead_designer_type}
|
||||||
verified_count={props.building.verified.lead_designer_type}
|
verified_count={props.building.verified.lead_designer_type}
|
||||||
/>
|
/>
|
||||||
|
<SelectDataEntry
|
||||||
|
title={dataFields.designers_source_type.title}
|
||||||
|
slug="designers_source_type"
|
||||||
|
value={props.building.designers_source_type}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.designers_source_type.tooltip}
|
||||||
|
options={dataFields.designers_source_type.items}
|
||||||
|
placeholder={dataFields.designers_source_type.example}
|
||||||
|
/>
|
||||||
|
{(props.building.designers_source_type == commonSourceTypes[0] ||
|
||||||
|
props.building.designers_source_type == commonSourceTypes[1] ||
|
||||||
|
props.building.designers_source_type == null) ? <></> :
|
||||||
|
<>
|
||||||
|
<MultiDataEntry
|
||||||
|
title={dataFields.designers_source_link.title}
|
||||||
|
slug="designers_source_link"
|
||||||
|
value={props.building.designers_source_link}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.designers_source_link.tooltip}
|
||||||
|
placeholder="https://..."
|
||||||
|
editableEntries={true}
|
||||||
|
isUrl={true}
|
||||||
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
|
<hr/>
|
||||||
<LogicalDataEntryYesOnly
|
<LogicalDataEntryYesOnly
|
||||||
slug='designer_awards'
|
slug='designer_awards'
|
||||||
title={dataFields.designer_awards.title}
|
title={dataFields.designer_awards.title}
|
||||||
@ -270,6 +382,21 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
user_verified_as={props.user_verified.builder}
|
user_verified_as={props.user_verified.builder}
|
||||||
verified_count={props.building.verified.builder}
|
verified_count={props.building.verified.builder}
|
||||||
/>
|
/>
|
||||||
|
<SelectDataEntry
|
||||||
|
title={dataFields.builder_source_type.title}
|
||||||
|
slug="builder_source_type"
|
||||||
|
value={props.building.builder_source_type}
|
||||||
|
mode={props.mode}
|
||||||
|
copy={props.copy}
|
||||||
|
onChange={props.onChange}
|
||||||
|
tooltip={dataFields.builder_source_type.tooltip}
|
||||||
|
options={dataFields.builder_source_type.items}
|
||||||
|
placeholder={dataFields.builder_source_type.example}
|
||||||
|
/>
|
||||||
|
{(props.building.builder_source_type == commonSourceTypes[0] ||
|
||||||
|
props.building.builder_source_type == commonSourceTypes[1] ||
|
||||||
|
props.building.builder_source_type == null) ? <></> :
|
||||||
|
<>
|
||||||
<MultiDataEntry
|
<MultiDataEntry
|
||||||
title={dataFields.builder_source_link.title}
|
title={dataFields.builder_source_link.title}
|
||||||
slug="builder_source_link"
|
slug="builder_source_link"
|
||||||
@ -281,6 +408,8 @@ const TeamView: React.FunctionComponent<CategoryViewProps> = (props) => {
|
|||||||
editableEntries={true}
|
editableEntries={true}
|
||||||
isUrl={true}
|
isUrl={true}
|
||||||
/>
|
/>
|
||||||
|
</>
|
||||||
|
}
|
||||||
</DataEntryGroup>
|
</DataEntryGroup>
|
||||||
</form>
|
</form>
|
||||||
);
|
);
|
||||||
|
@ -557,6 +557,19 @@ export const dataFields = { /* eslint-disable @typescript-eslint/camelcase */
|
|||||||
tooltip: "Date of last major building refurbishment",
|
tooltip: "Date of last major building refurbishment",
|
||||||
example: 1920,
|
example: 1920,
|
||||||
},
|
},
|
||||||
|
sust_retrofit_source_type: {
|
||||||
|
category: Category.Team,
|
||||||
|
title: "Source type",
|
||||||
|
tooltip: "Source of last significant retrofit data",
|
||||||
|
example: "",
|
||||||
|
items: commonSourceTypes
|
||||||
|
},
|
||||||
|
sust_retrofit_source_links: {
|
||||||
|
category: Category.Team,
|
||||||
|
title: "Source links",
|
||||||
|
tooltip: "URL(s) for last significant retrofit data source(s)",
|
||||||
|
example: ["", "", ""],
|
||||||
|
},
|
||||||
sust_life_expectancy: {
|
sust_life_expectancy: {
|
||||||
category: Category.EnergyPerformance,
|
category: Category.EnergyPerformance,
|
||||||
title: "Expected lifespan for typology",
|
title: "Expected lifespan for typology",
|
||||||
@ -837,6 +850,19 @@ export const dataFields = { /* eslint-disable @typescript-eslint/camelcase */
|
|||||||
tooltip_extension: "This should be the year the extension was built, not the original building",
|
tooltip_extension: "This should be the year the extension was built, not the original building",
|
||||||
example: 2020
|
example: 2020
|
||||||
},
|
},
|
||||||
|
extension_source_type: {
|
||||||
|
category: Category.Team,
|
||||||
|
title: "Source type",
|
||||||
|
tooltip: "Source type for extension data",
|
||||||
|
example: "",
|
||||||
|
items: commonSourceTypes
|
||||||
|
},
|
||||||
|
extension_source_links: {
|
||||||
|
category: Category.Team,
|
||||||
|
title: "Source link(s)",
|
||||||
|
tooltip: "Source link(s) for extension data",
|
||||||
|
example: ["", "", ""],
|
||||||
|
},
|
||||||
developer_type: {
|
developer_type: {
|
||||||
category: Category.Team,
|
category: Category.Team,
|
||||||
title: "What type of developer built the building?",
|
title: "What type of developer built the building?",
|
||||||
@ -858,6 +884,13 @@ export const dataFields = { /* eslint-disable @typescript-eslint/camelcase */
|
|||||||
tooltip: "Free text. First name, space, then Last name",
|
tooltip: "Free text. First name, space, then Last name",
|
||||||
example: ["", "", ""],
|
example: ["", "", ""],
|
||||||
},
|
},
|
||||||
|
developer_source_type: {
|
||||||
|
category: Category.Team,
|
||||||
|
title: "Source type",
|
||||||
|
tooltip: "Source type for developer data",
|
||||||
|
example: "",
|
||||||
|
items: commonSourceTypes
|
||||||
|
},
|
||||||
developer_source_link: {
|
developer_source_link: {
|
||||||
category: Category.Team,
|
category: Category.Team,
|
||||||
title: "Source links for developer(s)",
|
title: "Source links for developer(s)",
|
||||||
@ -870,10 +903,17 @@ export const dataFields = { /* eslint-disable @typescript-eslint/camelcase */
|
|||||||
tooltip: "Free text. First name, space, then Last name",
|
tooltip: "Free text. First name, space, then Last name",
|
||||||
example: ["", "", ""],
|
example: ["", "", ""],
|
||||||
},
|
},
|
||||||
|
landowner_source_type: {
|
||||||
|
category: Category.Team,
|
||||||
|
title: "Source type",
|
||||||
|
tooltip: "Source type for landowner data",
|
||||||
|
example: "",
|
||||||
|
items: commonSourceTypes
|
||||||
|
},
|
||||||
landowner_source_link: {
|
landowner_source_link: {
|
||||||
category: Category.Team,
|
category: Category.Team,
|
||||||
title: "Source links for landowner(s)",
|
title: "Source link(s)",
|
||||||
tooltip: "URL for source for landowner(s)",
|
tooltip: "URL(s) for source for landowner data",
|
||||||
example: ["", "", ""],
|
example: ["", "", ""],
|
||||||
},
|
},
|
||||||
designers: {
|
designers: {
|
||||||
@ -882,6 +922,13 @@ export const dataFields = { /* eslint-disable @typescript-eslint/camelcase */
|
|||||||
tooltip: "Free text. First name, space, then Last name",
|
tooltip: "Free text. First name, space, then Last name",
|
||||||
example: ["", "", ""],
|
example: ["", "", ""],
|
||||||
},
|
},
|
||||||
|
designers_source_type: {
|
||||||
|
category: Category.Team,
|
||||||
|
title: "Source type",
|
||||||
|
tooltip: "Source type for designer data",
|
||||||
|
example: "",
|
||||||
|
items: commonSourceTypes
|
||||||
|
},
|
||||||
designers_source_link: {
|
designers_source_link: {
|
||||||
category: Category.Team,
|
category: Category.Team,
|
||||||
title: "Source links for designer(s)",
|
title: "Source links for designer(s)",
|
||||||
@ -918,6 +965,13 @@ export const dataFields = { /* eslint-disable @typescript-eslint/camelcase */
|
|||||||
title: "Name of builder/construction team",
|
title: "Name of builder/construction team",
|
||||||
example: ["", "", ""],
|
example: ["", "", ""],
|
||||||
},
|
},
|
||||||
|
builder_source_type: {
|
||||||
|
category: Category.Team,
|
||||||
|
title: "Source type",
|
||||||
|
tooltip: "Source type for builder data",
|
||||||
|
example: "",
|
||||||
|
items: commonSourceTypes
|
||||||
|
},
|
||||||
builder_source_link: {
|
builder_source_link: {
|
||||||
category: Category.Team,
|
category: Category.Team,
|
||||||
title: "Source for builder/construction team",
|
title: "Source for builder/construction team",
|
||||||
@ -935,23 +989,26 @@ export const dataFields = { /* eslint-disable @typescript-eslint/camelcase */
|
|||||||
},
|
},
|
||||||
disaster_type: {
|
disaster_type: {
|
||||||
category: Category.Resilience,
|
category: Category.Resilience,
|
||||||
title: "What type of disaster management do you wish to collect data for?",
|
title: "Disaster type",
|
||||||
|
tooltip: "What type of disaster management do you wish to collect data for?",
|
||||||
example: "Flood"
|
example: "Flood"
|
||||||
},
|
},
|
||||||
disaster_severity: {
|
disaster_severity: {
|
||||||
category: Category.Resilience,
|
category: Category.Resilience,
|
||||||
title: "How severe do you assess the damage to be?",
|
title: "How severe do you assess the damage to be?",
|
||||||
|
tooltip: "Best estimate for the severity of damage to the building",
|
||||||
example: "Building destroyed"
|
example: "Building destroyed"
|
||||||
},
|
},
|
||||||
disaster_assessment_method: {
|
disaster_assessment_method: {
|
||||||
category: Category.Resilience,
|
category: Category.Resilience,
|
||||||
title: "Please add a method of assessment",
|
title: "Method of assessment",
|
||||||
|
tooltip: "Please add a Best estimate for the severity of damage to the building",
|
||||||
example: "Citizen/Passerby by eye"
|
example: "Citizen/Passerby by eye"
|
||||||
},
|
},
|
||||||
disaster_source_link: {
|
disaster_source_link: {
|
||||||
category: Category.Resilience,
|
category: Category.Resilience,
|
||||||
title: "Please add a source link to official documentation/photographic evidence where applicable",
|
title: "Source link(s)",
|
||||||
tooltip: "URL for data sources(s)",
|
tooltip: "Please add a source link(s) to official documentation/photographic evidence where applicable",
|
||||||
example: ["", "", ""],
|
example: ["", "", ""],
|
||||||
},
|
},
|
||||||
disaster_start_date: {
|
disaster_start_date: {
|
||||||
|
@ -14,3 +14,8 @@ ALTER TABLE buildings DROP COLUMN IF EXISTS size_height_eaves;
|
|||||||
ALTER TABLE buildings DROP COLUMN IF EXISTS size_width_frontage_source_type;
|
ALTER TABLE buildings DROP COLUMN IF EXISTS size_width_frontage_source_type;
|
||||||
ALTER TABLE buildings DROP COLUMN IF EXISTS size_width_frontage_source_links;
|
ALTER TABLE buildings DROP COLUMN IF EXISTS size_width_frontage_source_links;
|
||||||
ALTER TABLE buildings DROP COLUMN IF EXISTS survival_source_links;
|
ALTER TABLE buildings DROP COLUMN IF EXISTS survival_source_links;
|
||||||
|
ALTER TABLE buildings DROP COLUMN IF EXISTS landowner_source_type;
|
||||||
|
ALTER TABLE buildings DROP COLUMN IF EXISTS designers_source_type;
|
||||||
|
ALTER TABLE buildings DROP COLUMN IF EXISTS builder_source_type;
|
||||||
|
ALTER TABLE buildings DROP COLUMN IF EXISTS extension_source_type;
|
||||||
|
ALTER TABLE buildings DROP COLUMN IF EXISTS extension_source_links;
|
||||||
|
@ -16,3 +16,8 @@ ALTER TABLE buildings ADD COLUMN IF NOT EXISTS size_floor_area_source_links text
|
|||||||
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS size_width_frontage_source_type text;
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS size_width_frontage_source_type text;
|
||||||
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS size_width_frontage_source_links text[];
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS size_width_frontage_source_links text[];
|
||||||
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS survival_source_links text[];
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS survival_source_links text[];
|
||||||
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS landowner_source_type text;
|
||||||
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS designers_source_type text;
|
||||||
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS builder_source_type text;
|
||||||
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS extension_source_type text;
|
||||||
|
ALTER TABLE buildings ADD COLUMN IF NOT EXISTS extension_source_links text[];
|
Loading…
Reference in New Issue
Block a user