BLOG
|
@IsmaelChivite , @ZacharySutherby , I got the same problem as descrive in this old post: https://community.esri.com/t5/arcgis-survey123-questions/assistance-resolving-error/td-p/851272 I got the same massage when trying to save an edition of the form on Dashboard. Survey contains errors: 1. Press here to navigate to each error. I have tried the form on the Phone ans Web App, nothing wrong. I have no repeats or any complex survey. On the Console, there's any error on Network activities... Any help or idea in this issue?
... View more
12-11-2020
09:57 AM
|
1
|
0
|
1328
|
POST
|
Hello, For the past few weeks, we have been working in the field to raise the assets of a specific sector. We did a Survey123 to do these field work and all function very well. Now external teams need to validate the identified information . To get there, we did a Dashboard where we embedded the form. When trying to edit it we got this error: "Survey contains errors: 1. Press here to navigate to each error" A copy of the form was made, but always associated with the same AGOL service (field work form). This form has been modified to display 6 fields to be edited as needed on Dashboard. The copy of the modified form works well on the S123 app, on an iPhone app and on the Desktop app. Any idea why I have this erreur?
... View more
11-30-2020
07:51 AM
|
0
|
0
|
60
|
POST
|
Hello We are preparing a project whose aim is to validate the presence or absence of availability linked to an area (Cercles). An area can contain several availabilities, but when selecting it we want to validate these availabilities. In other words, in a group of polygons in the same service, for a selected element we want to know which polygons are intersected. This operation must be done in the Survey123 app and we try to proceed with JS functions. We tested the JS example well using a point and it works. But how to use it with polygons? I'm not a programmer, and my fellow programmers are struggling with this problem. Is it feasible to think of being able to select a polygon and have as answer a list of intersected polygons? Do you have examples or improvements to put on our code? Any ideas?! Thank you! function buildFormData(data, boundary) { let body = "" for (let key in data){ // console.debug(key) body += "--" + boundary + "\r\nContent-Disposition: form-data; name=" + key + "\r\n\r\n" + (isObject(data[key]) ? JSON.stringify(data[key]) : data[key]) + "\r\n" } body += "--" + boundary + "--\r\n" return body } // echo provides a basic check that JavaScript is working correctly function echo(input) { return input.toString(); } function isObject(obj) { return (typeof obj === "object" || typeof obj === "function") && obj !== null; } function buildFormData(data, boundary) { let body = "" for (let key in data){ // console.debug(key) body += "--" + boundary + "\r\nContent-Disposition: form-data; name=" + key + "\r\n\r\n" + (isObject(data[key]) ? JSON.stringify(data[key]) : data[key]) + "\r\n" } body += "--" + boundary + "--\r\n" return body } function encodeQueryParams(data) { const ret = []; for (let d in data) ret.push(encodeURIComponent(d) + "=" + encodeURIComponent(data )); return ret.join("&"); } function callEsriJsonApiSync(url, token, method = "GET", payload = null) { let boundary = "nVenJ7H4puv" let responseAsJson = null; let queryParams = null; let formData = null; const requestFormat = { f: "pjson" }; if (method === "GET") { queryParams = Object.assign( Object.assign(requestFormat, { token: token }), payload ); url = url + "?" + encodeQueryParams(queryParams); console.debug(url) } else { url = url + "?" + encodeQueryParams({ token: token }); // formData = new FormData(); // Object.keys(Object.assign(payload, requestFormat)).forEach(function (k) { // let value = isObject(payload ) ? JSON.stringify(payload ) : payload ; // formData.append(k, value); // }); formData = buildFormData(Object.assign(payload, requestFormat), boundary) } let xhr = new XMLHttpRequest(); xhr.open(method, url, false); if (method === 'POST') { xhr.setRequestHeader("Content-Type", "multipart/form-data; boundary=" + boundary) xhr.setRequestHeader("Content-Length", formData.length) } xhr.send(formData); if (xhr.status === 200) { responseAsJson = JSON.parse(xhr.response); if (!responseAsJson.error) { // console.debug("response", responseAsJson); return responseAsJson; } console.error(responseAsJson.error); return null; } else { console.error(xhr.status); return null; } } // Query a feature layer and returns the feature that intersects the location //function featureByLocation(layerURL, location, token) { function featureByLocation(F_Poste) { // Output value. Initially set to an empty string (XLSForm null) let outValue = ""; let geoValue = ""; let token = "TOKEN HERE"; let layerURL = "URL-SERVICE HERE"; let poste = "125-12";//F_Poste; if (poste == null || poste === "") { // The function can't go forward; exit with the empty value return "Il n'y a pas de poste."; } let firstUrl = "https://services.arcgis.com/DN2fPfpggEPlLhP6/arcgis/rest/services/Formulaire1620_100_AlexisNihon_Stantec_formulaire/FeatureServer/0/query" let firstPayload = { geometryType: "esriGeometryEnvelope", spatialRel: "esriSpatialRelIntersects", outFields: "*", returnGeometry: "true", where: "1=1" }; let firstResult = callEsriJsonApiSync(firstUrl, token, "GET", firstPayload); // console.info('firstResult => ', firstResult) return firstResult let buffer = firstResult.features[0].geometry let secondPayload = { geometryType: "esriGeometryPolygon", spatialRel: "esriSpatialRelIntersects", outFields: "*", returnGeometry: "false", where: "1=1", geometry: buffer, returnCountOnly: "true" }; let secondResult = callEsriJsonApiSync(firstUrl, token, "POST", secondPayload); //console.info('secondResult => ', secondResult) let nb = secondResult.count //console.info(nb) return nb; }
... View more
10-28-2020
05:59 PM
|
0
|
1
|
91
|
POST
|
Thank you for your replay! So I got this table with coordinates that help me buid my point layers (Hydrants). Each of this points has unique Id's. In the other hand I had this other table with multiples accessories (Hydrant components) witch had they unique ID's and also the ID of the point layer. So various accessories can be related to 1 hydrant (1:M). I built the relationship with this unique ID. Know, the client is collecting new hydrants and adding new accessories. The problem is that this new points have the same ID (Default value= 9999). When new accessories are added, all of them have the 9999 default code who's the related ID. I'm trying to find a way to make a random default value, take the value of the object ID or concatenate 2 values together when creating the point of the new Hydrant. I need an different ID for any new created point. Tested Solution: Arcade it's creating a new field, I didin't found any examples to automatically calculate the field one new entries are done. Any ideas?
... View more
10-20-2020
10:02 AM
|
0
|
2
|
46
|
POST
|
Hello all, Here's my problem. We have a point layer in Collector which is currently in use. The customer gave us a list of accessories attached to a point layer. We proceeded to the creation of a relational table between the points and a table. Everything is working. The point ID is linked to the table and inspections can take place. Where we have a problem is when a new point is created. All these new points have the same ID and the relationship is no longer made.All new entry has the same value. Can I use the calculate method in this field? Can it be automatically concatenated with the objectID? Other solutions to create a random ID on the same field used to create the relationship? Need to find a solution... it's start to be a very long process manually. Thank you. Cheers!
... View more
10-19-2020
06:43 PM
|
0
|
4
|
104
|
POST
|
Hello there, I konw, but almost 2 years after the last comment I wish to get that JS to referencing a separate feature service in Survey123. At this moment we are using a JS who's extracting the data from another hosted service and it's working (almost) like a charm. Now our client needs to go offline and guess what… the JS can go that way. So I tried to get more infos on the link posted by @ Johnathan Hasthorpe but there again it's going to the general Update to Survey123 Beta Website and can't find the original post. Can you guys tell me if this JS still out there? Any link to found it? Thanks for any help!
... View more
09-12-2020
12:13 PM
|
0
|
1
|
41
|
POST
|
Hello Philip, Thanx for your reply. Our form contains several repeats to determine compliant or non-compliant actions. For each repeat, we have an indicator that identifies the non-compliant actions (ind_NC_xx = 1 or 0). Outside the repeat, we sum them and apply them to various other calculations. Since repeats are used with minimal appearance, the starting value of the sum is empty. We must therefore ensure that the empty value is 0 if not the value of the sum (if (string-length ($ {gestion_null_nc_XX})> 0, $ {gestion_null_nc_elements_XX}, 0). When we test the form in Connect 3.10, the sum of the variables is done correctly, as are the calculations of the scores that we want to apply. On the other hand, when testing the forms already issued on the IOS or Android application in the InBox, th e changes made are not calculated and the data already issued are erased. All data is hosted in an AGOL service. Should we use the Calculate in the type to trigger a score calculation? Are the options in connect that can have an impact? Any idea? Many Thanx for any help!
... View more
08-11-2020
05:16 AM
|
0
|
1
|
52
|
POST
|
Hello, What is the best approach to edit forms in the inbox? We have several repeat and indicators are used to calculate 1 very precise state. We sum these indicators outside the repeat, and then use theme to calculate other fonctions,but when we modify them in the inbox, it resets to 0 on the DB and no modification is made. Are there specific parameters to adjust in the connect options? Thanks for any help!
... View more
08-09-2020
03:02 PM
|
0
|
3
|
136
|
POST
|
Hello We have been using Collector for a very long time and use it in all kinds of projects. Not very long ago, we had projects where we had to collect 1 points, comments and 1 photo. The photo was used to create a register with name, coordinates and direction of the photo. Everything works perfectly. Now, we have to do this type of project and take 4 photos on 4 cardinal points (north, east, south, west). To avoid the field teams having to write the cardinal point of each photo, we wanted to use the direction present in the EXIF file of each photo. But surprise, the direction of only the first photo is saved, the rest are still north (0 degrees). Is this normal behavior, or some other parameter must be set up under Collector? The tests were done under an iPhone 8 and Collector 20.2.2.
... View more
08-09-2020
02:50 PM
|
0
|
0
|
77
|
Online Status |
Offline
|
Date Last Visited |
yesterday
|