aboutsummaryrefslogtreecommitdiffstats
path: root/web/cobrands/bristol/js.js
blob: 1fc23d61ac5aae9bb4c5cfba984429df9fe4ae4d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
(function(){

if (!fixmystreet.maps) {
    return;
}

var options = {
    wfs_url: "https://maps.bristol.gov.uk/arcgis/services/ext/FixMyStreetSupportData/MapServer/WFSServer",
    wfs_feature: "COD_ASSETS_POINT",
    max_resolution: 0.33072982812632296,
    min_resolution: 0.00001,
    asset_id_field: 'COD_ASSET_ID',
    asset_type: 'spot',
    propertyNames: [ 'COD_ASSET_ID', 'COD_USRN' ],
    attributes: {
        asset_id: 'COD_ASSET_ID',
        usrn: 'COD_USRN'
    },
    geometryName: 'SHAPE'
};

$(fixmystreet.add_assets($.extend({}, options, {
    wfs_feature: "COD_ASSETS_AREA",
    asset_type: 'area',
    asset_category: "Bridges/Subways",
    asset_item: 'bridge/subway'
})));

$(fixmystreet.add_assets($.extend({}, options, {
    asset_category: "Gully/Drainage",
    asset_item: 'gully',
    filter_key: 'COD_ASSET_TYPE',
    filter_value: 'GULLY'
})));

$(fixmystreet.add_assets($.extend({}, options, {
    asset_category: "Grit Bins",
    asset_item: 'grit bin',
    filter_key: 'COD_ASSET_TYPE',
    filter_value: 'GRITBIN'
})));

$(fixmystreet.add_assets($.extend({}, options, {
    asset_category: "Street Lighting",
    asset_item: 'street light',
    filter_key: 'COD_ASSET_TYPE',
    filter_value: 'SL'
})));

})();