Changeset 405 in tmcsimulator for trunk/webapps/cptms/js/cctvLayer.js
- Timestamp:
- 05/15/2019 02:10:45 PM (7 years ago)
- File:
-
- 1 edited
-
trunk/webapps/cptms/js/cctvLayer.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/webapps/cptms/js/cctvLayer.js
r357 r405 63 63 nearVDS = map.data.getFeatureById(event.feature.getProperty("nearVDS")); 64 64 currentColor = nearVDS.getProperty("color"); 65 // Currently, Fast and Slow images are stored in separate folders. 66 // As Neil gets actual images collated, we will change this to a file name scheme 65 // file name scheme 67 66 // rte-id-velocity.jpg 68 67 // rte is route number, e.g., 055 69 68 // id is 4-digit camera id, e.g., 0012 70 69 // vel is traffic velocity: "freeflow", "slow", or "stopped" 71 var imgDir = "CCTVFast/"; 72 if (currentColor == "red" || currentColor == "yellow") 73 { 74 imgDir = "CCTVSlow/" 75 } 76 var label = "freeflow"; 70 var imgDir = "CCTV/"; 71 var label = "-day-freeflow"; 77 72 if (currentColor == "red") 78 73 { 79 label = " stopped";74 label = "-day-stopped"; 80 75 } 81 76 if (currentColor == "yellow") 82 77 { 83 label = " slow";78 label = "-day-slow"; 84 79 } 85 80 … … 92 87 // image from fast or slow directories 93 88 { 94 cctv_infowindow.setContent('<div style="font-weight:bold;font-family: monospace">' + cctvIndex + " " + cctvLocation + " " +label+ "<BR>" + imgTag + imgDir + cctvIndex + '.jpg">' + "</div>");89 cctv_infowindow.setContent('<div style="font-weight:bold;font-family: monospace">' + cctvIndex + " " + cctvLocation + " " +label+ "<BR>" + imgTag + imgDir + cctvIndex + label +'.jpg">' + "</div>"); 95 90 } 96 91 cctv_infowindow.setPosition(event.feature.getGeometry().get());
Note: See TracChangeset
for help on using the changeset viewer.
