File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change 2323 * Modified by: Daniel Calvo - ATOS Research & Innovation
2424 */
2525
26- const LOCATION_TYPE = 'geo:point' ;
2726const LOCATION_DEFAULT = '0, 0' ;
28- const DATETIME_TYPE = 'DateTime' ;
2927const DATETIME_DEFAULT = '1970-01-01T00:00:00.000Z' ;
3028const ATTRIBUTE_DEFAULT = ' ' ;
3129
@@ -36,10 +34,18 @@ const ATTRIBUTE_DEFAULT = ' ';
3634 * @return {String } A default value to use in the entity
3735 */
3836function getInitialValueForType ( type ) {
39- switch ( type ) {
40- case LOCATION_TYPE :
37+ switch ( type . toLowerCase ( ) ) {
38+ case 'geoproperty' :
4139 return LOCATION_DEFAULT ;
42- case DATETIME_TYPE :
40+ case 'point' :
41+ return LOCATION_DEFAULT ;
42+ case 'geo:point' :
43+ return LOCATION_DEFAULT ;
44+ case 'datetime' :
45+ return DATETIME_DEFAULT ;
46+ case 'date' :
47+ return DATETIME_DEFAULT ;
48+ case 'time' :
4349 return DATETIME_DEFAULT ;
4450 default :
4551 return ATTRIBUTE_DEFAULT ;
You can’t perform that action at this time.
0 commit comments