With ArcGIS Enterprise 10.7.1, have a web map with a polygon layer, and an App created using the Web AppBuilder with that web map. The polygon layer has a custom attribute defined with following Arcade code. When open attributes table in the App, that polygon layer can't show attributes but got stuck.
//
function MetersToLatLon(mx, my) {
var originShift = 2.0 * PI * 6378137.0 / 2.0;
var lon = (mx / originShift) * 180.0;
var lat = (my / originShift) * 180.0;
lat = 180.0 / PI * (2.0 * Atan( Exp( lat * PI / 180.0)) - PI / 2.0);
return [lat, lon];
}
var pnt_centr = Centroid($feature);
var latlon = MetersToLatLon(pnt_centr.x, pnt_centr.y);
var result = Round(latlon[0], 6) + "," + Round(latlon[1], 6);
var surveyUrl="https://survey123.arcgis.app/?itemID=*****"+"¢er="+result;
return surveyUrl;