Select to view content in your preferred language

Error in fetching asset title fields. Error: token required

226
0
07-09-2020 04:17 AM
by Anonymous User
Not applicable

I am working on developing the Adopt-A-Catch Basin OOTB solution from ESRI. I got the web map set up, configured the AuthGP service, and am now in WAB developer. I am able to sign up in app with a valid email (creates a record in my registered user table, but if try to use the Login function, I receive the error.

I opened the AuthGP arcpy and searched and found this:

def get_asset_titlefields(asset_layer, wconfig):
""" read widget configuration to get nicknamefield
# read popup title parameter
# read layer info to find display_field
# read layer info to find objectid field
# return dict of titlefields
"""
# get popup title
try:
asset_titlefields = {}
asset_titlefields["popupfields"] = []
asset_titlefields["popuptitle"] = ''
asset_titlefields["layername"] = asset_layer.properties.name
try:
if len(asset_popup_config) > 0:
popupfields = findall(r"\{(.*?)\}", asset_popup_config)
asset_titlefields["popupfields"] = popupfields
asset_titlefields["popuptitle"] = asset_popup_config
except Exception as e:
send_msg("Error in fetching configured popup title. Error: {0}".format(str(e)), "error")

# these are always present
asset_titlefields["nicknamefield"] = wconfig.get("nickNameField")
asset_titlefields["displayfield"] = asset_layer.properties.displayField
#asset_titlefields["objectidfield"] = asset_layer.objectIdField
asset_titlefields["objectidfield"] = asset_layer.properties.fields[0].name

return asset_titlefields
except Exception as e:
send_msg("Error in fetching asset title fields. Error: {0}".format(str(e)), "error")
return False

screenshot

0 Kudos
0 Replies