{ "id": "72", "displayName": "Survey Control (Existing)", "shortDisplayName": null, "description": "", "connectionString": "url=https://gis.maps.mississauga.ca:6443/arcgis/rest/services/Survey_Control/MapServer", "copyright": "", "hasAttributionData": false, "serviceType": "Dynamic", "serviceFunction": "Operational", "baseMapGroup": null, "baseMapGroupIndex": "", "baseMapGroupIsMutuallyExclusive": false, "opacity": 1, "visible": true, "initiallyVisible": true, "drawingBehavior": "MapService", "iconUri": null, "includeInLayerList": true, "defaultAllowSymbolization": true, "isExpanded": true, "updateInterval": null, "dataProvider": null, "disableClientCaching": null, "serviceTag": "fRp+t6N+G/bsOAEMBsyA8pvCtzo97XOzyq0XGY76yMs=", "identifiable": null, "includeMosaicDatasetValues": null, "includeCatalogItems": null, "includeInLegend": null, "startTime": null, "endTime": null, "serverVersion": "11.1", "failureAction": "Warn", "failureTimeout": null, "requestEncoding": null, "supportsDynamicLayers": true, "hasLayerCatalog": false, "format": null, "themeSettings": [ { "themeID": "0" }, { "themeID": "1" } ], "layerHyperlinks": [], "tileInfo": {}, "instantSearch": false, "layers": [ { "id": "2", "name": "Survey Control (Existing)", "nativeID": "2", "displayName": "Survey Controls", "description": "", "defaultVisibility": true, "featureType": "Point", "type": "FeatureLayer", "maxScale": 100, "minScale": 110000, "visible": true, "initiallyVisible": false, "showMapTips": true, "identifiable": true, "queryable": true, "searchable": true, "supportsIdentify": true, "supportsQuery": true, "canCopyFeature": true, "snappable": true, "snappingEnabled": false, "hasAttachments": true, "featureZoomFactor": null, "featureZoomScale": 2257, "featureBorderColor": null, "featureBorderWidth": null, "featureFillColor": null, "showFeatureHyperlinks": "ShowAll", "iconUri": null, "includeInLayerList": true, "includeInLegend": true, "allowSymbolization": true, "legendUrl": null, "styleName": null, "drawIndex": null, "canToggleLabels": true, "showLabels": true, "dataProvider": null, "timeZoneId": "Etc/UTC", "featureLabel": "Survey Control {Monument}", "featureDescription": "*** DO NOT USE (Kept for reference only, or until the feature service can be swapped for the map service externally) ***\r\n
Monument Number: {PDF}
Agency: {AgencyDesc}
Status: {Status} | {LastFoundUTC}

{Comments}
{Attachments}
{Nearest}

{Email}
", "featureLongDescription": "
Monument Number: {PDF}
Monument Type: {MonDesc}
Agency: {AgencyDesc}
{LastFoundUTC}

{Comments}
{Attachments}
{Nearest}

{Email}
", "displayField": "Monument", "primaryKeyField": "OBJECTID", "fullExtent": { "xmin": -8885753.6193403769, "ymin": 5382829.4292793879, "xmax": -8854071.4664179832, "ymax": 5428621.7471355293, "spatialReference": { "wkid": 102100 } }, "parentLayerId": null, "subLayerIds": [], "hasReports": false, "hasDataLinks": false, "fields": [ { "displayName": "OBJECTID", "uniqueValue": true, "name": "OBJECTID", "alias": "OBJECTID", "visible": false, "dataType": "Int32", "classBreaks": true }, { "displayName": "Monument Number", "uniqueValue": true, "name": "Monument", "alias": "Monument Number", "visible": true, "dataType": "String", "searchable": true, "classBreaks": false }, { "displayName": "Monument Type", "uniqueValue": true, "name": "MonType", "alias": "Monument Type", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "Agency", "uniqueValue": true, "name": "Agency", "alias": "Agency", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "Easting", "uniqueValue": true, "name": "Easting", "alias": "Easting", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Northing", "uniqueValue": true, "name": "Northing", "alias": "Northing", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Latitude", "uniqueValue": true, "name": "Latitude", "alias": "Latitude", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "Longitude", "uniqueValue": true, "name": "Longitude", "alias": "Longitude", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "Scale Factor", "uniqueValue": true, "name": "ScaleFactor", "alias": "Scale Factor", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Easting_CSRS", "uniqueValue": true, "name": "Easting_CSRS", "alias": "Easting_CSRS", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Northing_CSRS", "uniqueValue": true, "name": "Northing_CSRS", "alias": "Northing_CSRS", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Latitude_CSRS", "uniqueValue": true, "name": "Latitude_CSRS", "alias": "Latitude_CSRS", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "Longitude_CSRS", "uniqueValue": true, "name": "Longitude_CSRS", "alias": "Longitude_CSRS", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "ScaleFactor_CSRS", "uniqueValue": true, "name": "ScaleFactor_CSRS", "alias": "ScaleFactor_CSRS", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "CSRS_Version", "uniqueValue": true, "name": "CSRS_Version", "alias": "CSRS_Version", "visible": true, "dataType": "Int16", "classBreaks": true }, { "displayName": "Horizontal Control Order", "uniqueValue": true, "name": "HorizontalOrder", "alias": "Horizontal Control Order", "visible": true, "dataType": "Int16", "classBreaks": true }, { "displayName": "Elevation", "uniqueValue": true, "name": "Elevation", "alias": "Elevation", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Vertical Control Order", "uniqueValue": true, "name": "VerticalOrder", "alias": "Vertical Control Order", "visible": true, "dataType": "Int16", "classBreaks": true }, { "displayName": "Description", "uniqueValue": true, "name": "Description", "alias": "Description", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "Status", "uniqueValue": true, "name": "Status", "alias": "Status", "visible": true, "dataType": "Int16", "classBreaks": true }, { "displayName": "Last Found", "uniqueValue": true, "name": "LastFound", "alias": "Last Found", "visible": true, "dataType": "DateTime", "classBreaks": false }, { "displayName": "Last Printed", "uniqueValue": true, "name": "LastPrinted", "alias": "Last Printed", "visible": true, "dataType": "DateTime", "classBreaks": false }, { "displayName": "Notes", "uniqueValue": true, "name": "Notes", "alias": "Notes", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "Actionable", "uniqueValue": true, "name": "Actionable", "alias": "Actionable", "visible": true, "dataType": "Int16", "classBreaks": true }, { "displayName": "Easting74", "uniqueValue": true, "name": "Easting74", "alias": "Easting74", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Northing74", "uniqueValue": true, "name": "Northing74", "alias": "Northing74", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Scale Factor74", "uniqueValue": true, "name": "ScaleFactor74", "alias": "Scale Factor74", "visible": true, "dataType": "Double", "classBreaks": true }, { "displayName": "Shape", "uniqueValue": false, "name": "Shape", "alias": "Shape", "visible": true, "dataType": "Object", "classBreaks": false }, { "displayName": "GlobalID", "uniqueValue": true, "name": "GlobalID", "alias": "GlobalID", "visible": true, "dataType": "Guid", "classBreaks": false }, { "displayName": "created_user", "uniqueValue": true, "name": "created_user", "alias": "created_user", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "created_date", "uniqueValue": true, "name": "created_date", "alias": "created_date", "visible": true, "dataType": "DateTime", "classBreaks": false }, { "displayName": "last_edited_user", "uniqueValue": true, "name": "last_edited_user", "alias": "last_edited_user", "visible": true, "dataType": "String", "classBreaks": false }, { "displayName": "last_edited_date", "uniqueValue": true, "name": "last_edited_date", "alias": "last_edited_date", "visible": true, "dataType": "DateTime", "classBreaks": false } ], "featureHyperlinks": [], "layerHyperlinks": [], "arcadeExpressions": [ { "expression": "return Decode($feature.Agency,\r\n '001', 'NRCan - Geodetic Survey of Canada',\r\n '005', 'MTO - Engineering and Architectural Branch',\r\n '007', 'Public Works - Engineering Design Directorate',\r\n '008', 'MTO - Land Surveys',\r\n '009', 'MTO - Engineering Surveys',\r\n '020', 'City of Toronto (pre-1975: Metro Toronto, Dept of Roads)',\r\n '042', 'City of Brampton',\r\n '075', 'City of Mississauga',\r\n 'Unknown');\r\n//IIf(IsEmpty($feature.Agency), \"Unknown\", DomainName($feature, 'Agency'));", "token": "AgencyDesc" }, { "expression": "return Count(Attachments($feature));", "token": "AttachCount" }, { "expression": "var result = \"<\" + \"br/>\"; // + \"<\" + \"span style='font-weight: bold; text-decoration-line: underline;'>Attachments:<\" + \"/span><\" + \"br/>\";\r\n\r\nvar server = \"https://www6.mississauga.ca/BMHCM/\" + Decode($feature.MONTYPE, 'BM', 'Benchmarks', 'HorizontalControl') + \"/Images/\";\r\nvar attachUrl = server + \"R\" + $feature.MONUMENT + \".jpg\";\r\n\r\nresult += \"<\" + \"a href='\" + attachUrl + \"' target=_'blank'><\" + \"img width='300' height='300' align='center' src='\" + attachUrl + \"'/><\" + \"/a>\" + TextFormatting.NewLine;\r\nresult += \"<\" + \"span style='font-style: italic;'>Click to enlarge<\" + \"/span>\";\r\nreturn result;\r\n\r\nvar a = Attachments($feature);\r\nif (Count(a) > 0) {\r\n var attachUrl;\r\n for (var i in a) {\r\n attachUrl = server + $feature.OBJECTID + \"/attachments/\" + a[i].id;\r\n result += \"<\" + \"a href='\" + attachUrl + \"' target=_'blank'><\" + \"img width='300' height='300' align='center' src='\" + attachUrl + \"'/><\" + \"/a>\" + TextFormatting.NewLine;\r\n }\r\n result += \"<\" + \"span style='font-style: italic;'>Click to enlarge<\" + \"/span>\";\r\n return result;\r\n}", "token": "Attachments" }, { "expression": "if (!IsEmpty($feature.Description)) {\r\n return $feature.Description; //\"<\" + \"span style='text-decoration-line: underline; font-weight: bold;'>Description:<\" + \"/span> \" + $feature.Description;\r\n} else {\r\n return \"No Description Available\";\r\n}", "token": "Comments" }, { "expression": "return \"<\" + \"span style='font-size: 10px;'>To serve you better, please <\" + \"a href='mailto:Maps Feedback <\" + \"maps.feedback@mississauga.ca>?subject=About survey control monument \" + $feature.MONUMENT + \"'>contact us<\" + \"/a> with your questions or to report damage.<\" + \"/span>\";", "token": "Email" }, { "expression": "var horizontal = \"\";\r\nIf ($feature.MonType == \"CM\" || $feature.MonType == \"HCM\") {\r\n var coordinates = \"<\" + \"div><\" + \"span style='font-weight: bold;'>Latitude:<\" + \"/span> \" + Replace($feature.Latitude, \"^\", \"°\") + \"<\" + \"/div>\";\r\n coordinates += \"<\" + \"div><\" + \"span style='font-weight: bold;'>Longitude:<\" + \"/span> \" + Replace($feature.Longitude, \"^\", \"°\") + \"<\" + \"/div>\";\r\n \r\n var scale = \"<\" + \"div><\" + \"span style='font-weight: bold;'>Scale Factor:<\" + \"/span> \" + Text($feature.ScaleFactor) + \"<\" + \"/div>\"; \r\n\r\n var h_order = \"<\" + \"div><\" + \"span style='font-weight: bold;'>Horizontal Order:<\" + \"/span> \" + IIf(IsEmpty($feature.HorizontalOrder), \"N/A\", DomainName($feature, 'HorizontalOrder')) + \"<\" + \"/div>\";\r\n\r\n horizontal = coordinates + scale + h_order + \"<\" + \"br/>\";\r\n}\r\n\r\nvar vertical = \"\";\r\nIf ($feature.MonType == \"CM\" || $feature.MonType == \"BM\") {\r\n var elevation = \"<\" + \"div><\" + \"span style='font-weight: bold;'>Elevation:<\" + \"/span> \" + Text($feature.Elevation) + \" m<\" + \"/div>\";\r\n\r\n var v_order = \"<\" + \"div><\" + \"span style='font-weight: bold;'>Vertical Order:<\" + \"/span> \" + IIf(IsEmpty($feature.VerticalOrder), \"N/A\", DomainName($feature, 'VerticalOrder')) + \"<\" + \"/div>\";\r\n\r\n var datum = \"<\" + \"div><\" + \"span style='font-size: 8px;'>VERTICAL DATUM: CANADIAN GEODETIC DATUM, 1928 (NOT 1978 SOUTHERN ONTARIO READJUSTMENT<\" + \"/span><\" + \"/div>\";\r\n\r\n vertical = elevation + v_order + datum + \"<\" + \"br/>\";\r\n}\r\n\r\nreturn horizontal + vertical;", "token": "GeoData" }, { "expression": "return DomainName($feature, 'HorizontalOrder');", "token": "HOrderDesc" }, { "expression": "var last = \"<\" + \"span style='text-decoration-line: underline; font-weight: bold;'>Last Confirmed:<\" + \"/span> \";\r\nif (!IsEmpty($feature.LastFound)) {\r\n last += Text(ToUTC(Date($feature.LastFound)), \"Y-MM-DD\"); //Text(ToUTC($feature.LastFound), \"MMMM DD, Y\");\r\n} else {\r\n last += \"Unknown\";\r\n}\r\nreturn last;", "token": "LastFoundUTC" }, { "expression": "return Decode($feature.MonType, 'BM', 'Benchmark', 'CM', 'Control Monument', 'HCM', 'Horizontal Control Monument', $feature.MonType);\r\n//DomainName($feature, 'MonType');", "token": "MonDesc" }, { "expression": "var searchDist = 2000;\r\nvar searchUnit = \"m\";\r\n\r\nvar monuments = FeatureSetByName($map, \"Survey Control (Existing)\");\r\nreturn \"Count is \" + Text(Count(monuments));\r\nvar monEligible = Decode($feature.MonType, \"CM\", \" And MonType = 'CM'\", \"HCM\", \" And MonType In ('HCM', 'CM')\", \"BM\", \" And MonType In ('BM', 'CM')\", \"\");\r\nvar monFilter = Filter(monuments, \"Monument <> '\" + $feature.Monument + \"' And Status = 1\" + monEligible);\r\nreturn \"Count is \" + Text(Count(monFilter));\r\nvar monNearby = Intersects(monFilter, Buffer($feature, searchDist, searchUnit));\r\n\r\nvar dct = {};\r\nvar monDist;\r\nvar key;\r\nvar val;\r\nfor (var mon in monNearby) {\r\n monDist = DistanceGeodetic($feature, mon, searchUnit);\r\n key = Text(monDist, \"0000.00\"); // set the key to the formatted distance, so keys are in ascending order\r\n val = \"<\" + \"li>\" + mon.MonType + \" \" + mon.Monument + \" (<\" + \"a href='https://www6.mississauga.ca/BMHCM/\" + Decode(mon.MonType, \"BM\", \"Benchmarks\", \"HorizontalControl\") + \"/\" + mon.Monument + \".pdf'>PDF<\" + \"/a>) is ~\" + Round(monDist, 0) + \" \" + searchUnit + \" away<\" + \"/li>\";\r\n // In case of identical distances, append an extra digit to the end to create a unique key\r\n for (var i = 0; i < 3; i++) {\r\n if (HasKey(dct, key)) {\r\n key += Text(i);\r\n }\r\n }\r\n dct[key] = val;\r\n}\r\n\r\nvar results = \"<\" + \"br/><\" + \"span style='font-weight: bold; text-decoration-line: underline;'>Closest Compatible Monuments:<\" + \"/span>\";\r\nvar mx = Min([Count(monNearby), 4]);\r\nif (mx > 0) {\r\n results += \"<\" + \"ol style='margin-top: 5px; margin-bottom: 0px;' type='1'>\";\r\n var i = 0;\r\n for (var key in dct) {\r\n if (i < mx) {\r\n var val = dct[key];\r\n results += val;\r\n }\r\n i++;\r\n }\r\n results += \"<\" + \"/ol>\";\r\n} else {\r\n results += \"<\" + \"br/>None within a \" + Text(searchDist, \"#,###\") + \" \" + searchUnit + \" radius.\";\r\n}\r\n\r\nreturn results;", "token": "Nearest" }, { "expression": "return $feature.Monument + IIf($feature.Status == 0 || IsEmpty($feature.Status), \"\", \" (<\" + \"a href='https://www6.mississauga.ca/BMHCM/\" + Decode($feature.MonType, \"BM\", \"Benchmarks\", \"HorizontalControl\") + \"/\" + $feature.Monument + \".pdf'>PDF<\" + \"/a>)\");", "token": "PDF" }, { "expression": "var result = \"\"; if ($feature.MonType == \"CM\" || $feature.MonType == \"HCM\") { result = \"<\" + \"div><\" + \"span style='text-decoration-line: underline; font-weight: bold;'>Scale Factor:<\" + \"/span> \" + $feature.ScaleFactor + \"<\" + \"/div>\"; } return result;", "token": "Scale" }, { "expression": "return DomainName($feature, 'VerticalOrder');", "token": "VOrderDesc" } ], "isDynamic": false, "dynamicDefinition": null, "themeSettings": [ { "themeID": "0", "visible": true }, { "themeID": "1", "visible": true, "initiallyVisible": false } ], "tileLevelLimits": [] } ], "tables": [], "fullExtent": { "xmin": 595280.20710000023, "ymin": 4813345.4001, "xmax": 617731.87210000027, "ymax": 4846074.6731, "spatialReference": { "wkid": 26917 } }, "spatialReference": { "wkid": 26917 }, "properties": [], "extensions": [] }