Hi folks, I have an Arcade attribute expression puzzler.
A bit of background, I've created an attribute expression to display "Permit Numbers" from a related table in the feature service pop-up. My only problem is that I need to add the URL prefix and suffix to those numbers to create the hyperlink as well as a NewLine.
//code sample
//Attempt 2
//join field id
var id = $feature.ParcelID;
var relatedtable = FeatureSetById($datastore, "1");
var filtereddata = Filter(relatedtable, "ParcelID = @id");
var permits = []
var index = 0;
for (var permit in filtereddata) {
permits[index] = permit["PermitNumber"];
index++;
}
return Concatenate(permits, ',')
//result pop-up
| Permit Numbers | 2013-MSS-SWR-00211,EXC120338,EXC02-1861,EXC052208,2016-MSS-SWR-00488,13928,21394,2013-MSS-EXC-00009,2013-MSS-EXC-00305,2016-MSS-EXC-00742,2016-MSS-EXC-00743 |
//new format needed
https://asbuilts.ci.missoula.mt.us/scards/2013-MSS-SWR-00211.pdf
https://asbuilts.ci.missoula.mt.us/scards/EXC120338.pdf