|
POST
|
I am using the Public Information Center for an application, where I have set the coded values for my status field as assigned, unassigned, and closed....the application intermittently uses the assigned value when placing a point on the map, while it should remain as unassigned. The application was working until the feature service was overwritten with the same data architecture... What might cause this behavior??
function CreateServiceRequest() {
if (map.getLayer(tempServiceRequestLayerId).graphics.length == 0) {
ShowSpanErrorMessage("spanServiceErrorMessage", messages.getElementsByTagName("mapLocation")[0].childNodes[0].nodeValue);
return false;
}
if (ValicateRequestData()) {
ShowLoadingMessage("Creating Service Request...");
var mapPoint = map.getLayer(tempServiceRequestLayerId).graphics[0].geometry;
var date = new js.date();
var serviceRequestAttributes = {
"Address": dojo.byId('txtCustomerAddress').value.trim(),
"NAME": dojo.byId('txtName').value.trim(),
"Assignee": dojo.byId('txtAssignee').value.trim(),
"PHONE": dojo.byId('txtPhone').value.trim(),
"EMAIL": dojo.byId('txtMail').value.trim(),
"STATUS": "UNASSIGNED",
"REQUESTDATE": date.utcMsFromTimestamp(date.localToUtc(date.localTimestampNow()))
};
... View more
11-07-2014
04:10 PM
|
0
|
2
|
665
|
|
POST
|
Hi Jake, Thanks for your response, how does this work with mobile devices? Say if a public user edits a feature (submits request) how is this stored? Also if there is a Collector application working in parallel with the JS application, can this feature class maintain two creator fields? One in collector with the organizational user, and one that is public.
... View more
11-04-2014
10:18 AM
|
0
|
1
|
724
|
|
POST
|
I have a feature service with apply edits capabilities enabled; is it possible to create an active directory with users and whenever a user makes a change in the feature service link that change to the database. This is akin to an ArcGIS Online web-map; where if a user makes a change to a feature service; the created user is recorded into the DB. I am however using ArcGIS JavaScript API.
... View more
11-03-2014
03:00 PM
|
0
|
3
|
2717
|
|
POST
|
This is the solution, however my elements are still being moved around on the page when using your format. Should anything be changed in my CSS? EDIT: The DIV element takes up half of the page and incidentally covers my map.
... View more
10-23-2014
11:54 AM
|
0
|
0
|
1642
|
|
POST
|
This seems like a likely solution, however my footer is taking up half of my page and my header disappears. body class="claro" onkeydown="if (event.keyCode==dojo.keys.TAB) { if (dijit.byId('dialogLoadMessage').open || dijit.byId('dialogAlertMessage').open) {return event.keyCode!=dojo.keys.TAB;}}"> <div id="divMainContainer" dojotype="dijit.layout.BorderContainer" design="headline" gutters="false" style="width: 100%; height:100%; position: absolute"></div> <div id="map" class="map" region="center" dojotype="dijit.layout.ContentPane"></div> <div id="footer" data-dojo-type="dijit.layout.ContentPane" data-dojo-props="region:'bottom'" style="height:100px;width:100px"></div></div> Make a selection from any of these combo boxes:<br/> <table> <tr> <td> <select id="Select1" dojotype="dijit.form.ComboBox" autocomplete="true" hasdownarrow="true" style="width: 175px; background-color:Black; font:black;color: white;"> </td> <td> <select id="Select2" dojotype="dijit.form.ComboBox" autocomplete="true" hasdownarrow="true" style="width: 175px; background-color:Black; font:black;color: white;"> </td> <td> <select id="Select3" dojotype="dijit.form.ComboBox" autocomplete="true" hasdownarrow="true" style="width: 175px; background-color:Black; font:black;color: white;"> </td> <td> <select id="Select4" dojotype="dijit.form.ComboBox" autocomplete="true" hasdownarrow="true" style="width: 175px; background-color:Black; font:black;color: white;"> </td> <td> <select id="Select5" dojotype="dijit.form.ComboBox" autocomplete="true" hasdownarrow="true" style="width: 175px; background-color:Black; font:black;color: white;"> </td> <td> <select id="Select6" dojotype="dijit.form.ComboBox" autocomplete="true" hasdownarrow="true" style="width: 175px; background-color:Black; font:black;color: white;"> </td> </tr> <tr> <td> <select id="Select7" dojotype="dijit.form.ComboBox" autocomplete="true" hasdownarrow="true" style="width: 175px; background-color:Black; font:black;color: white;"> </td></div>
... View more
10-23-2014
09:29 AM
|
0
|
0
|
1642
|
|
POST
|
Hi Steve, My goal is to create a footer or nav bar towards the bottom of the page which will contain 6 columns of 11 combo boxes. Here is the more of my HTML without any nav bar or footer element. For whatever reason my HTML highlighting is not appearing. <body class="claro" onkeydown="if (event.keyCode==dojo.keys.TAB) { if (dijit.byId('dialogLoadMessage').open || dijit.byId('dialogAlertMessage').open) {return event.keyCode!=dojo.keys.TAB;}}"> <div id="divMainContainer" dojotype="dijit.layout.BorderContainer" design="headline" gutters="false" style="width: 100%; height: 100%; position: relative"> <div id="map" class="map" region="center" dojotype="dijit.layout.ContentPane"</
... View more
10-22-2014
12:48 PM
|
0
|
0
|
1642
|
|
POST
|
Using ArcGIS JS API, what is the proper method of embedding a combo box into the footer? Footer ends up at top of page with a strange box element next to my combo box.
<table>
<td>
<div id="footer" class="roundedCorners" data-dojo-type="dijit.layout.ContentPane" data-dojo-props="region:'bottom'">
<td align="left" style="width: 70%">
<select id="Select1" dojotype="dijit.form.ComboBox" autocomplete="true" hasdownarrow="true"
style="width: 250px; background-color:Black; font:black; color: white;" onchange="ValidateRequestType">
</div></td></table>
#footer {
border: solid 1px #7EABCD;
background-color:white;color:peru;font-size:10pt; text-align:center; height:250px; width: inherit;
}
... View more
10-22-2014
10:02 AM
|
0
|
8
|
2095
|
|
POST
|
I would ultimately like to query my feature layer for other fields when a specific field is chosen from my feature layer. If my request type is chosen as E-WASTE, my function to populate that drop down is below
function PopulateRequestTypes(serviceRequestLayerFields) {
var serviceRequestFields
for (var i = 0; i < serviceRequestLayerFields.length; i++) {
if (serviceRequestLayerFields.name == serviceRequestLayerInfo.RequestTypeFieldName) {
serviceRequestFields = serviceRequestLayerFields.domain.codedValues;
break;
}
}
var serviceRequestTypes = { identifier: "id", items: [] };
for (var i = 0; i < serviceRequestFields.length; i++) {
serviceRequestTypes.items = { id: serviceRequestFields.name, name: serviceRequestFields.name };
}
var serviceRequestStore = new dojo.data.ItemFileReadStore({ data: serviceRequestTypes });
dijit.byId('cbRequestType').attr('store', serviceRequestStore);
}
This is my function to add my feature layer
function AddServiceRequestLayerOnMap() {
var serviceRequestLayer = new esri.layers.FeatureLayer(serviceRequestLayerInfo.LayerURL, {
mode: esri.layers.FeatureLayer.MODE_SNAPSHOT,
outFields: [serviceRequestLayerInfo.OutFields],
id: serviceRequestLayerInfo.Key,
displayOnPan: false,
visible: false
});
map.addLayer(serviceRequestLayer);
I would like my query task to see that I have selected E-WASTE and populate my combo box with E-WASTE subtypes I did a bit of digging and retrieved this query task example which essentially populates a combo box from a feature query. My question is how do I link the two.
dojo.require("esri.map");
dojo.require("esri.tasks.query");
dojo.require("dojo.parser");
dojo.require("dijit.form.ComboBox");
dojo.require("dojo.data.ItemFileReadStore");
function populateList(results) {
//Populate the ComboBox with unique values
var zone;
var values = [];
var testVals = {};
//Add option to display all zoning types to the ComboBox
values.push({
name: "ALL"
})
//Loop through the QueryTask results and populate an array
//with the unique values
var features = results.features;
dojo.forEach(features, function(feature) {
zone = feature.attributes.webappfield;
if (!testVals[zone]) {
testVals[zone] = true;
values.push({
name: zone
});
}
});
//Create a ItemFileReadStore and use it for the
//ComboBox's data source
var dataItems = {
identifier: 'name',
label: 'name',
items: values
};
var store = new dojo.data.ItemFileReadStore({
data: dataItems
});
dijit.byId("mySelect").set('store', store);
}
function init() {
queryTask = new esri.tasks.QueryTask("http://localhost:6080/arcgis/rest/services/webAppService/MapServer/0");
query = new esri.tasks.Query();
query.returnGeometry = false;
query.outFields = ["webappfield "];
query.where = "webappfield <> ''";
queryTask.execute(query, populateList);
}
dojo.addOnLoad(init);
... View more
10-21-2014
01:16 PM
|
0
|
0
|
1545
|
|
POST
|
My goal is to create an application where services can only be accessed by those with certain permissions, much akin to ArcGIS Online web-maps, however I would like it so that when a user pings the URL where the map services is being consumed, that a log-in box appears that references ArcGIS Server?
... View more
10-20-2014
10:57 AM
|
0
|
1
|
1650
|
|
POST
|
Is this possible; say if I enter my host:port/webappbuilder/webappnumber and save my edits? I have Web App Builder installed on a server machine but would like to edit on a client.
... View more
10-15-2014
11:30 AM
|
0
|
1
|
1861
|
|
POST
|
Robert, Please follow me on GeoNet and I will inbox you...I connected with ESRI support regarding the matter and I think that they can offer further assistance from here. I greatly appreciate your help.
... View more
10-15-2014
11:25 AM
|
0
|
0
|
979
|
|
POST
|
I see, The issue is that two new combo boxes are created. Not sure what causes this, I am referencing two cb boxes that are present in the application. I think the statement in order to retrieve my request type should be data specific and iterate through the layer to grab those fields....I really appreciate your assistance Robert but this is proving to be a bit more difficult than I thought initially. EDIT: I would like to parse through the applications current feature layer and return the new items in existent cb boxes. The feature layer maintains the request type and there are description cb boxes that are there to link the two...
... View more
10-15-2014
10:22 AM
|
0
|
2
|
979
|
|
POST
|
Hi Robert, I am eternally grateful for your assistance, this seems like the correct solution, I am just having trouble applying to my existing code, thank you so much. My only question is at line 47 claro is already defined in my HTML, so I am having a bit of trouble seeing where I'd drop that block, especially if my commodities are already defined and referenced from my feature layer.
... View more
10-15-2014
09:05 AM
|
0
|
4
|
979
|
|
POST
|
Robert, Your solution is great, however I think that there was a bit of confusion. Please see the screen shot. I am currently passing a layer with several request types. I would like to populate the description combo boxes with related request types, so I am not necessarily creating new combo boxes as your example indicates, only populating my description cb boxes with hard coded parameters...i.e. copier, etc. The code that I am working with now populates each of the combo boxes based on the feature layer domain. Since these descriptions are not coming from my feature layer, I gather that this portion of the code is correct, but I am still missing something to pass to the description combo boxes.
function(
dom, on, parser){
parser.parse();
(dijit.byId("cbRequestType")).on('change',function(MFValue){
if (MFValue == 'E-WASTE') {
dijit.byId("Description1").set('value', 'Copy Machine');
} else if (MFValue == '...') {
dijit.byId('Description1').set('value', 'Printer');
}
});
});
... View more
10-14-2014
04:37 PM
|
0
|
6
|
979
|
|
POST
|
Hi Robert, This solution works great, I will try it in my application and give you an update, my initial errors I suppose came from the fact that my syntax was incorrect. I really appreciate your assistance.
... View more
10-14-2014
02:52 PM
|
0
|
0
|
979
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 03-16-2017 02:33 PM | |
| 1 | 01-18-2022 07:40 AM | |
| 1 | 04-28-2021 09:29 AM | |
| 1 | 10-24-2016 12:07 PM | |
| 1 | 04-28-2016 09:12 AM |
| Online Status |
Offline
|
| Date Last Visited |
01-18-2022
03:08 PM
|