POST
|
Hi All, Not expert into map making, I am trying to publish on my ArcgiServer 10.3.1 several kind of layer types as a test of my Javascript application. I have made 8 layers for that, with Arcmap 10.3.1, and they are very simple with few data (see images below). But the server does not publish all objects, nor all layers. Let me know if you need more information, as long as I used simplest way to configure my publications and server. I have created different types of layers in arcmap from new feature class on my.gdb : all types except multipatch. This screen capture shows how it appears into argis desktop : See image below how it comes out when displayed on a web page using simple API javascript with code lines like : new esri.layers.FeatureLayer( "http://win2:6080/arcgis/rest/services/Siv/MapServer/0", {mode: esri.layers.FeatureLayer.MODE_AUTO,outFields: ["*"]}); ... same for each service indexes... It should work fine as it does with other layers, but I might not have configured something in service parameters on server side, or in arcgis desktop at publishing time ? Regards, Chris.
... View more
04-19-2016
05:38 AM
|
0
|
0
|
2048
|
POST
|
Right, I can change on server. I've even tried 200 days : For this I had to configure the server on 288.000 minutes on the short-live token, implying to set 200 days too on the long-term part. BUT, the client is supposed to fit the server configuration and not the opposit ! Which means that if we have a customer using an arcgis server configured with ONLY long live token (e.g. long live token set to 5 days, short-live token set to 0), the REST API seems not to be able to get any valid token. It seems that in the ARCGis Server REST API there is no way to choose between long/short token types.
... View more
03-04-2016
02:19 AM
|
0
|
0
|
762
|
POST
|
Well, this code works fine. I set parameters : "username", "password", "client", "referer", and "expiration" in minutes. I send the request to our arcgis server. And our server is returning a good usable short-term token, and a correct expiration date. But the point is that I don't see anywhere to tell the server that I want a long-term token ? Regards.
... View more
02-24-2016
12:26 AM
|
0
|
3
|
762
|
POST
|
Hi all, We have a client javascript app that based on a java n-tier. For layers security pupose, java part calls arcgis server via REST API to get an ident. token this way : url = new URL( strUrl ); HttpURLConnection conn; conn = (HttpURLConnection)url.openConnection(); conn.setRequestMethod( "POST" ); conn.setRequestProperty( "Accept-Charset", "UTF-8" ); conn.setRequestProperty( "Content-type", "application/x-www-form-urlencoded" ); conn.setRequestProperty( "Accept", "application/json" ); conn.setDoOutput( true ); conn.setDoInput( true ); BufferedWriter bw = new BufferedWriter( new OutputStreamWriter( ( conn.getOutputStream() ), "UTF-8" ) ); String params = "username" + "=" + URLEncoder.encode( user, "UTF-8" ); params += "&"; params += "password" + "=" + URLEncoder.encode( pW, "UTF-8" ); params += "&"; params += "client" + "=" + URLEncoder.encode( "referer", "UTF-8" ); params += "&"; params += "referer" + "=" + URLEncoder.encode( referer, "UTF-8" ); params += "&"; params += "expiration" + "=" + URLEncoder.encode( duration, "UTF-8" ); params += "&"; params += "f" + "=" + URLEncoder.encode( "json", "UTF-8" ); bw.write( params ); bw.flush(); bw.close(); if( conn.getResponseCode() == HttpURLConnection.HTTP_OK ) //here we go with the returned TOKEN We pass the returned token to the javascript client app which is init with a "esri.id.initialize(..)" and it works fine. But it seems that in this way we only generate short-lived tokens. How to generate long-live tokens with the arcgis server API REST ? regards. Chris.
... View more
02-23-2016
09:18 AM
|
1
|
5
|
3232
|
POST
|
Ok I got it : And my 4 vertices polygons must be edited with a combinaison like this one : edToolbar.activate( Edit.SCALE | Edit.MOVE , ev.graphic, {"allowAddVertices":false, "allowDeleteVertices":false} ); In this way editions preserves rectangles.
... View more
02-13-2015
06:12 AM
|
0
|
0
|
443
|
POST
|
Hi All, Is there a way to edit a graphic rectangle the same way it is possible for polygons, using Edit class ? Instead of a rectangle I use graphic polygons and I can move 4 points around. OK. But I cant get to have it constrained to a simple rectangle at moving time, or even at the end of move. In a "vertex-move" event I tried to retrieve transformations to keep my polygon a rectangle but I failed in doing this because transformation from pixels (ev.transform.dx, ev.transform.dy) to map doesnt give a good result. Any idea ? Regards. Chris.
... View more
02-13-2015
03:31 AM
|
0
|
1
|
4038
|
Title | Kudos | Posted |
---|---|---|
1 | 02-23-2016 09:18 AM |
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|