diff --git a/src/components/Quantification.vue b/src/components/Quantification.vue index e897803635e504d072b634b9316d09a0e4252cca..ba75b05763a0d157691f7e521dfdd671033653d7 100644 --- a/src/components/Quantification.vue +++ b/src/components/Quantification.vue @@ -56,7 +56,13 @@ let pestList = JSON.parse(localStorage.getItem(CommonUtil.CONST_STORAGE_PEST_LIST)); let pest = pestList.find(({organismId}) => organismId === this.organism_id); - + if(pest == null) + { + // TODO: i18n this!! + pest = { + observationDataSchema: "{\"$schema\":\"http://json-schema.org/draft-04/schema#\",\"type\":\"object\",\"title\":\" \",\"properties\":{\"number\":{\"title\":\"Antall\",\"type\":\"string\"},\"unit\":{\"title\":\"MÃ¥leenhet\",\"type\":\"string\"}}}" + } + } this.observationDataSchema = JSON.parse(pest.observationDataSchema);