Eniro.Profile = {
    id: "fi",
    languageCode: "fi_fi",
    name: "Eniro.fi",
    layers: [ 'LAYER_MAP', 'LAYER_AERIAL', 'LAYER_HYBRID', 'LAYER_STREETVIEW', 'LAYER_OBLIQUE', 'LAYER_YELLOWSPLATTER' ],
    zoomLevels: {
        map: { min: 4, max: 17 },
        aerial: { min: 4, max: 10 },
        hybrid: { min: 4, max: 10 },
        nautical: { min: 4, max: 17 }
    },
    search: {
        fields: {
            where: {
                type: 'text',
                tabindex: '1',
                placeholder: '%{where-caption}',
                autofocus: 'autofocus'
            },
            q: {
                type: 'text',
                tabindex: '2',
                placeholder: '%{what-caption}'
            },
            p: {
                type: 'hidden',
                value: 'yp_fi'
            },
            disable_bought_area: {
                type: 'hidden',
                value: '1'
            },
            ap: {
                type: 'hidden',
                value: 'yp_fi'
            },
            pageSize: {//optional parameter
                type: 'hidden',
                value: '20'
            }
        },
        location: {
            field: 'where',
            provider: 'geo_fi',
            reset: true,
            zoomLevelKey: 'scale',
            zoomLevels: {
                '0': 8,
                '1': 9,
                '2': 10,
                '3': 11,
                '4': 12,
                '5': 13,
                '6': 14,
                '7': 15
            }
        },
        splatterMap: {
            "yp_fi": "yp_fi_sp"
        },
        defaultProvider: 'yp_fi'
    },
    // disable at-this-address reverse_lookup_providers: ['yp_fi'], 
    geoSuggest: {
        fieldId: 'where',
        provider: 'geo_sug_fi'
    },
    providers: {
        yp_fi: {
            id: "company",
            icon: "yellow",
            popup: "yellow",
            properties: {
                data: {
                    addressObject: 'e:address',
                    street: 'e:street_name',
                    city: 'e:post_area',
                    contents: 'content'
                }
            }
        },
        geo_fi: {
            id: "address",
            icon: "address",
            popup: "address",
            properties: {
                data: {
                    addressObject: 'address',
                    street: 'streetName',
                    streetNumber: 'streetNumber',
                    city: 'city',
                    postArea: 'postArea'
                }
            }
        },
        yp_ptr_fi: {
            id: 'predefinedyp',
            icon: "yellow",
            popup: "yellow",
            sellable: 'preDefinedYP',
            properties: {
                data: {
                    addressObject: 'e:address',
                    street: 'e:street_name',
                    streetNumber: 'e:street_number',
                    city: 'e:post_area',
                    contents: 'content'
                }
            }
        }
    },
    map: {
        bounds: "13, 56.5, 14, 67.5",
        zoomLevels: {
            '0': 5,
            '1': 7,
            '2': 9,
            '3': 11,
            '4': 12,
            '5': 13,
            '6': 14,
            '7': 15
        }
    },
    marker: {
        accentuated: {
            style: {
                graphicWidth: 16,
                graphicHeight: 16,
                graphicXOffset: 2,
                graphicYOffset: -30,
                backgroundWidth: 46,
                backgroundHeight: 38
            }
        },
        predefined: {
            iconStyle: {
                graphicWidth: 46,
                graphicHeight: 38,
                graphicXOffset: -21,
                graphicYOffset: -33
            },
            aggregateIconStyle: {
                graphicWidth: 16,
                graphicHeight: 16,
                graphicXOffset: -9,
                graphicYOffset: -31,
                backgroundWidth: 46,
                backgroundHeight: 38,
                backgroundXOffset: -21,
                backgroundYOffset: -33
            }
        }
    },
    oblique: {
        zoomLevels: {
            '1': 0,
            '2': 1,
            '3': 2
        },
        overviewZoomLevels: [14, 15, 16],
        defaultOrientation: 'N',
        cities: [{
            id: "espoo",
            lat: 60.20482,
            lon: 24.653642
        }, {
            id: "helsinki",
            lat: 60.169845,
            lon: 24.938551
        }, {
            id: "hameenlinna",
            lat: 60.993641,
            lon: 24.467283
        }, {
            id: "joensuu",
            lat: 62.600986,
            lon: 29.763548
        }, {
            id: "jyvaskyla",
            lat: 62.242642,
            lon: 25.747383
        }, {
            id: "kaarina",
            lat: 60.407169,
            lon: 22.368241
        }, {
            id: "kauniainen",
            lat: 60.211724,
            lon: 24.728879
        }, {
            id: "kerava",
            lat: 60.403731,
            lon: 25.104924
        }, {
            id: "kotka",
            lat: 60.466623,
            lon: 26.946
        }, {
            id: "kuopio",
            lat: 62.893335,
            lon: 27.679339
        }, {
            id: "lahti",
            lat: 60.982654,
            lon: 25.661465
        }, {
            id: "lappeenranta",
            lat: 61.058321,
            lon: 28.186213
        }, {
            id: "oulu",
            lat: 65.012615,
            lon: 25.471453
        }, {
            id: "pori",
            lat: 61.4852,
            lon: 21.797445
        }, {
            id: "tampere",
            lat: 61.49816,
            lon: 23.761056
        }, {
            id: "turku",
            lat: 60.450716,
            lon: 22.266551
        }, {
            id: "vaasa",
            lat: 63.095199,
            lon: 21.61637
        }, {
            id: "vantaa",
            lat: 60.293765,
            lon: 25.040088
        }]
    },
    streetview: {
        cities: [{
            id: "helsinki",
            lat: 60.167983,
            lon: 24.956117,
            heading: 45
        }, {
            id: "tampere",
            lat: 61.495217,
            lon: 23.769150,
            heading: 110
        }, {
            id: "turku",
            lat: 60.452517,
            lon: 22.267283,
            heading: 20
        }]
    },
    aerial: {
        zoomLevels: {
            '0': 4,
            '1': 6,
            '2': 8,
            '3': 9,
            '4': 10,
            '5': 11,
            '6': 12,
            '7': 13,
            '8': 14,
            '9': 15
        }  
    },
    init: {
        coordinates: {
            lon: '26.41',
            lat: '63.44'
        },
        // This _HAS_ to be an integer, not a String (or we'll get zoomlevel "5" + 1 = "51" when we double-click.. :))
        zoomLevel: 5,
        mode: 'search'
    },
    showOnMap: {
        collapsed: false, // Whether the show-on-map menu should be expanded by default.
        layers: [
            'FITraffic',
            'FICamera'
        ]
    },
    sellable: {
        preDefinedYP: {
            minZoom: 1,
            provider: 'yp_ptr_fi',
            nameIndex: 'e:company_name',
            options: [{
                title: 'Ottopiste',
                linkId: '8786367',
                marker: 'Otto'
            }],
            iconStyle: {
                graphicWidth: 46,
                graphicHeight: 38,
                graphicXOffset: -21,
                graphicYOffset: -33
            },
            aggregateIconStyle: {
                graphicWidth: 46,
                graphicHeight: 38,
                graphicXOffset: -21,
                graphicYOffset: -33
            }
        },
        routeRectangle: '2135',
        routeContextRectangle: '2894',
        smallRouteBanner: '2960',
        searchRectangle: '2893',
        geoResultRectangle: '2910',
        streetViewSponsor: '3137',
        obliqueSponsor: '3138'
    },
    postalCodeMinSize: 5,
    statistics: [
        {
            type: 'img',
            events: {
                page: {
                    search:     'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-map_search/',
                    route:      'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-02-route_search/',
                    draw:       'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-03-draw_search/',
                    streetview: 'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-03-streetview_search/',
                    oblique:    'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-04-oblique_search/'
                },
                content: {
                    yp:         'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-05-search_yp/',
                    wp:         'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-06-search_wp/',
                    geo:        'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-07-search_geo/',
                    route:      'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-08-search_route/',
                    streetview: 'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-09-streetview_loaded_panorama/',
                    oblique:    'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-10-oblique_loaded_new_layer/'
                },
                print: {
                    search:     'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-11-print_search/',
                    route:      'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-12-print_route/',
                    draw:       'http://statistik-gallup.net/V11***eniro2_fi/fi/ISO-8859-1/tmsec=01-eniro_finland_total&amp;tmsec=04-eniro_fi&amp;tmsec=04-20-search_total&amp;tmsec=04-05-01-map&amp;tmsec=04-05-12-print_draw/'
                },
                navigate: {
                    _default: false
                }
            }
        },
        {
            type: 'addax',
            events: {
                page: {
                    _default: false
                },
                content: {
                    yp: 'search'
                },
                contentItem: {
                    yp: 'search'
                },
                print: {
                    _deafult: false
                },
                navigate: {
                    itemRoute: 'route',
                    itemHomepage: 'homepage',
                    openPredefinedYpPopup: 'map_icon',
                    _default: false
                }
            }
        },
        {
            type: 'adform2',
            script: 'https://track.adform.net/logpoint/',
            events: {
                page: {
                    _default: [12425, 73403]
                },
                navigate: {
                    search: [12425, 73404, ['']],
                    route: [12425, 73405, ['']],
                    draw: [12425, 73406, ['']]
                },
                contentItem: {
                    selected: [12425, 73407, ['']]
                }
            }
        }
    ],
    controls:[
        "StatisticsController",
        {
            className: "OpenLayers.Control.Navigation",
            options: {
                dragPanOptions: {
                    stopDown: false
                }
            }
        },
        {
            className: "OpenLayers.Control.KeyboardDefaults",
            options: {
                slideFactor: 500
            }
        },
        "ProgressWhirl",
        "SearchZoomController",
        "StreetViewController",
        "ObliqueController",
        "ObliqueMissing",
        "ObliqueCopyright",
        "ObliqueView",
        "Control.Crashers",
        {
            className: "GPS",
            activate: false
        },
        "RouteController",
        "RouteGeometryView",
        "RouteMarkersView",
        "StreetViewView",
        "RightClickHandler",
        "UrlTranslatorController",
        {
            className: "EventLogger",
            requestParameterTrigger: {
                keys: ["eventLogger"],
                values: ["*"]
            }
        },
        {
            className: "ControlBarView",
            idKey: "LAYERBAR",
            options: {
                placement: "top"
            },
            controls: {
                center: [{
                    className: "LayerBarView",
                    customControls: ["ObliqueLayerbarButton", "StreetViewLayerbarButton"]
                }],
                right: ["ShowOnMapControl"]
            }
        },
        {
            className: "ControlBarView",
            idKey: "CONTROLBAR_FOOTER",
            options: {
                placement: "bottom",
                underlay: true
            },
            controls: {
                left: ["ScaleLine"],
                right: ["FooterView"]
            }
        },
        {
            className: "ControlBarView",
            idKey: "CONTROLBAR_ZOOM",
            options: {
                placement: "bottom"
            },
            controls: {
                center: ["ZoomBarView"]
            }
        },
        {
            className: "ControlBarView",
            idKey: "CONTROLBAR_TOP",
            options: {
                placement: "top",
                underlay: true
            },
            controls: {
                left: [{
                    className: "ModeSwitchingTabNavigatorView",
                    idKey: "TABNAVIGATOR_MAIN",
                    controls: [{
                        className: "SearchTabView",
                        idKey: "TABVIEW_SEARCH"
                    }, {
                        className: "RouteTabView",
                        idKey: "TABVIEW_ROUTE"
                    }, {
                        className: "DrawTabView",
                        idKey: "TABVIEW_DRAW"
                    }]
                }],
                right: [{
                    className: "ToolbarView",
                    idKey: "TOOLBARVIEW_COMMUNITY",
                    controls: [{
                        className: "PrintTool",
                        idKey: "COMMUNITY_PRINT"
                    }, {
                        className: "ShareTool",
                        idKey: "COMMUNITY_SHARE"
                    }, {
                        className: "MapStateTool",
                        idKey: "COMMUNITY_DA_MAPSTATE",
                        requestParameterTrigger: {
                            keys: ["finnishDa"],
                            values: ["*"]
                        }
                    }, {
                        className: "LinkTool",
                        idKey: "COMMUNITY_LINK",
                        requestParameterTrigger: {
                            keys: ["finnishDa"],
                            values: [null]
                        }
                    }, {
                        className: "SendMailTool",
                        idKey: "COMMUNITY_SEND_MAIL"
                    }, {
                        className: "SendSmsTool",
                        idKey: "COMMUNITY_SEND_SMS"
                    }]
                }]
            }
        }
    ]
};
