Hello! I am trying to write a simple script that will batch create assignments from an existing feature class. My existing feature class is using the GlobalID field as a primary key for linking to other data tables. As a result I want to use the GlobalID field. When I run my snippet of code in Jupyter Notebook it gives me an error:
TypeError: __init__() got an unexpected keyword argument 'workorderid'
Here is my code:
I did try to use other fields such as CustomerID and it threw the same error. Very maddening! Any hints or clues on what I am doing wrong?
Solved! Go to Solution.
You need to use the correct argument name of work_order_id. The assignment class is documented here:
https://developers.arcgis.com/python/api-reference/arcgis.apps.workforce.html#assignment
You need to use the correct argument name of work_order_id. The assignment class is documented here:
https://developers.arcgis.com/python/api-reference/arcgis.apps.workforce.html#assignment