diff options
-rw-r--r-- | web/cobrands/bathnes/assets.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/web/cobrands/bathnes/assets.js b/web/cobrands/bathnes/assets.js index aa06a6fbb..f508ca97c 100644 --- a/web/cobrands/bathnes/assets.js +++ b/web/cobrands/bathnes/assets.js @@ -206,11 +206,16 @@ fixmystreet.assets.add(fixmystreet.maps.banes_defaults, { asset_type: 'road', all_categories: true, // Not really, but want to allow on all but one, not stop no_asset_msg_id: '#js-not-a-road', + cat_map: { + 'Damage to pavement': 'pavement', + 'Damage to road': 'road' + }, actions: { found: fixmystreet.message_controller.road_found, not_found: function(layer) { var cat = $('select#form_category').val(); - if (cat === 'Damage to road') { + if (cat === 'Damage to pavement' || cat === 'Damage to road') { + layer.fixmystreet.asset_item = layer.fixmystreet.cat_map[cat]; fixmystreet.message_controller.road_not_found(layer); } else { fixmystreet.message_controller.road_found(layer); |