Esri BUG on the FeatureLayer for Secured Services with a proxy page

480
0
03-01-2011 04:06 PM
JoseSousa
Esri Contributor
Dear ArcGIS Javascript API team,

I have secured the ArcGIS Server 10 SP1 services using the database authentication provided in the server manager and I am using a token and proxy page to provide the security mechanism to authenticate the services.

I have published a simple MXD with one single (point) layer using a symbology based on one single field as a FeatureServer. Everything is correct and it displays correctly in ArcGIS Javascript Viewer.

When using your own code (Editor sample) pointing to this layer I have noticed that it does not work.
When I click on a feature on the TemplatePicker it does not do anything. I cannot edit nothing ... the text "click to add a point" does not appear ...

I have debugged the code and it seems that the templates property of the FeatureLayer is null even though the JSON response contains it (see the JSON response below).

Can anyone provide me a workaround for this?

Thanks,
José

{"currentVersion":10.01,"id":1,"name":"CreateEvents","type":"Feature Layer","displayField":"TYPE","description":"","copyrightText":"","relationships":[],"geometryType":"esriGeometryPoint","minScale":0,"maxScale":0,"extent":{"xmin":18619948.9873,"ymin":-5774689.9247,"xmax":19779884.6405,"ymax":-4442710.911,"spatialReference":{"wkid":102100}},"drawingInfo":{"renderer":{"type":"uniqueValue","field1":"TYPE","field2" : null,"field3" : null,"fieldDelimiter":", ","defaultSymbol" : null,"defaultLabel":"\u003call other values\u003e","uniqueValueInfos":[{"value":"1","label":"Abandoned Car","description":"","symbol":{"type":"esriPMS","url":"AFE304E","imageData":"...something....=","contentType":"image/png","color" : null,"width":57.75,"height":57.75,"angle":0,"xoffset":0,"yoffset":0}},{"value":"11","label":"Suspicious Vehicles","description":"","symbol":{"type":"esriPMS","url":"FCBA5356","imageData":"...something...==","contentType":"image/png","color" : null,"width":57.75,"height":57.75,"angle":0,"xoffset":0,"yoffset":0}}]},"transparency":0,"labelingInfo" : null},"hasAttachments":false,"htmlPopupType":"esriServerHTMLPopupTypeAsHTMLText","objectIdField":"OBJECTID","globalIdField":"","typeIdField":"TYPE","fields":[{"name":"OBJECTID","type":"esriFieldTypeOID","alias":"Event ID","editable":false,"domain" : null},{"name":"TYPE","type":"esriFieldTypeSmallInteger","alias":"Event type","editable":true,"domain":{"type":"codedValue","name":"EventTypeDomain","codedValues":[{"name":"Abandoned Car","code":1},{"name":"Aggressive Driving ??? Boy Racer/Burnouts","code":2},{"name":"Aggressive/Drunk Behaviour","code":3},{"name":"Dumping Site","code":4},{"name":"Graffiti","code":5},{"name":"Kids Out Late","code":6},{"name":"Noise","code":7},{"name":"Other","code":8},{"name":"Property Damage","code":9},{"name":"Suspicious Person(s)","code":10},{"name":"Suspicious Vehicles","code":11}]}},{"name":"STATUS","type":"esriFieldTypeSmallInteger","alias":"Status of the event","editable":false,"domain":{"type":"codedValue","name":"EventStatusDomain","codedValues":[{"name":"Acknowledged","code":1},{"name":"Actioned","code":2},{"name":"Observed","code":3}]}},{"name":"USER_LOGIN","type":"esriFieldTypeString","alias":"User login","editable":false,"length":100,"domain" : null},{"name":"SYS_DATE","type":"esriFieldTypeDate","alias":"Date when the user registered the event","editable":false,"length":36,"domain" : null},{"name":"OBS_DATE","type":"esriFieldTypeDate","alias":"Date when the user observed the event","editable":true,"length":36,"domain" : null},{"name":"DESCRIPTION","type":"esriFieldTypeString","alias":"Description of the event","editable":true,"length":255,"domain" : null},{"name":"ATTACHMENT","type":"esriFieldTypeString","alias":"Attachment","editable":true,"length":50,"domain" : null}],"types":[{"id":1,"name":"Abandoned Car","domains":{},"templates":[{"name":"Abandoned Car","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":1,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":2,"name":"Aggressive Driving ??? Boy Racer/Burnouts","domains":{},"templates":[{"name":"Aggressive Driving ??? Boy Racer/Burnouts","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":2,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":3,"name":"Aggressive/Drunk Behaviour","domains":{},"templates":[{"name":"Aggressive/Drunk Behaviour","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":3,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":4,"name":"Dumping Site","domains":{},"templates":[{"name":"Dumping Site","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":4,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":5,"name":"Graffiti","domains":{},"templates":[{"name":"Graffiti","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":5,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":6,"name":"Kids Out Late","domains":{},"templates":[{"name":"Kids Out Late","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":6,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":7,"name":"Noise","domains":{},"templates":[{"name":"Noise","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":7,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":8,"name":"Other","domains":{},"templates":[{"name":"Other","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":8,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":9,"name":"Property Damage","domains":{},"templates":[{"name":"Property Damage","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":9,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":10,"name":"Suspicious Person(s)","domains":{},"templates":[{"name":"Suspicious Person(s)","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":10,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]},{"id":11,"name":"Suspicious Vehicles","domains":{},"templates":[{"name":"Suspicious Vehicles","description":"","drawingTool":"esriFeatureEditToolPoint","prototype":{"attributes":{"ATTACHMENT" : null,"TYPE":11,"STATUS":3,"USER_LOGIN" : null,"SYS_DATE" : null,"OBS_DATE" : null,"DESCRIPTION" : null}}}]}],"templates":[],"capabilities":"Query,Editing"}
0 Kudos
0 Replies